Get Campaign Status
GEThttps://viso.li/api/campaign/:id/status
Returns how close a campaign is to its goal, plus the stored templateKey and typed goal.config.
Progress uses the campaign date window when dates are set, otherwise all clicks on the attached links.
Send Authorization: Bearer sk_api_your_api_key on every request. See authentication.
Path parameters
| Field | Type | Description |
|---|---|---|
id | string | Required. The campaign UUID. |
Example request
1curl https://viso.li/api/campaign/3f1c0c2a-7b4e-4d91-9c2a-1b8e6f0d2a11/status \
2 -H "Authorization: Bearer sk_api_your_api_key"
Success response
Returns 200 OK. goal.config is typed by goal.type and keeps template fields such as windowDays or burstDays.
response.json
1{
2 "id": "3f1c0c2a-7b4e-4d91-9c2a-1b8e6f0d2a11",
3 "name": "Bio link",
4 "status": "ACTIVE",
5 "templateKey": "bio-evergreen",
6 "goal": {
7 "type": "CLICKS",
8 "config": {
9 "target": 10000,
10 "windowDays": 30
11 }
12 },
13 "progress": {
14 "type": "CLICKS",
15 "target": 10000,
16 "current": 1240,
17 "remaining": 8760,
18 "percent": 12,
19 "reached": false
20 }
21}
Response fields
| Field | Type | Description |
|---|---|---|
id | string | Campaign UUID. |
goal.type | string | CLICKS, UNIQUE_VISITORS, or COMPARE. |
goal.config | object | Typed settings stored for this goal. |
progress.percent | number | 0–100, rounded. |
progress.reached | boolean | true when current meets the target. |
Errors
| Status | Error | Description |
|---|---|---|
| 400 | Bad Request | The campaign id is not a valid UUID. |
| 401 | Unauthorized | Missing, malformed, or invalid Bearer token. |
| 403 | Forbidden | Campaigns are not available on the current plan. |
| 404 | Not Found | No campaign with that id belongs to you. |
| 429 | Too Many Requests | More than 10 requests per minute or 50 requests per day. |
| 500 | Internal Server Error | Unexpected server error. Retry the request. |