@quickback-dev/cli 0.12.0 → 0.14.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (34) hide show
  1. package/dist/commands/create.d.ts.map +1 -1
  2. package/dist/commands/create.js +11 -3
  3. package/dist/commands/create.js.map +1 -1
  4. package/dist/docs/content.js +12 -12
  5. package/dist/docs/content.js.map +1 -1
  6. package/dist/index.js +1 -1
  7. package/dist/skill/docs/changelog.md +192 -1
  8. package/dist/skill/docs/compiler/config/auth.md +37 -0
  9. package/dist/skill/docs/compiler/definitions/access.md +164 -2
  10. package/dist/skill/docs/compiler/definitions/actions.md +145 -0
  11. package/dist/skill/docs/compiler/definitions/firewall.md +46 -0
  12. package/dist/skill/docs/compiler/definitions/index.md +2 -0
  13. package/dist/skill/docs/compiler/definitions/masking.md +11 -0
  14. package/dist/skill/docs/compiler/definitions/read.md +8 -7
  15. package/dist/skill/docs/compiler/definitions/views.md +100 -12
  16. package/dist/skill/docs/compiler/getting-started/full-example.md +12 -11
  17. package/dist/skill/docs/compiler/targets/hono-api/using-the-api/crud.md +1 -2
  18. package/dist/skill/docs/compiler/targets/hono-api/using-the-api/views-api.md +8 -13
  19. package/dist/templates/registry.d.ts.map +1 -1
  20. package/dist/templates/registry.js +14 -1
  21. package/dist/templates/registry.js.map +1 -1
  22. package/package.json +1 -1
  23. package/src/skill/docs/changelog.md +192 -1
  24. package/src/skill/docs/compiler/config/auth.md +37 -0
  25. package/src/skill/docs/compiler/definitions/access.md +164 -2
  26. package/src/skill/docs/compiler/definitions/actions.md +145 -0
  27. package/src/skill/docs/compiler/definitions/firewall.md +46 -0
  28. package/src/skill/docs/compiler/definitions/index.md +2 -0
  29. package/src/skill/docs/compiler/definitions/masking.md +11 -0
  30. package/src/skill/docs/compiler/definitions/read.md +8 -7
  31. package/src/skill/docs/compiler/definitions/views.md +100 -12
  32. package/src/skill/docs/compiler/getting-started/full-example.md +12 -11
  33. package/src/skill/docs/compiler/targets/hono-api/using-the-api/crud.md +1 -2
  34. package/src/skill/docs/compiler/targets/hono-api/using-the-api/views-api.md +8 -13
