---
title: "Create Coupon"
description: "How to call Create Coupon (POST /api/coupons) in the Klaviyo REST API: authentication, parameters, request and response bodies, and an example request."
url: "https://developers.klaviyo.com/en/reference/create_coupon"
revision: "2026-10-15"
operationId: "create_coupon"
method: "POST"
endpoint: "https://a.klaviyo.com/api/coupons"
authentication: "privateKey"
scopes: ["coupons:write"]
rateLimits: {"burst":"3/s","steady":"60/m"}
revisionHeader: {"name":"revision","required":true}
deprecated: false
openApi: "https://raw.githubusercontent.com/klaviyo/openapi/2026-10-15/openapi/stable/apis/create_coupon.json"
jsonApi: {"fields":{"coupon":["assigner_configuration","assigner_configuration.unused_expired","assigner_configuration.used","description","external_id","id","monitor_configuration"]}}
related: ["https://developers.klaviyo.com/en/reference/coupons/llms.txt","https://developers.klaviyo.com/en/reference/get_coupons.md","https://developers.klaviyo.com/en/reference/get_coupon.md","https://developers.klaviyo.com/en/reference/update_coupon.md","https://developers.klaviyo.com/en/reference/delete_coupon.md","https://developers.klaviyo.com/en/reference/get_coupon_codes.md","https://developers.klaviyo.com/en/reference/get_coupon_code.md","https://developers.klaviyo.com/en/reference/create_coupon_code.md","https://developers.klaviyo.com/en/reference/update_coupon_code.md","https://developers.klaviyo.com/en/reference/delete_coupon_code.md","https://developers.klaviyo.com/en/reference/get_bulk_create_coupon_code_jobs.md","https://developers.klaviyo.com/en/reference/get_bulk_create_coupon_codes_job.md","https://developers.klaviyo.com/en/reference/bulk_create_coupon_codes.md","https://developers.klaviyo.com/en/reference/get_coupon_codes_for_coupon.md","https://developers.klaviyo.com/en/reference/get_coupon_code_ids_for_coupon.md","https://developers.klaviyo.com/en/reference/get_coupon_for_coupon_code.md","https://developers.klaviyo.com/en/reference/get_coupon_id_for_coupon_code.md"]
---

# Create Coupon

> This is the Markdown version of https://developers.klaviyo.com/en/reference/create_coupon

```http
POST https://a.klaviyo.com/api/coupons
```

Creates a new coupon.

