@vercel/board 0.39.0 → 0.41.0

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 (100) hide show
  1. package/README.md +6 -4
  2. package/dist/{access-CVkjSfxj.mjs → access-C5HaO42b.mjs} +2 -2
  3. package/dist/access.d.mts +6 -6
  4. package/dist/access.mjs +5 -5
  5. package/dist/actors-nrOf7Y7z.mjs +160 -0
  6. package/dist/{auth-BXLCkeB0.d.mts → auth-Bn8J_1F2.d.mts} +14 -29
  7. package/dist/{auth-B3bBYOqf.mjs → auth-DAlYi6TN.mjs} +9 -19
  8. package/dist/{backend-HcCCGPG4.d.mts → backend-CYsTLxtP.d.mts} +139 -43
  9. package/dist/backend-local.d.mts +1 -1
  10. package/dist/backend-local.mjs +1 -1
  11. package/dist/blocks-CVoBC7ur.mjs +402 -0
  12. package/dist/blocks-DGvh2alZ.d.mts +33 -0
  13. package/dist/{chat-provider-1WKsLEnM.mjs → chat-provider-CPZg2MQb.mjs} +2 -2
  14. package/dist/{chat-provider-DyNy5xdC.d.mts → chat-provider-Cgkh9xJw.d.mts} +2 -2
  15. package/dist/cli-commands.d.mts +1 -1
  16. package/dist/cli-commands.mjs +1 -1
  17. package/dist/cli-embedded.d.mts +3 -3
  18. package/dist/cli-embedded.mjs +4 -4
  19. package/dist/cli.mjs +8 -13
  20. package/dist/{commands-B5d-lmNN.d.mts → commands-CrEVjASe.d.mts} +14 -26
  21. package/dist/{commands-BLS7erNu.mjs → commands-QRD0U9AQ.mjs} +114 -105
  22. package/dist/{conformance-D59Py2m2.mjs → conformance-ClxEEZ9C.mjs} +378 -101
  23. package/dist/conformance.d.mts +11 -9
  24. package/dist/conformance.mjs +1 -1
  25. package/dist/data-values-C-Cq80hz.mjs +176 -0
  26. package/dist/digest-Dna1CGa_.mjs +4 -0
  27. package/dist/{engine-eUgO5jTM.mjs → engine-8BcNeckB.mjs} +197 -84
  28. package/dist/{errors-rYDxZEuN.mjs → errors-DcQf5WeM.mjs} +123 -42
  29. package/dist/{events-C6HwB046.mjs → events-BT8y_81j.mjs} +2 -2
  30. package/dist/{exports-M5o4PTfO.mjs → exports-B6udRV_E.mjs} +961 -383
  31. package/dist/exports-C8zsIL1A.d.mts +4 -0
  32. package/dist/{external-CHDxWIVf.mjs → external-DymyhUzl.mjs} +1 -1
  33. package/dist/{index-rNqqgkyu.d.mts → index-fcpEFCTR.d.mts} +2 -2
  34. package/dist/index.d.mts +7 -6
  35. package/dist/index.mjs +8 -6
  36. package/dist/index.node.d.mts +7 -6
  37. package/dist/index.node.mjs +5 -4
  38. package/dist/inspect/app.js +110 -109
  39. package/dist/inspect/engine.js +5 -5
  40. package/dist/inspect-BsF3mYMY.mjs +2 -0
  41. package/dist/{inspect-BkXxR2uB.mjs → inspect-DPRoC_Gg.mjs} +6 -6
  42. package/dist/{local-DvkOWf4U.mjs → local-B9y4p6N7.mjs} +463 -512
  43. package/dist/{main-DtV_Po9i.mjs → main-S0A-c_kP.mjs} +549 -178
  44. package/dist/{memory-DkoqhxIH.mjs → memory-DhduVbUu.mjs} +2 -2
  45. package/dist/{mentions-CB6ShY4R.mjs → mentions-DfZGp3B-.mjs} +18 -4
  46. package/dist/{middleware-CPqAuRtp.mjs → middleware-DHdrxmoc.mjs} +71 -3
  47. package/dist/{targets-C1mT3M1N.mjs → origin-B3m2lnZC.mjs} +43 -64
  48. package/dist/{page-64IwoGRu.mjs → page-2jjHZmIW.mjs} +2 -2
  49. package/dist/page-CAUe4GmQ.mjs +2 -0
  50. package/dist/{provider-D5yVFisj.d.mts → provider-dY54GFNz.d.mts} +20 -34
  51. package/dist/{routes-BffuaoTX.d.mts → routes-By9lmvUD.d.mts} +91 -77
  52. package/dist/{schemas-AZkxk06N.mjs → schemas-DAzSsgWk.mjs} +8 -3
  53. package/dist/schemas.d.mts +37 -0
  54. package/dist/schemas.mjs +3 -0
  55. package/dist/{serve-CX1rqDF_.mjs → serve-B15I2Ibf.mjs} +5 -5
  56. package/dist/{server-DkYkyarg.mjs → server-DgpRZ4Nu.mjs} +74 -127
  57. package/dist/{serving-DJMcG0dT.mjs → serving-CALKWs9K.mjs} +1 -1
  58. package/dist/{sql-l3ysn4O5.mjs → sql-P9g-rLIF.mjs} +75 -12
  59. package/dist/{sqlite-CAwNHbQD.mjs → sqlite-B3rCcIof.mjs} +2 -2
  60. package/dist/{sqlite-db-cm5yhrD-.mjs → sqlite-db-D0Fyju-4.mjs} +1 -1
  61. package/dist/sync-chat-sdk.d.mts +2 -2
  62. package/dist/sync-chat-sdk.mjs +2 -2
  63. package/dist/sync-github.d.mts +2 -2
  64. package/dist/sync-github.mjs +2 -2
  65. package/dist/sync-linear.d.mts +3 -3
  66. package/dist/sync-linear.mjs +2 -2
  67. package/dist/sync-slack.d.mts +14 -8
  68. package/dist/sync-slack.mjs +46 -19
  69. package/dist/sync.d.mts +2 -2
  70. package/dist/sync.mjs +2 -2
  71. package/dist/{tokens-DA9ipsZ-.mjs → tokens-D7_ZIWpX.mjs} +4 -4
  72. package/docs/01-board/01-mounting.md +13 -16
  73. package/docs/01-board/03-identity.md +112 -74
  74. package/docs/01-board/04-messages.md +61 -2
  75. package/docs/01-board/05-reading.md +11 -5
  76. package/docs/01-board/06-watchers.md +17 -13
  77. package/docs/01-board/07-schedules.md +8 -6
  78. package/docs/01-board/08-middleware.md +1 -1
  79. package/docs/01-board/09-access.md +80 -132
  80. package/docs/02-sync/01-overview.md +75 -4
  81. package/docs/02-sync/02-functions.md +11 -6
  82. package/docs/02-sync/03-slack.md +43 -19
  83. package/docs/02-sync/06-providers.md +9 -4
  84. package/docs/03-guides/01-coding-agents.md +18 -22
  85. package/docs/03-guides/02-inspector.md +4 -5
  86. package/docs/03-guides/03-ci.md +7 -26
  87. package/docs/03-guides/04-triage.md +2 -2
  88. package/docs/03-guides/05-agent-factory.md +7 -9
  89. package/docs/03-guides/06-sandboxed-agents.md +149 -0
  90. package/docs/04-reference/01-cli.md +161 -104
  91. package/docs/04-reference/02-board.md +89 -37
  92. package/docs/04-reference/03-http.md +176 -71
  93. package/docs/04-reference/05-conformance.md +47 -21
  94. package/docs/index.md +5 -5
  95. package/package.json +5 -1
  96. package/dist/actors-kfMejhaw.mjs +0 -156
  97. package/dist/digest-krhjNAt4.mjs +0 -4
  98. package/dist/exports-vLQ2Y2Nd.d.mts +0 -4
  99. package/dist/inspect-lnv1sLXM.mjs +0 -2
  100. package/dist/page-BUj8_UZv.mjs +0 -2
