List Campaigns
List your organization's push campaigns, newest first.
Endpoint
GET /push/campaigns
Returns: 200 OK
Query Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
search | string | — | Filter by campaign name. |
status | string | all | Draft, Scheduled, Queued, Sending, Paused, Sent, Failed, Cancelled, Archived. |
limit | integer | 20 | Items per page, 1–100. |
after | string | — | Return items after this id (exclusive). |
before | string | — | Return items before this id (exclusive). |
See Pagination for how cursor paging works.
Headers
| Header | Value | Required |
|---|---|---|
Authorization | Bearer <your-api-key> | Yes |
Response
{
"object": "list",
"has_more": false,
"data": [
{
"id": "0192a1b2-c3d4-7e5f-9000-abcdef123456",
"name": "Flash sale — 6h only",
"title": "Doors close at midnight",
"body": "Everything 40% off for the next six hours.",
"status": "Sent",
"scheduled_at": null,
"sent_at": "2026-09-01T09:05:00.000Z",
"created_at": "2026-08-10T12:00:00.000Z",
"updated_at": "2026-09-01T09:05:00.000Z"
}
]
}
Each item has the same shape as the Create Campaign response.
Examples
- cURL
- JavaScript
- Python
- C#
- PHP
curl "https://api.arsel.sa/v1/push/campaigns?status=Sent&limit=50" \
-H "Authorization: Bearer be_your_api_key"
const response = await fetch(
"https://api.arsel.sa/v1/push/campaigns?status=Sent&limit=50",
{ headers: { Authorization: "Bearer be_your_api_key" } },
);
const { data, has_more } = await response.json();
console.log(data.length, has_more);
import requests
response = requests.get(
"https://api.arsel.sa/v1/push/campaigns",
headers={"Authorization": "Bearer be_your_api_key"},
params={"status": "Sent", "limit": 50},
)
payload = response.json()
print(len(payload["data"]), payload["has_more"])
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("Authorization", "Bearer be_your_api_key");
var response = await client.GetStringAsync(
"https://api.arsel.sa/v1/push/campaigns?status=Sent&limit=50");
Console.WriteLine(response);
<?php
$ch = curl_init("https://api.arsel.sa/v1/push/campaigns?status=Sent&limit=50");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["Authorization: Bearer be_your_api_key"]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
echo curl_exec($ch);
curl_close($ch);
Error Responses
- 401 Unauthorized
{
"status_code": 401,
"name": "unauthorized",
"message": "Invalid or missing API key"
}