---
title: "Update coupon"
method: PUT
path: "/v1/applications/{applicationId}/campaigns/{campaignId}/coupons/{couponId}"
tags: ["Coupons"]
---

# Update coupon

`PUT /v1/applications/{applicationId}/campaigns/{campaignId}/coupons/{couponId}`

## Request

- Base URL: `https://yourbaseurl.talon.one`
- URL: `https://yourbaseurl.talon.one/v1/applications/{applicationId}/campaigns/{campaignId}/coupons/{couponId}`
- Auth: one of:
  - API key in header `Authorization`
  - API key in header `Authorization`
- TypeScript: <https://skmtc.dev/talon/apis/management-api/docs/v1/applications/:applicationId/campaigns/:campaignId/coupons/:couponId/put.ts> (a function with typed inputs; its response is checked against the schema)

> [!note] Management API endpoints are **not** meant to be used in real-time integrations that directly serve your end users. Rate limit: 3 requests per second.

Update the specified coupon.

> [!note]
> With this `PUT` endpoint, if you do not explicitly set a value for the `startDate`, `expiryDate`,
> and `recipientIntegrationId` properties in your request, it is automatically set to `null`.

## Path parameters

- `applicationId` integer, required
- `campaignId` integer, required
- `couponId` string, required

## Request body

- UpdateCoupon
  - `usageLimit` integer: The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply.
  - `discountLimit` number: The total discount value that the code can give. Typically used to represent a gift card value.
  - `reservationLimit` integer: The number of reservations that can be made with this coupon code.
  - `startDate` string, date-time: Timestamp at which point the coupon becomes valid.
  - `expiryDate` string, date-time: Expiration date of the coupon. Coupon never expires if this is omitted.
  - `limits` LimitConfig[]: Limits configuration for a coupon. These limits will override the limits set from the campaign. **Note:** Only usable when creating a single coupon which is not tied to a specific recipient. Only per-profile limits are allowed to be configured.
    - `action` string, required: The limitable action to which this limit applies. For example: - `setDiscount` - `setDiscountEffect` - `redeemCoupon` - `createCoupon`
    - `limit` number, required: The value to set for the limit.
    - `period` 'daily' | 'weekly' | 'monthly' | 'yearly': The period on which the budget limit recurs.
    - `entities` string[], required: The entity that this limit applies to.
  - `recipientIntegrationId` string: The integration ID for this coupon's beneficiary's profile.
  - `attributes` object: Arbitrary properties associated with this item.
  - `isReservationMandatory` boolean: An indication of whether the code can be redeemed only if it has been reserved first.
  - `implicitlyReserved` boolean: An indication of whether the coupon is implicitly reserved for all customers.

## Response `200`

OK

- Coupon
  - `id` integer, required: The internal ID of the coupon.
  - `created` string, date-time, required: The time the coupon was created.
  - `campaignId` integer, required: The ID of the campaign that owns this entity.
  - `value` string, required: The coupon code.
  - `usageLimit` integer, required: The number of times the coupon code can be redeemed. `0` means unlimited redemptions but any campaign usage limits will still apply.
  - `discountLimit` number: The total discount value that the code can give. Typically used to represent a gift card value.
  - `reservationLimit` integer: The number of reservations that can be made with this coupon code.
  - `startDate` string, date-time: Timestamp at which point the coupon becomes valid.
  - `expiryDate` string, date-time: Expiration date of the coupon. Coupon never expires if this is omitted.
  - `limits` LimitConfig[]: Limits configuration for a coupon. These limits will override the limits set from the campaign. **Note:** Only usable when creating a single coupon which is not tied to a specific recipient. Only per-profile limits are allowed to be configured.
    - `action` string, required: The limitable action to which this limit applies. For example: - `setDiscount` - `setDiscountEffect` - `redeemCoupon` - `createCoupon`
    - `limit` number, required: The value to set for the limit.
    - `period` 'daily' | 'weekly' | 'monthly' | 'yearly': The period on which the budget limit recurs.
    - `entities` string[], required: The entity that this limit applies to.
  - `usageCounter` integer, required: The number of times the coupon has been successfully redeemed.
  - `discountCounter` number: The amount of discounts given on rules redeeming this coupon. Only usable if a coupon discount budget was set for this coupon.
  - `discountRemainder` number: The remaining discount this coupon can give.
  - `reservationCounter` number: The number of times this coupon has been reserved.
  - `attributes` object: Custom attributes associated with this coupon.
  - `referralId` integer: The integration ID of the referring customer (if any) for whom this coupon was created as an effect.
  - `recipientIntegrationId` string: The Integration ID of the customer that is allowed to redeem this coupon.
  - `importId` integer: The ID of the Import which created this coupon.
  - `reservation` boolean: Defines the reservation type: - `true`: The coupon can be reserved for multiple customers. - `false`: The coupon can be reserved only for one customer. It is a personal code.
  - `batchId` string: The id of the batch the coupon belongs to.
  - `isReservationMandatory` boolean: An indication of whether the code can be redeemed only if it has been reserved first.
  - `implicitlyReserved` boolean: An indication of whether the coupon is implicitly reserved for all customers.

---

[API](https://skmtc.dev/talon/apis/management-api.md) - [All operations](https://skmtc.dev/talon/apis/management-api/llms.txt) - [OpenAPI document](https://skmtc.dev/talon/apis/management-api/revisions/7ef1b9504c3a?raw)
