Rensei docs

Submit an inbound BYOA agent-dispatch request.

Authentication accepts an rsk API key, a requester-registration-bound OAuth agent token, a WorkOS user token, or a browser session. REG-10 is conditional: a bound registration with a public key requires all three X-Rensei-Request-* headers; a light registration without a key, an unbound rsk key, a user token, and a session do not. A strict registration without a key is misconfigured and returns 403. The public key is canonical standard base64 of the raw 32-byte Ed25519 key. The signature is canonical standard base64 of 64 bytes over the exact UTF-8 canonical-envelope JSON. Nonce replay rejection is best-effort: if Redis is unavailable, replay-cache checks fail open while signature and inclusive +/-300-second timestamp validation remain enforced.

POST
/api/cli/dispatch

Authorization

AuthorizationBearer <token>

Rensei API key presented as Authorization: Bearer rsk_live_. Required API-key scopes are recorded per operation in x-rensei-required-scopes.

In: header

Header Parameters

X-Rensei-Request-Signature?string

Conditionally required: standard base64 of the 64-byte Ed25519 signature over the exact canonical envelope UTF-8 bytes.

Match^[A-Za-z0-9+/]{86}==$
X-Rensei-Request-Timestamp?string

Conditionally required: canonical base-10 integer Unix seconds signed in the envelope; accepted within the inclusive +/-300 second window.

Match^(0|[1-9][0-9]*)$
X-Rensei-Request-Nonce?string

Conditionally required: non-empty opaque per-request nonce signed in the envelope. Replay rejection is best-effort while the Redis replay cache is available.

Length1 <= length

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X POST "https://example.com/api/cli/dispatch" \  -H "Content-Type: application/json" \  -d '{    "project": "string",    "goal": "string"  }'
{
  "workflowId": "string",
  "instanceId": "string",
  "sessionId": "string",
  "streamUrl": "string",
  "receiptUrl": "string",
  "callbackSecret": "string"
}
Empty
Empty
Empty
Empty
Empty
Empty