Skip to main content
POST
Adds a message to a GIA campaign queue. The campaign is created on the first request if it does not exist yet.

cURL examples

The request panel includes complete commands for direct, AI-generated, and WhatsApp template messages. Replace YOUR_GIA_TOKEN, the account and inbox IDs, and the message details with your own values. Use a campaign and configuration set configured for that inbox; WhatsApp templates must be approved and match the supplied language and parameters. The cURL commands use Bash syntax. --include prints the HTTP status and response headers along with the JSON body.

Authentication

Send the GIA token as a bearer token:
The token is compared with project.gia_token. Find it under Settings → Inboxes → Inbox Settings → AI Resources.
Never expose the GIA token in client applications or public repositories.

Common fields

* Send account_id and inbox_id together, or use project_id according to the project format.

Direct message

content is required for direct_message.
Minimum payload:

AI-generated message

content is required for system_with_ai and acts as an instruction for the AI.

WhatsApp template

template_params, template_params.name, and template_params.language are required for whatsapp_template_message. category is optional.
template_params preserves additional properties. They must still be compatible with downstream processing and the WhatsApp API.
Projects using a whatsapp_cloud channel only accept whatsapp_template_message on this endpoint.

Validation rules

  • identifier cannot be empty.
  • content is required for direct_message and system_with_ai.
  • template_params is required for whatsapp_template_message.
  • priority only accepts integers from 1 to 5.
  • Unknown top-level fields are discarded; additional fields inside template_params are preserved.

Response models

202 Accepted

The request was accepted and queued for asynchronous processing. This endpoint returns 202, rather than 200, on success.
This response confirms that the message was added to the queue. See Campaigns → History to monitor its execution.

401 Unauthorized

The project was found, but the token is missing or invalid for that project.

404 Not Found

No project was found for the supplied project_id or account/inbox pair. A missing campaign is not this error: campaigns are created on first use.
Both error examples use this model: