POST
/
dispatches

Creates a new dispatch or updates an existing one.

Body Parameters

id
string

The ID of the dispatch to update. If not provided, a new dispatch will be created.

name
string
required

The name of the dispatch.

status
string
required

The status of the dispatch.

agentId
string
required

The ID of the agent.

crmScenarioId
string
required

The ID of the CRM scenario.

crmStepId
string
required

The ID of the CRM step.

scheduledAt
string

The ISO 8601 date-time for scheduling.

templateMessage
string

The message template.

interval
integer

The sending interval in minutes.

Response

Success
object

Authorizations

Authorization
string
headerrequired

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
id
string | null

Include the ID to update an existing dispatch. Omit to create a new one.

name
string

The name of the dispatch.

status
string

The status of the dispatch (e.g., 'draft', 'scheduled', 'sent').

agentId
string

The ID of the agent responsible for the dispatch.

crmScenarioId
string

The ID of the CRM scenario associated with the dispatch.

crmStepId
string

The ID of the CRM step associated with the dispatch.

scheduledAt
string | null

The date and time when the dispatch is scheduled to be sent.

contactListIds
string[]

An array of contact list IDs to associate with the dispatch.

Response

200 - application/json
id
string
name
string
status
string
agentId
string
crmScenarioId
string
crmStepId
string
scheduledAt
string | null
templateMessage
string | null
interval
integer | null
createdAt
string
updatedAt
string
totalCount
integer
sentCount
integer
errorCount
integer
latestErrorMessage
string | null