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

# POST Cancel Subscription

> Cancel a user subscription.

## Cancel subscription

`DELETE /api/subscriptions/:id`

Cancel an active subscription.

### Headers

**x-api-key** `string` *required*

Your API key

**x-api-secret** `string` *required*

Your API secret key

**x-channel-id** `string` *required*

WhatsApp channel ID

**id** `integer` *required*

Subscription ID.

```bash cURL theme={null}
curl -X DELETE https://zeplo.ai/api/subscriptions/1 \
  -H "x-api-key: YOUR_API_KEY" \
  -H "x-api-secret: YOUR_API_SECRET" \
  -H "x-channel-id: YOUR_CHANNEL_ID"
```

```json Response theme={null}
{
  "success": true,
  "message": "Subscription cancelled",
  "data": {
    "id": 1,
    "status": "cancelled",
    "endDate": "2026-02-01T23:59:59Z"
  }
}
```

> [!NOTE]
>
> The subscription remains active until the end of the current billing period.


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