Quickback Docs

Using the API

Overview of the API generated by Quickback. CRUD endpoints, filtering, batch operations, views, and custom actions.

When you run quickback build, Quickback generates a complete REST API from your definitions. This section covers how to use the generated endpoints.

Base URL

Generated endpoints use the contract selected in quickback.config.ts. The backward-compatible default is /api/v1/; projects with contract: { routes: "v2" } use /api/v2/ (and /auth/v2/ for Better Auth):

https://your-api.com/api/v1/{resource}

The examples below show the default v1 contract. Replace /api/v1 with /api/v2 when the project selects v2. The generated OpenAPI document is the authoritative path list for the compiled project.

The resource name is derived from the filename: jobs.ts → /api/v1/jobs.

Endpoint Overview

For each resource with export default defineTable(...):

MethodEndpointDescription
GET/api/v1/{resource}List records (paginated)
GET/api/v1/{resource}/:idGet single record
POST/api/v1/{resource}Create record
PATCH/api/v1/{resource}/:idUpdate record
DELETE/api/v1/{resource}/:idDelete record
POST/api/v1/{resource}/batchBatch create
PATCH/api/v1/{resource}/batchBatch update
DELETE/api/v1/{resource}/batchBatch delete

Moved routes (0.72)

Better Auth owns /auth/v1/*. Quickback's own routes there moved under the API base in 0.72 (plan 031 Q7), so a Better Auth upgrade or plugin cannot collide with them and a Cloudflare Access path rule can cover the operator plane in one prefix. The prefix follows contract.routes (/api/v2/… on v2).

Before 0.72Since 0.72Emitted when
GET /auth/v1/admin/list-organizationsGET /api/v1/operator/organizationscms.sysadmin or account.auth.admin
GET /auth/v1/admin/get-organization?organizationId=:idGET /api/v1/operator/organizations/:idsame
POST /auth/v1/admin/create-organizationPOST /api/v1/operator/organizationssame
POST /auth/v1/admin/set-organization-member { organizationId, userId, role }PUT /api/v1/operator/organizations/:id/members/:userId { role }same
POST /auth/v1/admin/remove-organization-member { organizationId, userId }DELETE /api/v1/operator/organizations/:id/members/:userIdsame
GET /auth/v1/organization/rosterGET /api/v1/organization/rosterauth.organizationRoster
GET /auth/v1/ses/statusGET /api/v1/auth/email-statusalways

Response bodies are unchanged. The old paths keep working through 0.72.x and are removed in 0.73.0:

  • The old GETs answer 308 Permanent Redirect to the new path (the query string is kept; get-organization?organizationId=X redirects to /operator/organizations/X).
  • The old POSTs cannot redirect, because two of them changed verb. They run the same handler as the new route.
  • Both add Deprecation: true and Link: <new path>; rel="successor-version", and the Worker logs [quickback] deprecated route <method> <path> once per isolate per path. Grep your logs for it before upgrading to 0.73.

The bundled CMS and Account SPAs call the new paths. The OpenAPI document lists GET /api/v1/auth/email-status (operationId getEmailStatus, marked x-quickback-auth-surface, so like every auth endpoint it stays out of the MCP catalogue unless agents.mcp.exposeAuthTools is on, where the tool auth__sesStatus is now auth__getEmailStatus); the aliases are not advertised. A feature or table that would mount over one of these routes (/api/v1/operator, /api/v1/auth, /api/v1/organization with the roster on) is a compile error.

ses/status note: after 0.73.0, an aws-ses project's vendored Better Auth plugin answers /auth/v1/ses/status itself, with a different body (provider: 'aws-ses', plus region and fromEmail). Use email-status.

Guides

On this page