Project Structure
The recommended backend template is a collaborative task backend.
myapp/ package.json tsconfig.json .project.json .zeroapi-data/
zeroapi.config.ts zeroapi.schema.ts zeroapi.rules.ts zeroapi.server.ts
collections/ users.ts workspaces.ts memberships.ts projects.ts tasks.ts comments.ts
rules/ roles.ts users.rules.ts workspaces.rules.ts memberships.rules.ts projects.rules.ts tasks.rules.ts comments.rules.ts
queries/ workspace-summary.ts
triggers/ on-workspace-created.ts
crons/ daily-task-digest.tsDefinition Files
Section titled “Definition Files”zeroapi.config.ts defines project identity, local runtime options, and deploy defaults.
zeroapi.schema.ts registers collections and field definitions.
zeroapi.rules.ts registers collection access rules.
zeroapi.server.ts registers queries, triggers, and crons.
Local State
Section titled “Local State”.project.json links the folder to a ZeroAPI Cloud project.
.zeroapi-data/ stores local development runtime data.
Generated Runtime
Section titled “Generated Runtime”Collections become document API routes:
/workspaces/projects/tasks/commentsCustom queries live under:
/queries/*