OdyDocs

Conversations

Threads between one of your Ody numbers and an outside party: list them, read the full timeline, mark them open or done, and take them over from the texting agent.

A conversation is one thread between one of your Ody numbers and an outside party (one person, or several people in a group text). Every message, call, voicemail, internal note and system event in the thread is an activity, in time order. It is the same object your team sees as a row in the inbox.

#The conversation object

  • id uuid — Unique identifier.
  • inboxId uuid — The inbox the thread lives in.
  • numberE164 string | null — The Ody number on your side of the thread.
  • participants array of strings — The outside party's E.164 numbers.
  • contactName string — Display name: the contact's name, or the formatted number.
  • status "open" | "done" — Inbox state. A new inbound message re-opens a done thread.
  • assigneeUid string | null — Teammate the thread is assigned to.
  • lastActivityAt timestamp — When the latest activity happened.
  • preview string | null — Snippet of the latest activity.
  • unread integer — Unread count for the key's creator.
  • aiTexting object — Business AI Texting state, on Retrieve only (lists stay lean): available (the line has a texting agent linked and that agent's texting is on), paused (a human took the thread over — the agent stays quiet until handed back), pausedBy (the member's uid, or "ai" when the agent handed off itself), agentId, agentName.
The conversation object
{
  "id": "c4f1a2b3-5d6e-4f70-8a9b-0c1d2e3f4a5b",
  "inboxId": "1e2d3c4b-5a69-4788-9a0b-1c2d3e4f5a6b",
  "numberE164": "+15125550100",
  "participants": ["+15125550123"],
  "contactName": "Ada Lovelace",
  "status": "open",
  "assigneeUid": null,
  "lastActivityAt": "2026-10-14T18:05:42.000Z",
  "preview": "Can I move my appointment to Friday?",
  "unread": 1
}

#The activity object

  • id uuid — Unique identifier.
  • type string — message, call, voicemail, internal_note or system.
  • direction "inbound" | "outbound" | null — null for notes and system events.
  • authorUid string | null — The teammate who sent it, if any.
  • body string | null — Message text, or the note's text.
  • media array — Attachments: url (a short-lived signed link), contentType (detected from the file itself), size, filename, and for photos width / height. Outbound attachments also carry delivery — "mms" (attached to the text) or "link" (sent as a secure Ody link because it was too large for MMS or the recipient is outside the US/Canada) — plus linkExpiresAt and, once revoked, linkRevokedAt.
  • deliveryStatus string | null — For messages: queued, sent, delivered, failed, received, or simulated (sent with a test key).
  • call object | null — For calls and voicemails: status, duration, recording, AI summary and so on.
  • aiTextingAgentId uuid — Present on outbound messages the texting agent sent on its own (Business AI Texting); absent on human-sent messages. Use it to tell AI replies from your team's in a timeline or a webhook payload.
  • automationId uuid — Present on outbound messages an automation sent (Build → Automations); absent otherwise. authorUid is null on these, as it is on AI replies.
  • automationName string | null — With automationId: the automation's name as it is today, or null once the automation has been deleted. The message itself stays.
  • callTranscript array | null — Speaker-labelled transcript turns, once transcription finishes.
  • aiTags array of strings — Labels the AI attached (for example appointment).
  • createdAt timestamp — ISO 8601.

#List conversations

GET/v1/api/conversations

Returns conversations with the most recent activity first. Results are cursor-paginated.

Scope: conversations:read

Query parameters

  • status "open" | "done" — Filter by inbox state. Omit for both.
  • limit integer — 1–100, default 50.
  • cursor string — nextCursor from the previous page.

Returns { conversations: Conversation[], nextCursor: string | null }.

curl "https://api.ody.co/v1/api/conversations?status=open&limit=25" \
  -H "Authorization: Bearer $ODY_API_KEY"

#Retrieve a conversation

GET/v1/api/conversations/:id

Returns the conversation and its full activity timeline, oldest to newest: messages with media, calls with transcripts and AI summaries, voicemails, notes and system events.

Scope: conversations:read

Returns { conversation, activities: Activity[] }, or 404 not_found.

curl https://api.ody.co/v1/api/conversations/c4f1a2b3-5d6e-4f70-8a9b-0c1d2e3f4a5b \
  -H "Authorization: Bearer $ODY_API_KEY"
Response
{
  "conversation": { "id": "c4f1a2b3-…", "status": "open", "contactName": "Ada Lovelace" },
  "activities": [
    {
      "id": "a1…",
      "type": "message",
      "direction": "inbound",
      "body": "Can I move my appointment to Friday?",
      "media": [],
      "deliveryStatus": "received",
      "aiTags": ["appointment"],
      "createdAt": "2026-10-14T18:05:42.000Z"
    }
  ]
}

#Update a conversation

PATCH/v1/api/conversations/:id

Marks the thread done (archived from the open inbox) or open again. This is the API equivalent of the inbox's Done button.

Scope: conversations:write

Body

  • status "open" | "done" required

Returns { conversation: { id, status } }.

curl -X PATCH https://api.ody.co/v1/api/conversations/c4f1a2b3-5d6e-4f70-8a9b-0c1d2e3f4a5b \
  -H "Authorization: Bearer $ODY_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"status":"done"}'

#Take a thread over from the AI, or hand it back

POST/v1/api/conversations/:id/ai-texting

The conversation-level switch of Business AI Texting. paused: true makes the texting agent stay quiet in this conversation — every other thread keeps working, and the pause holds even if the customer texts again days later — until paused: false hands it back. This is the API equivalent of the inbox's I'll take it from here / Hand back button.

Sending a message with POST /messages does not pause the agent by itself (it only makes the agent skip the one text a teammate already answered) — pause first when a human takes over.

Scope: conversations:write

  • paused boolean required

Returns { ok: true, conversation: { id, aiTextingPaused } }, or 404 not_found.

curl -X POST https://api.ody.co/v1/api/conversations/c4f1a2b3-5d6e-4f70-8a9b-0c1d2e3f4a5b/ai-texting \
  -H "Authorization: Bearer $ODY_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"paused":true}'

#Why did (or didn't) the AI reply?

GET/v1/api/conversations/:id/ai-texting/runs

Every inbound text the texting agent looked at in this thread — replied, skipped (with a reason) or failed — newest first. See the run object for the reasons. Empty for threads on lines without a texting agent.

Scope: conversations:read · Query: limit (1–100, default 20)

Returns { runs: AiTextingRun[] }.

const runs = await ody.conversations.aiTextingRuns(conversationId);
console.log(runs[0]?.status, runs[0]?.reason); // "skipped" "paused"
Last updated Mon Nov 02 2026 00:00:00 GMT+0000 (Coordinated Universal Time)Something wrong on this page? Tell us