Skip to Content
SettingsDeveloperDeveloper APIs

AeternityChat Developer API

Welcome to the AeternityChat Developer API.

Use these APIs to send messages, schedule customer sequences etc programmatically.


Authentication

All Developer API requests must include your API key in the request headers.

Required Header

{ "x-aeternitychat-key": "<your_api_key>" }

Messaging API

Send Bulk Messages

Send up to 100 messages in a single asynchronous request.

Note

  • Maximum 100 messages per API request.
  • Requests are accepted immediately and processed asynchronously in the background.

Endpoint

POST https://api.aeternity.chat/api/v1/developer/message/channel/:channel/connection/:connectionId

Path Parameters

ParameterTypeRequiredDescription
channelstringYesMessaging channel (for example: whatsapp)
connectionIdstringYesChannel connection identifier

Request Body

{ "messages": [ { "messaging_product": "whatsapp", "to": "910000000000", "type": "text", "text": { "body": "test" } } ] }

Response

HTTP Status: 202 Accepted

{ "messages": [ { "id": "<unique_id>", "status": "ready" }, { "id": "<unique_id>", "status": "failed", "error": "<error_reason>" } ] }

Response Fields

FieldTypeDescription
messagesarrayProcessing result for each submitted message
messages[].idstringUnique message identifier
messages[].statusstringProcessing status (ready or failed)
messages[].errorstringFailure reason (only present when status is failed)

cURL Example

curl --request POST \ --url "https://api.aeternity.chat/api/v1/developer/message/channel/CHANNEL/connection/CONNECTION_ID" \ --header "Content-Type: application/json" \ --header "x-aeternitychat-key: YOUR_API_KEY" \ --data '{ "messages": [ { "messaging_product": "whatsapp", "to": "910000000000", "type": "text", "text": { "body": "Hello from AeternityChat" } } ] }'

Notes

  • Requests are processed asynchronously.
  • Each message is validated independently.
  • A successful API response (202 Accepted) only indicates that the request has been accepted for processing.
  • Individual message failures are returned inside the messages array.

Sequence API

Schedule a Journey

Schedule a sequence for a contact.


Endpoint

POST https://api.aeternity.chat/api/v1/developer/journey/schedule/:sequenceId/contact/:contactId

Parameters

ParameterTypeRequiredDefaultDescription
sequenceIdstringYesSequence identifier
contactIdstringYesContact identifier
cancelAllPreviousJourneysbooleanNotrueCancel all existing scheduled sequences for the contact before scheduling the new one
shiftMessagesBySecondsnumberNo0Shift the timing of every message in the sequence by the specified number of seconds

Response

HTTP Status: 202 Accepted

{}

cURL Example

curl --request POST \ "https://api.aeternity.chat/api/v1/developer/journey/schedule/<sequenceId>/contact/<contactId>" \ --header "x-aeternitychat-key: YOUR_API_KEY"

Cancel a Scheduled Sequence

Cancel one or all scheduled sequences for a contact.


Endpoint

POST https://api.aeternity.chat/api/v1/developer/journey/cancel/contact/:contactId

Parameters

ParameterTypeRequiredDefaultDescription
contactIdstringYesContact identifier
cancelledReasonstringYesReason for cancelling the journey
scheduledJourneyIdstringNoCancel a specific scheduled journey

Response

HTTP Status: 202 Accepted

{}

cURL Example

curl --request POST \ "https://api.aeternity.chat/api/v1/developer/journey/cancel/contact/<contactId>" \ --header "x-aeternitychat-key: YOUR_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "scheduledJourneyId": "test", "cancelledReason": "Contact is qualified" }'

Notes

  • To cancel a specific scheduled sequence, provide scheduledJourneyId.