Skip to main content
GET
/
campaigns
List campaigns
curl --request GET \
  --url https://api.mailglyph.com/campaigns \
  --header 'Authorization: Bearer <token>'
{
  "data": [
    {
      "id": "<string>",
      "name": "<string>",
      "description": "<string>",
      "subject": "<string>",
      "body": "<string>",
      "from": "jsmith@example.com",
      "fromName": "<string>",
      "replyTo": "jsmith@example.com",
      "audienceCondition": {
        "groups": [
          {
            "filters": [
              {
                "field": "<string>",
                "value": "<unknown>"
              }
            ],
            "conditions": "<unknown>"
          }
        ]
      },
      "segmentId": "<string>",
      "totalRecipients": 123,
      "sentCount": 123,
      "deliveredCount": 123,
      "openedCount": 123,
      "clickedCount": 123,
      "bouncedCount": 123,
      "scheduledFor": "2023-11-07T05:31:56Z",
      "sentAt": "2023-11-07T05:31:56Z",
      "createdAt": "2023-11-07T05:31:56Z",
      "updatedAt": "2023-11-07T05:31:56Z",
      "segment": {
        "id": "<string>",
        "name": "<string>",
        "description": "<string>",
        "condition": {
          "groups": [
            {
              "filters": [
                {
                  "field": "<string>",
                  "value": "<unknown>"
                }
              ],
              "conditions": "<unknown>"
            }
          ]
        },
        "trackMembership": true,
        "memberCount": 123,
        "projectId": "<string>",
        "createdAt": "2023-11-07T05:31:56Z",
        "updatedAt": "2023-11-07T05:31:56Z"
      }
    }
  ],
  "page": 123,
  "pageSize": 123,
  "total": 123,
  "totalPages": 123
}

Documentation Index

Fetch the complete documentation index at: https://docs.mailglyph.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

API Key authentication. Secret keys (sk_*) are required for all endpoints except /v1/track. Public keys (pk_*) only work with the /v1/track endpoint for client-side event tracking. Workspaces can have multiple active keys, and sender-domain operations enforce per-key domain scope when configured.

Query Parameters

page
integer
default:1

Page number

Required range: x >= 1
pageSize
integer
default:20

Items per page (max 100)

Required range: 1 <= x <= 100
status
enum<string>
Available options:
DRAFT,
SCHEDULED,
SENDING,
SENT,
CANCELLED

Response

200 - application/json

List of campaigns

data
object[]
page
integer
pageSize
integer
total
integer
totalPages
integer