All pages

Docs / Reference

API

Everything answers { "data": … } or { "error": { "code", "message" } }. Bodies are JSON. Codes: bad_request 400, unauthorized 401, not_found 404, conflict 409, rate_limited 429, unavailable 503.

For the person (in the browser or app)

Take a session, then send it as Authorization: Bearer <session>. Sessions last an hour.

RouteWhat it does
POST /v1/sessions{ appKey, token } with your server’s token; or { appKey } for a visitor, or { appKey, visitorToken } to resume one. Answers { session, expiresIn }.
GET /v1/widget/config?appKey=The app’s name, colour and whether visitors may chat. Public.
POST /v1/chat{ conversationId?, body, attachmentIds? }. Answers with server-sent events: request, text deltas, done with the saved message, or error.
GET /v1/conversationsThe person’s conversations, newest first, with unread.
GET /v1/conversations/:idOne conversation and its messages; marks it read.
POST /v1/filesA picture as the raw body (PNG, JPEG, WebP or GIF, up to 10 MB). Answers its id for attachmentIds.

For your server (API key)

Send Authorization: Bearer sk_…. Never from a browser.

RouteWhat it does
GET /v1/owner/inboxProposals waiting, conversations handed over, open bugs.
GET /v1/owner/conversations?status=waiting|open|allConversations, newest first.
GET /v1/owner/conversations/:idOne conversation with its messages and proposals.
POST /v1/owner/conversations/:id/messagesThe team’s answer: { body, resolve?, attachmentIds? }.
POST /v1/owner/conversations/:id/filesA picture for the team’s answer.
POST /v1/owner/proposals/:id{ approve }. Approving runs the action’s execute once.
PATCH /v1/owner/bugs/:id{ status: "closed" }.
POST /v1/owner/bugs/:id/fixStarts a fix run.
GET, PUT /v1/owner/settingsName, instructions, help text, actions, limits, webhook and alerts. Changes to instructions, help text or actions are live at once, as a new version.
GET, PUT /v1/owner/draftThe draft: { instructions?, procedures?, knowledge?, actions? }.
POST /v1/owner/draft/publish{ note? }. Makes the draft the next version.
GET /v1/owner/versions, POST /v1/owner/versions/:n/restoreVersions, and making one live again.
GET, PUT /v1/owner/scenariosSaved scenarios; PUT replaces them all.
POST /v1/owner/simulations/run{ target: "draft"|"live", names? }. Runs saved scenarios.
POST /v1/owner/simulations{ scenarios }. Runs scenarios given in the request without saving them.
GET /v1/owner/users/:id/exportEverything kept about one person, by your id for them.
DELETE /v1/owner/users/:idDeletes one person’s conversations, pictures and events. Call it when they delete their account.

From your app and other services

RouteWhat it does
POST /v1/errorsAn error report from the error reporter: { appKey, kind, frames, release?, codes? }. Any message is dropped.
POST /v1/integrations/sentry/:appIdSentry’s webhook, checked with the integration’s client secret.
POST /v1/integrations/githubDezzi’s GitHub App’s webhook: CI results on fixes, and uninstalls.
POST /v1/billing/stripeThe payment provider’s webhook, for plans and payments.

Dezzi calls you

Actions and webhook events are POSTs signed with your action signing secret: X-Support-Signature: t=<unix seconds>,v1=<hex HMAC-SHA256 of "<t>.<raw body>">. Refuse a timestamp more than five minutes off. See Actions and webhooks.

Limits

GET /v1/health answers 200 when the database and the minute’s schedule work.