---
title: "update promo code"
method: PATCH
path: "/promo_codes/{uuid}"
tags: ["Promo Codes"]
---

# update promo code

`PATCH /promo_codes/{uuid}`

Updates a specific promo code
#### For custom components:
`RaiselyComponents.api.one('promo_codes', '{uuid}').patch(data = {}, params = {}, headers = {}) => Promise<{result}>`

 :fa-gears: See [Restie Response Data](https://github.com/raisely/restie#reading-and-handling-responses) for a more detailed overview of responses through the client wrapper

## Path parameters

- `uuid` string, required

## Headers

- `Authorization` string

## Request body

- object
  - `data` UpdatePromoCode
    - `code` string — The user-facing promo code Example: `10OFF`
    - `discountAmount` integer — The amount or percentage off the purchase, used in conjunction with discountType Examples: `10`, `1500`
    - `discountType` 'PERCENTAGE' | 'FIXED' — Either FIXED or PERCENTAGE Examples: `PERCENTAGE`, `FIXED`
    - `endDate` string — ISO8601 timestamp for when this promo code stops being available Example: `2022-12-01T00:00:00.000Z`
    - `maxUses` integer — The number of times this promo code can been claimed Example: `100`
    - `startDate` string — ISO8601 timestamp for when this promo code starts being available Example: `2022-12-01T00:00:00.000Z`
    - `uses` integer — The number of times this promo code has been claimed Example: `50`

## Response `200`

The resulting Promo Code record

- object
  - `data` PromoCode
    - `code` string, required — `public` The user-facing promo code
    - `discountAmount` integer, required — `public` The amount or percentage off the purchase, used in conjunction with discountType
    - `discountType` 'PERCENTAGE' | 'FIXED', required — `public` Either FIXED or PERCENTAGE
    - `endDate` string — `public` ISO8601 timestamp for when this promo code stops being available
    - `maxUses` integer — `public` The number of times this promo code can been claimed
    - `startDate` string — `public` ISO8601 timestamp for when this promo code starts being available
    - `uses` integer — `public` The number of times this promo code has been claimed
    - `uuid` string — `public` Unique identifier for the record

## Other responses

- `401` — Authorization credentials were missing or invalid
- `403` — The user is authenticated, but is not allowed to perform the requested operation
- `410` — The requested record no longer exists, or that API has been deprecated
- `429` — You have made too many requests to the given endpoint, please try again later
- `500` — An unexpected error has occurred with Raisely. If the error persists you can contact support@raisely.com

---

[API](https://skmtc.dev/raisely/apis/raisely-api.md) · [All operations](https://skmtc.dev/raisely/apis/raisely-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/raisely/raisely-api/revisions/d7f8dd294cb0/schema)
