200 (or 201 when something was created).
Anything else comes with a JSON body in one of two shapes.
Application errors — the error_code envelope
Errors raised by an endpoint’s own logic — a validation rule, a missing record, a refused
operation — always look like this:
Branch on
error_code, never on message. Messages are written for humans and may be
reworded; codes are the contract and do not change.details is optional and endpoint-specific: the calendar endpoints use it to list the values
that would have been accepted (valid_service_names, valid_professional_names,
matching_professional_ids) or to name the offending field.
Framework errors — the detail body
Two failures happen before an endpoint runs, and they use a plainer body:
401 — authentication
401 — authentication
422 — request does not match the schema
422 — request does not match the schema
limit above the maximum). loc starts with body, query
or path and then names the field. Fix the listed fields and retry.404 — unknown route or record (some endpoints)
404 — unknown route or record (some endpoints)
500 — INTERNAL_ERROR
Something went wrong on our side. The operation was not applied (no call queued, no
contact created, no appointment booked), so retrying is safe. If it persists, contact
support with the request you sent.
Error codes by endpoint
Calls
Clients
Salesflow ingest
Salesflow batch ingest
The batch endpoint reports most problems per row inresults[].errors[].code (required, invalid_format, too_long, duplicate_in_batch, not_found, exists, conflict) with a 200 response; the codes below apply to the request as a whole.