> ## Documentation Index
> Fetch the complete documentation index at: https://loops.so/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# List campaigns

> Retrieve a paginated list of campaigns.

<Warning>
  Content API endpoints are currently in an open alpha and are subject to
  change.
</Warning>

## Request

### Query parameters

<ParamField query="perPage" type="string" default={20}>
  How many results to return in each request. Must be between 10 and 50.
</ParamField>

<ParamField query="cursor" type="string">
  A cursor to return a specific page of results. Cursors can be found from the
  `pagination.nextCursor` value in each response.
</ParamField>

## Response

### Success

<ResponseField name="success" type="boolean" required />

<ResponseField name="pagination" type="object">
  <Expandable title="metadata" defaultOpen={false}>
    <ResponseField name="totalResults" type="number">
      Total results found.
    </ResponseField>

    <ResponseField name="returnedResults" type="number">
      The number of results returned in this response.
    </ResponseField>

    <ResponseField name="perPage" type="number">
      The maximum number of results requested.
    </ResponseField>

    <ResponseField name="totalPages" type="number">
      Total number of pages.
    </ResponseField>

    <ResponseField name="nextCursor" type="nullable string">
      The next cursor (for retrieving the next page of results using the `cursor`
      parameter), or `null` if there are no further pages.
    </ResponseField>

    <ResponseField name="nextPage" type="nullable string">
      The URL of the next page of results, or `null` if there are no further
      pages.
    </ResponseField>
  </Expandable>
</ResponseField>

<ResponseField name="data" type="array" required>
  <Expandable title="campaign" defaultOpen={true}>
    <ResponseField name="campaignId" type="string" required>
      The campaign ID.
    </ResponseField>

    <ResponseField name="emailMessageId" type="nullable string" required>
      The associated email message ID.
    </ResponseField>

    <ResponseField name="name" type="string" required>
      The campaign name.
    </ResponseField>

    <ResponseField name="subject" type="string" required>
      The campaign subject line.
    </ResponseField>

    <ResponseField name="status" type="string" required>
      Campaign lifecycle status (for example `Draft`, `Scheduled`, `Sending`,
      `Sent`).
    </ResponseField>

    <ResponseField name="createdAt" type="string" required>
      ISO 8601 timestamp for when the campaign was created.
    </ResponseField>

    <ResponseField name="updatedAt" type="string" required>
      ISO 8601 timestamp for when the campaign was last updated.
    </ResponseField>
  </Expandable>
</ResponseField>

### Error

If `perPage` is invalid, a `400 Bad Request` is returned.

If the API key is invalid (or content API is not enabled for your team), a
`401 Unauthorized` is returned.

<ResponseField name="success" type="boolean" required />

<ResponseField name="message" type="string" required>
  An error message describing what went wrong.
</ResponseField>

<ResponseExample>
  ```json Response theme={"dark"}
  {
    "success": true,
    "pagination": {
      "totalResults": 2,
      "returnedResults": 2,
      "perPage": 20,
      "totalPages": 1,
      "nextCursor": null,
      "nextPage": null
    },
    "data": [
      {
        "campaignId": "cmp_01hxyz",
        "emailMessageId": "em_01hxyz",
        "name": "Spring announcement",
        "subject": "Big spring updates",
        "status": "Draft",
        "createdAt": "2026-03-28T15:00:00.000Z",
        "updatedAt": "2026-03-28T15:00:00.000Z"
      }
    ]
  }
  ```

  ```json Error response theme={"dark"}
  {
    "success": false,
    "message": "Invalid perPage value"
  }
  ```
</ResponseExample>
