Visitar URL original
Update Coupon Code | Klaviyo API ReferenceSkip to content

This page is available as Markdown at https://developers.klaviyo.com/en/reference/update_coupon_code.md. Its OpenAPI document is at https://raw.githubusercontent.com/klaviyo/openapi/2026-10-15/openapi/stable/apis/update_coupon_code.json. An index of every page is at https://developers.klaviyo.com/llms.txt.

KlaviyoKlaviyoDevelopers

PATCHhttps://a.klaviyo.com/api/coupon-codes/{id}

Updates a coupon code specified by the given identifier synchronously. We allow updating the 'status' and 'expires_at' of coupon codes.

Revision header
revision: 2026-10-15required
Scopes
coupon-codes:write
Rate limits
Burst: 350/sSteady: 3500/m

Path parameters

  • id#stringrequired

    The id of a coupon code is a combination of its unique code and the id of the coupon it is associated with.

    Example: 10OFF-ASD325FHK324UJDOI2M3JNES99

Query parameters

  • fields[coupon-code]#string[]

    For more information please visit API overview

    Allowed values:
    • expires_at
    • id
    • status
    • unique_code

Headers

  • revision#stringrequired

    API endpoint revision (format: YYYY-MM-DD[.suffix])

    2026-10-15

Request body

Content type: application/vnd.api+jsonrequired

  • data#objectrequired
    Show 3 fields
    • type#stringrequired
      Allowed values:
      • coupon-code
    • id#stringrequired

      The id of a coupon code is a combination of its unique code and the id of the coupon it is associated with.

      Example: 10OFF-ASD325FHK324UJDOI2M3JNES99

    • attributes#objectrequired
      Show 2 fields
      • status#stringnullable

        The API status of our coupon codes.

        Allowed values:
        • ASSIGNED_TO_PROFILE
        • DELETING
        • PROCESSING
        • UNASSIGNED
        • USED
        • VERSION_NOT_ACTIVE
      • expires_at#string<date-time>nullable

        The datetime when this coupon code will expire. If not specified or set to null, it will be automatically set to 1 year.

        Example: 2022-11-08T00:00:00+00:00

Responses

200Success

Content type: application/vnd.api+json

  • data#objectrequired
    Show 5 fields
    • type#stringrequired
      Allowed values:
      • coupon-code
    • id#stringrequired

      The id of a coupon code is a combination of its unique code and the id of the coupon it is associated with.

      Example: 10OFF-ASD325FHK324UJDOI2M3JNES99

    • attributes#objectrequired
      Show 3 fields
      • unique_code#stringnullable

        This is a unique string that will be or is assigned to each customer/profile and is associated with a coupon.

        Example: ASD325FHK324UJDOI2M3JNES99

      • expires_at#string<date-time>nullable

        The datetime when this coupon code will expire. If not specified or set to null, it will be automatically set to 1 year.

        Example: 2022-11-08T00:00:00+00:00

      • status#stringnullable

        The current status of the coupon code.

        Allowed values:
        • ASSIGNED_TO_PROFILE
        • DELETING
        • PROCESSING
        • UNASSIGNED
        • USED
        • VERSION_NOT_ACTIVE

        Example: UNASSIGNED

    • relationships#object
      Show 2 fields
      • coupon#object
        Show 2 fields
        • data#object
          Show 2 fields
          • type#stringrequired
            Allowed values:
            • coupon
          • id#stringrequired

            Example: 10OFF

      • profile#object
        Show 2 fields
        • data#object
          Show 2 fields
          • type#stringrequired
            Allowed values:
            • profile
          • id#stringrequired

            Example: 01GDDKASAP8TKDDA2GRZDSVP4H

  • meta#object

    Response-level metadata

    Show 1 field
    • agent_hints#object

      Optional hints emitted by the API for agent callers

      Show 1 field
      • next_steps#string[]

        Suggested follow-up actions for agents to take after this response

4XXClient Error

Content type: application/vnd.api+json

  • errors#object[]required
    Show 5 fields
    • id#stringrequired
    • code#stringrequired
    • title#stringrequired
    • detail#stringrequired
    • source#object
      Show 2 fields
      • pointer#string
      • parameter#string

5XXServer Error

Content type: application/vnd.api+json

  • errors#object[]required
    Show 5 fields
    • id#stringrequired
    • code#stringrequired
    • title#stringrequired
    • detail#stringrequired
    • source#object
      Show 2 fields
      • pointer#string
      • parameter#string