@vercel/board 0.25.1 → 0.26.1

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 (42) hide show
  1. package/dist/{a2-A830f5NS.mjs → a2-C4A4vr0M.mjs} +4 -4
  2. package/dist/{attempts-CLG840Oj.mjs → attempts-HXcskN1w.mjs} +1 -11
  3. package/dist/backend-a2.mjs +1 -1
  4. package/dist/{backend-http-CYtfwqAW.mjs → backend-http-3IxGe13a.mjs} +18 -4
  5. package/dist/{backend-http-CJd4Fu0U.mjs → backend-http-CQWTNzym.mjs} +2 -2
  6. package/dist/backend-http.mjs +1 -1
  7. package/dist/backend-http.node.mjs +1 -1
  8. package/dist/{backend-vercel-Bqg2QfTd.mjs → backend-vercel-BPyPi8Cv.mjs} +24 -6
  9. package/dist/{backend-vercel-BhwPExmE.mjs → backend-vercel-l5465vyw.mjs} +3 -3
  10. package/dist/backend-vercel.mjs +1 -1
  11. package/dist/backend-vercel.node.d.mts +5 -0
  12. package/dist/backend-vercel.node.mjs +2 -2
  13. package/dist/cli-commands.d.mts +1 -1
  14. package/dist/cli-commands.mjs +1 -1
  15. package/dist/cli-embedded.d.mts +5 -1
  16. package/dist/cli-embedded.mjs +8 -4
  17. package/dist/cli.mjs +4 -4
  18. package/dist/{commands-D0wXq6CY.d.mts → commands-D6gvrOh3.d.mts} +4 -4
  19. package/dist/{commands-BtL4jFq8.mjs → commands-nEG47RM_.mjs} +7 -7
  20. package/dist/{engine-ROa7-IQY.mjs → engine-Bfe6pcXb.mjs} +2 -2
  21. package/dist/{exports-DCqgO_mr.mjs → exports-B-AeCbYw.mjs} +2 -2
  22. package/dist/{index.default-BejExznB.mjs → index.default-CfAjbQrU.mjs} +1 -1
  23. package/dist/index.mjs +3 -3
  24. package/dist/index.node.mjs +1 -1
  25. package/dist/inspect/app.js +29 -29
  26. package/dist/inspect/engine.js +5 -5
  27. package/dist/{main-DOhNCWMd.mjs → main-DGyQ4gje.mjs} +24 -9
  28. package/dist/{node-Bkd1x0QI.mjs → node-Ybi9E6bO.mjs} +67 -37
  29. package/dist/{serve-D2O0C6Kk.mjs → serve-BDLJebk7.mjs} +3 -3
  30. package/dist/{server-BF4WJ7qi.mjs → server-BSXTDTOp.mjs} +3 -3
  31. package/dist/{ids-C6AYo1bu.mjs → wait-until-Dw4XrIDQ.mjs} +12 -1
  32. package/dist/{watchers-hash-BHNXy_N7.mjs → watchers-hash-BTF_bMIN.mjs} +4 -4
  33. package/docs/01-board/04-messages.md +1 -1
  34. package/docs/01-board/05-reading.md +2 -2
  35. package/docs/01-board/06-watchers.md +7 -5
  36. package/docs/02-sync/01-overview.md +2 -2
  37. package/docs/03-guides/03-ci.md +2 -2
  38. package/docs/03-guides/04-triage.md +5 -5
  39. package/docs/04-reference/01-cli.md +10 -4
  40. package/docs/04-reference/03-http.md +1 -1
  41. package/docs/index.md +2 -2
  42. package/package.json +1 -1
@@ -47,6 +47,12 @@ const code = await createApp({
47
47
  onError: (failure, { json }) => console.error(json ? JSON.stringify(failure) : failureLines(failure).join('\n')),
48
48
  // { reason, message }: a write that went through, with something to say. With --json, it's in the result.
49
49
  onWarning: (warning) => console.error(warning.message),
50
+ // Your Vercel login, and the team whose board to use when --scope names none, as this CLI
51
+ // resolves its own: asked for only when a request needs them. Help, a typo, or misuse never asks.
52
+ // A login that throws fails the request: board never falls back to `vercel login`'s. A team
53
+ // that throws fails it too, with what it threw as the failure's details.
54
+ login: async () => process.env.VERCEL_AUTH_TOKEN!,
55
+ team: async () => process.env.VERCEL_ORG_ID ?? null,
50
56
  }).run(process.argv.slice(3))
51
57
  ```
52
58
 
@@ -485,7 +491,7 @@ schedules that reply in that thread. `--all` adds done and canceled ones.
485
491
  ### post
486
492
 
487
493
  ```text
488
- vb post <channel|id> ["<text>"] [--label k=v]... [--attach <file>]... [--sync <target>]... [--no-sync] [--id <key>]
494
+ vb post <channel|id> ["<text>"] [--label k=v]... [--attach <file>]... [--sync <target>]... [--no-sync] [--idempotency-key <key>]
489
495
  ```
490
496
 
491
497
  Starts a thread. The channel is created by its first post. Given a message ID
@@ -499,7 +505,7 @@ for new threads only.
499
505
  | `--attach <file>` | uploads a file (at most 4 MB, or 100 MB on a board whose blob store takes direct uploads; 10 per message) and attaches it. Every file is checked before any uploads. A board that keeps no files refuses: ``error: this board keeps no files: pass `blob` to `a2()` `` |
500
506
  | `--sync <target>` | also starts or joins a thread there: `slack:#incidents`, `github:owner/repo:12`; new threads only |
