Promotion codes are how you can make your coupon discounts available to your customers.
Promotion codes are a customer-redeemable code for a coupon.
The promotionCode
object makes it convenient to issue codes for your customers to be able to use your coupons and get discounts. They can be used to create multiple codes for a single coupon.
The promotion code object
Let's take a look at a full promotionCode
object:
{
"id": "promotionCode_1641f4a72e864d9caf0cedc66bbdcaaf",
"code": "TAKE50",
"active": true,
"coupon": "coupon_0744fb224cc54e14b496511b941f916b",
"customer": "customer_adda9b08993a40dcb9251eb6b0bad739",
"expiresAt": "2024-05-12T23:59:59.000Z",
"maxRedemptions": 5,
"timesRedeemed": "paymentLink_c302781a01744287b4583f9951ccb26b",
"updated": "2021-08-01T00:00:00.000Z",
"created": "2021-08-01T00:00:00.000Z"
}
id
: string
Unique identifier for the object. Auto-generated by Sphere upon creation.
code
: string
The code that your customers will use at checkout.
active
: boolean
Denotes whether the promotion code will successfully apply at checkout.
coupon
: string
The id
of the coupon
object that this promotion code is tied to.
customer
: string
The id
of the customer
object that this promotion code can be used by.
- Useful if you would like to limit usage of the promotion code to a specific customer.
expiresAt
: string
datetime for when the promotion code will no longer be usable.
- Once the promotion code has expired, its
active
field will be set to false.
maxRedemptions
: number
Defines the number of times that this promotion can be used.
timesRedeemed
: number
Identifies the number of times that this promotion code has been used.
updated
: string
datetime for when the promotion code was last updated.
created
:string
datetime for when the promotion code was created.
Now that we've examined the promotionCode
object in full, the next step is to create a promotion code!
If you would like to learn more check out the coupon tutorialor no-code coupon setup.