For developers

The person API

Build an app that works as the person who signs it in: it shows their cards, answers one when they press something in it, and keeps their phone quiet while they’re there. Herdr’s plugin is the first.

What an app may do

An app acts as the person, and only when they press something in it. Pending You never answers for them, and neither may your app.

It may

  • See the cards the person’s assistants ask them, on one computer or all of them.
  • Answer a card, write to its assistant, put it in Later, or hand it to another assistant.
  • See which assistants are running, and in which terminal.
  • Bring the assistant that asked to the front on its computer, when the person presses Show.
  • Keep the person’s phone quiet while they’re using it.

It never may

  • Act on a high-stakes card (it spends money, can’t be undone or goes public). It can show one: send the person to the card’s url.
  • Answer on a timer, from a model’s decision, or for a card the person hasn’t seen.
  • See or change their account, sign-in, billing, secrets or assistants.
Every answer says where it came from
The card, its history and the assistant that asked all read “Answered in Herdr on build-01”. Answers are limited to 30 a minute, watched for bursts, and the person removes an app in one tap.

Apps and review

Every app is registered with Pending You. Register yours in Settings › Developers: it works for you at once, and for everyone once we’ve reviewed it.

  • Yours works for you at once.An app you register works for your own account and up to 10 testers while it waits for review.
  • Everyone else needs it verified.Review checks who publishes it, its domain, its name and logo, its privacy policy, that its scopes match what it does, and that every answer comes from a press by the person.
  • The person sees who it is.Its name, its publisher and whether it’s verified are on the approval, with what it may do in plain words.
  • You agree to the developer terms.Use what your app sees only to serve the person who signed it in: never sell it or train models on it. Read the developer terms.

Register your app

In Pending You, open Settings › Developers and press Register an app. You get a client ID at once, and a client secret if your app is a website with a server.

  1. Name it, and say how it signs in.A terminal or script signs in with a code on a computer set up with Pending You. A desktop or phone app, a website with a server, or a single-page web app signs in with PKCE and comes back to one of its redirect addresses.
  2. List its redirect addresses, exactly.https on your website’s domain or one under it; http://127.0.0.1 or http://localhost on any port; or, for a desktop or phone app, its own scheme named for your domain backwards (example.acme.desk:/oauth for acme.example). No wildcards, at most 10.
  3. Choose the most it may ask for.Its scopes’ ceiling: a sign-in asks for some or all of them, and the person sees each in plain words. A web or desktop app has no computer of its own, so it always holds cards:read:all.
  4. Keep the secret on your server.A website’s client secret is shown once. Rotate it in Settings › Developers; the old one stops working at once.
It works for you and your testers right away
Name up to 10 testers by the address they sign in to Pending You with. Anyone else needs it verified. You can have 5 apps waiting to be verified at once.

Before review

  • Prove your domain.Add a TXT record pendingyou-app-verification=<token> to it, or put that line in https://<domain>/.well-known/pendingyou-app-verification.txt, then press Check now. Settings › Developers shows your token.
  • Add a privacy policy, terms and a support email.The policy says what your app keeps of people’s cards, and where. They stay as they are while we review it.
  • Press Request review.We check who publishes it, its domain and redirect addresses, its name, its privacy policy, that its scopes match what it does, and that every answer comes from a press by the person. We write to its support email if something needs to change.

Signing in

OAuth 2.1 at Pending You, for the resource /v1. Terminals and plugins sign in by device code, proving which computer they’re on; web and desktop apps sign in with authorization code and PKCE (below).

  1. Make a key for the sign-in.A P-256 key that stays with your app (see DPoP below). Its thumbprint goes in the computer’s attestation, so the sign-in is bound to it from the start.
  2. Have the computer vouch for it, and start.pendingyou machine attest signs an attestation with the computer’s own key (made by npx pendingyou init). A computer the person hasn’t set up can’t be allowed.
  3. Show the code, and poll.The person allows it on their phone, on the card Pending You shows them, or at the link. Poll the token endpoint every interval seconds with a DPoP proof each time.
StartShell
curl -X POST https://www.pendingyou.com/oauth/device \
-d client_id=YOUR-CLIENT-ID \
-d scope='cards:read cards:answer' \
-d resource=https://www.pendingyou.com/v1 \
-d machine=build-01 \
--data-urlencode machine_attestation="$(npx -y pendingyou@latest machine attest \
--client-id YOUR-CLIENT-ID --cnf YOUR-KEY-THUMBPRINT --name build-01)"
What comes backJSON
{
"device_code": "Gq7…",
"user_code": "WDJB-MJHT",
"verification_uri": "https://www.pendingyou.com/device",
"verification_uri_complete": "https://www.pendingyou.com/device?code=WDJB-MJHT",
"expires_in": 600,
"interval": 3,
"client_id": "YOUR-CLIENT-ID"
}
PollShell
curl -X POST https://www.pendingyou.com/oauth/token \
-H "DPoP: $PROOF" \
-d grant_type=urn:ietf:params:oauth:grant-type:device_code \
-d device_code=Gq7… \
-d client_id=YOUR-CLIENT-ID
JSONJSON
{
"access_token": "usr_…:…:…",
"token_type": "DPoP",
"expires_in": 900,
"refresh_token": "usr_…:…:…",
"scope": "cards:read cards:answer"
}
One sign-in per computer
Access tokens last 15 minutes. Refresh tokens change with every use. A sign-in bound to a computer’s key renews each time it’s used; any other lasts 30 days. Signing the same app in again on the same computer replaces the old sign-in.

Example:Signing in with a code, in a whole appexamples/answer-cards/sign-in.ts

Sign in from a web or desktop app

A desktop app, a single-page app or a website signs in through the person’s browser: authorization code with PKCE (S256 only), for the resource /v1. The person sees your app’s card, with where it goes back to, and allows it.

  1. Make a key, a verifier and a state.A P-256 key for the sign-in (see DPoP below), a PKCE verifier, and a random state. Name the key’s thumbprint as dpop_jkt (RFC 9449 §10), so the code is bound to it too.
  2. Send the person to Pending You.Use one of your app’s registered redirect addresses, exactly. A desktop app may listen on any port of its registered http://127.0.0.1 address (RFC 8252), or come back through its own scheme.
  3. Exchange the code.Check the state that comes back, then exchange the code with the verifier and a DPoP proof by your key. A desktop or single-page app must prove it; Pending You asks for a nonce first.
Where to send the personText
https://www.pendingyou.com/oauth/authorize
?response_type=code
&client_id=YOUR-CLIENT-ID
&redirect_uri=http://127.0.0.1:53682/callback
&scope=cards:read cards:read:all cards:answer
&state=RANDOM-STATE
&code_challenge=BASE64URL-SHA256-OF-THE-VERIFIER
&code_challenge_method=S256
&resource=https://www.pendingyou.com/v1
&dpop_jkt=YOUR-KEY-THUMBPRINT
What comes backText
http://127.0.0.1:53682/callback?code=usr_…:…:…&state=RANDOM-STATE&iss=https://www.pendingyou.com
Exchange the codeShell
curl -X POST https://www.pendingyou.com/oauth/token \
-H "DPoP: $PROOF" \
-d grant_type=authorization_code \
-d code=usr_…:…:… \
-d redirect_uri=http://127.0.0.1:53682/callback \
-d client_id=YOUR-CLIENT-ID \
-d code_verifier=THE-VERIFIER \
-d resource=https://www.pendingyou.com/v1
  • Every card.An app signed in this way has no computer, so it asks for cards:read and cards:read:all, and sees every card the person’s assistants ask them.
  • One sign-in per copy.Signing in again with the same key replaces the sign-in; another copy of your app, with its own key, keeps its own. A website’s sign-in replaces the person’s earlier one.
  • A website with a server.It exchanges its code with its client secret, and may skip DPoP: its tokens are then bearer tokens, which never leave its server.