501
507
  | `--no-sync` | keeps the message on the board: it reaches none of the channel's mirrored channels |
502
- | `--id <key>` | an idempotency key: the same key never posts twice |
508
+ | `--idempotency-key <key>` | the same key never posts twice, so a retried step posts once |
503
509
 
504
510
  `--sync` and `--no-sync` together are a usage error. See
505
511
  [Messages](../01-board/04-messages.md) and
@@ -508,7 +514,7 @@ for new threads only.
508
514
  ### reply
509
515
 
510
516
  ```text
511
- vb reply <id> ["<text>"] [--attach <file>]... [--no-sync] [--id <key>]
517
+ vb reply <id> ["<text>"] [--attach <file>]... [--no-sync] [--idempotency-key <key>]
512
518
  ```
513
519
 
514
520
  Replies in a thread. `<id>` may be any message in it: the board stores the
@@ -739,7 +745,7 @@ of them must match.
739
745
  | `--by <handle>` | messages by an actor, by handle or exact actor ID. A person's handle covers their agents (`julian/claude`) and linked accounts |
740
746
  | `--mentions` | messages that mention you |
741
747
  | `--mentions @handle` | messages that mention that actor |
742
- | `--from <source>` | where a message came from: a sync key (`slack`, `github`), or `board` for messages written on the board |
748
+ | `--source <source>` | where a message came from: a sync key (`slack`, `github`), or `board` for messages written on the board |
743
749
  | `--label <key>` | messages with the label, any value |
744
750
  | `--label <key>=<value>` | that value; `state=open\|draft` means either |
745
751
  | `--text <words>` | a case-insensitive substring of the text (1 to 200 characters), not search |
@@ -122,7 +122,7 @@ a refused write it can read answers 403. `GET /me` returns the caller's
122
122
  | GET | `/watchers` | `{ watchers }`: the caller's registration, or every one for `manage` in every channel |
123
123
  | GET | `/watchers/matches` | `{ matches }`: the caller's matches it can run now, one thread at a time and in order, each `{ id, watcher, thread, lease, attempt, event }` and leased to it for 5 minutes. Query: `limit` (10 by default, at most 50), `wait` (seconds to hold for one, at most 25). 404 `no_registration` without a registration |
124
124
  | POST | `/watchers/matches/:id/ack` | `{ lease, error?, skip? }`: done, an error to try again after a wait (after 5 tries it's `watch.failed`), or `skip` to drop it. 404 `no_match`, 409 `stale_lease` for a lease that ran out |
125
- | POST | `/wake` | On a board on `http()` (no token): it has matches to pull. Answers `{ ran }` |
125
+ | POST | `/wake` | On a board on `http()` (no token): it has matches to pull. Answers `{ ran }` once they've run, or 202 after 2 seconds while they keep running |
126
126
  | GET | `/inbox/:key` | `{ events }`: raw platform events for a sync entry, newest first. Query: `channel`, `limit` (50 by default, at most 500). With `sync` in every channel, the board's own and every registered sync's; a sync elsewhere sees what it pushed |
127
127
  | GET | `/sources/:key/read` | Read a platform channel, thread, or permalink without syncing it. Query: `target`, `limit` (50 by default, at most 200). The board reads it with entry `key`'s app, through the sync it runs, and needs `manage` in every channel; a board that runs no entry `key` answers 404 `not_synced_here` |
128
128
  | POST | `/sources/:key/join` | Add entry `key`'s app to a public channel so `/sources/:key/read` can read it. Body: `{ target }`, a channel (`#name`, an ID) or a link into it. Answers `{ channel, name, joined }`, `joined: false` when the app was already in. Only where the entry opted in (`slack({ join: true })`), 403 `join_disabled` otherwise; private and Slack Connect channels are never joined. Needs `manage` in every channel; a board that runs no entry `key` answers 404 `not_synced_here` |
package/docs/index.md CHANGED
@@ -110,7 +110,7 @@ const team = board({
110
110
  // sync as above
111
111
  watch: {
112
112
  triage: {
113
- tail: 'errors-www --from slack',
113
+ tail: 'errors-www --source slack',
114
114
  run: async ({ event, board }) => {
115
115
  if (event.type !== 'message.posted' || event.message?.re !== null) return
116
116
  // the reply reaches the Slack thread too:
@@ -124,7 +124,7 @@ export const { scheduler } = backend
124
124
  ```
125
125
 
126
126
  A watcher is a `vb tail` the board runs for you. Try the expression in a
127
- terminal first (`vb tail errors-www --from slack --json`); `run` gets exactly
127
+ terminal first (`vb tail errors-www --source slack --json`); `run` gets exactly
128
128
  those events, durably, with retries and nothing kept open. See
129
129
  [Watchers](./01-board/06-watchers.md).
130
130
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vercel/board",
3
- "version": "0.25.1",
3
+ "version": "0.26.1",
4
4
  "description": "A message board you mount in one route: one durable log, verified authors, live tail, and two-way sync.",
5
5
  "license": "MIT",
6
6
  "type": "module",