Skip to main content
POST
Validate a Coupon Code

Authorizations

Authorization
string
header
required

Basic authentication header of the form Basic <encoded-value>, where <encoded-value> is the base64-encoded string username:password.

Path Parameters

campaign_code
string
required

The coupon code to validate

Query Parameters

activate
boolean
default:false

When enabled, (1) this parameter activates the coupon code as part of same call.

Response

JSON A full CampaignCodes object.

object
string
required

Value is "CampaignCode"

id
string
required

Primary redemption string (either a Promotion code or a Coupon code) used for redeeming CampaignCoode

vid
string

A Globally Unique Identifier (GUID) for this object. Assigned by CashBox

Maximum string length: 128
code_aliases
string

An array of alternative redemption codes specified on a Promotion Campaign

type
enum<string>

Type of Campaign associated with this CampaignCode

Available options:
Promotion,
Campaign
campaign
object

Campaign associated with the CampaignCode

sequence
integer

Unique sequence number for the CampaignCode in the parent code set.

state
enum<string>

State of the CampaignCode

Available options:
Not Yet Activated,
Activated,
Redeemed,
Expired,
Marked Used,
Retrieved,
Invalidated,
Initialized
last_chars
string

Last characters (typically 4) of the CampaignCode

redemption_count
integer

Number of times the (Coupon) CampaignCode has been redeemed