With the SDKTypeScript
// A desktop app: the browser comes back to this computer.
import { fileStore, loopbackSignIn } from '@recordplane/pendingyou-sdk/node'
 
const signIn = await loopbackSignIn({
origin: 'https://www.pendingyou.com',
clientId: 'YOUR-CLIENT-ID',
scopes: ['cards:read', 'cards:read:all', 'cards:answer'],
store: fileStore(`${process.env.HOME}/.config/example-app/pendingyou.json`),
open: (url) => openInBrowser(url),
})
await signIn.signedIn
 
// A single-page app: away to Pending You, and back to its own page.
import { finishRedirectSignIn, redirectToSignIn } from '@recordplane/pendingyou-sdk'
 
await redirectToSignIn({ origin: 'https://www.pendingyou.com', clientId: 'YOUR-CLIENT-ID', redirectUri, scopes })
// …then on redirectUri's page:
await finishRedirectSignIn({ store })

Example:A desktop app’s sign-in through the browser, in a whole appexamples/answer-cards/sign-in.ts

DPoP

A device sign-in’s tokens, and a desktop or single-page app’s, are bound to your app’s key (RFC 9449), so a copy of them is useless without it. Send each request with a proof made for it.

A requestShell
curl https://www.pendingyou.com/v1/cards \
-H "Authorization: DPoP $ACCESS_TOKEN" \
-H "DPoP: $PROOF"
  • A new proof for every request.Its method and address (no query), the time, a random jti, and at /v1 the access token’s SHA-256 (ath). ES256 only.
  • Nonces.Every answer carries DPoP-Nonce: put the latest in your next proof. The token endpoint requires one; /v1 asks again with use_dpop_nonce when yours is old. Make the proof again with the new one and send the request once more.
dpop.jsTypeScript
// One key for the sign-in: keep its private JWK with the tokens, nowhere else.
const key = await crypto.subtle.generateKey({ name: 'ECDSA', namedCurve: 'P-256' }, true, ['sign'])
const { kty, crv, x, y } = await crypto.subtle.exportKey('jwk', key.publicKey)
const jwk = { kty, crv, x, y }
 
const b64url = (bytes) => btoa(String.fromCharCode(...new Uint8Array(bytes)))
.replaceAll('+', '-').replaceAll('/', '_').replace(/=+$/, '')
const sha256 = async (text) => b64url(await crypto.subtle.digest('SHA-256', new TextEncoder().encode(text)))
const part = (value) => b64url(new TextEncoder().encode(JSON.stringify(value)))
 
// What the sign-in is bound to (the attestation's --cnf): RFC 7638.
const thumbprint = await sha256(JSON.stringify({ crv, kty, x, y }))
 
