The Toolkit
Run a board from another service: its notices, the QR codes beside it, and notices pushed to the front (a paid question, a shout-out).
https://deckboard.party/api.- How a board shows things
- Keys
- Example: paid questions on a stream
- Boards
- Notices and links
- Pushing a notice
- The queue
- Public address and screens
- Live updates
- What the cards carry
- Account and keys
- Errors and limits
How a board shows things
A board has its own list of notices (1 to 12), and turns from one to the next. Each notice holds for its own seconds, or the board's holdSeconds when it has none. Or the owner pins one notice (pinned) and the board holds it and does not turn. Each notice may carry a link; a small frame on the wall beside the board shows that link as a QR code a viewer can scan. When the notice changes, a roller shutter in the frame comes down, the code changes behind it, and the shutter rolls back up. A notice with no link leaves the shutter down.
Screens (the public address and private TV links) also lay flat QR codes over the picture, in the bottom-left corner: Scan for details for the notice showing now (pushed or not; none when it has no link), and Buy screentime for the board's buyLink (none when it is null). They stay up when the pointer idles, so they can always be scanned, and are left out with ?clean.
A service can also push a notice. Pushed notices wait in a queue and take the board one after another, each for its own number of seconds, even over a pinned notice. Then the board goes back to its own notices. Every screen showing the board (the owner's page, its public address, a private TV link) works out what to show from the same clock, so they all flip together: one full turn of the notices (the cycle) is the sum of their times, and the notice showing at Unix ms t is the one whose slot t mod cycle falls in, counting from notice 1.
Keys
The box holder makes a key at deckboard.party/account and hands it to your service. Send it on every request:
Authorization: Bearer dk_3f9a… # 43 characters, shown once when made
Content-Type: application/json
A key acts for its account on that account's boards (up to 3). It cannot make or revoke keys, change the username or close the account. Revoke a key at the same page and it stops working at once. Call the API from your server, never from a browser: the key is a password.
Base address: https://deckboard.party/api. Bodies are JSON. Times are Unix milliseconds unless the field says seconds.
Example: paid questions on a stream
A podcaster's board hangs in their stream (an OBS browser source pointed at its public address). Your service runs the page where viewers ask, takes the payment and checks the content. Deckboard only shows what you send it.
- A viewer finds the podcaster's page on your service, writes their question and their link, and pays.
- Your service checks the payment and the content (and the link) by its own rules.
- Your service pushes the notice to the podcaster's board, with the link and your payment id as
ref:curl https://deckboard.party/api/boards/7c1e…/push \ -H "Authorization: Bearer $DECKBOARD_KEY" -H "Content-Type: application/json" \ -d '{"text": "SAM ASKS: WHAT IS THE BEST BOARD?", "link": "https://sam.example/show", "seconds": 45, "ref": "pay_8812"}' - Deckboard answers with the notice's place and times. Your service can tell the viewer when they'll be on. On the stream, the board flips to their question and the frame rolls up their QR code.
- If something goes wrong (a refund, a moderator's second thoughts), remove it:
DELETE /api/boards/7c1e…/queue/p_….
Boards
No key needed: the sizes, the rooms (scenes[].id), the sounds and drum, every character the cards carry.
The account's boards: {"boards": [Board, …], "max": 3}.
Make a board, with any of the fields below (at most 3 per account; a fourth is 409 board_limit). Answer 201 {"board": Board}.
Take a board down. Its queue goes with it, and every screen showing it is told.
Change any of the fields below. The answer is the whole board.
| Field | What |
|---|---|
| id | 24 hex characters (read only) |
| name | 1–40 characters |
| owner, slug | its address: deckboard.party/<owner>/<slug>. slug is 1–40 of a–z, 0–9 and single hyphens, unique among the owner's boards. It follows the name until set. |
| public | true (default): anyone may watch it at its address. false: only the owner and private TV links. |
| size | note (3 rows × 15), medium (6 × 22), large (8 × 32) |
| scene | the room: GET /api/catalog lists them |
| sound | station, card, enamel, glass |
| messages | the notices: a list of 1–12, each a list of rows (upper-cased and padded to the board) |
| links | parallel to messages: a URL or null each |
| qr | what each link's QR code encodes (read only): the link itself, or a short deckboard.party/go/… address for links over 48 characters, so the code stays small enough to scan off a stream |
| message | the first notice (read only here; see below for setting one notice) |
| holdSeconds | 3–3600 (default 20): how long each of the board's own notices holds, unless it has its own time |
| seconds | parallel to messages: each notice's own hold, 3–3600 (numbers outside are clamped), or null for holdSeconds |
| pinned | the index (from 0) of the notice fixed on the board, or null to turn through them all. Pushed notices still take over for their time. |
| buyLink | the owner's “buy screentime” URL, shown as a second QR code on screens, or null |
| buyQr | what that code encodes (read only): the link, or a short deckboard.party/go/… address, as with qr |
| pushSeconds | 3–3600 (default 30): how long a pushed notice holds the board when the push gives no seconds |
| queue | the pushed notices showing or waiting (read only; see the queue) |
| viewpoint | where the camera stands: {pos, target, fov} or null. Set by the owner by dragging; visitors may look about but never change it. |
| now | the server's clock when the answer was made (Unix ms) |
Notices and links
Set the board's own notices in whichever shape suits you:
// the clearest: each notice with its link; text wraps to the board by itself
PATCH /api/boards/:id
{"notices": [
{"text": "Ask me anything, live Fridays", "link": "https://pod.example/ask", "seconds": 40},
{"message": ["", "NEXT SHOW", "FRIDAY 8PM"], "link": null, "seconds": null}
], "holdSeconds": 15, "pinned": null, "buyLink": "https://pod.example/buy-screentime"}
// or the parallel lists
{"messages": [["HELLO"], ["WORLD"]], "links": ["https://a.example", null], "seconds": [10, null]}
// or one notice (replaces the list; the pace is kept)
{"text": "Back in five", "link": null}
// fix notice 1 on the board; null goes back to turning
{"pinned": 0}
A notice's seconds may be left out or null for the board's holdSeconds. links and seconds lists may also be sent alone, for the current notices (a shorter list leaves the rest null); messages alone keeps each place's link and time. If a new list is too short for the pin, the pin is dropped. {"buyLink": null} takes the buy-screentime code down.
text wraps at word boundaries, keeps your line breaks, and splits a word longer than a row. If it doesn't fit, the answer is 400 too_long and nothing changes. message is rows as you lay them out. Links must be http:// or https://, at most 2000 characters, with no user name or password in them.
Pushing a notice
| Field | What |
|---|---|
| text | message | the notice (as above); one is required |
| link | optional URL for the frame's QR code |
| seconds | 3–3600; default the board's pushSeconds |
| ref | optional, up to 200 characters: your own id for it (a payment, a message). It comes back in the queue. |
The notice joins the end of the queue. It starts when the one before it ends, or about 1.5 s from now if nothing is waiting (so every screen hears of it first). Answer 201:
{"push": {"id": "p_04270540d1bfc3d39135", "message": ["SAM ASKS: WHAT", "IS THE BEST", "BOARD?"],
"link": "https://sam.example/show", "qr": "https://sam.example/show", "ref": "pay_8812",
"startsAt": 1794450001500, "endsAt": 1794450046500},
"position": 0, "now": 1794450000000}
Pushes are limited to 120 a minute per board, and 100 may wait at once.
The queue
{"queue": [Push, …], "now": …}: the one showing (if any) first, then the waiting ones in order.
Remove one. If it is showing, it ends now. The ones after it move up and keep their order.
Clear the queue; the board goes back to its own notices.
Public address and screens
https://deckboard.party/<owner>/<slug> shows the board full screen in its room, from the owner's saved place. Anyone watching may drag to look about and scroll to step closer. That is never saved, and the next visit starts from the owner's place again. Point a stream's browser source at it.
The owner can make a board private ("public": false). Its address then answers only to the owner, and anyone watching is cut off. A private board can still be shown on a TV or a stream through a private line: a secret /tv/… address the owner makes in The Counter. Usernames can change, and a board's address changes with them, so read owner and slug from the API rather than storing the address.
The public board, without a key (404 if it is private).
Make (or replace) the board's private screen link: {"token", "url"}, shown once. Any screen on the old link is cut off at once.
Cut the private screen link.
The board behind a private screen link, without a key.
Live updates
Every change (a PATCH, a push, a removal) is sent at once to every screen through a WebSocket. You don't need these to drive a board, but a dashboard can listen too:
wss://deckboard.party/api/u/<owner>/<slug>/live // public boards
wss://deckboard.party/api/display/<token>/live // a private screen link
// messages: {"type": "board", "board": Board} | {"type": "deleted"} | {"type": "revoked"}
// send "ping" every 30 s to keep it open; the answer is "pong"
What the cards carry
Every printable key on a US keyboard: A–Z (lower case is upper-cased), 0–9 and
. - : ! ? ' / & , $ ; " # % @ * ( ) [ ] { } < > + = _ ^ ~ \ | `
Anything else (accents, emoji, other currencies) is refused with 400 bad_message, naming the character. Nothing is silently dropped. GET /api/catalog returns the drum as a string.
Account and keys
The account behind the key: {"user": {"id", "email", "username", "emailVerified", "created"}}.
These need the owner signed in on the site, not a key:
{"username": "…"}: 3–30 of a–z, 0–9 and single hyphens, unique, some words reserved. The account's board addresses change with it.
List, make ({"name"}; returns {"key", "token"}, the token shown once) and revoke API keys. At most 10 per account.
Errors and limits
Errors come back as {"error": {"code": "…", "message": "…"}} with an HTTP status:
| Code | When |
|---|---|
| bad_key (401) | missing, malformed or revoked key |
| session_required (403) | keys, username and closing the account need the person signed in |
| not_found (404) | no such board on this account, or no such pushed notice |
| bad_message, too_long (400) | a character not on the cards, a row too long, text that doesn't fit |
| bad_link (400) | not an http(s) URL |
| bad_seconds, bad_hold (400) | not a number, outside 3–3600 (pushes and holdSeconds), or more seconds than notices |
| bad_pinned (400) | pinned is neither null nor the index of a notice |
| queue_full (409) | 100 notices already waiting |
| slug_taken, username_taken (409) | the address is in use |
| board_limit (409) | the account already has 3 boards |
| bad_slug, bad_username (400) | wrong form, or a reserved word |
| rate_limited (429) | 600 requests a minute per key; 120 pushes a minute per board |