Get campaign status
Description
Retrieve the current status of a campaign.
Access rights
To use this method, the API token must have:
- Campaigns — View object
- Access to the groups where the campaigns are located
Configure permissions in Settings → Tokens.
Request URL
Method: POST
https://example.com/api/v1.1/scampaigns/get_status
Request parameters
| Parameter | Type | Example | Required | Description |
|---|---|---|---|---|
| token | string | "abcdefghijklmnqrstuvwxyz" | Yes | API token |
| id | int | 10 | Yes | Campaign ID |
Request example
- JSON
- XML
{
"token": "abcdefghijklmnqrstuvwxyz",
"id": 10
}
<xml>
<token>abcdefghijklmnqrstuvwxyz</token>
<id>10</id>
</xml>
Response example
- JSON
- XML
{
"data": {
"status": "active"
},
"error": 0,
"error_text": "Successful operation"
}
<xml>
<error>0</error>
<error_text>Successful operation</error_text>
<data>
<status>active</status>
</data>
</xml>
Returned parameters
| Parameter | Type | Description |
|---|---|---|
| error | int | Error code |
| error_text | string | Error description |
| data | object | Object containing status information |
Status fields
| Parameter | Type | Description |
|---|---|---|
| status | string | Current campaign status |
Possible statuses
| Status | Description |
|---|---|
| cloning | Being cloned |
| inactive | Inactive |
| waiting | Awaiting activation |
| active | Active |
| completed | Completed |
| deleted | Deleted |