- Revision header: `revision: 2026-10-15` (required)
- Scopes: `coupons:write`
- Rate limits: Burst: `3/s`, Steady: `60/m`
- OpenAPI: [Download this endpoint's OpenAPI document](https://raw.githubusercontent.com/klaviyo/openapi/2026-10-15/openapi/stable/apis/create_coupon.json)

## Example request

### curl

```bash
curl --request POST \
     --url 'https://a.klaviyo.com/api/coupons' \
     --header 'Authorization: Klaviyo-API-Key your-private-api-key' \
     --header 'accept: application/vnd.api+json' \
     --header 'revision: 2026-10-15' \
     --header 'content-type: application/vnd.api+json' \
     --data '{
  "data": {
    "type": "coupon",
    "attributes": {
      "external_id": "10OFF",
      "description": "10% off for purchases over $50",
      "monitor_configuration": {
        "low_balance_threshold": 500
      }
    }
  }
}'
```

### CLI

```bash
klaviyo coupons create \
  -d '{
  "data": {
    "type": "coupon",
    "attributes": {
      "external_id": "10OFF",
      "description": "10% off for purchases over $50",
      "monitor_configuration": {
        "low_balance_threshold": 500
      }
    }
  }
}'
```

Sign in first with `klaviyo auth login`. [Install the Klaviyo CLI](https://developers.klaviyo.com/en/docs/klaviyo_cli.md)

### Python

```python
from klaviyo_api import KlaviyoAPI

klaviyo = KlaviyoAPI("your-private-api-key")

response = klaviyo.Coupons.create_coupon(
    {
        "data": {
            "type": "coupon",
            "attributes": {
                "external_id": "10OFF",
                "description": "10% off for purchases over $50",
                "monitor_configuration": {
                    "low_balance_threshold": 500,
                },
            },
        },
    },
)
```

Install it with `pip install klaviyo-api`. [The Python SDK on GitHub](https://github.com/klaviyo/klaviyo-api-python)

### Node.js

```javascript
import { ApiKeySession, CouponsApi } from 'klaviyo-api'

const session = new ApiKeySession('your-private-api-key')
const couponsApi = new CouponsApi(session)

const response = await couponsApi.createCoupon(
  {
    data: {
      type: 'coupon',
      attributes: {
        externalId: '10OFF',
        description: '10% off for purchases over $50',
        monitorConfiguration: {
          low_balance_threshold: 500,
        },
      },
    },
  },
)
```

Install it with `npm install klaviyo-api`. [The Node.js SDK on GitHub](https://github.com/klaviyo/klaviyo-api-node)

### Ruby

```ruby
require 'klaviyo-api-sdk'

KlaviyoAPI.configure do |config|
  config.api_key['Klaviyo-API-Key'] = 'Klaviyo-API-Key your-private-api-key'
end

response = KlaviyoAPI::Coupons.create_coupon(
  {
    data: {
      type: 'coupon',
      attributes: {
        external_id: '10OFF',
        description: '10% off for purchases over $50',
        monitor_configuration: {
          low_balance_threshold: 500,
        },
      },
    },
  },
)
```

Install it with `gem install klaviyo-api-sdk`. [The Ruby SDK on GitHub](https://github.com/klaviyo/klaviyo-api-ruby)

### PHP

```php
<?php
require_once(__DIR__ . '/vendor/autoload.php');

use KlaviyoAPI\KlaviyoAPI;

$klaviyo = new KlaviyoAPI('your-private-api-key');

$response = $klaviyo->Coupons->createCoupon(
    [
        'data' => [
            'type' => 'coupon',
            'attributes' => [
                'external_id' => '10OFF',
                'description' => '10% off for purchases over $50',
                'monitor_configuration' => [
                    'low_balance_threshold' => 500,
                ],
            ],
        ],
    ],
);
```

Install it with `composer require klaviyo/api`. [The PHP SDK on GitHub](https://github.com/klaviyo/klaviyo-api-php)

## Query parameters

- `fields[coupon]` (string[]): For more information please visit [API overview](https://developers.klaviyo.com/en/reference.md) Allowed values: `assigner_configuration`, `assigner_configuration.unused_expired`, `assigner_configuration.used`, `description`, `external_id`, `id`, `monitor_configuration`

## Headers

- `revision` (string, required): API endpoint revision (format: YYYY-MM-DD[.suffix]) Default: `2026-10-15`

## Request body

Content type: `application/vnd.api+json` (required)

- `data` (object, required)
  - `type` (string, required): Allowed values: `coupon`
  - `attributes` (object, required)
    - `external_id` (string, required): This is the id that is stored in an integration such as Shopify or Magento. Example: `10OFF`
    - `description` (string, nullable): A description of the coupon. Example: `10% off for purchases over $50`
    - `monitor_configuration` (object, nullable): The monitor configuration for the coupon.
    - `assigner_configuration` (object)
      - `used` (string, required): Controls when a new coupon code is issued relative to the customer's existing code being used. Allowed values: `ALWAYS_ASSIGN`, `ASSIGN_IF_EXPIRED`, `NEVER_ASSIGN` Example: `ALWAYS_ASSIGN`
      - `unused_expired` (string, required): Controls when a new coupon code is issued relative to the customer's existing, unused code expiring. Allowed values: `ALWAYS_ASSIGN`, `NEVER_ASSIGN` Example: `ALWAYS_ASSIGN`

### Example request body

```json
{
  "data": {
    "type": "coupon",
    "attributes": {
      "external_id": "10OFF",
      "description": "10% off for purchases over $50",
      "monitor_configuration": {
        "low_balance_threshold": 500
      }
    }
  }
}
```

## Responses

### 201: Success

Content type: `application/vnd.api+json`

- `data` (object, required)
  - `type` (string, required): Allowed values: `coupon`
  - `id` (string, required): The internal id of a Coupon is equivalent to its external id stored within an integration. Example: `10OFF`
  - `attributes` (object, required)
    - `external_id` (string, required): This is the id that is stored in an integration such as Shopify or Magento. Example: `10OFF`
    - `description` (string, nullable): A description of the coupon. Example: `10% off for purchases over $50`
    - `monitor_configuration` (object, nullable): The monitor configuration for the coupon.
    - `assigner_configuration` (object): Same fields as CouponAssignerConfiguration in the request body above.
  - `links` (object, required)
    - `self` (string<uri>, required)
- `links` (ObjectLinks): Same fields as the first ObjectLinks above.
- `meta` (object): Response-level metadata
  - `agent_hints` (object): Optional hints emitted by the API for agent callers
    - `next_steps` (string[]): Suggested follow-up actions for agents to take after this response

#### Example response body

```json
{
  "data": {
    "type": "coupon",
    "id": "10OFF",
    "attributes": {
      "external_id": "10OFF",
      "description": "10% off for purchases over $50",
      "monitor_configuration": {
        "low_balance_threshold": 500
      },
      "assigner_configuration": {
        "used": "ALWAYS_ASSIGN",
        "unused_expired": "ALWAYS_ASSIGN"
      }
    },
    "links": {
      "self": "https://www.example.com"
    }
  },
  "links": {
    "self": "https://www.example.com"
  },
  "meta": {
    "agent_hints": {
      "next_steps": [
        "string"
      ]
    }
  }
}
```

### 4XX: Client Error

Content type: `application/vnd.api+json`

- `errors` (object[], required)
  - `id` (string, required)
  - `code` (string, required)
  - `title` (string, required)
  - `detail` (string, required)
  - `source` (object)
    - `pointer` (string)
    - `parameter` (string)

#### Example response body

```json
{
  "errors": [
    {
      "id": "string",
      "code": "string",
      "title": "string",
      "detail": "string",
      "source": {
        "pointer": "string",
        "parameter": "string"
      }
    }
  ]
}
```

### 5XX: Server Error

Content type: `application/vnd.api+json`

- `errors` (object[], required)
  - `id` (string, required)
  - `code` (string, required)
  - `title` (string, required)
  - `detail` (string, required)
  - `source` (object)
    - `pointer` (string)
    - `parameter` (string)

#### Example response body

```json
{
  "errors": [
    {
      "id": "string",
      "code": "string",
      "title": "string",
      "detail": "string",
      "source": {
        "pointer": "string",
        "parameter": "string"
      }
    }
  ]
}
```
