Agent share links (public beta)

Share links are revocable, budget-capped URLs that let anyone talk to an agent — no account, no embed, no setup. Create one, share the URL, the recipient opens it and talks.

Three unauthenticated endpoints power the recipient experience:

EndpointWhat it does
GET /v1/agents/share-links/previewResolve a token for display (cosmetic only — no call starts).
POST /v1/agents/share-links/sessionsStart a realtime session against a share link. Call time is deducted from the link’s budget before dispatch.

Management endpoints let the owner list, create, revoke, and re-read a link:

EndpointWhat it does
GET /v1/agents/{agent_id}/share-linksList the agent’s share links, cursor-paginated. Revoked and expired links are included; the token is masked to a short prefix.
POST /v1/agents/{agent_id}/share-linksMint a new share link with a second budget and optional description.
POST /v1/agents/{agent_id}/share-links/{share_link_id}/revealReturn the link’s token so the URL can be copied again. Separately rate-limited.
DELETE /v1/agents/{agent_id}/share-links/{share_link_id}Revoke a link (idempotent). Stops new calls; a call already in progress runs to its own duration limit.

Reveal rather than re-create: re-creating kills the copy the recipient already holds. Check token_recoverable on the link before offering the action — links minted before tokens were stored recoverably answer 409 share_link_token_unavailable, and no retry will produce it.

Error codes:

  • 404 share_link_not_found — the token is unknown, revoked, or expired. The three states are deliberately indistinguishable.
  • 409 share_link_exhausted — the link’s remaining budget is too small for another call.
  • 409 share_link_token_unavailable — the link’s token was not stored recoverably, so reveal cannot return it.
  • 429 — the link has reached its simultaneous-call ceiling.

Every cap is optional and falls back to a bounded default. There is no way to express “unlimited” — an anonymous URL that could spend the workspace’s balance should not be creatable by omitting a field. The recipient is anonymous and holds no plan of their own, so the link’s own budget and concurrency ceiling are what bound it. Set them deliberately.