OORQO API
Campaigns

Create a campaign

Creates a draft. Launch it with `POST /campaigns/{id}/launch`. Send an `Idempotency-Key` header to retry safely.

POST
/v1/campaigns

Creates a draft. Launch it with POST /campaigns/{id}/launch. Send an Idempotency-Key header to retry safely.

Authorization

http
headerAuthorizationBearer <token>

Header Parameters

Idempotency-Key?string

Any unique string up to 255 characters, such as a UUID. Retrying with the same key returns the first response (with Idempotent-Replayed: true) instead of acting twice.

Request Body

application/json
  1. body
name*string
Lengthlength <= 200
channel*"whatsapp"
Value in"whatsapp"
audience_type?|

Defaults to segment.

Value in"segment""contact_list""tag""csv"
audience_ref?|

Segment id, tag name or CSV upload reference, depending on audience_type.

template?array<string>|

Approved WhatsApp template: name, language and component parameters.

payload?array<string>|

Extra message payload, such as header media.

schedule_at?|

ISO 8601 time to send at; omit to send on launch.

Formatdate-time
timezone?|

IANA time zone, e.g. Africa/Cairo.

Lengthlength <= 64

Response Body

Campaign

application/json
  1. response
data*
Example Request
curl -X POST 'https://app.orqo.site/api/v1/campaigns' \  -H 'Idempotency-Key: 9f1c2a7e-4b8d-4e57-a3f0-6c1d2e3f4a5b' \  -H 'Content-Type: application/json' \  -d '{  "name": "string",  "channel": "whatsapp"}'
Example Response
{  "data": {    "id": 0,    "name": "string",    "channel": "string",    "status": "string",    "audience_type": "string",    "audience_ref": "string",    "template": [      null    ],    "payload": [      null    ],    "schedule_at": "string",    "timezone": "string",    "stats": {      "total": 0,      "queued": 0,      "sent": 0,      "delivered": 0,      "read": 0,      "failed": 0    },    "created_at": "string",    "updated_at": "string"  }}