@@ -16,10 +16,10 @@ description: The board's routes, headers, filters, errors, and event feed, relat
16
16
 
17
17
  ## Authentication
18
18
 
19
- Every request sends an OIDC token, or a token the board issued:
19
+ Every request sends an OIDC token:
20
20
 
21
21
  ```text
22
- Authorization: Bearer <OIDC JWT | board_…>
22
+ Authorization: Bearer <OIDC JWT>
23
23
  ```
24
24
 
25
25
  - **The token's `aud` must be the board's URL**, as discovery returns it
@@ -28,9 +28,6 @@ Authorization: Bearer <OIDC JWT | board_…>
28
28
  - **Issuers:** Vercel (`https://oidc.vercel.com/<team>`), GitHub Actions
29
29
  (`https://token.actions.githubusercontent.com`), and any issuer a grant
30
30
  names, verified against their published keys.
31
- - **The board's own tokens** start with `board_`, and `board()` checks them
32
- before anything else: each acts as whoever minted it, narrowed (see
33
- [Tokens](../01-board/09-access.md#tokens)).
34
31
  - **Who's trusted:** people with access to the board's Vercel project (a
35
32
  development token carrying `user_id`), the project's own deployments in the
36
33
  environment the board runs in, and anything one of the board's grants lets
@@ -48,7 +45,7 @@ These routes take no token:
48
45
  | `GET /` | discovery: tells a client which project to mint a token for |
49
46
  | `GET /avatars/:name` | built-in agent avatars |
50
47
  | `GET /openapi.json` | the API's schema |
51
- | `POST /webhooks/:key` | platforms can't send a board token; the sync adapter verifies the request |
48
+ | `POST /webhooks/:key` | platforms can't send a token the board verifies; the sync adapter verifies the request |
52
49
  | `POST /wake` | on a deployment whose watchers Vercel's board matches: something matched, and it pulls what with its own credentials |
53
50
 
54
51
  ### Request headers
@@ -56,36 +53,36 @@ These routes take no token:
56
53
  | Header | Purpose |
57
54
  | --- | --- |
58
55
  | `authorization` | `Bearer <token>` |
59
- | `x-board-profile` | write as a profile of your principal: a letter, then up to 31 letters, numbers, or hyphens |
60
- | `x-board-avatar` | the profile's avatar (or your own, as a person): an `https` URL, `http` only on localhost |
61
- | `x-board-session` | the runtime session, recorded on writes (up to 200 characters) |
62
- | `x-board-handle` | a person's handle, e.g. their Vercel username. Ignored for machines, and for people a host's verifier names |
63
- | `x-board-name` | a person's display name, URI-encoded. Ignored for machines |
64
- | `x-board-can` | narrows what the token may do, for a proxy that holds it: `dev/=read,post;ci/=read`, or `all` for an entry's permissions (`dev/=all`). It never widens, and a narrowed caller can't register, pull, or ack watchers, or keep sync's records (403). See [Access](../01-board/09-access.md#narrowing-a-token) |
56
+ | `x-board-profile` | write as a profile of your principal, as an [RFC 8941](https://www.rfc-editor.org/rfc/rfc8941) structured-field Item: the profile's name (a letter, then up to 31 letters, numbers, or hyphens), with an optional `avatar` parameter, a string holding an `https` URL (`http` only on localhost): `fixer; avatar="https://example.com/fixer.png"` |
57
+ | `x-board-can` | narrows what the token may do, for a proxy that holds it: `dev/=read,post;ci/=read`, or `all` for an entry's permissions (`dev/=all`). It never widens, and a narrowed caller can't register, pull, or ack watchers, or keep sync's records (403). See [Access](../01-board/09-access.md#narrowing-a-caller) |
65
58
  | `x-vercel-protection-bypass` | Vercel's own header, to pass Deployment Protection |
66
59
 
67
60
  `board()` checks their shape (a 400 for one that's malformed), and the board
68
61
  records them after verifying the token. They're labels under the verified
69
- principal, never who it is. Provenance (`by`,
70
- `mentions`, `origin`, and sync receipts) is never read from the body of a post
62
+ principal, never who it is. What clients sent before, and released `vb` still
63
+ does, is read by nothing: `x-board-avatar` (an avatar comes only with a
64
+ profile, in its header), `x-board-session` (nothing on the board is kept per
65
+ session), and `x-board-handle` and `x-board-name` (a caller's handle and name
66
+ are what verified it). Provenance (`by`,
67
+ `origin`, and sync receipts) is never read from the body of a post
71
68
  or any other write; only [sync's routes](#syncs-routes) take an author and an
72
69
  origin, from a caller that may `sync` where they land.
73
70
 
74
71
  ### Permissions
75
72
 
76
73
  People and the board's own deployments in its environment can do everything. Anything else can do
77
- what its grants give it, in each channel, and a board token what its minter may, narrowed. Every check is against the
74
+ what its grants give it, in each channel, and `x-board-can` only narrows either. Every check is against the
78
75
  channel the board looked up: a reply's is its root's, and a route with `:id`
79
76
  uses the target's own.
80
77
 
81
78
  | Permission | Routes |
82
79
  | --- | --- |
83
80
  | `read` | `GET /messages`, `/threads`, `/messages/:id`, `/events`, `/channels`, `/actors`, `/schedules`, `/attachments/:id` show only what it covers; `POST /watchers` needs it somewhere, and a registered watcher sees only what it covers |
84
- | `post` | `POST /messages` (a reply also needs `read`), `/channels` (with `read`), `/messages/:id/edit` and `/messages/:id/delete` (your own), `/messages/:id/typing` (with `read`), `/schedules`; `/attachments` needs it, or `sync`, somewhere |
81
+ | `post` | `POST /messages` (a reply also needs `read`), `/channels` (with `read`), `/messages/:id/edit` and `/messages/:id/delete` (your own: see [Who edits what](../01-board/09-access.md#who-edits-what)), `/messages/:id/typing` (with `read`), `/schedules`; `/attachments` needs it, or `sync`, somewhere |
85
82
  | `react` | `POST /messages/:id/reactions` |
86
83
  | `label` | `POST /messages/:id/labels`, and a post or schedule with `labels` |
87
84
  | `sync` | `POST /messages/:id/sync`, a post with `sync` targets, and [sync's routes](#syncs-routes); in every channel, `GET /inbox/:key` for the board's own inbox |
88
- | `manage` | `POST /schedules/:id/cancel` for someone else's; in every channel, `GET /sources/:key/read`, `POST /sources/:key/join`, every registration in `GET /watchers`, `/grants`, and everyone's `/tokens` |
85
+ | `manage` | `POST /schedules/:id/cancel` for someone else's; in every channel, `GET /sources/:key/read`, `POST /sources/:key/join`, every registration in `GET /watchers`, and `/grants`; at `*`, `POST /schemas` |
89
86
 
90
87
  `react`, `label`, and `sync` imply `read`, and `manage` implies everything. A
91
88
  message, schedule, or file the caller can't read answers 404 on every route;
@@ -97,36 +94,36 @@ a refused write it can read answers 403. `GET /me` returns the caller's
97
94
  | Method | Path | Purpose |
98
95
  | --- | --- | --- |
99
96
  | GET | `/` | Discovery (no token): `{ version, url, audience, team_id, project_id, sync, wake_by_path? }`, where `sync` lists each entry's `key` and `platform`, and `wake_by_path` says `POST /watchers` takes a `path`. A board with no backend has none: it answers only wake-ups and webhooks |
100
- | GET | `/me` | Who this token and profile write as: `{ actor, principal, kind, handle, name, avatar, profile, session, expiresAt, can }`, where `can` maps each channel pattern to its permissions |
97
+ | GET | `/me` | Who this token and profile write as: `{ actor, principal, kind, handle, name, avatar, profile, expiresAt, can }`, where `can` maps each channel pattern to its permissions |
101
98
  | GET | `/channels` | `{ channels, cursor }`: each `{ path, lastIndex?, messages?, threads? }`, sorted by path. A board that doesn't count them, as one on Vercel's API doesn't, leaves the counts out |
102
99
  | POST | `/channels` | `{ path }`: makes a channel before anything posts to it. `{ channel, created }`, 201 when it made it, and 200 with `created: false` for one that's there, which it leaves as it is. A key it doesn't know is 400, so `private` makes nothing |
103
- | GET | `/actors` | `{ actors, cursor }`: each `{ id, kind, handle, name, avatar }`, sorted by handle |
100
+ | GET | `/actors` | `{ actors, cursor }`: each `{ id, kind, handle, name, avatar, via?, platform?, verified? }`, sorted by handle. `verified: true` is for one the board checked rather than took their name from what they sent: shown under the handle a credential it checked gave them (an OIDC token, a host's verifier), as itself or after `via` |
104
101
  | GET | `/messages` | `{ messages, cursor }`, filtered. See [Listing messages](#listing-messages) |
105
102
  | GET | `/threads` | `{ threads, cursor }`: a summary per matching thread. See [Listing threads](#listing-threads) |
106
103
  | GET | `/messages/:id` | The thread around any message: `{ message, replies, cursor, schedules }`, where `message` is the root |
107
104
  | GET | `/posts/:id` | Your post with client ID `id`, as `POST /messages` answered it: `{ message }`, or 404 `post_not_found`. Someone else's is as good as missing |
108
- | POST | `/messages` | Post or reply. Answers 201 `{ message }`, with `unknownMentions` when handles in it matched no one and you read the channel. See [Posting](#posting) |
109
- | POST | `/messages/:id/edit` | `{ text, revision? }`. Answers `{ ok: true }`, with `unknownMentions` like a post. With `revision`, only if the message is still at it: otherwise 409 `revision_conflict`, and nothing changes |
110
- | POST | `/messages/:id/delete` | `{ revision? }`. Answers `{ ok: true }`. With `revision`, as an edit |
105
+ | POST | `/messages` | Post or reply. Answers 201 `{ message }`. See [Posting](#posting) |
106
+ | POST | `/messages/:id/edit` | `{ text, revision? }`. Only its author: as a profile, only what that profile wrote; as the principal itself, what it or any of its profiles wrote. Answers `{ ok: true }`. With `revision`, only if the message is still at it: otherwise 409 `revision_conflict`, and nothing changes |
107
+ | POST | `/messages/:id/delete` | `{ revision? }`. Only its author, as an edit. Answers `{ ok: true }`. With `revision`, as an edit |
111
108
  | POST | `/messages/:id/reactions` | `{ emoji, remove? }`. `emoji` is a short name: `eyes`, `thumbs_up` |
112
109
  | POST | `/messages/:id/labels` | `{ set?, unset?, if? }`, at least one of `set` and `unset`. `if` maps up to 16 keys to the value each must have now, or `null` for none: otherwise 409 `label_conflict`, and nothing changes. The check and the change are one write |
113
110
  | POST | `/messages/:id/sync` | `{ target }`: attach the thread to an external target and backfill it. Answers `{ target, attached }` |
114
- | GET | `/messages/:id/sync` | Where the thread is synced: `{ targets }`, each `{ target, key, thread, message, url, undelivered }`, with this message's copy there and the platform's link to it. Needs `read` where it is |
111
+ | GET | `/messages/:id/sync` | Where the thread is synced: `{ targets }`, each `{ target, key, thread, message, url, undelivered }`, with this message's copy there and the platform's link to it. On Vercel's board, another project's target is under `<project>/<key>` (`www/slack:C0123`), with no link. Needs `read` where it is |
115
112
  | GET | `/links` | The thread a platform link names, as `GET /messages/:id` answers it. Query: `url`. From sync's records alone; a link the board didn't sync, or to a message the caller can't read, is 404 `message_not_found` |
116
113
  | POST | `/messages/:id/typing` | `{ status? }`: show typing in the thread's synced platform threads. Answers `{ targets }`. Writes nothing to the log |
117
114
  | POST | `/attachments` | Upload one file. Answers 201 `{ attachment: { id, name, type, size } }`. See [Attachments](#attachments) |
118
115
  | GET | `/attachments/:id` | The file |
119
- | POST | `/schedules` | Schedule a message. Answers 201 `{ schedule }`, with `unknownMentions` like a post. See [Schedules](#schedules) |
116
+ | POST | `/schedules` | Schedule a message. Answers 201 `{ schedule }`. See [Schedules](#schedules) |
120
117
  | GET | `/schedules` | `{ schedules }`. Query: `re`, `channel`, `by`, `all` |
121
- | POST | `/schedules/:id/cancel` | Cancel one, by the ID the board gave it (`s12` on `local()`, which also takes `12`). Its creator, or `manage` in its channel. Answers `{ schedule, canceled }` |
122
- | GET | `/grants` | `{ grants }`: each one's `id`, `principals`, `can`, `capped`, `by`, and `at`. Needs `manage` at `*`, or a team owner. See [Grants and tokens](#grants-and-tokens) |
123
- | POST | `/grants` | `{ principals, can }`: a new grant, even for principals another grant names. Needs `manage` at each pattern in `can`, and under each wherever your token's or your own grants' limits narrow you, and what `everyone` gives wherever it gives something; `manage` everywhere to name an `oidc` principal. A key it doesn't know is 400. Answers `{ grant }` |
118
+ | POST | `/schedules/:id/cancel` | Cancel one, by the ID the board gave it (`s12` on `local()`, which also takes `12`). Its creator (as a profile, only what that profile scheduled), or `manage` in its channel. Answers `{ schedule, canceled }` |
119
+ | GET | `/grants` | `{ grants }`: each one's `id`, `principals`, `can`, `capped`, `by`, and `at`. Needs `manage` at `*`, or a team owner. See [Grants](#grants) |
120
+ | POST | `/grants` | `{ principals, can }`: a new grant, even for principals another grant names. Needs `manage` at each pattern in `can`, and under each wherever your `x-board-can`'s or your own grants' limits narrow you, and what `everyone` gives wherever it gives something; `manage` everywhere to name an `oidc` principal. A key it doesn't know is 400. Answers `{ grant }` |
124
121
  | PATCH | `/grants/:id` | `{ add?, remove?, can? }`: adds principals, removes them by who they are, or replaces `can`. Needs, at the grant as it was, what `POST /grants` needs but what `everyone` gives, and to add principals or set `can`, all of it. Answers `{ grant }`; 404 `grant_not_found`, 400 `not_in_grant` or `grant_empty` |
125
122
  | GET | `/grants/explain` | Which grants decide a channel: `{ channel, pattern, over, level, grants, capped, can }`, `over` the other patterns that cover it, most specific first. Query: `channel`, and for someone else (with `manage` at `*`) `user`, `project` and `environment`, `github` and `workflow`, `branch`, `event`, `oidc` and `claim=name=value`, or `app`. `grants` is empty for a caller that can't list them |
126
123
  | POST | `/grants/:id/revoke` | Answers `{ revoked }`, false when it was already gone. Needs what `POST /grants` needs at its patterns, but what `everyone` gives |
127
- | GET | `/tokens` | `{ tokens }`: yours, or everyone's with `manage` in every channel. With a token, yours are it and those minted with it. Each one's `can` is what it may do now. Each one's `id`, `name`, `can`, `profile`, `session`, `by`, `at`, `expiresAt`, and `parent`, never its secret |
128
- | POST | `/tokens` | `{ name, can?, profile?, avatar?, session?, expires? }`: mint a token acting as you. Answers `{ token, secret }`, the only time the secret shows |
129
- | POST | `/tokens/:id/revoke` | Revoke one of yours, or anyone's with `manage` in every channel: it and every token minted with it stop. Answers `{ revoked }`, false for one that's gone, never was, or isn't yours, alike |
124
+ | GET | `/schemas` | `{ schemas }`: the built-in ones, then the board's own by name and version. Each one's `id`, `name`, `version`, `description`, `schema`, `builtIn`, `by`, and `at`. Anyone the board lets in. See [Schemas](#schemas) |
125
+ | GET | `/schemas/:id` | `{ schema }`: one version, by `name@version` |
126
+ | POST | `/schemas` | `{ name, version, description?, schema }`: register a version, for good. Needs `manage` at `*`. Answers `{ schema, created }`, `created` false for one that's there with the same definition |
130
127
  | GET | `/events` | The event feed. See [Event feed](#event-feed) |
131
128
  | POST | `/watchers` | `{ watch, sync? }` or `{ path, branch?, watch, sync? }`: registers the caller's watchers (at most 32, each `{ tail, when? }`), its sync entries, and where to wake it, replacing its last registration. Without a `path` the caller pulls its matches. A `url` answers 501 `no_wake_by_url` on a `local()` board, which wakes nothing, and 400 on Vercel's board. On a board whose discovery says `wake_by_path`, a `path` on the caller's own Vercel project, which the board finds from the caller's token and wakes through its Deployment Protection: production's best domain, or with `branch`, a preview's latest ready deployment of that branch (403 `not_a_project` for a caller that isn't a Vercel project, 501 `no_wake_by_path` on a board that can't). Needs `read` somewhere, and `sync` somewhere for sync entries. Answers the registration, `{ owner, url: null, watch, sync, hash }`, or `{ owner, url: null, path, branch?, watch, sync, hash }`. On a deployment's board on Vercel's, it takes no token and registers that board's own watchers with Vercel's API |
132
129
  | GET | `/watchers` | `{ watchers }`: the caller's registration, or every one for `manage` in every channel |
@@ -154,7 +151,7 @@ sync `board()` runs beside it. A board with no backend answers only wake-ups
154
151
  and webhooks. There are no
155
152
  optional groups, so a client never asks a board what it does. A board that
156
153
  keeps no schedules or files still answers their routes, with 501 `no_scheduler` or `no_files`, and one that keeps
157
- no grants or issues no tokens answers 501 `no_grants` or `no_tokens`.
154
+ no grants or schemas answers 501 `no_grants` or `no_schemas`.
158
155
  [Conformance](./05-conformance.md) checks a board against all of it, and
159
156
  reports those checks as skipped on such a board.
160
157
 
@@ -167,7 +164,7 @@ lands or is, or somewhere for the lookups and the inbox.
167
164
 
168
165
  | Method | Path | Purpose |
169
166
  | --- | --- | --- |
170
- | POST | `/sync/imports` | A platform's write, as its platform `author` (`{ id, handle, name, avatar, isBot }`), through sync entry `from`. The author is a user of a platform the caller syncs (the entry's, with `from`), never an ID the board authenticates (`vercel:`, `github:repo:`, `oidc:`, `local:`, `board:`), nor a host's principal, of any kind, that has registered or written here, or one of its agents or registered watchers (`<principal>+<id>`): 403 otherwise. An `avatar` that isn't an `https` URL is dropped. Who the author is on the board (their name, handle, and avatar, which every channel shows) changes only for the board's own sync or a caller with `sync` in every channel; anyone else's import names its author and leaves that be. `from` is null for a write a sync callback makes as that user, which syncs out like one written on the board. `op` is `post` (with `channel` or `re`, `text`, `labels`, `noSync`, `attachments`, `links`, its platform `origin`, and an `id` from the platform event, which makes it idempotent), `edit`, `delete`, `react`, `labels`, or `links`, each naming the message it changes by `origin: { thread, message? }`, the platform message (no `message`: the root of the board thread the platform thread belongs to), or by `message`, its board ID (an edit or delete then only of the author's own), or `seen`, a platform user the board should know. A post or an edit may say where on the platform it came from, `source: { key, channel, thread }`, which the board's middleware is told. A post's `origin` is under its `from` key, and its `subthread`, when it has one, is in its `thread` (`github:acme/www:12:rc:9` in `github:acme/www:12`; 400 otherwise): a new root's platform thread is no board thread's yet (409 `already_synced`), a reply's is its own thread's (409 `not_synced`), and its platform message is no board message's (409 `already_synced`). A link names a board message only if the caller may read it, and then carries the board's own copy as its snapshot, whatever the import said; any other keeps its `url`, and its snapshot as the platform's. Answers `{ message }`, the ID it made or changed, or null for a message it didn't find, and with `dropped`, what the middleware responded when it kept a post or an edit off the board, for sync to say in the platform thread |
167
+ | POST | `/sync/imports` | A platform's write, as its platform `author` (`{ id, handle, name, avatar, isBot }`), through sync entry `from`. The author is a user of a sync key the caller registered, named under it: their ID starts with `from` (`slack-eu:user:U0456` through `slack-eu`), or with no `from`, any of its keys. Never an ID the board authenticates (`vercel:`, `github:repo:`, `oidc:`, `local:`, `board:`), nor a host's principal, of any kind, that has registered or written here, or one of its agents or registered watchers (`<principal>+<id>`): 403 otherwise. An `avatar` that isn't an `https` URL is dropped. What it writes is by a profile of the caller's principal, `<principal>+<author id>` (`vercel:project:prj_support:production+slack:user:U0456`), with the author's ID as its `profile` and `author.via` naming the caller: the platform user is the caller's word, and their name, handle, and avatar are that profile's, which only the caller's own imports change. Its handle is under the caller's name, typable: `support/jurgen-ubl` for "Jürgen Ubl" (accents off, lowercased, other runs as `-`, ends trimmed; their platform ID without the key when nothing's left). Only the board's own sync, which checks each platform webhook itself, writes as the platform user alone (`slack:user:U0456`). Its text's mentions of its keys' users (`@[slack-eu:user:U0456]`) mention the caller's profiles of them. `from` is null for a write a sync callback makes as that user, which syncs out like one written on the board. `op` is `post` (with `channel` or `re`, `text`, `labels`, `noSync`, `attachments`, `links`, its platform `origin`, and an `id` from the platform event, which makes it idempotent), `edit`, `delete`, `react`, `labels`, or `links`, each naming the message it changes by `origin: { thread, message? }`, the platform message (no `message`: the root of the board thread the platform thread belongs to), or by `message`, its board ID (an edit or delete then only of the author's own). A post or an edit may say where on the platform it came from, `source: { key, channel, thread }`, which the board's middleware is told. A post's `origin` is under its `from` key, and its `subthread`, when it has one, is in its `thread` (`github:acme/www:12:rc:9` in `github:acme/www:12`; 400 otherwise): a new root's platform thread is no board thread's yet (409 `already_synced`), a reply's is its own thread's (409 `not_synced`), and its platform message is no board message's (409 `already_synced`). A link names a board message only if the caller may read it, and then carries the board's own copy as its snapshot, whatever the import said; any other keeps its `url`, and its snapshot as the platform's. Answers `{ message }`, the ID it made or changed, or null for a message it didn't find, and with `dropped`, what the middleware responded when it kept a post or an edit off the board, for sync to say in the platform thread |
171
168
  | POST | `/sync/receipts` | What sync did, about board message `message`: `kind: 'message'` (it landed on `target` as `external`, with its `files`), `files`, `failed` (with `error`), or `thread` (its thread syncs with `target`, a `targetKind` channel or thread, by `cause` `config` or `request`). A receipt but `thread`'s is for one of its thread's targets (400 `not_a_target`), under a sync key the caller registered and the board's own sync doesn't have (403), and `external` is a platform thread and message no other board thread or message has (409 `already_synced`). Its copy is the caller's: only its sync sees it, and only it says what its files are. Answers `{ ok }`, and for a thread, `attached`: false when it already was |
172
169
  | GET | `/sync/threads/:thread` | A board thread's sync, by its key: `{ thread, root, channel, targets, external }` |
173
170
  | GET | `/sync/find` | What platform IDs are on the board. Query: `post` (an import's client ID), `thread` (and `message` in it). Answers `{ thread, message }`: the board thread and message |
@@ -186,18 +183,42 @@ deliver as matches of watcher `@sync` when it registers its sync entries: see
186
183
 
187
184
  `sync` in a channel says this project may speak for platform users there. A
188
185
  caller with it can write as any user of a platform it syncs, with the origin
189
- it says, and read the platform IDs of what's there. It names the platforms it syncs when it
186
+ it says, and read the platform IDs of what's there. Each user is named under
187
+ the key it came through (`slack-eu:user:U0456`), and what it writes is by its
188
+ own profile of that user (`<principal>+slack-eu:user:U0456`), which shows
189
+ through it: `Malte via support`. It names the platforms it syncs when it
190
190
  registers (`POST /watchers` with `sync`, which needs `sync` somewhere, and
191
191
  no key the board's own sync has), and it can't write as anyone the board signs
192
192
  in. A key names one sync's platform locations: two
193
193
  syncs elsewhere that register one share its platform threads on the board,
194
194
  though each sees and changes only its own copies, so give each key one sync.
195
- Who a platform user is (name, avatar) is board-wide too, so only `sync` in
196
- every channel changes it. Give it to the deployment that runs
197
- a board's sync, in the channels it syncs, and to no one else:
198
- `vb grants create --project prj_support --environment production --can support=all`.
199
- A sync with it in one subtree can't import into
200
- another, and a message it can't sync is as good as missing to it.
195
+ Each sync's platform users are its own actors, so no sync renames another's.
196
+ A sync with it in one subtree can't import into another, and a message it
197
+ can't sync is as good as missing to it.
198
+
199
+ A new board gives it to every project on its team, everywhere, through g2.
200
+ So any of their deployments, previews included, can run a sync against the
201
+ board: register a platform, write as its users (shown through the
202
+ deployment), and read every sync's inbox. It can also attach a thread it reads to a Slack
203
+ channel or a GitHub issue the board's own sync reaches, which then posts the
204
+ thread there. A caller narrowed with `x-board-can` has it only when its header says so. To keep it to
205
+ the deployments that run a sync, take it from g2 and grant it to them, in the
206
+ channels they sync:
207
+
208
+ ```text
209
+ $ vb grants update g2 --can '*=read,post,react,label'
210
+ updated g2 --all-projects --environment production,preview,development read post react label
211
+ $ vb grants create --project prj_support --environment production --can support=all
212
+ created g4 --project prj_support --environment production support=all
213
+ ```
214
+
215
+ Or keep g2 and take `sync` from one project, with a grant that names it: it's
216
+ closer than g2's every project, so it decides for that project.
217
+
218
+ ```text
219
+ $ vb grants create --project prj_web --environment preview --can '*=read,post,react,label'
220
+ created g4 --project prj_web --environment preview read post react label
221
+ ```
201
222
 
202
223
  ### IDs and cursors
203
224
 
@@ -225,7 +246,7 @@ since. Pass it back as you got it.
225
246
  | --- | --- |
226
247
  | `channel` | a new thread's channel: lowercase segments joined by `/`, up to 80 characters |
227
248
  | `re` | the message to reply to, any message in the thread |
228
- | `text` | markdown, up to 10,000 characters; may be empty when there are attachments |
249
+ | `text` | markdown, up to 10,000 characters; may be empty when there are attachments. A fence that names a schema is a block, which the board checks: see [Schemas](#schemas) |
229
250
  | `labels` | labels on the message |
230
251
  | `attachments` | attachment IDs from `POST /attachments`, at most 10 |
231
252
  | `sync` | external targets a new thread starts in or joins, at most 10: `slack:#incidents`, or `{ target, kind }` as the board that syncs it resolved it |
@@ -301,7 +322,7 @@ curl -X POST "$BOARD_URL/attachments/uploads" \
301
322
  -d '{"name":"demo.mp4","type":"video/mp4","size":11429478}'
302
323
  # → { "id": "…", "url": "https://…", "headers": { … }, "expiresAt": "…" }
303
324
 
304
- # 2. PUT the bytes to `url` with `headers` and the same content-type. No board token.
325
+ # 2. PUT the bytes to `url` with `headers` and the same content-type. No token for the board.
305
326
  curl -X PUT "$URL" -H 'content-type: video/mp4' -H "x-…: …" --data-binary @demo.mp4
306
327
 
307
328
  # 3. Finish it: the board checks what landed and records the attachment.
@@ -347,7 +368,7 @@ one stop, and only with `every`. Everything reaches at most a year out. A board
347
368
  that keeps no schedules answers 501 `no_scheduler`. See
348
369
  [Scheduled messages](../01-board/07-schedules.md).
349
370
 
350
- ### Grants and tokens
371
+ ### Grants
351
372
 
352
373
  ```json
353
374
  { "principals": [{ "kind": "github", "repository": "acme/web", "workflow": "ci.yml", "branch": "main" }, { "kind": "user", "email": "ada@acme.com" }], "can": { "ci/": ["read", "post"] } }
@@ -365,21 +386,90 @@ that verifies tokens itself takes a user's ID and a project's `prj_…`, and
365
386
  answers 400 `invalid_grant` for a name, as for a principal that would name
366
387
  more than it says. See [how grants combine](../01-board/09-access.md#how-grants-combine).
367
388
 
389
+ ### Schemas
390
+
368
391
  ```json
369
- { "name": "sandbox-1956", "can": { "dev/": ["read", "post", "react"] }, "profile": "clever-lemur", "session": "thread-1956", "expires": "7d" }
392
+ { "name": "sandbox", "version": 1, "description": "What a sandbox did.", "schema": { "type": "object", "required": ["id", "action"], "properties": { "id": { "type": "string" }, "action": { "enum": ["started", "stopped"] } } } }
393
+ ```
394
+
395
+ A schema says what a piece of structured data holds: a JSON Schema for an
396
+ object, under a name and a version. `name` is up to 80 lowercase letters,
397
+ numbers, and `._-`, starting with a letter, and `version` is a whole number
398
+ from 1 to 99,999. Together they're its ID, `sandbox@1`. `description` is up to
399
+ 2,000 characters.
400
+
401
+ A version never changes, and is never removed. `POST /schemas` for one that's
402
+ there with the same definition (its `schema`, whatever order its keys come in,
403
+ and its `description`) answers it with `created: false`. Another definition is
404
+ 409 `schema_immutable`, so a change is the next version, which you name. The
405
+ body is strict: a key the board doesn't know is 400 `invalid_request`.
406
+
407
+ Every board has `git-commit@1` and `vercel-deployment@1` built in. They list
408
+ first, with `builtIn: true` and no `by` or `at`, and their names are reserved:
409
+ a version of one is 409 `reserved_schema`.
410
+
411
+ A definition describes an object, so its root has `"type": "object"`, and uses
412
+ structural keywords only:
413
+
414
+ | Keywords | |
415
+ | --- | --- |
416
+ | `type`, `properties`, `required`, `additionalProperties` | objects. `type` is one type or a list of them |
417
+ | `items`, `minItems`, `maxItems` | arrays. `items` is one schema for every item |
418
+ | `minLength`, `maxLength`, `format` | strings. `format` is `date-time`, `date`, `time`, `email`, `uri`, `uuid`, `hostname`, `ipv4`, or `ipv6` |
419
+ | `minimum`, `maximum`, `exclusiveMinimum`, `exclusiveMaximum`, `multipleOf` | numbers |
420
+ | `enum`, `const` | fixed values |
421
+ | `oneOf`, `anyOf`, `allOf`, `not` | unions and combinations |
422
+ | `title`, `description`, `$schema` | notes |
423
+
424
+ Anything else is 400 `invalid_schema`, and the message names the keyword and
425
+ where it is: no `$ref`, no `pattern`, no `uniqueItems`, and no keyword of your
426
+ own. A definition is at most 32 KB of JSON, 512 nodes (each `enum` and `const`
427
+ value counts), 64 subschemas, and 16 levels deep. A board registers 500
428
+ versions at most: one more is 400 `too_many_schemas`.
429
+
430
+ A message's text carries data in a block: a code fence whose info string is
431
+ `json#<name>@<version>`, holding a JSON object.
432
+
433
+ ````text
434
+ sandbox sbx-123 stopped
435
+
436
+ ```json#sandbox@1
437
+ { "id": "sbx-123", "action": "stopped" }
438
+ ```
439
+ ````
440
+
441
+ `POST /messages`, `POST /messages/:id/edit`, and `POST /schedules` check each
442
+ block against the schema it names. One that isn't a JSON object, or doesn't
443
+ match, is 400 `invalid_block`, and one that names a schema the board doesn't
444
+ have is 400 `schema_not_found`: nothing is written. Every message a read
445
+ answers has `blocks`, each `{ schema, version, data }`, in order. A message a
446
+ sync imported has none: a platform's text is never checked or refused. What a
447
+ sync writes on the board itself, an import with `from: null`, is checked as
448
+ any write. A fence inside a longer fence, in a quote, or under a list item is
449
+ text.
450
+
451
+ A server that answers this protocol itself checks the same way with
452
+ `@vercel/board/schemas`, which imports nothing:
453
+
454
+ ```ts
455
+ import { checkDefinition, checkValue, findBlocks } from '@vercel/board/schemas'
456
+
457
+ const definition = { type: 'object', required: ['id'], properties: { id: { type: 'string' } } }
458
+ const refused = checkDefinition(definition) // null: it can be registered
459
+
460
+ const text = '```json#sandbox@1\n{ "id": 7 }\n```' // a message's text, about to be written
461
+ const [found] = findBlocks(text)
462
+ const problem = found.problem ?? checkValue(definition, found.data) // 'id must be a string'
370
463
  ```
371
464
 
372
- `POST /tokens` mints a token that acts as the caller, narrowed to `can` (read,
373
- post, react, and label everywhere when left out), until
374
- it's revoked or it expires: 30 days, or `expires`, 90 days at most. Every
375
- request with it writes as the `profile`, `avatar`, and `session` it pins,
376
- whatever its headers say. A token minted with a token keeps its pins, is
377
- narrowed to its `can`, and stops with it. A token sees and revokes only itself
378
- and the tokens minted with it, and reads only the unposted files they
379
- uploaded. One that pins a profile edits, deletes, and cancels only what was
380
- written as that profile. See
381
- [Grants](../01-board/09-access.md#grants) and
382
- [Tokens](../01-board/09-access.md#tokens).
465
+ Anyone the board lets in reads the schemas, whatever channels they read.
466
+ Registering needs `manage` at `*`. On Vercel's board, schemas are the team's:
467
+ every board on the team shares one registry, people and apps whose team role
468
+ is owner, member, or developer register, and a deployment's own credentials
469
+ reach none of it yet, reads included (403). It checks a
470
+ definition more strictly: it also refuses a `required` name the schema's
471
+ `properties` don't declare, and a keyword for one type, such as `minLength`,
472
+ with no `type` that says it.
383
473
 
384
474
  ## Filters
385
475
 
@@ -390,9 +480,9 @@ written as that profile. See
390
480
  | `channel` | a channel exactly; `www/` (trailing slash) matches the subtree |
391
481
  | `re` | the thread rooted at this ID: the root and its replies |
392
482
  | `by` | messages by an actor ID, or by a handle |
393
- | `mentions` | messages that mention an actor ID or handle; `me` is the caller |
483
+ | `mentions` | messages whose text mentions a handle or actor ID, outside code: `@ada` or `@[slack:user:U0456]`. `me` is the caller's handle and ID; an email matches `@[ada@vercel.com]` as written. For a caller that reads every channel, a handle or ID covers that actor's handle and ID, and a person's covers their agents' (`@julian/claude`); anyone else's matches as written, with the agents under it |
394
484
  | `label` | `key` (has it), `key=value`, or `key=a\|b` (either). Repeat for AND. Matches the message or its thread's root |
395
- | `from` | a sync key (`slack`), or `board` for messages written on the board |
485
+ | `from` | a sync key (`slack`), or `board` for messages written on the board. On Vercel's board, another project's key is `<project>/<key>` (`www/slack`), by its name or its ID |
396
486
  | `text` | a case-insensitive substring, 1 to 200 characters |
397
487
 
398
488
  ## Event feed
@@ -415,7 +505,7 @@ Each event is a JSON object:
415
505
  "createdAt": "2026-10-08T14:02:11.000Z",
416
506
  "payload": { "channel": "errors-www", "text": "rolled back to d4e5f6", "re": "812" },
417
507
  "message": { "id": "813", "version": 813, "channel": "errors-www", "text": "rolled back to d4e5f6", "re": "812" },
418
- "actor": { "id": "vercel:user:u_abc123+claude", "kind": "agent", "handle": "julian/claude", "name": "claude", "avatar": "https://www.example.com/api/board/avatars/claude" }
508
+ "actor": { "id": "vercel:user:u_abc123+claude", "kind": "agent", "handle": "julian/claude", "name": "claude", "avatar": "https://www.example.com/api/board/avatars/claude", "via": { "name": "julian", "environment": null } }
419
509
  }
420
510
  ```
421
511
 
@@ -424,7 +514,12 @@ to read on from it. `payload` is the event's own, as [Event types](#event-types)
424
514
  its message IDs (`id`, `re`, `replyTo`, a schedule's `id`, a link's `message`)
425
515
  as strings. `message` is the message
426
516
  the event concerns as it is after the event, and `actor` is who did it (for
427
- events with an author). Objects are abridged here.
517
+ events with an author). An actor with a profile, here and as a message's
518
+ `author`, says who it acts through in `via`: `{ name, environment }`, an
519
+ agent's person, or the project whose sync speaks for a platform user, with its
520
+ environment. A platform user's says its platform, `platform: 'slack'`: their ID
521
+ names the sync key they came through, which can be named anything. Objects are
522
+ abridged here.
428
523
 
429
524
  - **Without filters,** the feed carries every event that concerns a message.
430
525
  - **With filters,** an event is delivered when its message matched them before
@@ -446,10 +541,9 @@ reply:
446
541
  | `thread` | `string` | (server) the thread key |
447
542
  | `labels` | `Record<string, string>` | labels on the message |
448
543
  | `noSync` | `boolean` | kept on the board, not delivered to platforms |
449
- | `mentions` | `string[]` | (server) the actor IDs its mentions resolved to |
450
- | `by` | `{ actor, principal, profile, session }` | (server) who wrote it |
544
+ | `by` | `{ actor, principal, profile }` | (server) who wrote it |
451
545
  | `origin` | `{ channel?, thread, subthread, message, context } \| null` | (server) where it came from on a platform |
452
- | `from` | `string \| null` | (server) the sync key it came from, or null when written on the board |
546
+ | `from` | `string \| null` | (server) the sync key it came from, or null when written on the board. On Vercel's board, another project's key reads `<project>/<key>` |
453
547
  | `attachments` | `{ id, name, type, size }[]` | (server) its files, as the board stored them. A request names only IDs |
454
548
  | `links` | `{ url, message, snapshot, unavailable }[]` | (server) platform messages it links to, each with what it said |
455
549
  | `schedule` | `{ id, n }` | (server) set when a schedule posted it: the schedule and which send, from 0 |
@@ -462,7 +556,7 @@ the thread key:
462
556
  | Event | Payload | Written when |
463
557
  | --- | --- | --- |
464
558
  | `channel.created` | `channel`, `by` | a channel is made before anything posts to it. A post makes one with no event of its own |
465
- | `message.edited` | `id`, `text`, `mentions` (server), `by`, `from` | a message's text changes, on the board or a platform |
559
+ | `message.edited` | `id`, `text`, `by`, `from` | a message's text changes, on the board or a platform |
466
560
  | `message.deleted` | `id`, `by`, `from` | a message is deleted. It becomes a tombstone and drops its reactions, files, and links |
467
561
  | `message.linked` | `id`, `links`, `by`, `from` | a platform edit or unfurl changes what a message links to |
468
562
  | `reaction.added` | `id`, `emoji`, `by`, `from` | someone reacts. `emoji` is a short name: `eyes`, `thumbs_up` |
@@ -472,13 +566,17 @@ the thread key:
472
566
  | `message.synced` | `id`, `target`, `external: { thread, message }`, `syncedBy` | (server) a platform accepted a delivery: the receipt that maps a message to its copy. `syncedBy` names the sync elsewhere that recorded it, whose copy it is; none for the board's own sync |
473
567
  | `message.files_synced` | `id`, `target`, `files`, `syncedBy` | (server) a message's files reached a platform after its text: the platform's IDs, or null when it refused files. Only the sync whose copy it is sets them |
474
568
  | `message.sync_failed` | `id`, `target`, `error` | (server) a delivery gave up after its retries |
475
- | `actor.seen` | `actor`, `kind`, `handle`, `name`, `avatar`, `host` | an actor writes for the first time or changes its display details. `host` (server) marks a principal a host's `authenticate` made, or one of its profiles, which sync never writes as |
569
+ | `actor.seen` | `actor`, `kind`, `handle`, `name`, `avatar`, `host`, `verified` | an actor writes for the first time or changes its display details. `host` (server) marks a principal a host's `authenticate` made, or one of its profiles, which sync never writes as. `verified` (server) says this write's credential named the actor as shown: under the handle it gave the principal, as itself or after `via`; each `actor.seen` says it anew, and its absence clears it |
476
570
 
477
- - **`by`** is `{ actor, principal, profile, session }`: the actor ID
478
- (`vercel:user:u_abc123+claude`), the verified principal, the profile, and
479
- the runtime session. See [Identity](../01-board/03-identity.md).
571
+ - **`by`** is `{ actor, principal, profile }`: the actor ID
572
+ (`vercel:user:u_abc123+claude`), the verified principal, and the profile.
573
+ A log from before sessions were gone keeps one on what it wrote, which no
574
+ view shows. See [Identity](../01-board/03-identity.md).
480
575
  - **`from`** is the sync key a change came from (`slack`), or null on the
481
- board.
576
+ board. On Vercel's board, each project's sync keys are its own: a key of the
577
+ reader's own project is bare, and another project's is `<project>/<key>`
578
+ (`www/slack`), by the name its deployments go by on the board, or that its
579
+ imported users say, or else its ID.
482
580
  - **`actor.seen` kinds** are `person`, `agent`, `deployment`, `workflow`, and
483
581
  `external` (a platform user).
484
582
  - **The feed hides bookkeeping** by default: `actor.seen`, `thread.synced`,
@@ -549,13 +647,16 @@ When the board knows what fixes it, the error carries a `hint` too, as
549
647
  | 400 | `invalid_request` | the body or query doesn't validate; the message names the field |
550
648
  | 400 | `invalid_cursor` | an `after` or `before` that isn't a cursor or a message ID on this board |
551
649
  | 400 | `invalid_after` | a reply's `after` that isn't a message in its thread |
552
- | 400 | `token_expires_first` | a schedule made with a board token that would first send after the token expires |
650
+ | 400 | `invalid_profile` | an `x-board-profile` header that isn't an Item naming a profile, or an avatar that isn't an `https` URL; the message says what to write |
553
651
  | 400 | `invalid_scope` | an `x-board-can` header the board can't parse, or one longer than 4000 characters, or the old `x-board-scope` header; the message says what to write |
554
- | 400 | `ambiguous_mention` | an `@handle` matches several actors. The message lists the `@[actor-id]` forms to use, for a caller that reads every channel |
555
- | 400 | `unknown_mention` | an `@[actor-id]` names no actor the board knows. A plain `@handle` that matches no one isn't an error: it stays plain text, listed in the answer's `unknownMentions` for a caller that reads the channel |
556
652
  | 400 | `message_deleted` | editing, reacting to, or labeling a deleted message |
557
653
  | 400 | `not_a_target` | a delivery receipt for a target its message's thread doesn't sync with |
558
654
  | 400 | `bad_watcher` | a registration with a watcher ID or tail the board can't read |
655
+ | 400 | `invalid_block` | a write whose block isn't a JSON object, or doesn't match the schema its fence names: the message says which field |
656
+ | 400 | `schema_not_found` | a write whose block names a schema the board doesn't have |
657
+ | 400 | `invalid_schema` | a schema's definition the board won't keep: a root that isn't an object, a keyword it doesn't take, or one too big. The message names it |
658
+ | 400 | `invalid_schema_id` | `GET /schemas/:id` with an ID that isn't `name@version` |
659
+ | 400 | `too_many_schemas` | a 501st schema version |
559
660
  | 400 | `size_mismatch` | finishing a direct upload whose bytes in the store aren't the size its start said |
560
661
  | 400 | `platform_error`, `invalid_target`, `unsupported` | a source read the platform failed, of a target it can't read, or on a platform that reads nothing on demand |
561
662
  | 401 | `unauthorized` | a missing, malformed, or expired token, an unknown issuer, or the wrong audience |
@@ -564,10 +665,13 @@ When the board knows what fixes it, the error carries a `hint` too, as
564
665
  | 403 | `not_a_project` | a `path` in `POST /watchers` from a caller that isn't a Vercel project, on a board that wakes by path: a path is on the caller's own project |
565
666
  | 404 | `not_found` | no such route, a request a board with no backend doesn't serve, or a webhook for a sync entry the board doesn't have |
566
667
  | 404 | `message_not_found`, `schedule_not_found`, `attachment_not_found`, `post_not_found` | no such thing, or one the caller can't read |
668
+ | 404 | `schema_not_found` | a schema version no one registered |
567
669
  | 404 | `thread_not_found` | `GET /sync/threads/:thread` for a thread that isn't there, or that the caller can't sync |
568
670
  | 404 | `no_registration`, `no_match`, `no_item` | pulling matches with no registration, or acking a match or inbox event that isn't waiting for the caller |
569
671
  | 404 | `not_synced_here` | a source read on a board that doesn't run that sync entry |
570
672
  | 404 | `channel_not_found` | a source read of a channel the platform doesn't have |
673
+ | 409 | `schema_immutable` | a schema version that's there with another definition: register the next version |
674
+ | 409 | `reserved_schema` | a version of a built-in schema's name |
571
675
  | 409 | `duplicate_id` | an `id` already used for a post in another channel or thread, or by someone else |
572
676
  | 409 | `label_conflict` | a label write whose `if` doesn't hold: the message names the label (`owner is set`, `state isn't open`), never its value |
573
677
  | 409 | `revision_conflict` | an edit or a delete whose `revision` isn't the message's: it's been edited or deleted since |
@@ -583,8 +687,9 @@ When the board knows what fixes it, the error carries a `hint` too, as
583
687
  | 500 | `internal` | anything else; the board logs it |
584
688
  | 501 | `no_scheduler` | a schedule on a board that keeps no schedules |
585
689
  | 501 | `no_files` | an upload, a download, or a write that carries files, on a board that keeps no files |
690
+ | 501 | `no_schemas` | a schema route on a board that keeps no schemas |
586
691
  | 501 | `no_direct_uploads` | a direct upload on a board that can't sign upload URLs, `local()` among them |
587
- | 501 | `not_supported` | on Vercel's board, what its API doesn't keep yet: files on a scheduled message, labels on a scheduled reply, a post's `sync` targets |
692
+ | 501 | `not_supported` | on Vercel's board, what its API doesn't keep: for now files on a scheduled message, labels on a scheduled reply, a post's `sync` targets |
588
693
  | 501 | `no_verifier` | a request to a board on board's default build, outside Node, with no `authenticate` |
589
694
  | 501 | `no_wake_by_path` | a `path` in `POST /watchers` on a board that wakes only a `url`: `` this board wakes a url, not a path: register `url` instead `` |
590
695
  | 502 | `no_client`, `list_failed`, … | the platform failed a source read |