curl -X POST https://api.open.cx/connect/threads/order_84421/messages \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"participant_id": "mrc_204",
"lane": "customer_merchant",
"text": "Out of garlic sauce — swap for tahini or refund the item?"
}'
{
"message": {
"id": "msg_4t1a",
"lane": "customer_merchant",
"sender": { "participant_id": "prt_m32", "role": "merchant" },
"text": "Out of garlic sauce — swap for tahini or refund the item?",
"translations": {
"ar": "نفدت صلصة الثوم — نستبدلها بالطحينة أم نسترد قيمة الصنف؟"
},
"created_at": "2026-07-30T14:12:40Z"
}
}
Connect
Send a Connect message
Send a message into a lane on behalf of a participant — the server-side path for headless UIs and system notices. Translation and safety run before delivery.
POST
/
connect
/
threads
/
{thread_id}
/
messages
curl -X POST https://api.open.cx/connect/threads/order_84421/messages \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"participant_id": "mrc_204",
"lane": "customer_merchant",
"text": "Out of garlic sauce — swap for tahini or refund the item?"
}'
{
"message": {
"id": "msg_4t1a",
"lane": "customer_merchant",
"sender": { "participant_id": "prt_m32", "role": "merchant" },
"text": "Out of garlic sauce — swap for tahini or refund the item?",
"translations": {
"ar": "نفدت صلصة الثوم — نستبدلها بالطحينة أم نسترد قيمة الصنف؟"
},
"created_at": "2026-07-30T14:12:40Z"
}
}
Send a message into a lane on behalf of a participant. This is the headless path — apps using the drop-in component send through their participant token instead.
Every message passes through the Supervisor’s pipeline before delivery: safety masking, then translation into each recipient’s language. Sending into a
locked thread returns 409.
Path
string
required
Thread ID (
th_…) or your reference.Request
string
required
Sender — participant ID (
prt_…) or their external_id. Use "system" for order-event notices (“Your order was picked up”), rendered as system chips, not chat bubbles.string
required
customer_merchant, customer_courier, or merchant_courier. The sender’s role must belong to the lane.string
Message text. Required unless
attachments is present.array
Files by URL:
[{ "url": "https://…", "content_type": "image/jpeg" }].Response
object
The created message, including
translations keyed by language and the post-masking text.curl -X POST https://api.open.cx/connect/threads/order_84421/messages \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"participant_id": "mrc_204",
"lane": "customer_merchant",
"text": "Out of garlic sauce — swap for tahini or refund the item?"
}'
{
"message": {
"id": "msg_4t1a",
"lane": "customer_merchant",
"sender": { "participant_id": "prt_m32", "role": "merchant" },
"text": "Out of garlic sauce — swap for tahini or refund the item?",
"translations": {
"ar": "نفدت صلصة الثوم — نستبدلها بالطحينة أم نسترد قيمة الصنف؟"
},
"created_at": "2026-07-30T14:12:40Z"
}
}
Was this page helpful?