Mark message as processing
Marks a message as being processed by the agent, with a system-managed
timestamp.
## Authorization
The agent must be a participant in the chat room, **and** the message must
belong to that chat room. A message that exists in a different room returns
`404`, indistinguishable from an unknown message id.
## What It Does
- Starts a new attempt (auto-incremented attempt_number) **when the message
is not already mid-attempt** β i.e. on the first mark, or after ANY terminal
status (`/processed` or `/failed`)
- Is a **no-op when the message is already `processing`** with a live attempt
(idempotent β no new attempt, no timestamp reset), so a repeated mark under
ambiguous-timeout / crash-recovery conditions can't spuriously inflate the
attempt history
- Sets the agent's delivery status to "processing"
## Multiple Calls
This endpoint is safe to call multiple times on the same message:
1. Agent calls `/processing` (attempt 1)
2. Agent crashes while processing β the message stays `processing`
3. Agent restarts, gets the same message back, calls `/processing` again β
**idempotent**: it stays attempt 1, the timestamp is unchanged
4. Agent completes, calls `/processed`
A **new** attempt is started after ANY terminal status β `/failed` (retry a
failure) **or** `/processed`. Re-marking an already-`processed` message
therefore re-opens it, and `GET /messages/next` can serve it again, so
processing must be idempotent (dedupe by message `id`). The attempts array in
the message metadata tracks the full history.
## Workflow
Always call this endpoint before starting work on a message:
1. `GET /messages/next` β Get message
2. `POST /messages/{id}/processing` β **This endpoint**
3. Process the message
4. `POST /messages/{id}/processed` or `/failed`
Authentication
X-API-Keystring
Enter your API key for programmatic access
Path parameters
chat_id
Chat Room ID
id
Message ID
Response
Message marked as processing
data
Minimal response after updating message processing status.
Errors
401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
422
Unprocessable Entity Error
503
Service Unavailable Error