// A proof for each request: its method and address, now, the token's hash, and the last nonce.
async function proof(method, url, accessToken, nonce) {
const header = { typ: 'dpop+jwt', alg: 'ES256', jwk }
const claims = {
jti: crypto.randomUUID(),
htm: method,
htu: url.split(/[?#]/)[0],
iat: Math.floor(Date.now() / 1000),
...(accessToken ? { ath: await sha256(accessToken) } : {}),
...(nonce ? { nonce } : {}),
}
const signing = `${part(header)}.${part(claims)}`
const signature = await crypto.subtle.sign({ name: 'ECDSA', hash: 'SHA-256' }, key.privateKey,
new TextEncoder().encode(signing))
return `${signing}.${b64url(signature)}`
}

Scopes

Ask for what your app does, no more. The person may allow less: every card, not just one computer’s, is a tick that starts off.

ScopeWhat it allows
cards:readSee the cards the assistants on the signed-in computer ask the person.
cards:read:allSee every card, from all the person’s computers and assistants.
cards:answerAnswer cards when the person presses something, and take an answer back in its 5 seconds.
cards:replyWrite to the assistant that asked, on its card.
cards:laterPut cards in Later and bring them back.
cards:delegateHand a card to another of the person’s assistants, and take it back.
assistants:readSee which assistants are running, and in which terminal.
assistants:showBring the assistant that asked to the front on this computer when you press Show. It learns which card and assistant.
presence:deskKeep the person’s phone quiet while they’re using the app.
cards:high_stakesPending You’s own apps only: act on high-stakes cards, each time with the person’s yes signed on the device.
cards:managePending You’s own apps only: say the person opened a card with a new reply, keep an answer back while its Undo is paused, and read the thread above a card.
notify:managePending You’s own apps only: send the person’s notifications to this device, and see and change their notification settings.
assistants:managePending You’s own apps only: rename the person’s assistants, the names they see them called.
account:managePending You’s own apps only: open a page of Pending You on the web, signed in.
presence:focusPending You’s own apps only: say which assistant’s pane the person is in, so its cards wait until they leave it (30 minutes at most). It learns which pane they’re in.

Endpoints

33 routes under https://www.pendingyou.com/v1, each with the scope it needs. Open one for its fields, its example and what it may refuse.

GET/v1/meWho and what this sign-in is

The person, their workspace, the app and this sign-in: its scopes, its reach (one computer or every card), its computer, and when it ends. Any scope.

Scope: anyETag

RequestText
GET /v1/me
200JSON
{
"user": {
"id": "usr_0a1b2c3d4e5f60718293"
},
"workspace": {
"id": "ws_0a1b2c3d4e5f60718293"
},
"app": {
"id": "app_00000000000000000002",
"name": "Pending You for Herdr",
"verified": true
},
"grant": {
"id": "apg_7d6c5b4a39281706f5e4",
"scopes": ["cards:read", "cards:answer", "presence:desk"],
"reach": "machine",
"machine": {
"id": "mch_1e2d3c4b5a6978877665",
"name": "build-01"
},
"dpop": true,
"createdAt": "2026-10-05T19:20:00.000Z",
"expiresAt": "2026-11-04T19:20:00.000Z"
}
}

May refuse with: invalid app_not_available rate_limited server_error unavailable

GET/v1/snapshotThe queue in one read

Every list at once, as Pending You shows them: the stack’s first 200 in its order (the first 3 whole), Later’s soonest 100, the newest 100 with a helper, and Done (every card with a new reply the person hasn’t opened, then the newest 50 of the last 30 days); the counts; and the areas and groups the cards are filed in, as the person arranged them. Kept to this sign-in’s reach. Send its ETag back as If-None-Match to hear 304 when nothing changed; GET /v1/cards pages on past each list’s first.

Scope: cards:readETag

RequestText
GET /v1/snapshot
If-None-Match: "5d41402abc4b2a76b9719d911017c592"
200JSON
{
"lanes": {
"new": ["req_4f1c9a0e2b7d6c5a8e31"],
"yours": ["req_8b7a6c5d4e3f2a1b0c9d"],
"theirs": ["req_1c2d3e4f5a6b7c8d9e0f"],
"threads": {
"new": [
{
"id": "req_4f1c9a0e2b7d6c5a8e31",
"cards": 1,
"more": 0
}
],
"yours": [
{
"id": "req_8b7a6c5d4e3f2a1b0c9d",
"cards": 2,
"more": 0
}
],
"theirs": []
},
"opens": "motion"
},

May refuse with: invalid app_not_available rate_limited server_error unavailable

GET/v1/cardsThe cards in reach, one list at a time

Waiting on the person in the stack’s order (pending), in Later soonest back first (snoozed), with a helper (delegated), or done in the last 30 days newest first. Filters repeat (`?area=prj_…&area=prj_…`); pages follow `next`. The first `whole` cards come whole.

Scope: cards:readETag

Query
Field ? optionalTypeWhat it’s for
status?"pending" | "snoozed" | "delegated" | "done"
area?string[]
assistant?string[]
agent?string[]
app?("claude-code" | "codex" | "cursor" | "gemini-cli" | "opencode" | "pi" | "antigravity" | "grok" | "muse" | "chatgpt" | "claude" | "dots" | "other" | "webhook")[]
machine?string[]
threadId?string
limit?integer
whole?integer
after?string
RequestText
GET /v1/cards?status=pending&limit=20
200JSON
{
"cards": [
{
"id": "req_4f1c9a0e2b7d6c5a8e31",
"version": 3,
"status": "pending",
"turn": "you",
"kind": "choice",
"title": "Which queue should the nightly sweeper use?",
"summary": "Two queues can take it. The old one is slower but already has alerts.",
"urgency": "today",
"blocking": true,
"options": [
{
"id": "a",
"label": "The new queue"
},
{
"id": "b",
"label": "The old queue"
}
],
"recommendedIds": ["a"],
"threadId": "req_4f1c9a0e2b7d6c5a8e31",

May refuse with: invalid app_not_available rate_limited server_error unavailable

GET/v1/cards/{id}One card, whole

A card out of reach is not found, exactly as one that doesn’t exist.

Scope: cards:readETag

RequestText
GET /v1/cards/req_4f1c9a0e2b7d6c5a8e31
200JSON
{
"card": {
"id": "req_4f1c9a0e2b7d6c5a8e31",
"…": "…"
}
}

May refuse with: invalid app_not_available not_found rate_limited server_error unavailable

POST/v1/cards/{id}/answerAnswer a card

With the version you showed the person. Its assistant hears it once its 5 seconds are over; until `undoUntil` this app may take it back. On a card waiting to be sent (`sendTo`), its no is `notSent` and its yes is POST /v1/cards/{id}/delegate; a teammate’s is answered in Pending You.

Scope: cards:answerIdempotency-Key required

Body (JSON)
Field ? optionalTypeWhat it’s for
versioninteger
choiceIds?string[]
approved?boolean
text?string
note?object
textstring
via?"text" | "voice"
theyDecide?true
answers?map
failed?true
failedStep?integer
done?boolean
askId?string
handled?"self" | "leave"
notSent?true
notNeeded?true
holdSeconds?integer
RequestText
POST /v1/cards/req_4f1c9a0e2b7d6c5a8e31/answer
Idempotency-Key: 6f1d2c9e-…
 
{
"version": 3,
"choiceIds": ["a"],
"note": {
"text": "Keep the alerts on."
}
}
200JSON
{
"id": "req_4f1c9a0e2b7d6c5a8e31",
"status": "answered",
"version": 4,
"undoUntil": "2026-10-06T14:05:05.000Z"
}

May refuse with: invalid app_not_available high_stakes yes_required area_change forbidden not_found version_conflict not_waiting delegated conflict idempotency_in_progress idempotency_mismatch rate_limited server_error not_available client_outdated unavailable

POST/v1/cards/{id}/undoTake this app’s answer back

Within its 5 seconds, and only an answer given in this app.

Scope: cards:answer

Body (JSON)
Field ? optionalTypeWhat it’s for
askId?string
RequestText
POST /v1/cards/req_4f1c9a0e2b7d6c5a8e31/undo
200JSON
{
"id": "req_4f1c9a0e2b7d6c5a8e31",
"status": "pending",
"version": 5
}

May refuse with: invalid app_not_available high_stakes not_your_answer forbidden not_found not_waiting hold_over conflict idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

POST/v1/cards/{id}/finishMove a card to Done

The person moves a card in In motion to Done themselves (its `actions` offer `finish`), with the version you showed. Filed (`how` filed): done for them, and nothing its assistant receives changes: an answer still to pick up, words it still owes, its status and version. One that still waited on them (`how` closed) is answered as closed without an answer (`answer.closed`), held, woken and read as any answer. Until `undoUntil`, POST /v1/cards/{id}/undo takes it back. Pending You’s own apps only (`cards:manage`).

Scope: cards:manage

Body (JSON)
Field ? optionalTypeWhat it’s for
versioninteger
RequestText
POST /v1/cards/req_4f1c9a0e2b7d6c5a8e31/finish
 
{
"version": 4
}
200JSON
{
"id": "req_4f1c9a0e2b7d6c5a8e31",
"how": "filed",
"status": "answered",
"version": 4,
"undoUntil": "2026-10-06T14:05:05.000Z"
}

May refuse with: invalid app_not_available high_stakes forbidden not_found version_conflict conflict idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

POST/v1/cards/{id}/messagesWrite to the assistant that asked

The person’s words, on its card. They hand it the turn and it acts on them as the answer, so they count against the answers’ limit.

Scope: cards:reply

Body (JSON)
Field ? optionalTypeWhat it’s for
bodystring
via?"text" | "voice"
RequestText
POST /v1/cards/req_4f1c9a0e2b7d6c5a8e31/messages
 
{
"body": "Ask Sam first: it’s their queue."
}
200JSON
{
"id": "req_4f1c9a0e2b7d6c5a8e31",
"messageId": "msg_3c2b1a0f9e8d7c6b5a49",
"turn": "agent",
"version": 4
}

May refuse with: invalid app_not_available high_stakes yes_required forbidden not_found not_waiting delegated conflict idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

POST/v1/cards/{id}/laterPut a card in Later

Until a time (a minute to two months ahead) or a preset, `1h`, `tonight` or `tomorrow`, in `timeZone`.

Scope: cards:later

Body (JSON)
Field ? optionalTypeWhat it’s for
untilISO datetime | "1h" | "tonight" | "tomorrow"A time, or a preset: in an hour, tonight (6:00 PM) or tomorrow morning (8:00 AM), in timeZone.
timeZone?stringThe person’s IANA time zone, e.g. "America/Chicago", for the presets. Default UTC.
RequestText
POST /v1/cards/req_4f1c9a0e2b7d6c5a8e31/later
 
{
"until": "tomorrow",
"timeZone": "America/Chicago"
}
200JSON
{
"id": "req_4f1c9a0e2b7d6c5a8e31",
"status": "snoozed",
"until": "2026-10-07T13:00:00.000Z",
"version": 4
}

May refuse with: invalid app_not_available high_stakes forbidden not_found not_waiting delegated conflict idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

POST/v1/cards/{id}/backBring a card back from Later

Now, to its place in the stack. One already back answers with its version.

Scope: cards:later

RequestText
POST /v1/cards/req_4f1c9a0e2b7d6c5a8e31/back
200JSON
{
"id": "req_4f1c9a0e2b7d6c5a8e31",
"status": "pending",
"version": 5
}

May refuse with: invalid app_not_available high_stakes forbidden not_found not_waiting conflict idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

POST/v1/cards/{id}/delegateHand a card to another assistant

One of the person’s assistants in reach (GET /v1/assistants). `freely`: its answer goes straight back; `loop`: it comes to the person first. Until `undoUntil` the helper can’t see it. On “Ask Maple again?”, yes this time is the card’s `sendTo.to` in `sendTo.mode`; “from now on” is the person’s, in Pending You.

Scope: cards:delegate

Body (JSON)
Field ? optionalTypeWhat it’s for
toobject
assistantIdstring
agentId?string
mode"freely" | "loop"
note?string
RequestText
POST /v1/cards/req_4f1c9a0e2b7d6c5a8e31/delegate
 
{
"to": {
"assistantId": "con_2b3c4d5e6f708192a3b4"
},
"mode": "loop",
"note": "Sam owns the queues."
}
200JSON
{
"id": "req_4f1c9a0e2b7d6c5a8e31",
"status": "delegated",
"version": 4,
"hears": "while-working",
"undoUntil": "2026-10-06T14:05:05.000Z"
}

May refuse with: invalid app_not_available high_stakes yes_required forbidden not_found not_waiting delegated conflict idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

POST/v1/cards/{id}/take-backTake a card back from its helper

Before the helper answers it: the card waits on the person again.

Scope: cards:delegate

RequestText
POST /v1/cards/req_4f1c9a0e2b7d6c5a8e31/take-back
200JSON
{
"id": "req_4f1c9a0e2b7d6c5a8e31",
"status": "pending",
"version": 5
}

May refuse with: invalid app_not_available high_stakes forbidden not_found not_waiting conflict idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

POST/v1/cards/{id}/seenSay the person opened a card

Seen for the person on every device, up to `upTo` (the newest thing the screen drew: send the `presentation.seen.upTo` the whole card came with; absent: now), never backwards: the card is no longer `unread`, and a new reply the screen drew leaves Pending and loses its mark in Done. `seen: false` when there was no new reply for them on it. Pending You’s own apps only, for now (cards:manage).

Scope: cards:manage

Body (JSON)
Field ? optionalTypeWhat it’s for
upTo?ISO datetimeThe newest thing on the card the screen drew: the `presentation.seen.upTo` the whole card it drew came with (its newest message, or when it came or last changed). Absent: up to now.
RequestText
POST /v1/cards/req_4f1c9a0e2b7d6c5a8e31/seen
 
{
"upTo": "2026-10-06T14:04:30.000Z"
}
200JSON
{
"id": "req_4f1c9a0e2b7d6c5a8e31",
"seen": true
}

May refuse with: invalid app_not_available not_found idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

POST/v1/cards/{id}/holdKeep an answer back while its Undo is paused

Its assistant sees it `seconds` from now instead: a minute ahead while the person keeps the Undo paused, asked again as it stays paused, then the time it had left. Pending You’s own apps only (cards:manage).

Scope: cards:manage

Body (JSON)
Field ? optionalTypeWhat it’s for
secondsintegerFrom now: a minute ahead while the Undo is paused (asked again as it stays paused), or the time it has left once it resumes.
RequestText
POST /v1/cards/req_4f1c9a0e2b7d6c5a8e31/hold
 
{
"seconds": 60
}
200JSON
{
"id": "req_4f1c9a0e2b7d6c5a8e31",
"undoUntil": "2026-10-06T14:06:05.000Z"
}

May refuse with: invalid app_not_available forbidden not_found not_waiting hold_over conflict idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

POST/v1/cards/{id}/stepsTick a to-do’s step off, or untick it

By its id (`s3`): `done` true or false, never a toggle, so the last to arrive wins. `through` ticks the steps before it too, but not one with a command to copy or a link of its own to open, nor one the person unticked. Kept on the card for every device; nothing reaches its assistant, and its version doesn’t move. Refused once the card stops waiting on the person, and `invalid` for a step that isn’t on it anymore.

Scope: cards:answer

Body (JSON)
Field ? optionalTypeWhat it’s for
stepstring
doneboolean
through?boolean
RequestText
POST /v1/cards/req_4f1c9a0e2b7d6c5a8e31/steps
 
{
"step": "s3",
"done": true,
"through": true
}
200JSON
{
"id": "req_4f1c9a0e2b7d6c5a8e31",
"progress": {
"rev": 4,
"done": ["s1", "s2", "s3"]
}
}

May refuse with: invalid app_not_available high_stakes forbidden not_found not_waiting delegated conflict idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

GET/v1/threads/{threadId}A thread’s older items, a page at a time

What “Show N earlier” brings above a card (`presentation.conversation.before`): its thread’s earlier items older than the ones `before` showed, newest first (reverse a page to draw it), each in `before`’s words, at most `limit` (50). `after` is `before.next`, then each page’s `next`, until a page has none. Only the cards in this sign-in’s reach, as the card’s own thread: never a card of another computer for a sign-in kept to one, nor a card a teammate handed the person; a thread out of reach is not found. Pending You’s own apps only (cards:manage); any other app is `forbidden` (`reason` `not_pending_you`).

Scope: cards:manageETag

Query
Field ? optionalTypeWhat it’s for
afterstring
limit?integer
RequestText
GET /v1/threads/req_4f1c9a0e2b7d6c5a8e31?after=req_7c6b5a4f3e2d1c0b9a88~2026-10-06T13%3A40%3A00.000Z~card~req_4f1c9a0e2b7d6c5a8e31
200JSON
{
"thread": {
"id": "req_4f1c9a0e2b7d6c5a8e31",
"items": [
{
"kind": "line",
"cardId": "req_4f1c9a0e2b7d6c5a8e31",
"at": "2026-10-06T13:31:00.000Z",
"line": "message",
"messageId": "msg_5e4d3c2b1a0f9e8d7c6b",
"time": {
"key": "conversation.time",
"args": {
"at": {
"time": "2026-10-06T13:31:00.000Z",
"as": "clock",
"zone": "UTC"
}
},
"text": "1:31 PM"
},
"mark": {
"id": "said",
"tone": "quiet"

May refuse with: invalid app_not_available forbidden not_found rate_limited server_error unavailable

POST/v1/yes-keyRegister the key that signs the person’s yes

The key that signs the person’s yes to a high-stakes card (`Pending-You-Yes`), kept on the device behind Face ID or the phone’s passcode. `proof` is a JWS of type `pending-you-yes-key+jwt`, signed by that key with it in its header, naming this sign-in (`grant`), when it was made (`iat`) and a `jti`. A new key replaces the last. Pending You’s own apps only (cards:high_stakes).

Scope: cards:high_stakes

Body (JSON)
Field ? optionalTypeWhat it’s for
proofstring
RequestText
POST /v1/yes-key
 
{
"proof": "eyJ0eXAiOiJwZW5kaW5nLXlvdS15ZXMta2V5K2p3dCIs…"
}
200JSON
{
"registeredAt": "2026-10-06T14:00:00.000Z"
}

May refuse with: invalid app_not_available forbidden idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

GET/v1/changesWhat changed since a cursor

Ids and types only, in commit order, kept to the reach. Without `after`: from now. With `wait` (up to 25 seconds) it waits for the first change. Read GET /v1/cards again on start and every 10 minutes too: a card that comes into reach makes no change.

Scope: cards:readETag

Query
Field ? optionalTypeWhat it’s for
after?string
wait?integer
limit?integer
RequestText
GET /v1/changes?after=djEuNzAwMC4xMg&wait=25
200JSON
{
"changes": [
{
"type": "card.created",
"cardId": "req_4f1c9a0e2b7d6c5a8e31",
"at": "2026-10-06T14:02:11.000Z"
}
],
"cursor": "djEuNzAxMi4w",
"more": false
}

May refuse with: invalid app_not_available rate_limited server_error unavailable

GET/v1/assistantsThe assistants in reach

Each sign-in, its computer and how it hears answers, and its agents: live, recent or quiet, their open cards, and the sessions running now with the terminal each runs in. Live ones first.

Scope: assistants:readETag

RequestText
GET /v1/assistants
200JSON
{
"assistants": [
{
"id": "con_9f8e7d6c5b4a39281706",
"app": "claude-code",
"appName": "Claude Code",
"name": "Claude Code on build-01",
"machine": {
"id": "mch_1e2d3c4b5a6978877665",
"name": "build-01"
},
"hears": "while-working",
"agents": [
{
"id": "agt_6a5b4c3d2e1f0a9b8c7d",
"name": "sweeper",
"state": "live",
"liveAt": "2026-10-06T14:04:40.000Z",
"openCards": 1,
"liveSessions": [
{
"appSessionId": "5b0c…",
"cwd": "/home/sam/code/sweeper",
"liveAt": "2026-10-06T14:04:40.000Z",

May refuse with: invalid app_not_available rate_limited server_error unavailable

PATCH/v1/agents/{agentId}Rename an assistant

The name the person sees one of their assistants called, on every card, row and notification (`shownName`), 1 to 40 characters; null takes it away, so it’s called by its own name again. Nothing the assistant sends changes it, and its own name (`name`), cards and webhook stay as they are. `invalid` with `reason` `name_empty`, `name_too_long` or `name_characters` (a line break or a hidden character). Pending You’s own apps only (assistants:manage).

Scope: assistants:manage

Body (JSON)
Field ? optionalTypeWhat it’s for
namestringThe name you see it called, 1 to 40 characters; null goes back to its own.
RequestText
PATCH /v1/agents/agt_6a5b4c3d2e1f0a9b8c7d
 
{
"name": "Sweeper"
}
200JSON
{
"agentId": "agt_6a5b4c3d2e1f0a9b8c7d",
"shownName": "Sweeper",
"changed": true
}

May refuse with: invalid app_not_available not_found idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

GET/v1/showsShow requests for this computer

The person pressed Show on a card in Pending You: bring the agent that asked to the front, in a place of the kinds this app names (`places`, repeated: `herdr`, `tmux`). Only the show requests still open for this sign-in’s computer, oldest first, each with its card’s and agent’s ids and the agent’s places of those kinds, never a card’s words. With `wait` (up to 25 seconds) it waits for the first; each call says this app is listening for the next minute, so the button shows. Before moving anything, check the place is yours and still the agent’s: answer `not_found` when it isn’t, and leave a place on another server of yours to that server’s app. A show only brings a window you already know to the front: never type, run or open anything for one. A sign-in with no computer is refused, `no_machine`.

Scope: assistants:showETag

Query
Field ? optionalTypeWhat it’s for
places("herdr" | "tmux")[]
wait?integer
RequestText
GET /v1/shows?places=herdr&wait=25
200JSON
{
"shows": [
{
"id": "shw_3c2b1a09f8e7d6c5b4a3",
"card": {
"id": "req_4f1c9a0e2b7d6c5a8e31"
},
"agent": {
"id": "agt_6a5b4c3d2e1f0a9b8c7d",
"name": "sweeper",
"app": "claude-code"
},
"places": [
{
"app": "herdr",
"paneId": "w2:p1",
"server": "3f9a6c1e0b7d2458",
"sessionId": "5b0c…"
}
],
"expiresAt": "2026-10-06T14:05:12.000Z"
}
]
}

May refuse with: invalid app_not_available no_machine rate_limited server_error unavailable

POST/v1/shows/{showId}Answer a show request

`shown` once the agent’s place is at the front, `not_found` when you couldn’t confirm it and moved nothing. The person sees what came of it. The first answer wins (`already_answered`), and a show request is dead 30 seconds after the press (`expired`). One for another computer is not found.

Scope: assistants:show

Body (JSON)
Field ? optionalTypeWhat it’s for
result"shown" | "not_found"
RequestText
POST /v1/shows/shw_3c2b1a09f8e7d6c5b4a3
 
{
"result": "shown"
}
200JSON
{
"id": "shw_3c2b1a09f8e7d6c5b4a3",
"result": "shown",
"answeredAt": "2026-10-06T14:04:43.000Z"
}

May refuse with: invalid app_not_available no_machine not_found already_answered expired idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

POST/v1/presenceSay the person is at this app

`here: true` every 30 seconds while they’re active in it (it lasts 75), `here: false` when they leave. Meanwhile their phones stay quiet, as with Pending You open on a computer. Answers 204.

Scope: presence:desk

Body (JSON)
Field ? optionalTypeWhat it’s for
hereboolean
RequestText
POST /v1/presence
 
{
"here": true
}
AnswerText
204 No Content

May refuse with: invalid app_not_available rate_limited server_error client_outdated unavailable

POST/v1/focusSay which pane the person is in

Pending You’s own apps only (Herdr’s watcher). The focused pane (`place`, null for none: a Herdr pane by its id and its server’s hash) and the person’s last sign of activity there (`activeAt`, taken as now at the latest). A card their assistant in that pane also asks them in the conversation waits out of their sight while they stay; it shows when they leave the pane, after 5 minutes with no sign of them, or after 30 minutes, and never if it’s answered in the conversation first. Say it on every change of focus, and every `everySeconds` while they’re active or `held` isn’t empty. `held` names the cards held in this place now, ids only, to keep off what the app shows.

Scope: presence:focus

Body (JSON)
Field ? optionalTypeWhat it’s for
placeobject
app"herdr"
paneIdstringThe focused Herdr pane: "w2:p1".
serverstringWhich Herdr server: sha256(hostname + HERDR_SOCKET_PATH), its first 16 hex characters.
activeAtISO datetime
RequestText
POST /v1/focus
 
{
"place": {
"app": "herdr",
"paneId": "w2:p1",
"server": "3f9a0c1d2e4b5a69"
},
"activeAt": "2026-11-03T15:04:05Z"
}
200JSON
{
"held": ["req_4e5f60718293a4b5c6d7"],
"idleSeconds": 300,
"everySeconds": 30
}

May refuse with: invalid app_not_available not_found rate_limited server_error client_outdated unavailable

GET/v1/clientWhat this app should know of Pending You

For Pending You’s own apps, which say who they are in `Pending-You-Client` (`ios/1.4.0+120`): whether this version must update (`status`, `minimum`, `recommended`), its switches, and the versions of the string catalog and of cards’ presentation. Any scope, or no sign-in at all; signed in, switches that reach some people are read for the person.

Scope: any, or noneETag

RequestText
GET /v1/client
Pending-You-Client: ios/1.4.0+120
200JSON
{
"client": {
"name": "ios",
"version": "1.4.0",
"build": 120
},
"status": "ok",
"minimum": "1.2.0",
"recommended": "1.4.0",
"switches": {
"lanes": false,
"liveActivities": false,
"lockScreenAnswers": true
},
"catalog": {
"version": "69e8a26f5a67fa34"
},
"presentation": {
"v": 1
}
}

May refuse with: invalid app_not_available rate_limited server_error unavailable

POST/v1/web-handoffOpen a page of Pending You on the web, signed in

For Pending You’s own app on the phone, signed in with its key: a link that signs its browser view in to Pending You once, within 60 seconds, and lands on `path` (Settings or one of its sections, an area, a card, or another page of the app). The link stops working once this sign-in ends, and so does the session it starts. Ask for a new one each time: it’s never kept, and never sent again for a retry. Pending You’s own apps only (account:manage).

Scope: account:manage

Body (JSON)
Field ? optionalTypeWhat it’s for
pathstring
RequestText
POST /v1/web-handoff
 
{
"path": "/app/settings?section=data"
}
200JSON
{
"url": "https://www.pendingyou.com/signin/handoff#token=Hk3v9QZr0sYb7WmT2xLp5NcE8uJd4FgA6iOq1yRtKwM",
"expiresAt": "2026-10-06T14:21:00.000Z",
"path": "/app/settings?section=data"
}

May refuse with: invalid app_not_available forbidden rate_limited server_error client_outdated unavailable

POST/v1/time-zoneKeep the person’s time zone

The person’s time zone, by its IANA name (`America/Chicago`), kept as the web keeps it: the days a card’s conversation breaks on, and the zone its times and dates are written in (`zone` in a time’s arguments), are the person’s own. Send it when the app starts and whenever the device’s zone changes; the same zone again changes nothing (`changed` false). An unknown zone is refused (`invalid`). Pending You’s own apps only (account:manage).

Scope: account:manage

Body (JSON)
Field ? optionalTypeWhat it’s for
timeZonestring
RequestText
POST /v1/time-zone
 
{
"timeZone": "America/Chicago"
}
200JSON
{
"timeZone": "America/Chicago",
"changed": true
}

May refuse with: invalid app_not_available forbidden rate_limited server_error client_outdated unavailable

POST/v1/push/devicesRegister this iPhone for notifications

Pending You’s own iPhone app, with the push token iOS gave it (hex), the APNs host it belongs to (`sandbox` for a build from Xcode, `production` for TestFlight and the App Store) and its bundle id. Register on every launch: the same token is the same device, and a new token from this sign-in replaces its last. `firstDevice` says no device of the person’s took notifications before this one: then, and only then, ask “Show the question on your lock screen?”, as the web does. Once the person removed this iPhone (Settings’ Remove, or DELETE), registering again leaves it off and says so (`device.off: removed`, `ready` false): send `turnOn: true` only from the person’s own Turn on in the app. Its notifications follow the person’s settings and carry ids only (`cardId`, `threadId`, `reason`); read the card to show more. It takes pushes while this sign-in lasts: signing out removes it. `ready` is false until this server can send to iPhones; the device is kept either way. Pending You’s own apps only (notify:manage).

Scope: notify:manage

Body (JSON)
Field ? optionalTypeWhat it’s for
kind"apns"
tokenstring
environment"sandbox" | "production"
bundlestring
turnOn?boolean
RequestText
POST /v1/push/devices
 
{
"kind": "apns",
"token": "5f3c5f3c5f3c5f3c5f3c5f3c5f3c5f3c5f3c5f3c5f3c5f3c5f3c5f3c5f3c5f3c",
"environment": "production",
"bundle": "com.pendingyou.app"
}
200JSON
{
"device": {
"id": "psh_3c4d5e6f708192a3b4c5",
"kind": "apns",
"environment": "production",
"addedAt": "2026-11-17T15:04:05.000Z"
},
"ready": true,
"firstDevice": true
}

May refuse with: invalid app_not_available forbidden idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

DELETE/v1/push/devices/{deviceId}Stop notifications to a device

One of the person’s devices gets nothing more, as Remove in Settings. `reason`: `removed` (the default) when the person turned notifications off, so it stays off when the app registers again at launch, until they turn them on in the app (`turnOn`); `signed_out` when the app is signing out, so the next sign-in brings it back. `removed` is false when it was off already. Pending You’s own apps only (notify:manage).

Scope: notify:manage

Query
Field ? optionalTypeWhat it’s for
reason?"removed" | "signed_out"
RequestText
DELETE /v1/push/devices/psh_3c4d5e6f708192a3b4c5?reason=signed_out
200JSON
{
"id": "psh_3c4d5e6f708192a3b4c5",
"removed": true
}

May refuse with: invalid app_not_available not_found rate_limited server_error client_outdated unavailable

POST/v1/push/devices/{deviceId}/testSend a test notification

A real notification to one of the person’s devices, now, as Send test in Settings: whether its push service took it, or says it’s gone (then it’s removed; register again). Where this server can’t send to it yet, `push_not_set_up`. Pending You’s own apps only (notify:manage).

Scope: notify:manage

RequestText
POST /v1/push/devices/psh_3c4d5e6f708192a3b4c5/test
200JSON
{
"id": "psh_3c4d5e6f708192a3b4c5",
"sent": true,
"gone": false
}

May refuse with: invalid app_not_available not_found rate_limited server_error client_outdated push_not_set_up unavailable

GET/v1/push/settingsThe person’s notification settings

Their mute, whether an assistant stuck on a card still notifies while muted, whether lock screens show the question, and which new cards notify: the same settings as on the web, for every device. Also in GET /v1/snapshot as `notify`. Pending You’s own apps only (notify:manage).

Scope: notify:manageETag

RequestText
GET /v1/push/settings
200JSON
{
"mute": {
"choice": "1h",
"until": "2026-11-17T16:04:05.000Z"
},
"stillWhenStuck": true,
"showQuestion": true,
"newCards": "soon",
"apns": {
"ready": true
}
}

May refuse with: invalid app_not_available rate_limited server_error unavailable

PATCH/v1/push/settingsChange the person’s notification settings

The fields sent change; the rest stay. `mute`: `1h`, `2h`, `tomorrow` (8:00 AM in `timeZone`) or `forever`, or null to turn notifications back on. The web shows the change too: they’re one set of settings. Pending You’s own apps only (notify:manage).

Scope: notify:manage

Body (JSON)
Field ? optionalTypeWhat it’s for
mute?"1h" | "2h" | "tomorrow" | "forever"
timeZone?string
stillWhenStuck?boolean
showQuestion?boolean
newCards?"stuck" | "soon" | "all"
RequestText
PATCH /v1/push/settings
 
{
"mute": null,
"showQuestion": false
}
200JSON
{
"stillWhenStuck": true,
"showQuestion": false,
"newCards": "soon",
"apns": {
"ready": true
}
}

May refuse with: invalid app_not_available idempotency_in_progress idempotency_mismatch rate_limited server_error client_outdated unavailable

GET/v1/push/notifications/{id}What a card’s notification says

For Pending You’s iPhone app’s notification service extension, after a push (which carries ids, `reason` and a neutral line only): the words a browser’s notification says for this card, by the person’s choice to show the question on the lock screen, with `reason` as the push carried it. A reason it doesn’t know answers the neutral line. `gone`: the card no longer waits on the person for that reason; drop the notification or show the words. Any failure: keep the neutral line. Pending You’s own apps only (notify:manage).

Scope: notify:manageETag

Query
Field ? optionalTypeWhat it’s for
reasonstring
RequestText
GET /v1/push/notifications/req_4f1c9a0e2b7d6c5a8e31?reason=waiting
200JSON
{
"title": "Wren · Billing",
"body": "Which reply should go to the customer?",
"url": "/app/r/req_4f1c9a0e2b7d6c5a8e31"
}

May refuse with: invalid app_not_available forbidden not_found rate_limited server_error unavailable

  • Reads have ETags.Send the ETag back as If-None-Match and a read that hasn’t changed answers 304.
  • Answers need an Idempotency-Key.A new key for each answer (every other change to a card takes one too). The same key and request within 24 hours get the first answer again, so a retry never answers twice.
  • The person can end a card themselves.An answer with handled: "self" says they’ll do it themselves (I’ll handle it), and "leave" that they won’t do a to-do (Skip). Nothing is sent in their name, and a card with a helper comes back from it.
  • A to-do can say it didn’t work.With what happened in note (or a file): failed: true, and failedStep when a step is named. A to-do without steps sends failed alone; words without it read as Done with a note.
  • Show the version you answer.An answer names the card’s version. If the card changed meanwhile, it’s a 409 version_conflict: show it again and ask.

Example:Showing a card and answering it from the person’s key pressexamples/answer-cards/answer.ts

The snapshot

GET /v1/snapshot reads the whole queue at once, as Pending You shows it: each list’s first cards, the counts, and the areas and groups the cards are filed in. Read it when your app opens and whenever the change feed says something changed.

FieldWhat it holds
pendingWaiting on the person, in the stack’s order: the first 200, the first 3 whole.
laterIn Later, soonest back first: the first 100.
delegatedWith a helper, newest first: the first 100.
doneEvery card with a new reply the person hasn’t opened, then the newest 50 done in the last 30 days.
countsHow many there are of each, and for one computer’s sign-in, how many wait on the person elsewhere.
areasThe areas the cards are filed in, as the person arranged them: colour, icon, group, place, pinned, hidden and their notifications.
groupsThe person’s groups of areas, in their order.
  • Send its ETag back.With If-None-Match, a snapshot that hasn’t changed answers 304, so reading it every few seconds while your app is open costs next to nothing.
  • Kept to the sign-in’s reach.One computer’s sign-in sees that computer’s cards, the areas they’re in and those areas’ groups. A sign-in that sees every card sees every area.
  • Page on with GET /v1/cards.Each list stops at its first cards: counts says how many there are, and GET /v1/cards pages through the rest.
  • The lanes.lanes lists the cards of New, Your turn and Waiting on them in each one’s order, and lanes.threads the same lanes as rows, one per thread: the card to draw, how many of the thread’s cards it stands for (cards), and how many more of them are in its own lane (more). lanes.opens says which lane to open on: In motion when something there is the person’s turn, else New. motion lists the cards In motion that no other list holds, Your turn first, so every card a lane counts is here. For Pending You’s own apps, a card In motion carries presentation.row.motion, the line its row says: whose move it is and what was done last.
  • New replies.When an assistant writes back after the person answered, its card carries newReply until they open it: answersYou when it answers what they asked, with their words in asked.
  • Images.An image on a card has its width and height, and a thumbUrl and previewUrl beside its downloadUrl, all running out together.
  • Files on their way.A card lists every file on it, each with its status: ready once it has arrived, waiting while it’s on its way, failed when it never came, and removed once its card had been done 90 days. Only a ready file has links. Keep a status you don’t know, and show the file as one you can’t open.

Cards waiting to be sent

An assistant may ask to send its card on: to another of the person’s assistants, one they introduced it to by handing it one of its cards (“Ask Maple again?”), or to one of their teammates (“Send this to Doug?”). The card waits on the person, and its sendTo says to whom.

FieldWhat it holds
nameWhom: an assistant by its whole name (“Maple”, “stripe-migration”), a teammate by the name the two share a team under.
kind“assistant”, asked again, or “teammate”. Read any other as a teammate’s: it’s answered in Pending You.
toAn assistant’s, while the card waits and your sign-in may hand it to them: what POST /v1/cards/:id/delegate takes for the yes. Absent when they’re out of your sign-in’s reach, or gone.
modeAn assistant’s: how its answer goes on a yes. “freely”: straight to the assistant that asked, the decision being the helper’s to make. “loop”: back to the person first, for an approval or anything high stakes.
helpedAn assistant’s: the card of the asker’s it last answered (answered true), else the one the person handed it, and when. theirs true: introductions go both ways, and that card was this assistant’s own, which the one asking worked on: say “Ask Maple?”, not “again”.
  • Yes, this time.POST /v1/cards/:id/delegate with sendTo.to and sendTo.mode. It goes to that assistant as Delegate hands it, and the person can take it back.
  • No.POST /v1/cards/:id/answer with notSent: true, and a note if they like. The assistant that asked hears answer.notSent (“Don’t send it to Maple”) and doesn’t ask again. Any other answer is refused, invalid with send_first, and so are words to its assistant.
  • Never “from now on”.Letting it ask Maple without asking the person each time is theirs to say, in Pending You. A card it then hands straight over is with Maple, its delegation.onStandingOk true.
  • A teammate’s is answered in Pending You.Its actions offer neither, and Pending You refuses both (forbidden, teammate): show it, and send the person to its url.
ask-again.tsTypeScript
const card = await pendingYou.cards.get(id)
const sendTo = card.sendTo
if (sendTo?.kind === 'assistant' && card.status === 'pending') {
// Yes, this time: to that assistant, as Pending You says its answer goes.
if (key === 'y' && sendTo.to && card.actions.includes('delegate'))
await pendingYou.cards.delegate(card.id, {
to: sendTo.to,
mode: sendTo.mode === 'freely' ? 'freely' : 'loop',
})
// No: its assistant hears answer.notSent, and doesn't ask again.
if (key === 'n' && card.actions.includes('answer'))
await pendingYou.cards.answer(card.id, { version: card.version, notSent: true })
}

Questions on a card

An assistant may ask the person something on a card that’s still open: its helper, on a card the person handed it (the card stays with the helper), or its own assistant. The card’s ask holds it, and your answer goes to the question, not the card.

FieldWhat it holds
from, name“helper” or “asker”, and its name: “Maple asks”.
title, summary, whyThe question, and what its assistant wrote when it asked. Show why whole, its line breaks kept.
options, recommendedIdsIts answers, as a card’s. None, and no action: the person’s own words answer it.
actionA helper’s to-do: something only the person can do, its steps as an action card’s (where, steps, done). “Maple needs you to: …”, answered Done or “I can’t”.
artifactsWhat it shows. With a draft on it, only Pending You’s own apps answer it.
answeredThe person’s answer once it’s in: choiceIds, text, note, and on a to-do done.
  • Answer it by its id.POST /v1/cards/:id/answer with askId and one of its options, or text. A to-do takes done: true for Done, false for “I can’t”, with what stopped them in text if they say. Offered while actions has answer: never on a high-stakes question.
  • Take it back by its id.POST /v1/cards/:id/undo with the same askId, in its 5 seconds: the question waits on the person again.
  • A helper that picked it back up.delegation.resumes says each time the helper handed the card back and then picked it up again itself, while it still waited on the person: when, why, and what it had said.

The change feed

GET /v1/changes says what changed since a cursor, in commit order: ids and types only. Read the cards you show again.

TypeWhen
card.createdAn assistant asked something new.
card.answeredSomeone answered it: the person, here or elsewhere, or a helper.
card.changedAnything else: words, Later, handed over, back, updated.
card.closedIts assistant picked the answer up, withdrew it, or it ran out.
  • Wait for the next change.wait holds the request up to 25 seconds until something changes. Keep the cursor and pass it back as after; without one, the feed starts from now.
  • Read the cards again every 10 minutes.On start, and every 10 minutes, read GET /v1/snapshot or GET /v1/cards too: a card that comes into reach makes no change of its own.

Example:Following the feed, and passing each change to your own serverexamples/change-feed/watch.ts

Show me

The person presses Show on a card in Pending You, and the assistant that asked comes to the front where it runs. Your app can be what brings it forward: it listens on the computer it’s signed in on, for the kinds of place it can show, and moves to the agent’s window when they press.

  1. Sign in on the computer, with assistants:show.The person sees “Bring the assistant that asked to the front on this computer when you press Show. It learns which card and assistant.” A show goes to the computer the agent runs on, so only a sign-in by device code there hears it; any other is refused with no_machine. If Pending You doesn’t know which computer the agent runs on, the show goes to the one computer where apps are listening (none if there are several), so always check the place.
  2. Wait for a press.GET /v1/shows?places=tmux&wait=25 waits up to 25 seconds for a show request on this computer, of the kinds of place you name: herdr or tmux. Each wait says your app is listening for the next 60 seconds, and while it is, the cards of agents running there have the button: “Show in tmux”.
  3. Check the place, bring it forward, and answer.Each show names the card, the agent that asked and its places, newest first: the place’s app, its pane (Herdr’s w2:p1, tmux’s %12), its server and the session. Find that pane in your own list, bring it to the front, and answer POST /v1/shows/{showId} with shown, or not_found when you couldn’t and moved nothing.
GET /v1/shows?places=tmux&wait=25JSON
{
"shows": [
{
"id": "shw_3c2b1a09f8e7d6c5b4a3",
"card": {
"id": "req_4f1c9a0e2b7d6c5a8e31"
},
"agent": {
"id": "agt_6a5b4c3d2e1f0a9b8c7d",
"name": "sweeper",
"app": "claude-code"
},
"places": [
{
"app": "tmux",
"paneId": "%12",
"server": "3f9a6c1e0b7d2458",
"sessionId": "5b0c…"
}
],
"expiresAt": "2026-10-06T14:05:12.000Z"
}
]
}
  • Which server.A place’s server is the first 16 hex characters of a SHA-256 of the computer’s name and the terminal’s socket path (Herdr’s HERDR_SOCKET_PATH, tmux’s #{socket_path}), as the pendingyou command line sends it with each session’s presence. Keep only the places on your own server, and leave a show with none to that server’s app.
  • Ids only.A show carries the card’s id, the agent’s id, name and app, and its places: never a card’s words. Read the card with cards:read if your app shows it.
  • Only the person makes one.A show request comes only from the person’s press in Pending You: no assistant, app or route can make one. Their press waits 4 seconds for your answer and says what came of it: “Shown in tmux on build-01”, or why not.
  • Yours before review.Your app shows your own agents, and your testers’, as soon as you register it, as every app works for you before review. Anyone else needs it verified.

What every app that brings windows forward must do

  • It MUST bring a window to the front, and do nothing else.A press means “show me”, and nothing more.
  • It MUST check the place before it moves anything.It must be on its own server, there now, and still the agent’s where it can tell. When it can’t confirm that, it answers not_found and nothing moves.
  • It MUST never type, run or open anything for a show.Nothing typed into a window, no command, no link. It brings forward only a window from its own list, takes a pane’s id from a show only once it reads as that terminal’s own, and never passes one through a shell.
RefusalStatusWhen
no_machine403The sign-in has no computer: sign the app in with a device code on the computer whose windows it brings forward.
not_found404An answer to a show that isn’t this computer’s, or isn’t there at all.
already_answered409Another app’s answer to the show came first: there’s nothing to do.
expired410The person pressed Show over 30 seconds ago: move nothing.
rate_limited429Past 24 waits a minute: wait `retryAfterSeconds`, then wait again.
nobody_listening409Pending You’s own, to the person’s press: nothing listens where the agent runs. Your app never gets it.
LimitHow much
A waitUp to 25 seconds; Pending You looks every 1 second.
Show waits24 a minute for each sign-in, apart from the change feed’s.
ListeningFor 60 seconds after each wait, while the sign-in stands.
A showEnds 30 seconds after the press; at most 3 places, and 10 shows to a wait.
Presses1 a second and 20 a minute for each person.
With the SDKTypeScript
import { createClient } from '@recordplane/pendingyou-sdk'
 
// Signed in with a device code on this computer, with assistants:show.
await createClient({ store }).followShows({
places: ['tmux'],
// Only the places on your own server: another server's app answers its own.
mine: (place) => place.server === thisServer,
// The agent's pane in your own list, there now, or nothing: then it answers not_found.
find: (show) => paneThere(show.places),
// That pane, brought to the front, and nothing else: then it answers shown.
focus: (pane) => bringForward(pane),
signal,
})

followShows waits, keeps the places that are yours (mine), hands them to find, and gives focus only what find returned from your own list. It answers shown once focus ran, or not_found when find found nothing or either threw; another app’s answer coming first, or a show past its 30 seconds, ends it quietly. shows() and answerShow() do the same by hand.

Example:Bringing the agent’s tmux pane to the front when the person presses Showexamples/show-in-tmux/show.ts

Errors

Refusals are problem details (RFC 9457), application/problem+json, with a stable code. Sign-in’s own refusals are OAuth’s, with WWW-Authenticate.

403 · application/problem+jsonJSON
{
"type": "https://www.pendingyou.com/docs/api/errors#high_stakes",
"title": "This card is high stakes",
"status": 403,
"code": "high_stakes",
"detail": "Answer it in Pending You: it spends money, can’t be undone or goes public.",
"requestId": "rid_0b5e8c1d2a3f4e5d6c7b",
"url": "https://www.pendingyou.com/app/r/req_4f1c9a0e2b7d6c5a8e31"
}
Every error

Limits

Past one: 429 rate_limited with retry-after. They’re per sign-in, and per person for all their apps together.

LimitA minuteCounts
Reads300Every GET
Writes60Every POST
Answers30Answers, and words on a card
Waits6GET /v1/changes that waits
Show waits24GET /v1/shows that waits
Per person1,200Every call of every app

Versions

/v1 only adds: paths, optional fields, answer fields and new values. Ignore what you don’t know.

  • Changes in behaviour are dated.Send Pending-You-Version: 2026-10-05 to pin one; every answer says which it followed. Anything that can’t be added waits for /v2.
  • The OpenAPI document.OpenAPI 3.1 at /v1/openapi.json, made from the same definitions the API serves. Device sign-in and DPoP are in x-pendingyou-device and x-pendingyou-dpop. What it sends is open, so a generated client reads a newer answer: its enums take any string beside the known ones, and its objects take fields they don’t name.
  • Two fields only Pending You’s own apps get, for now.A card’s presentation says how Pending You draws it: its layout, its lines and its buttons, each line a catalog key with its English beside it. An action’s answer carries a toast. Both are in the OpenAPI document, but your app won’t receive them until the changelog says they’re open to every app.
  • Pending You’s own apps say which they are.They send Pending-You-Client (ios/1.4.0+120), read GET /v1/client, and every answer tells them in Pending-You-Client-Status whether to update. An app older than the minimum can still read, but anything it tries to change is a 426 client_outdated. Your app needs neither.
  • Three scopes only Pending You’s own apps hold.cards:manage, with POST /v1/cards/:id/seen, which says the person had a card whole on screen, up to the presentation.seen.upTo it came with, POST /v1/cards/:id/hold, which keeps an answer back while its Undo is paused, POST /v1/cards/:id/finish, Move to Done, which moves a card in In motion to Done for the person (how filed: only their place for it changes, nothing its assistant reads; closed, one that still waited on them: answered as closed without an answer, answer.closed, held for Undo as any answer is), and GET /v1/threads/:threadId, which brings a thread’s older items above a card a page at a time. cards:high_stakes, with POST /v1/yes-key and the person’s yes, signed on the device, in Pending-You-Yes on every change to a high-stakes card. account:manage, with POST /v1/web-handoff, which opens a page of Pending You on the web, signed in, from Pending You’s app on the phone. They’re in the OpenAPI document, but no other app can be granted them.

The SDK

@recordplane/pendingyou-sdk does all of this for you: device sign-in, sign-in by code with PKCE, DPoP and nonces, refreshes, ETags, Idempotency-Keys and the change feed. No dependencies; Node 20 or later, browsers and Workers.

app.tsTypeScript
import { createClient, deviceSignIn } from '@recordplane/pendingyou-sdk'
import { cliAttester, fileStore } from '@recordplane/pendingyou-sdk/node'
 
const store = fileStore(`${process.env.HOME}/.config/example-app/pendingyou.json`)
const signIn = await deviceSignIn({
origin: 'https://www.pendingyou.com',
clientId: 'YOUR-CLIENT-ID',
scopes: ['cards:read', 'cards:answer'],
machine: 'build-01',
attest: cliAttester(),
store,
})
console.log(`Allow it at ${signIn.verificationUriComplete}`)
await signIn.signedIn
 
const pendingYou = createClient({ store })
for await (const batch of pendingYou.changes()) {
if (batch.resync) await showAll(await pendingYou.cards.list())
for (const change of batch.changes) await show(await pendingYou.cards.get(change.cardId))
}

Example:Every call Pending You for Herdr makes, as a terminal queueexamples/herdr-queue/

Example:Every example, with how to run itexamples/

Changelog

VersionWhat changed
2026-10-05The first version: the queue, answers and undo, words, Later, handing over, assistants, presence and the change feed.