Przejdź do głównej treści
GET
/
api
/
v1
/
campaigns
Wylistuj kampanie
curl --request GET \
  --url https://api.railmail.app/api/v1/campaigns \
  --header 'X-API-Key: <api-key>'
{
  "data": [
    {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "campaignKey": "<string>",
      "name": "<string>",
      "subject": "<string>",
      "previewText": "<string>",
      "contentJson": "<string>",
      "contentText": "<string>",
      "status": "<string>",
      "sendStrategy": "<string>",
      "topicIds": [
        "3c90c3cc-0d44-4b50-8888-8dd25736052a"
      ],
      "segmentIds": [
        "3c90c3cc-0d44-4b50-8888-8dd25736052a"
      ],
      "estimatedRecipientCount": 123,
      "scheduledAt": "2023-11-07T05:31:56Z",
      "completedAt": "2023-11-07T05:31:56Z",
      "fromEmail": "<string>",
      "fromName": "<string>",
      "preSendScore": 123,
      "preSendStatus": "<string>",
      "createdAt": "2023-11-07T05:31:56Z",
      "updatedAt": "2023-11-07T05:31:56Z"
    }
  ],
  "pagination": {
    "page": 123,
    "size": 123,
    "totalElements": 123,
    "totalPages": 123,
    "hasNext": true,
    "hasPrevious": true
  }
}

Autoryzacje

X-API-Key
string
header
wymagane

Project-scoped API key, format rm_(live|test)_... . May also be sent as Authorization: Bearer rm_....

Parametry zapytania

page
integer
domyślnie:0

Zero-based page index.

Wymagany zakres: x >= 0
size
integer
domyślnie:20

Page size, clamped to a maximum of 100.

Wymagany zakres: 1 <= x <= 100

Odpowiedź

Stronicowane kampanie

data
object[]
pagination
object