Returns one campaign. Permission: `campaigns`.

## Path Parameters

| Name | Type | Description |
| ---- | ---- | ----------- |
| `campaignId` | string | **Required.** Campaign id. |

## Response Fields

| Field | Type | Description |
| ----- | ---- | ----------- |
| `id` | string | Campaign id. |
| `name` | string | Campaign name. |
| `subject` | string | Subject line. |
| `preview` | string or null | Preview text. |
| `status` | string | `DRAFT`, `ARCHIVED`, `SCHEDULED`, `SENDING`, `SENT`, or `FAILED`. |
| `contentType` | string | `MAILY`, `PLATE`, or `MARKDOWN`. |
| `mailFormat` | string | Render format. |
| `content` | unknown | TipTap document. |
| `recipientCount` | integer | Matching recipients. |
| `recipientFilters` | array | Audience filters. |
| `emailsSentCount` | integer | Emails handed to SES. |
| `emailsOpenedCount` | integer | Unique opens. |
| `emailsClickedCount` | integer | Unique clicks. |
| `scheduledAt` | string or null | Scheduled send time. |
| `sendAt` | string or null | Actual send time. |
| `timezone` | string or null | Schedule timezone. |
| `senderId` | string | Sender id. |
| `sender` | object or null | `{ id, name, email }`. |
| `replyTo` | string or null | Reply-To address. |

## Errors

| Status | `name` | When |
| ------ | ------ | ---- |
| 401 | `missing_api_key` | Missing or invalid bearer token |
| 403 | `missing_permission` | Token lacks the `campaigns` permission |
| 404 | `not_found` | Unknown campaign id |

## Related

- [Update Campaign](/docs/api-reference/v2/campaigns-update)
- [Send Campaign](/docs/api-reference/v2/campaigns-send)
- [SDK: lumail.campaigns.get](/docs/sdk/v2/campaigns-get)


## API Reference
**Method:** GET
**Endpoint:** /api/v2/campaigns/:campaignId

### SDK
```ts
import { Lumail } from "lumail";

const lumail = new Lumail({ apiKey: process.env.LUMAIL_API_KEY });
const { data, error } = await lumail.campaigns.get("cmp_abc123");
if (error) {
  throw error;
}
console.log(data.subject, data.status);
```

### cURL
```bash
curl https://lumail.io/api/v2/campaigns/cmp_abc123 \
  -H "Authorization: Bearer YOUR_API_TOKEN"
```

### JavaScript
```javascript
const response = await fetch(
  "https://lumail.io/api/v2/campaigns/cmp_abc123",
  {
    headers: {
      Authorization: "Bearer YOUR_API_TOKEN",
    },
  },
);
const data = await response.json();
```

### Success Response
```json
{
  "id": "cmp_abc123",
  "name": "Launch",
  "subject": "Hello",
  "preview": null,
  "status": "DRAFT",
  "contentType": "MAILY",
  "mailFormat": "HTML",
  "content": { "type": "doc", "content": [] },
  "recipientCount": 0,
  "recipientFilters": [],
  "scheduledAt": null,
  "sendAt": null,
  "senderId": "snd_abc123",
  "sender": {
    "id": "snd_abc123",
    "name": "Ada",
    "email": "hello@yourdomain.com"
  },
  "replyTo": null
}
```

### Error Response
```json
{
  "name": "not_found",
  "message": "Campaign not found",
  "statusCode": 404
}
```
