Skip to content
First requestVisit website ↗
Navigation

Send an agent LiveChat text or media reply as RCS

Used by the LiveChat composer to send an agent's text or single image/prepared video RCS-first. Twilio delivers RCS where the device supports it and otherwise falls back to SMS/MMS from the contact's own board number (FallbackFrom), so the conversation stays on one number. A contact not yet confirmed RCS-capable is only attempted when that board number resolves. Gated by RCS_MESSAGING + workspace_rcs_config. Returns sent:false (HTTP 200) with a fallback-safe outcome only when no RCS send was attempted or definitively rejected by the configuration allowlist. Invalid, raw or unverifiable media returns rejected and must never fall back. Media is workspace-owned public storage, at most 5,000,000 bytes including UTF-8 text; videos must be prepared MP4 files at most 600,000 bytes. MMS-only image formats and multiple attachments use the existing MMS path after validation. Requires an authenticated workspace agent (Bearer).

POST
https://api.channelautomation.com/api/rcs/workspaces/{workspaceId}/agent-send

Authorization

  • BearerAuth
    HTTP Bearer (JWT)
    required

Path parameters

  • workspaceId
    string
    required

Request body JSON required

  • contactId
    string
    required
  • body
    optional
    string

    Reply text (max 1600 chars), optional when mediaUrls is present.

  • mediaUrls
    optional
    array of
    string

    Public workspace-owned image or prepared MP4 URL. One attachment uses RCS.

  • mediaPaths
    optional
    array of
    string

    Matching storage object paths, in the same order as mediaUrls.

  • userName
    optional
    string

    Agent display name stored on the message.

  • userAvatar
    optional
    string

    Agent avatar URL stored on the message.

Returns

200

Always 200 on a well-formed request. sent:true with a messageSid when handed to Twilio RCS-first. Otherwise sent:false with an outcome: not_attempted or rejected_fallback_ok → the UI sends plain SMS; rejected → Twilio refused it (e.g. unsubscribed) and nothing may be re-sent; unknown → Twilio may have accepted it, so nothing may be re-sent.

400

Missing contactId, or no text and no media.

401

Authentication required
JSON
  • error
    optional
    string
  • success
    optional
    boolean

403

Membership in the path workspace is required.

503

Identity or workspace access verification is temporarily unavailable.

Type to search…

↑↓ navigate↵ selectEsc close