@@ -133,6 +133,7 @@ export default defineAction({
133
133
  | `allowRawSql` | No | Explicit compile-time opt-in for raw SQL in execute code |
134
134
  | `unsafe` | No | Unsafe raw DB mode. Object config (`reason`, `adminOnly`, `crossTenant`, `targetScope`). |
135
135
  | `transition` | No | State-machine policy enforcing the from/to pair (record-based actions). See [Transitions](#transition-state-machine-policy) |
136
+ | `bulkVariant` | No | Auto-generate a `POST /:resource/batch/{action}` route alongside the per-record route (record-based actions). See [Bulk Variant](#bulk-variant) |
136
137
  | `cms` | No | Pass-through metadata blob for CMS surfaces |
137
138
 
138
139
  `execute` must be an `async (ctx) => { … }` arrow function. `async function`
@@ -217,6 +218,107 @@ Content-Type: application/json
217
218
  }
218
219
  ```
219
220
 
221
+ ### Bulk variant
222
+
223
+ Set `bulkVariant: true` to auto-generate a bulk version of the action at
224
+ `POST /:resource/batch/{action}`. The compiler emits a second route alongside
225
+ the per-record one, looping the same access + transition + execute pipeline
226
+ over an array of ids. This is the answer to "I need to advance 50
227
+ applications at once" — you don't have to hand-roll a parallel standalone
228
+ action that duplicates the per-record logic.
229
+
230
+ ```typescript
231
+ // features/applications/actions/advance.ts
232
+ export default defineAction({
233
+ description: "Move an application forward in the pipeline.",
234
+ input: z.object({ nextStatus: z.enum(["screening", "interview", "offer"]) }),
235
+ access: { roles: ["owner", "admin"] },
236
+ bulkVariant: true,
237
+ transition: {
238
+ field: "status",
239
+ via: "nextStatus",
240
+ fromTo: { applied: ["screening"], screening: ["interview"], interview: ["offer"] },
241
+ },
242
+ async execute({ db, record, input, whereTransition }) {
243
+ const [updated] = await db
244
+ .update(applications)
245
+ .set({ status: input.nextStatus })
246
+ .where(whereTransition!(applications))
247
+ .returning();
248
+ if (!updated) throw new TransitionLostError("status", record.status, input.nextStatus);
249
+ return updated;
250
+ },
251
+ });
252
+ ```
253
+
254
+ **Request shape:**
255
+
256
+ ```http
257
+ POST /applications/batch/advance
258
+ Content-Type: application/json
259
+
260
+ {
261
+ "ids": ["app_001", "app_002", "app_003"],
262
+ "input": { "nextStatus": "interview" },
263
+ "failFast": false
264
+ }
265
+ ```
266
+
267
+ The `input` is shared across the batch — the action's Zod schema is
268
+ validated once, not per id. For per-record input variation, use the
269
+ single-record endpoint (`POST /:id/{action}`) or write a standalone action.
270
+
271
+ **Response (207 Multi-Status when any record fails, 200 when clean):**
272
+
273
+ ```json
274
+ {
275
+ "success": [{ "id": "app_001", "status": "interview" }],
276
+ "errors": [
277
+ {
278
+ "index": 1,
279
+ "id": "app_002",
280
+ "error": {
281
+ "error": "Action not allowed for current state",
282
+ "code": "ACCESS_ACTION_NOT_ALLOWED_FOR_STATE",
283
+ "details": { "field": "status", "currentValue": "rejected" }
284
+ }
285
+ }
286
+ ],
287
+ "meta": {
288
+ "total": 3,
289
+ "succeeded": 2,
290
+ "failed": 1,
291
+ "failFast": false,
292
+ "transactional": false
293
+ }
294
+ }
295
+ ```
296
+
297
+ **Per-record pipeline** mirrors the single-record route exactly — the same
298
+ firewall fetch, access reason split (403 vs 409), transition pre-check,
299
+ `whereTransition` factory, and `TransitionLostError` handling. Per-record
300
+ failures land in `errors[]` with their original index; successful records
301
+ land in `success[]` masked the same way the single-record response is.
302
+
303
+ **Transactional matrix** (same as `PATCH /batch`):
304
+
305
+ | Provider | failFast | transactional | Behavior |
306
+ |---|---|---|---|
307
+ | postgres / supabase / neon / libsql / sqlite drivers | `true` | `true` | `db.transaction()` wraps the loop; any throw rolls back all writes |
308
+ | (any) | `false` | `false` | Independent per-record outcomes, partial success |
309
+ | cloudflare-d1 | `true` | `false` | Fail-fast loop without rollback — earlier records stay committed |
310
+
311
+ **Constraints:**
312
+
313
+ - Record-based actions only. Standalone actions reject `bulkVariant: true`
314
+ at compile time (no record context to loop over).
315
+ - `unsafe` actions reject `bulkVariant: true` in v1 — the cross-tenant
316
+ per-record audit story is not yet wired through.
317
+ - Method is forced to POST regardless of the action's `method` setting. The
318
+ semantic asymmetry (one row → many rows) makes inheriting GET/DELETE
319
+ confusing.
320
+ - Max batch size is 100 ids per request.
321
+
220
322
  ## Standalone Actions
221
323
 
222
324
  Standalone actions are independent endpoints that don't require a record context. Set a `path:` to declare the action standalone.
@@ -400,6 +502,49 @@ access: async (ctx, record) => {
400
502
  }
401
503
  ```
402
504
 
505
+ ### Relationship-roles in actions (v1 limitation)
506
+
507
+ Relationship-roles declared under `authz.roles` (e.g. `guest: { via: 'guestOf' }`) are **not yet supported in action access blocks**. The compiler refuses to build with a clear error message because the binding semantics — which input field or which loaded record's column to check the relationship against — differ between record-actions and standalone-actions and require explicit declaration not yet wired in v1.
508
+
509
+ The runtime evaluator fails closed on unrecognized relationship arms, so silent grants are impossible.
510
+
511
+ **Workaround**: gate the action on BA roles only and apply the relationship at the resource layer via a firewall `via:` predicate:
512
+
513
+ ```typescript
514
+ // quickback.config.ts
515
+ authz: {
516
+ relationships: {
517
+ guestOf: {
518
+ from: 'event_guests',
519
+ subject: { column: 'userId', equals: 'ctx.userId' },
520
+ resource: { column: 'eventId' },
521
+ where: { status: 'confirmed' },
522
+ },
523
+ },
524
+ }
525
+
526
+ // features/sessions/sessions.ts — firewall scopes rows; action gates on BA role
527
+ firewall: [
528
+ { field: 'organizationId', equals: 'ctx.activeOrgId' },
529
+ { field: 'eventId', via: 'guestOf' }, // ← row-level relationship check
530
+ ],
531
+ actions: {
532
+ comment: defineAction({
533
+ access: { roles: ['member', 'admin'] }, // ← BA role only on the action
534
+ input: z.object({ text: z.string() }),
535
+ execute: async (input, ctx, db, record) => {
536
+ // record is already filtered by the firewall — guest membership
537
+ // is enforced before this handler runs.
538
+ return db.insert(comments).values({ ... });
539
+ },
540
+ }),
541
+ }
542
+ ```
543
+
544
+ This pattern composes cleanly: the firewall guarantees the caller has the relationship to the record being acted on; the action's access list keeps the role surface obvious.
545
+
546
+ A future `actions.<name>.relationshipBindings` declaration is on the roadmap to remove this limitation. See [Access — relationship authorization](/compiler/definitions/access#relationship-based-authorization) for the full picture.
547
+
403
548
  ## Scoped Database
404
549
 
405
550
  All actions receive a **scoped `db`** instance that automatically enforces security:
@@ -64,6 +64,7 @@ type FirewallPredicate =
64
64
  | { field: string; equals: string } // column = ctx.* (or literal)
65
65
  | { field: string; isNull: true } // column IS NULL
66
66
  | { field: string; in: string[] | string }// column IN (...)
67
+ | { field: string; via: string } // column IN (relationship subquery)
67
68
  | { exception: true }; // opt out of tenant scoping
68
69
 
69
70
  type FirewallConfig = ReadonlyArray<FirewallPredicate>;
@@ -74,6 +75,51 @@ firewallErrorMode?: 'reveal' | 'hide';
74
75
 
75
76
  Predicates are AND'd together. `firewallErrorMode` lives at the resource top level — it's a presentation-layer choice (403 vs 404), not a query-shape one.
76
77
 
78
+ ## Relationship-based scoping (`via:`)
79
+
80
+ For relationship authorization — "this user can see rows X if they have a confirmed `event_guests` row pointing at X" — declare the relationship under `authz.relationships` in `quickback.config.ts`, then reference it from `firewall:` with a `via:` predicate:
81
+
82
+ ```typescript
83
+ // quickback.config.ts
84
+ authz: {
85
+ relationships: {
86
+ guestOf: {
87
+ from: 'event_guests', // table name
88
+ subject: { column: 'userId', equals: 'ctx.userId' }, // caller side
89
+ resource: { column: 'eventId' }, // resource side
90
+ where: { status: 'confirmed' }, // optional row filter
91
+ },
92
+ },
93
+ }
94
+
95
+ // features/sessions/sessions.ts
96
+ firewall: [
97
+ { field: 'organizationId', equals: 'ctx.activeOrgId' },
98
+ { field: 'eventId', via: 'guestOf' },
99
+ ]
100
+ ```
101
+
102
+ Compiles to:
103
+
104
+ ```sql
105
+ WHERE sessions.organizationId = ?
106
+ AND sessions.eventId IN (
107
+ SELECT eventId FROM event_guests
108
+ WHERE userId = ?
109
+ AND status = 'confirmed'
110
+ AND <event_guests' own firewall — tenant scope + soft-delete>
111
+ )
112
+ ```
113
+
114
+ Key properties:
115
+
116
+ - **Firewall stays the outermost AND.** A guest of an event in another tenant is still blocked by your tenant predicate. Relationship-based scoping never bypasses tenant isolation.
117
+ - **The relationship table's own firewall is AND'd into the subquery.** Soft-deleting a `event_guests` row revokes access immediately; cross-tenant relationship rows can't grant access.
118
+ - **Anonymous callers fail closed.** `ctx.userId` is null-guarded; the subquery short-circuits to `WHERE 1 = 0` for unauthenticated requests.
119
+ - **The relationship table must be tenant-scoped** (`firewall: { exception: true }` is rejected at compile time on relationship tables).
120
+
121
+ See [Access — relationships](/compiler/definitions/access#authz-relationships) for the full `authz.relationships` shape and role-binding patterns.
122
+
77
123
  ## Context Sources
78
124
 
79
125
  When `equals` references the request context, use these standard sources:
@@ -110,6 +110,8 @@ The firewall controls **which records** a user can see. It automatically adds WH
110
110
 
111
111
  No manual configuration needed - Quickback applies smart rules based on your schema.
112
112
 
113
+ For relationship-based row visibility (e.g. "user can see this event because they have a confirmed `event_guests` row pointing at it"), declare the relationship under `authz.relationships` and reference it from the firewall with a `via:` predicate. See [Firewall → Relationship-based scoping](/compiler/definitions/firewall#relationship-based-scoping-via).
114
+
113
115
  [Learn more about Firewall →](/compiler/definitions/firewall)
114
116
 
115
117
  ### 2. Access (CRUD Permissions)
@@ -139,6 +139,17 @@ show: {
139
139
 
140
140
  The `'owner'` condition compares against the owner column declared via `q.scope('owner')` (or auto-detected from a `userId` / `ownerId` column). If no owner scope is present, it falls back to `createdBy`.
141
141
 
142
+ ### Relationship-roles in masking (v1 limitation)
143
+
144
+ Relationship-roles declared under `authz.roles` (e.g. `guest: { via: 'guestOf' }`) are **not yet supported in `show:` clauses**. The compiler refuses to build with a clear error message because async, db-aware mask functions plus a batched relationship matcher (to avoid N+1 on list responses) are required to ship safely — that pipeline has not yet landed. The runtime evaluator fails closed on unrecognized arms, so silent grants are impossible.
145
+
146
+ **Workarounds**, depending on intent:
147
+
148
+ - **Gate on BA roles only**: keep masking simple and put the relationship check at the access layer instead — `read.views.<v>.access: { roles: ['guest'] }` returns a curated field projection that excludes the sensitive column entirely for non-staff callers, without involving masking.
149
+ - **Move the field into a view that's gated by the relationship-role at access**: same pattern — column-level security via field projection rather than per-row masking.
150
+
151
+ A future async-mask pipeline with batched lookups will lift this limitation; the schema slot is reserved so the v2 add will be non-breaking.
152
+
142
153
  ## Query Gate (filter / sort / search)
143
154
 
144
155
  Masking has a second concern beyond hiding values in the response: a non-admin caller could enumerate masked PII via the query string — e.g. `?filter=email:like:%@target.com` — and infer presence even when the response payload is redacted. The `query` allowlist closes this:
@@ -53,8 +53,7 @@ export default defineTable(customers, {
53
53
  |----------|------|
54
54
  | `GET /api/v1/{resource}` | `read.access` |
55
55
  | `GET /api/v1/{resource}/:id` | `read.access` |
56
- | `GET /api/v1/{resource}?view={name}` | `read.views[name].access` (falls back to `read.access`) |
57
- | `GET /api/v1/{resource}/views/{name}` | Same — explicit path form of the `?view=` dispatch |
56
+ | `GET /api/v1/{resource}/views/{name}` | `read.views[name].access` (falls back to `read.access`) |
58
57
 
59
58
  Single-record `GET /:id` inherits `read.access` automatically — there's no
60
59
  separate `read.get` block. If you need different access for single records,
@@ -145,10 +144,10 @@ read: {
145
144
  }
146
145
  ```
147
146
 
148
- Both endpoint shapes are emitted automatically:
147
+ Named views are emitted at dedicated path routes:
149
148
 
150
- - Query-string dispatch: `GET /api/v1/jobs?view=internal`
151
- - Explicit path: `GET /api/v1/jobs/views/internal`
149
+ - `GET /api/v1/jobs/views/internal`
150
+ - If `read.defaultView` is set, bare `GET /api/v1/jobs` resolves to that view.
152
151
 
153
152
  ## Migrating from `crud.list` / `crud.get`
154
153
 
@@ -161,7 +160,7 @@ DSL v2 rejects both at compile time. The migration is mechanical:
161
160
  | `crud.list.maxPageSize` | `read.maxPageSize` |
162
161
  | `crud.list.fields: [...]` | Move to a named view under `read.views` |
163
162
  | `crud.get.access` | `read.access` (or record-level conditions) |
164
- | `crud.get.fields: [...]` | Move to a named view; clients call `?view=...` |
163
+ | `crud.get.fields: [...]` | Move to a named view; clients call `/views/{name}` |
165
164
  | Top-level `views: {...}` | `read.views: {...}` |
166
165
 
167
166
  Example before/after:
@@ -197,7 +196,9 @@ crud: {
197
196
  ```
198
197
 
199
198
  Clients that previously hit `GET /:id` to retrieve only summary fields now
200
- call `GET /:id?view=summary`.
199
+ move that projection to a named collection view such as
200
+ `GET /api/v1/jobs/views/summary`. Single-record `GET /:id` always returns the
201
+ full masked record.
201
202
 
202
203
  ## Read-Only Resources
203
204
 
@@ -75,20 +75,18 @@ export default defineTable(candidates, {
75
75
 
76
76
  ## Generated Endpoints
77
77
 
78
- Each view generates **two** equivalent GET endpoints — pick whichever is more ergonomic for your client:
78
+ Each named view generates a dedicated GET endpoint:
79
79
 
80
80
  ```
81
81
  GET /api/v1/candidates # Full read - read.access fields
82
- GET /api/v1/candidates?view=pipeline # Query-string dispatch
83
- GET /api/v1/candidates/views/pipeline # Explicit path form
84
- GET /api/v1/candidates?view=full # hiring-manager/recruiter only
82
+ GET /api/v1/candidates/views/pipeline # interviewer/recruiter/etc.
83
+ GET /api/v1/candidates/views/full # hiring-manager/recruiter only
85
84
  GET /api/v1/candidates/views/report # report fields
86
85
  ```
87
86
 
88
- The `?view=` query-string form is convenient when the rest of your client
89
- already builds collection URLs and you only need to swap the projection.
90
- The `/views/{name}` path form is better when you want a stable URL per
91
- projection.
87
+ If `read.defaultView` is set, bare `GET /api/v1/candidates` can also resolve
88
+ to that named view. Without `defaultView`, bare `GET /api/v1/candidates`
89
+ returns `VIEW_REQUIRED` once views are declared.
92
90
 
93
91
  ## Query Parameters
94
92
 
@@ -227,6 +225,93 @@ read: {
227
225
  | `/views/full` | interviewer | Yes | `j***@c******.com` |
228
226
  | `/views/full` | recruiter | Yes | `jane@company.com` |
229
227
 
228
+ ## Aggregations
229
+
230
+ Views can declare pre-computed aggregations that run alongside the row
231
+ query and surface as `aggregations: { ... }` on the response. This avoids a
232
+ custom standalone action for every "count of X grouped by Y" dashboard
233
+ tile — the firewall and view filters already in place drive the metric.
234
+
235
+ ```typescript
236
+ read: {
237
+ access: { roles: ['owner', 'admin', 'member'] },
238
+ views: {
239
+ pipeline: {
240
+ fields: ['id', 'jobId', 'candidateId', 'status', 'appliedAt'],
241
+ aggregations: {
242
+ totalApplications: { fn: 'count' },
243
+ byStatus: { fn: 'groupBy', field: 'status' },
244
+ },
245
+ },
246
+ },
247
+ }
248
+ ```
249
+
250
+ Response now carries the aggregations alongside `data`:
251
+
252
+ ```json
253
+ {
254
+ "data": [/* paginated rows */],
255
+ "view": "pipeline",
256
+ "pagination": { "count": 50, "page": 1, "pageSize": 50, "hasMore": true },
257
+ "aggregations": {
258
+ "totalApplications": 173,
259
+ "byStatus": {
260
+ "applied": 102,
261
+ "screening": 41,
262
+ "interview": 18,
263
+ "offer": 7,
264
+ "rejected": 5
265
+ }
266
+ }
267
+ }
268
+ ```
269
+
270
+ ### Supported aggregation functions
271
+
272
+ | `fn` | `field` | Returns | Example |
273
+ |---|---|---|---|
274
+ | `sum` | required, numeric | scalar number | `{ fn: 'sum', field: 'guestCount' }` |
275
+ | `avg` | required, numeric | scalar number | `{ fn: 'avg', field: 'salary' }` |
276
+ | `min` | required | scalar number | `{ fn: 'min', field: 'price' }` |
277
+ | `max` | required | scalar number | `{ fn: 'max', field: 'price' }` |
278
+ | `count` | optional | `COUNT(*)` if omitted, `COUNT(field)` (non-null) if given | `{ fn: 'count' }` |
279
+ | `count_distinct` | required | scalar number | `{ fn: 'count_distinct', field: 'sourceId' }` |
280
+ | `groupBy` | required | `{ value: count }` map | `{ fn: 'groupBy', field: 'status' }` |
281
+
282
+ `groupBy` always returns a count map keyed by the distinct values of `field`.
283
+ `NULL` values bucket under the literal string `"(none)"`. Other rollup
284
+ functions (`groupBy` + `sum` of another column) are deferred to a future
285
+ release.
286
+
287
+ ### Filter and firewall inheritance
288
+
289
+ Aggregations always run over the **same** filtered, firewalled set as the
290
+ row query. Pagination is intentionally ignored — you get the value over
291
+ every matching record, not just the current page.
292
+
293
+ In practice: a request like
294
+ `GET /applications/views/pipeline?status=applied&jobId=job_123&limit=10`
295
+ returns the first 10 applied rows for that job, AND `byStatus` reflects
296
+ only that filtered set (which will be `{ applied: <total> }` since the
297
+ filter pinned the status). This is the only consistent default — divorcing
298
+ the metric from the user's filters would surprise.
299
+
300
+ ### Constraints (compile-time)
301
+
302
+ - `field` must reference a real column on the table.
303
+ - `sum`/`avg` require numeric column types (`int`, `real`, `decimal`,
304
+ `numeric`, `bigint`). Non-numeric columns are rejected at compile time.
305
+ - The same masking opt-out gate that governs `query.{filterable, sortable,
306
+ searchable}` applies to aggregations: the view's roles must satisfy the
307
+ masking rule, otherwise the aggregation is rejected. (A `sum(salary)`
308
+ leaks structure across the masked set even when the row payload is
309
+ redacted.)
310
+ - Aggregation names cannot collide with the reserved response fields
311
+ `data`, `pagination`, `view`.
312
+ - No raw SQL `expr:` form. Column references only — declare a generated
313
+ column or write a custom action if you need arithmetic.
314
+
230
315
  ## Response Format
231
316
 
232
317
  View responses include metadata about the view:
@@ -238,15 +323,18 @@ View responses include metadata about the view:
238
323
  { "id": "cnd_456", "name": "John Smith", "source": "referral" }
239
324
  ],
240
325
  "view": "pipeline",
241
- "fields": ["id", "name", "source"],
242
326
  "pagination": {
243
- "limit": 50,
244
- "offset": 0,
245
- "count": 2
327
+ "count": 2,
328
+ "page": 1,
329
+ "pageSize": 50,
330
+ "hasMore": false
246
331
  }
247
332
  }
248
333
  ```
249
334
 
335
+ When the view declares `aggregations`, the response also includes an
336
+ `aggregations: { ... }` field. See [Aggregations](#aggregations).
337
+
250
338
  ## Complete Example
251
339
 
252
340
  ```typescript
@@ -253,16 +253,17 @@ import { AuthErrors, AccessErrors, GuardErrors } from '../../lib/errors';
253
253
 
254
254
  const app = new Hono();
255
255
 
256
- // GET /candidates?view=<name> — unified read handler dispatched by ?view
256
+ // GET /candidates/views/:viewName — named view projection
257
257
  const READ_ACCESS = { roles: ['owner', 'hiring-manager', 'recruiter', 'interviewer'] };
258
258
 
259
- app.get('/', async (c) => {
259
+ app.get('/views/:viewName', async (c) => {
260
260
  const ctx = c.get('ctx');
261
261
  const db = c.get('db');
262
262
 
263
+ const viewName = c.req.param('viewName');
263
264
  const params = Object.fromEntries(new URL(c.req.url).searchParams);
264
- const view = VIEWS_CONFIG[params.view as keyof typeof VIEWS_CONFIG];
265
- if (!view) return c.json({ error: 'View required', code: 'VIEW_REQUIRED' }, 400);
265
+ const view = VIEWS_CONFIG[viewName as keyof typeof VIEWS_CONFIG];
266
+ if (!view) return c.json({ error: 'Unknown view', code: 'VIEW_NOT_FOUND' }, 400);
266
267
 
267
268
  // Per-view access gate (falls back to read-level access)
268
269
  if (!await evaluateAccess(view.access ?? READ_ACCESS, ctx)) {
@@ -273,7 +274,7 @@ app.get('/', async (c) => {
273
274
  const results = await db.select(/* projected fields */).from(candidates)
274
275
  .where(buildFirewallConditions(ctx));
275
276
 
276
- return c.json({ data: maskCandidates(results, ctx), view: params.view });
277
+ return c.json({ data: maskCandidates(results, ctx), view: viewName });
277
278
  });
278
279
 
279
280
  // POST /candidates - Create with guards
@@ -383,10 +384,10 @@ Views control **which fields are returned**. Masking controls **what values are
383
384
 
384
385
  | Endpoint | Role | `phone` in response? | `phone` value |
385
386
  |----------|------|--------------------|-------------|
386
- | `/candidates?view=pipeline` | interviewer | No | N/A |
387
- | `/candidates?view=pipeline` | recruiter | No | N/A |
388
- | `/candidates?view=full` | interviewer | No | N/A (no access) |
389
- | `/candidates?view=full` | recruiter | Yes | `555-123-4567` |
387
+ | `/candidates/views/pipeline` | interviewer | No | N/A |
388
+ | `/candidates/views/pipeline` | recruiter | No | N/A |
389
+ | `/candidates/views/full` | interviewer | No | N/A (no access) |
390
+ | `/candidates/views/full` | recruiter | Yes | `555-123-4567` |
390
391
 
391
392
  ### Guards Enforcement
392
393
 
@@ -417,8 +418,8 @@ POST /candidates
417
418
  | `POST` | `/candidates` | hiring-manager, recruiter |
418
419
  | `PATCH` | `/candidates/:id` | hiring-manager, recruiter |
419
420
  | `DELETE` | `/candidates/:id` | hiring-manager |
420
- | `GET` | `/candidates?view=pipeline` | owner, hiring-manager, recruiter, interviewer |
421
- | `GET` | `/candidates?view=full` | hiring-manager, recruiter |
421
+ | `GET` | `/candidates/views/pipeline` | owner, hiring-manager, recruiter, interviewer |
422
+ | `GET` | `/candidates/views/full` | hiring-manager, recruiter |
422
423
 
423
424
  ---
424
425
 
@@ -75,8 +75,7 @@ Calls a client makes:
75
75
  ```bash
76
76
  GET /jobs # Collection — gated by read.access
77
77
  GET /jobs/:id # Single — gated by read.access (with ID-probe defense)
78
- GET /jobs?view=summary # View dispatch
79
- GET /jobs/views/summary # Explicit view path
78
+ GET /jobs/views/summary # Named view projection
80
79
  ```
81
80
 
82
81
  ### ID-probe defense on `/:id`
@@ -4,14 +4,14 @@ Views provide named column projections that limit which fields are returned in A
4
4
 
5
5
  ## Endpoints
6
6
 
7
- Views are dispatched two equivalent ways:
7
+ Named views are queried through a dedicated path endpoint:
8
8
 
9
9
  ```
10
- GET /api/v1/{resource}?view={view-name} # Query-string dispatch
11
- GET /api/v1/{resource}/views/{view-name} # Explicit path
10
+ GET /api/v1/{resource}/views/{view-name}
12
11
  ```
13
12
 
14
- Both forms are emitted automatically and behave identically.
13
+ If you set `read.defaultView`, bare `GET /api/v1/{resource}` can still resolve
14
+ to that view. Named views themselves are addressed via `/views/{view-name}`.
15
15
 
16
16
  ## Example
17
17
 
@@ -39,11 +39,6 @@ export default defineTable(candidates, {
39
39
  ### Request
40
40
 
41
41
  ```bash
42
- # Query-string form
43
- curl '/api/v1/candidates?view=pipeline' \
44
- -H "Authorization: Bearer <token>"
45
-
46
- # Path form (equivalent)
47
42
  curl /api/v1/candidates/views/pipeline \
48
43
  -H "Authorization: Bearer <token>"
49
44
  ```
@@ -57,11 +52,11 @@ curl /api/v1/candidates/views/pipeline \
57
52
  { "id": "cand_002", "name": "Bob Martinez", "source": "referral" }
58
53
  ],
59
54
  "view": "pipeline",
60
- "fields": ["id", "name", "source"],
61
55
  "pagination": {
62
- "limit": 50,
63
- "offset": 0,
64
- "count": 2
56
+ "count": 2,
57
+ "page": 1,
58
+ "pageSize": 50,
59
+ "hasMore": false
65
60
  }
66
61
  }
67
62
  ```
@@ -1 +1 @@
1
- {"version":3,"file":"registry.d.ts","sourceRoot":"","sources":["../../src/templates/registry.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAkB,KAAK,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAEzE,MAAM,WAAW,kBAAkB;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,GAAG,MAAM,GAAG,KAAK,GAAG,UAAU,CAAC;IAC/C,IAAI,EAAE,MAAM,EAAE,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,MAAM,EAAE,MAAM,CAAC;IACf,kBAAkB,EAAE,OAAO,CAAC;IAC5B,IAAI,EAAE,MAAM,GAAG,KAAK,CAAC;CACxB;AAKD;;GAEG;AACH,wBAAsB,oBAAoB,IAAI,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,YAAY,CAAC,CAAC,CAYlF;AAED;;GAEG;AACH,wBAAsB,aAAa,CAAC,YAAY,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAY1E;AAED,eAAO,MAAM,iBAAiB,EAAE,MAAM,CAAC,MAAM,EAAE,kBAAkB,CAuDhE,CAAC;AAKF,eAAO,MAAM,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAOnD,CAAC;AAEF,wBAAgB,WAAW,CAAC,WAAW,EAAE,MAAM,GAAG,kBAAkB,GAAG,SAAS,CAG/E;AAED,wBAAgB,aAAa,IAAI,kBAAkB,EAAE,CAEpD;AAED,wBAAgB,iBAAiB,IAAI,MAAM,EAAE,CAE5C;AAED,wBAAgB,WAAW,IAAI,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAEpD;AAED,wBAAgB,kBAAkB,IAAI,MAAM,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
42
42
  // Free tier templates
43
43
  "betterauth-d1-cloudflare": {
44
44
  name: "Better Auth + D1 + Cloudflare",
45
- description: "Authentication with Better Auth, D1 database, deployed to Cloudflare Workers",
45
+ description: "Authentication with Better Auth, D1 database, deployed to Cloudflare Workers — bare scaffold, add your own features",
46
46
  category: "auth",
47
47
  tags: ["auth", "cloudflare", "d1", "hono"],
48
48
  author: "quickback",
@@ -52,6 +52,18 @@ export const TEMPLATE_REGISTRY = {
52
52
  requiresCloudflare: true,
53
53
  tier: "free",
54
54
  },
55
+ "todos-cloudflare": {
56
+ name: "Todos Example (Cloudflare)",
57
+ description: "Working todos example — schema with masking, two record-based actions (complete / uncomplete), Better Auth, D1. Read the source as a learning template.",
58
+ category: "api",
59
+ tags: ["example", "todos", "actions", "cloudflare", "d1"],
60
+ author: "quickback",
61
+ version: "1.0.0",
62
+ includes: ["betterauth", "d1", "hono", "drizzle"],
63
+ preset: "cloudflare",
64
+ requiresCloudflare: true,
65
+ tier: "free",
66
+ },
55
67
  // bun template hidden — see apps/compiler/src/providers/runtime/providers/bun/README.md
56
68
  // → "Known Issues" for the list of generator drift bugs blocking it.
57
69
  // Pro tier templates
@@ -102,6 +114,7 @@ export const TEMPLATE_ALIASES = {
102
114
  "cf": "betterauth-d1-cloudflare",
103
115
  "saas": "b2bsaas-cloudflare",
104
116
  "blog": "blog-cloudflare",
117
+ "todos": "todos-cloudflare",
105
118
  "empty": "empty-cloudflare",
106
119
  "scaffold": "empty-cloudflare",
107
120
  };
@@ -1 +1 @@
1
- {"version":3,"file":"registry.js","sourceRoot":"","sources":["../../src/templates/registry.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,cAAc,EAAqB,MAAM,sBAAsB,CAAC;AAezE,6BAA6B;AAC7B,IAAI,oBAAoB,GAAwC,IAAI,CAAC;AAErE;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,oBAAoB;IACtC,IAAI,oBAAoB,EAAE,CAAC;QACvB,OAAO,oB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,iBAAiB,CAAC,CAAC;AAC5C,CAAC;AAED,MAAM,UAAU,iBAAiB;IAC7B,OAAO,MAAM,CAAC,IAAI,CAAC,iBAAiB,CAAC,CAAC;AAC1C,CAAC;AAED,MAAM,UAAU,WAAW;IACvB,OAAO,gBAAgB,CAAC;AAC5B,CAAC;AAED,MAAM,UAAU,kBAAkB;IAC9B,MAAM,KAAK,GAAa,CAAC,wBAAwB,CAAC,CAAC;IAEnD,KAAK,MAAM,CAAC,EAAE,EAAE,QAAQ,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,iBAAiB,CAAC,EAAE,CAAC;QAC7D,KAAK,CAAC,IAAI,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC;QACtB,KAAK,CAAC,IAAI,CAAC,OAAO,QAAQ,CAAC,WAAW,EAAE,CAAC,CAAC;QAC1C,KAAK,CAAC,IAAI,CAAC,aAAa,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;QACpD,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACnB,CAAC;IAED,KAAK,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;IACvB,KAAK,MAAM,CAAC,KAAK,EAAE,MAAM,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,gBAAgB,CAAC,EAAE,CAAC;QAC7D,KAAK,CAAC,IAAI,CAAC,KAAK,KAAK,OAAO,MAAM,EAAE,CAAC,CAAC;IAC1C,CAAC;IAED,OAAO,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AAC5B,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@quickback-dev/cli",
3
- "version": "0.12.0",
3
+ "version": "0.14.2",
4
4
  "description": "CLI for Quickback — define your backend in TypeScript, compile to a fully wired Cloudflare Worker (or Bun / Node) with auth, database, migrations, security, CMS, and Account UI.",
5
5
  "author": "Kardoe Incorporated <paul@kardoe.com>",
6
6
  "license": "MIT",