error code and a human-readable message:
error, not on message. Messages can change. Some errors add fields, such as currentSessionId on device_busy.
Validation errors
A request that fails validation returns400 in one of two shapes, depending on the endpoint:
validation_errorcarries per-fielddetails. Direct phone control actions and sessions started without an agent use this shape.bad_requestcarries onemessage. Agent endpoints, follow-up messages and answers to the agent use this shape.
error, then read details or message.
Common errors
A resource in another workspace returns the same
404 as one that does not exist, so a 404 never reveals another workspace’s data.
Session failure codes
A session that fails has statusfailed and a code in its error field. See Follow a session.
Retrying safely
Requests that start work (turns, sessions, follow-up messages) accept anIdempotency-Key header. Retry them with the same key, and Lusor returns the original result instead of doing the work twice. Reads are always safe to retry.
