post https://a.klaviyo.com/api/coupon-codes
Synchronously creates a coupon code for the given coupon.
Rate limits:
Burst: 350/s
Steady: 3500/m
Scopes:
coupon-codes:write
Responses
Synchronously creates a coupon code for the given coupon.
Rate limits:
Burst: 350/s
Steady: 3500/m
Scopes:
coupon-codes:write
xxxxxxxxxx
20curl --request POST \
--url https://a.klaviyo.com/api/coupon-codes \
--header 'Authorization: Klaviyo-API-Key your-private-api-key' \
--header 'accept: application/vnd.api+json' \
--header 'content-type: application/vnd.api+json' \
--header 'revision: 2025-01-15' \
--data '
{
"data": {
"type": "coupon-code",
"relationships": {
"coupon": {
"data": {
"type": "coupon"
}
}
}
}
}
'
xxxxxxxxxx
36}
{
"data": {
"type": "coupon-code",
"id": "10OFF-ASD325FHK324UJDOI2M3JNES99",
"attributes": {
"unique_code": "ASD325FHK324UJDOI2M3JNES99",
"expires_at": "2023-01-01T00:00:00Z",
"status": "UNASSIGNED"
},
"relationships": {
"coupon": {
"data": {
"type": "coupon",
"id": "10OFF"
},
"links": {
"self": "string",
"related": "string"
}
},
"profile": {
"data": {