Campaign — Test¶
GET retrieves the campaign in its current state.
POST sends a test to the specified email addresses and/or telephone numbers. Both email and SMS payloads are tested.
Endpoint¶
All verbs: /campaign/<campaign>/test
GET /campaign/<campaign>/test¶
Payload: No payload.
Returns: The campaign.
Example:
curl -u "username:api_key" -H "Accept: application/json" \
https://app.duo.pt/campaign/{campaign_id}/test
Response:
{
"success": true,
"data": {
"campaign": {
"id": 1,
"owner": 1,
"list": 1,
"name": "Summer Newsletter 2026",
"domain": 1,
"segments": [],
"recipients": null,
"state": "DRAFT",
"when": {
"date": "2026-06-22 21:54:05.000000",
"timezone_type": 3,
"timezone": "UTC"
},
"event_callback": null
}
}
}
POST /campaign/<campaign>/test¶
Sends a test of the campaign email payload to a destination address. SMS payloads are not included in test sends.
| Parameter | Type | Description |
|---|---|---|
destination |
string | Comma-separated email addresses and telephone numbers. Numbers without @ are sent as SMS. Maximum 20 destinations. Test sends do not consume email or SMS credits. e.g. email@example.com,351910000001 |
Returns: The campaign.
Example: