Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.1to1ai.com/llms.txt

Use this file to discover all available pages before exploring further.

The POST /conversation/actions endpoint runs a group of up to 10 actions on a single conversation, in the order you send them. Instead of making N requests to label, leave a note and run the AI, you chain them in a single request.

The 11 actions

Each element of the actions array carries a type field. Almost all mirror an individual API endpoint; send_quick_reply_or_template is the exception: it sends the quick reply if the 24h window is open, or the template if it’s closed — the mode is decided by the server at runtime.
  • send_message — sends a message (text, media, quick reply, or template).
  • send_quick_reply_or_template — quick reply or template, depending on the window.
  • assign_label — assigns a label to the conversation.
  • remove_label — removes a label from the conversation.
  • assign_mailbox — moves the conversation to a mailbox.
  • context_note — leaves an internal note.
  • mark_resolved — marks the conversation as resolved.
  • mark_pending — marks the conversation as pending.
  • run_ai — runs the AI employee on the conversation.
  • ai_assistance — generates a suggested reply with the AI.
  • assign_ai_employee — assigns an AI employee to the conversation.
A group allows up to 10 actions, of which at most 3 can trigger the AI. Exceeding it fails with BATCH_LIMIT_EXCEEDED.

How it runs

1

Synchronous validation

The API validates the request. If the preflight rejects it (e.g. the AI has no tokens), it responds a synchronous 4xx and no action runs.
2

202 Accepted

If validation passes, it responds 202 immediately; the group runs in the background.
3

Execution in order

The actions run one by one, in the order sent.
The 202 confirms the group was accepted, not that every action succeeded. The per-action result does not travel in the response — query it in the conversation status or in the business’s activity log.

Stop on error

stop_on_error controls what happens when an action fails during execution:
ValueBehavior
true (default)The first failure halts the remaining actions.
falseThe group runs all actions, ignoring intermediate failures.

Example

Label, leave a note and run the AI, without halting on failures:
{
  "conversation": { "phone": "+5215512345678" },
  "stop_on_error": false,
  "actions": [
    { "type": "assign_label", "tags": [{ "name": "VIP" }] },
    { "type": "context_note", "note": "Customer requested a quote." },
    { "type": "run_ai", "ai_employee": { "name": "Sales Agent" } }
  ]
}
If the preflight rejects the group, the response is a synchronous 4xx and no action runs. See Errors.