Campaigns
Campaigns, campaign modules, processes and customer forms.
Set up a campaign
Choose or create the process it follows; its
idis the campaign'sprocessId.Create the campaign.
Turn on the modules it uses and set its customer form.
PUTEnable or disable a campaign modulePUTSave a campaign's customer form
On this page
Campaigns
Modules and customer form
Processes
- GETList processes
- POSTCreate a process
- GETGet a process
- PATCHUpdate a process
- DELETEArchive a process
List campaigns
GET/v1/tenants/{tenantSlug}/campaigns
Lists campaigns, optionally filtered by process and status. Paged with an opaque cursor: pass nextCursor back as cursor until it is null.
Query parameters
processIdID of the process.
statusCurrent status of the campaign.
cursorOpaque cursor from the previous page's
nextCursor. Leave it out to start at the first page.limitMaximum number of records to return in one page.
Responses
One page of campaigns.
itemsThe records in this response, in the documented order.
nextCursorPass as
cursorto fetch the next page;nullon the last page.
Errors
VALIDATION_ERRORA parameter, header or body field is invalid; compare the request with the fields above (Validation errors).PARTNER_OPERATION_FORBIDDENThe key lacks thecampaigns.readscope.PERMISSION_DENIEDThe key's acting member lacks the permission or data access.
Create a campaign
POST/v1/tenants/{tenantSlug}/campaigns
Creates a campaign in a process. New campaigns start in DRAFT; enable at least one module with Enable or disable a campaign module, then set status to ACTIVE with Update a campaign.
startsAt must be before endsAt when both are set. Names are unique among the process's non-archived campaigns (409 otherwise). An unknown processId returns 404.
Request body (application/json)
descriptionFree-text description.
endsAtWhen it ends (ISO 8601);
nullif not yet.nameName of the campaign, as shown in the LMS.
processIdID of the process.
startsAtWhen it starts (ISO 8601);
nullif not yet.timezoneIANA time zone, for example
Asia/Kolkata.
Responses
The new campaign.
LocationURL of the new campaign.
createdAtWhen it was created (ISO 8601).
descriptionFree-text description.
endsAtWhen it ends (ISO 8601);
nullif not yet.idID of the campaign.
nameName of the campaign, as shown in the LMS.
processIdID of the process.
startsAtWhen it starts (ISO 8601);
nullif not yet.statusCurrent status of the campaign.
tenantIdID of the workspace.
timezoneIANA time zone, for example
Asia/Kolkata.updatedAtWhen it last changed (ISO 8601). Send it back as
expectedUpdatedAtwhen you update.
Errors
VALIDATION_ERRORA parameter, header or body field is invalid; compare the request with the fields above (Validation errors).PARTNER_OPERATION_FORBIDDENThe key lacks thecampaigns.writescope.PERMISSION_DENIEDThe key's acting member lacks the permission or data access.- The record does not exist or the key cannot see it.
CAMPAIGN_NAME_CONFLICTAnother campaign already has this name.
Get a campaign
GET/v1/tenants/{tenantSlug}/campaigns/{campaignId}
Path parameters
campaignIdCampaign ID.
Responses
The campaign.
createdAtWhen it was created (ISO 8601).
descriptionFree-text description.
endsAtWhen it ends (ISO 8601);
nullif not yet.idID of the campaign.
nameName of the campaign, as shown in the LMS.
processIdID of the process.
startsAtWhen it starts (ISO 8601);
nullif not yet.statusCurrent status of the campaign.
tenantIdID of the workspace.
timezoneIANA time zone, for example
Asia/Kolkata.updatedAtWhen it last changed (ISO 8601). Send it back as
expectedUpdatedAtwhen you update.
Errors
PARTNER_OPERATION_FORBIDDENThe key lacks thecampaigns.readscope.PERMISSION_DENIEDThe key's acting member lacks the permission or data access.CAMPAIGN_NOT_FOUNDThe campaign does not exist or the key cannot see it.
Update a campaign
PATCH/v1/tenants/{tenantSlug}/campaigns/{campaignId}
Changes campaign fields or moves it through its lifecycle. Send only the fields to change.
Allowed status changes: DRAFT → ACTIVE or ARCHIVED; ACTIVE ↔ PAUSED; any → ARCHIVED. An ACTIVE campaign needs at least one enabled module. Archived campaigns cannot be changed. These rules, and a duplicate name, return 409.
Path parameters
campaignIdCampaign ID.
Request body (application/json)
descriptionFree-text description.
endsAtWhen it ends (ISO 8601);
nullif not yet.nameName of the campaign, as shown in the LMS.
startsAtWhen it starts (ISO 8601);
nullif not yet.statusCurrent status of the campaign.
timezoneIANA time zone, for example
Asia/Kolkata.
Responses
The updated campaign.
createdAtWhen it was created (ISO 8601).
descriptionFree-text description.
endsAtWhen it ends (ISO 8601);
nullif not yet.idID of the campaign.
nameName of the campaign, as shown in the LMS.
processIdID of the process.
startsAtWhen it starts (ISO 8601);
nullif not yet.statusCurrent status of the campaign.
tenantIdID of the workspace.
timezoneIANA time zone, for example
Asia/Kolkata.updatedAtWhen it last changed (ISO 8601). Send it back as
expectedUpdatedAtwhen you update.
Errors
VALIDATION_ERRORA parameter, header or body field is invalid; compare the request with the fields above (Validation errors).PARTNER_OPERATION_FORBIDDENThe key lacks thecampaigns.writescope.PERMISSION_DENIEDThe key's acting member lacks the permission or data access.CAMPAIGN_NOT_FOUNDThe campaign does not exist or the key cannot see it.CAMPAIGN_NAME_CONFLICTAnother campaign already has this name.
List a campaign's modules
GET/v1/tenants/{tenantSlug}/campaigns/{campaignId}/modules
Shows which modules (LMS, DIALER, QMS, IVR, VOICEBOT) are enabled for the campaign. Features such as Voicebot calling only work for a campaign whose module is enabled.
Path parameters
campaignIdCampaign ID.
Responses
The campaign's modules.
An array, not paged. Each item:
campaignIdID of the campaign.
enabledWhether it is turned on.
moduleCampaign module key.
tenantIdID of the workspace.
updatedAtWhen it last changed (ISO 8601). Send it back as
expectedUpdatedAtwhen you update.
Errors
PARTNER_OPERATION_FORBIDDENThe key lacks thecampaigns.readscope.PERMISSION_DENIEDThe key's acting member lacks the permission or data access.CAMPAIGN_NOT_FOUNDThe campaign does not exist or the key cannot see it.
Enable or disable a campaign module
PUT/v1/tenants/{tenantSlug}/campaigns/{campaignId}/modules/{module}
Turns one module on or off for the campaign. Enabling a module the workspace's plan does not include returns 403 with WORKSPACE_NOT_ENTITLED. Disabling the last enabled module of an ACTIVE campaign, or changing an archived campaign, returns 409. Setting a module to its current state changes nothing.
Path parameters
campaignIdCampaign ID.
moduleCampaign module.
Request body (application/json)
enabledWhether it is turned on.
Responses
The module's new state.
campaignIdID of the campaign.
enabledWhether it is turned on.
moduleCampaign module key.
tenantIdID of the workspace.
updatedAtWhen it last changed (ISO 8601). Send it back as
expectedUpdatedAtwhen you update.
Errors
VALIDATION_ERRORA parameter, header or body field is invalid; compare the request with the fields above (Validation errors).PARTNER_OPERATION_FORBIDDENThe key lacks thecampaigns.writescope.PERMISSION_DENIEDThe key's acting member lacks the permission or data access.CAMPAIGN_NOT_FOUNDThe campaign does not exist or the key cannot see it.- The change conflicts with the record's current state or a workflow rule;
error.codenames it.
Get a campaign's customer form
GET/v1/tenants/{tenantSlug}/lms/campaigns/{campaignId}/customer-form
Returns the customer form: the extra fields captured for each lead of the campaign, in display order. A campaign without a form returns an empty field list at revision 0. Lead values are read and saved with Get a lead's customer fields and Save a lead's customer fields.
Path parameters
campaignIdCampaign ID.
Responses
The customer form.
campaignIdCampaign the form belongs to.
revisionForm revision, increased on every change. Send it as
formRevisionwhen saving values.fieldsThe fields, in display order.
updatedAtWhen the form last changed;
nullif never saved.
Errors
PARTNER_OPERATION_FORBIDDENThe key lacks thecampaigns.readscope.PERMISSION_DENIEDThe key's acting member lacks the permission or data access.CAMPAIGN_NOT_FOUNDThe campaign does not exist or the key cannot see it.
Save a campaign's customer form
PUT/v1/tenants/{tenantSlug}/lms/campaigns/{campaignId}/customer-form
Replaces the form's field list (up to 60 fields with unique keys). SELECT and MULTI_SELECT fields need at least one option; other types take none. To retire a field without losing saved values, set active: false rather than removing it. Send the form's current revision as expectedRevision; a stale revision returns 409.
Path parameters
campaignIdCampaign ID.
Request body (application/json)
expectedRevisionThe
revisionfrom your last read. If the record changed since, the request fails with409and nothing is saved.fieldsThe fields, in display order.
Responses
The saved form.
campaignIdCampaign the form belongs to.
revisionForm revision, increased on every change. Send it as
formRevisionwhen saving values.fieldsThe fields, in display order.
updatedAtWhen the form last changed;
nullif never saved.
Errors
VALIDATION_ERRORA parameter, header or body field is invalid; compare the request with the fields above (Validation errors).PARTNER_OPERATION_FORBIDDENThe key lacks thecampaigns.writescope.PERMISSION_DENIEDThe key's acting member lacks the permission or data access.CAMPAIGN_NOT_FOUNDThe campaign does not exist or the key cannot see it.CUSTOMER_FORM_STALEThe form changed after you read it; read it again and resend.
List processes
GET/v1/tenants/{tenantSlug}/processes
Lists the workspace's processes, optionally only active or archived ones. A process holds the pipeline stages, identity rules and campaigns of one line of business. Paged with an opaque cursor: pass nextCursor back as cursor until it is null.
Query parameters
statusCurrent status of the process.
cursorOpaque cursor from the previous page's
nextCursor. Leave it out to start at the first page.limitMaximum number of records to return in one page.
Responses
One page of processes.
itemsThe records in this response, in the documented order.
nextCursorPass as
cursorto fetch the next page;nullon the last page.
Errors
VALIDATION_ERRORA parameter, header or body field is invalid; compare the request with the fields above (Validation errors).PARTNER_OPERATION_FORBIDDENThe key lacks thecampaigns.readscope.PERMISSION_DENIEDThe key's acting member lacks the permission or data access.
Create a process
POST/v1/tenants/{tenantSlug}/processes
Creates an active process. Names are unique among active processes (409 otherwise). The workspace's plan caps the number of active processes; at the cap the request fails with 409 and error.details carries the current count and limit.
Request body (application/json)
descriptionFree-text description.
nameName of the process, as shown in the LMS.
timezoneIANA time zone, for example
Asia/Kolkata.
Responses
The new process.
LocationURL of the new process.
createdAtWhen it was created (ISO 8601).
descriptionFree-text description.
idID of the process.
nameName of the process, as shown in the LMS.
statusCurrent status of the process.
tenantIdID of the workspace.
timezoneIANA time zone, for example
Asia/Kolkata.updatedAtWhen it last changed (ISO 8601). Send it back as
expectedUpdatedAtwhen you update.
Errors
VALIDATION_ERRORA parameter, header or body field is invalid; compare the request with the fields above (Validation errors).PARTNER_OPERATION_FORBIDDENThe key lacks thecampaigns.writescope.PERMISSION_DENIEDThe key's acting member lacks the permission or data access.PROCESS_NAME_CONFLICTAnother process already has this name.PROCESS_LIMIT_REACHEDThe workspace has reached its plan's process limit.
Get a process
GET/v1/tenants/{tenantSlug}/processes/{processId}
Path parameters
processIdProcess ID.
Responses
The process.
createdAtWhen it was created (ISO 8601).
descriptionFree-text description.
idID of the process.
nameName of the process, as shown in the LMS.
statusCurrent status of the process.
tenantIdID of the workspace.
timezoneIANA time zone, for example
Asia/Kolkata.updatedAtWhen it last changed (ISO 8601). Send it back as
expectedUpdatedAtwhen you update.
Errors
PARTNER_OPERATION_FORBIDDENThe key lacks thecampaigns.readscope.PERMISSION_DENIEDThe key's acting member lacks the permission or data access.PROCESS_NOT_FOUNDThe process does not exist or the key cannot see it.
Update a process
PATCH/v1/tenants/{tenantSlug}/processes/{processId}
Changes a process's name, description or time zone. Send only the fields to change. Archived processes cannot be changed (409).
Path parameters
processIdProcess ID.
Request body (application/json)
descriptionFree-text description.
nameName of the process, as shown in the LMS.
timezoneIANA time zone, for example
Asia/Kolkata.
Responses
The updated process.
createdAtWhen it was created (ISO 8601).
descriptionFree-text description.
idID of the process.
nameName of the process, as shown in the LMS.
statusCurrent status of the process.
tenantIdID of the workspace.
timezoneIANA time zone, for example
Asia/Kolkata.updatedAtWhen it last changed (ISO 8601). Send it back as
expectedUpdatedAtwhen you update.
Errors
VALIDATION_ERRORA parameter, header or body field is invalid; compare the request with the fields above (Validation errors).PARTNER_OPERATION_FORBIDDENThe key lacks thecampaigns.writescope.PERMISSION_DENIEDThe key's acting member lacks the permission or data access.PROCESS_NOT_FOUNDThe process does not exist or the key cannot see it.PROCESS_NAME_CONFLICTAnother process already has this name.PROCESS_ARCHIVEDArchived processes cannot be changed.
Archive a process
DELETE/v1/tenants/{tenantSlug}/processes/{processId}
Archives the process. Nothing is deleted: the process and its history remain readable, but it can no longer be changed. Archiving an archived process succeeds without changes.
Path parameters
processIdProcess ID.
Responses
The process is archived.
Errors
PARTNER_OPERATION_FORBIDDENThe key lacks thecampaigns.writescope.PERMISSION_DENIEDThe key's acting member lacks the permission or data access.PROCESS_NOT_FOUNDThe process does not exist or the key cannot see it.