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

# Update Campaign

> Update details of an existing draft or scheduled campaign.

Update properties such as name, subject, template, or schedule for a campaign via the Mailofly API.

### Path Parameters

**id** `string` *required*

The unique identifier of the campaign.

### Body Parameters

**name** `string`

The campaign name.

**subject** `string`

The email subject line.

**content** `string`

HTML content for the campaign.

**scheduledAt** `string`

ISO 8601 timestamp to reschedule delivery.

### Response

**data** `object`

**id** `string`

The campaign ID.

**name** `string`

The updated campaign name.

**status** `string`

Campaign status.

```bash cURL theme={null}
curl -X PATCH https://api.mailofly.com/campaigns/cmp_123 \
  -H "Authorization: Bearer mf_live_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Summer Product Launch (Updated)",
    "subject": "Exclusive early access inside!"
  }'
```

```json 200 OK theme={null}
{
  "data": {
    "id": "cmp_123",
    "name": "Summer Product Launch (Updated)",
    "status": "draft"
  }
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.