Campaigns

Create campaign

Create a campaign.

Header Parameters

X-Request-Id?string

Your id for this request; it becomes the request_id of any error. Without it the server makes one.

Request Body

application/json
  1. body
name*string
description?string
sender_id?string
channel?string

Set once. A channel that does not run campaigns, such as instagram, answers 400 invalid_value.

Default"sms"
from?string

sender_id by its unified name: a sender ID, or a WhatsApp phone_number_id.

body?string

{{name}}, {{first_name}}, {{phone}} and any contact attribute are filled in per recipient.

group_ids?array<>
all_contacts?boolean
curl -X POST 'https://v3.ghala.io/v1/campaigns' \  -H 'Content-Type: application/json' \  -d '{  "name": "string"}'
{  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",  "name": "string",  "description": "string",  "sender_id": "string",  "body": "string",  "status": "draft",  "channel": "sms",  "audiences": [    {      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",      "name": "string",      "description": "string",      "contact_count": 0,      "created_at": "2019-08-24T14:15:22Z"    }  ],  "all_contacts": true,  "created_at": "2019-08-24T14:15:22Z",  "updated_at": "2019-08-24T14:15:22Z"}