---
title: "Archive a coupon"
description: "Soft — active=false."
canonical_url: "https://twominutebilling.com/help/developers/api-reference/catalog/archive-a-coupon"
---
# Archive a coupon

> Soft — active=false.

<api-operation method="DELETE" path="/v1/businesses/{biz}/coupons/{cpn}">
<template v-slot:docs="">

## Path parameters

<table>
<thead>
  <tr>
    <th>
      Parameter
    </th>
    
    <th>
      Type
    </th>
    
    <th>
      Required
    </th>
    
    <th>
      Description
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      <code>
        biz
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      <strong>
        yes
      </strong>
    </td>
    
    <td>
      Business id (biz_…)
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        cpn
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      <strong>
        yes
      </strong>
    </td>
    
    <td>
      The coupon's id (a slug id, e.g. <code>
        welcome-10
      </code>
      
      ).
    </td>
  </tr>
</tbody>
</table>

## Headers

<table>
<thead>
  <tr>
    <th>
      Parameter
    </th>
    
    <th>
      Type
    </th>
    
    <th>
      Required
    </th>
    
    <th>
      Description
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      <code>
        Idempotency-Key
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      no
    </td>
    
    <td>
      Safely retry writes — repeats return the original response. If a write FAILED after it had already taken effect, that failure is what repeats: the key is spent, and a new attempt needs a new key.
    </td>
  </tr>
</tbody>
</table>

## Response

<table>
<thead>
  <tr>
    <th>
      Field
    </th>
    
    <th>
      Type
    </th>
    
    <th>
      Description
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      <code>
        object
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      The object type.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        id
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      The coupon's id (<code>
        welcome-10
      </code>
      
      ).
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        code
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      Same value as <code>
        id
      </code>
      
       — the code IS the id
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        name
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      The coupon's name.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        kind
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      Whether the coupon takes off a percentage or a fixed amount.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        percent_off_bps
      </code>
    </td>
    
    <td>
      <code>
        integer
      </code>
    </td>
    
    <td>
      The percentage off in basis points (100 = 1%), for a percentage coupon.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        amount_off_minor
      </code>
    </td>
    
    <td>
      <code>
        integer
      </code>
    </td>
    
    <td>
      The fixed amount off, in minor units, for a fixed-amount coupon.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        currency
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      The currency of <code>
        amount_off_minor
      </code>
      
       (ISO-4217 code).
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        duration_type
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      How long the discount lasts.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        duration_in_periods
      </code>
    </td>
    
    <td>
      <code>
        integer
      </code>
    </td>
    
    <td>
      The number of periods the discount lasts, for <code>
        repeating
      </code>
      
      .
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        apply_on
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      Whether the discount applies to the invoice amount or to each specified item.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        invoice_name
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      The name printed on invoices for this discount.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        valid_from
      </code>
    </td>
    
    <td>
      <code>
        string · ISO-8601
      </code>
    </td>
    
    <td>
      When the coupon becomes valid (ISO-8601 UTC).
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        redeem_by
      </code>
    </td>
    
    <td>
      <code>
        string · ISO-8601
      </code>
    </td>
    
    <td>
      The last time the coupon can be redeemed (ISO-8601 UTC).
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        times_redeemed
      </code>
    </td>
    
    <td>
      <code>
        integer
      </code>
    </td>
    
    <td>
      How many times the coupon has been redeemed.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        max_redemptions
      </code>
    </td>
    
    <td>
      <code>
        integer
      </code>
    </td>
    
    <td>
      The most times the coupon can be redeemed.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        max_redemptions_per_customer
      </code>
    </td>
    
    <td>
      <code>
        integer
      </code>
    </td>
    
    <td>
      Redemptions allowed per customer across their subscriptions; null = no cap. Applying past it is a 400.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        active
      </code>
    </td>
    
    <td>
      <code>
        boolean
      </code>
    </td>
    
    <td>
      True if the coupon is active.
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        status
      </code>
    </td>
    
    <td>
      <code>
        string
      </code>
    </td>
    
    <td>
      Derived, in the business timezone — not a stored column One of <code>
        future
      </code>
      
      , <code>
        active
      </code>
      
      , <code>
        expired
      </code>
      
      , <code>
        archived
      </code>
      
      .
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        item_constraints
      </code>
    </td>
    
    <td>
      <code>
        array of object
      </code>
    </td>
    
    <td>
      null when apply_on is not each_specified_item
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        metadata
      </code>
    </td>
    
    <td>
      <code>
        object
      </code>
    </td>
    
    <td>
      Key-value pairs you attach to the coupon.
    </td>
  </tr>
</tbody>
</table>

## Status codes

<table>
<thead>
  <tr>
    <th>
      Status
    </th>
    
    <th>
      Meaning
    </th>
  </tr>
</thead>

<tbody>
  <tr>
    <td>
      <code>
        200
      </code>
    </td>
    
    <td>
      Success
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        404
      </code>
    </td>
    
    <td>
      No such coupon
    </td>
  </tr>
  
  <tr>
    <td>
      <code>
        409
      </code>
    </td>
    
    <td>
      Idempotency-Key conflict — the key is already in flight, or was reused with a different request payload.
    </td>
  </tr>
</tbody>
</table>
</template>

<template v-slot:request="">

```bash [Request]
curl -X DELETE "$TMBILLING_URL/v1/businesses/biz_XXXXXXXXXXXX01/coupons/welcome-10" \
  -H "Authorization: Bearer $TMBILLING_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)"
```

</template>

<template v-slot:response="">
<code-group>

```json [200 OK]
{
  "object": "coupon",
  "id": "welcome-10",
  "code": "welcome-10",
  "name": "Welcome 10% off",
  "kind": "percentage",
  "percent_off_bps": 1000,
  "amount_off_minor": 2900,
  "currency": "USD",
  "duration_type": "once",
  "duration_in_periods": 1,
  "apply_on": "invoice_amount",
  "invoice_name": "Welcome 10% off",
  "valid_from": "2026-03-14T09:30:00Z",
  "redeem_by": "2026-03-14T09:30:00Z",
  "times_redeemed": 1,
  "max_redemptions": 1,
  "max_redemptions_per_customer": 1,
  "active": false,
  "status": "active",
  "item_constraints": [
    {
      "item_kind": "plan",
      "constraint_type": "all"
    }
  ],
  "metadata": {
    "crm_id": "acct-1001"
  }
}
```

```json [404 Not Found]
{
  "error": {
    "type": "invalid_request_error",
    "message": "No such coupon"
  }
}
```

```json [409 Conflict]
{
  "error": {
    "type": "idempotency_error",
    "message": "Idempotency-Key conflict — the key is already in flight, or was reused with a different request payload."
  }
}
```

</code-group>
</template>
</api-operation>


## Sitemap

See the full [sitemap](https://twominutebilling.com/sitemap.md) for all pages.
