curl -X PUT \
/coupons/{id} \
--header "Content-Type: application/json" \
--header "Authorization: Bearer <token>" \
--data '{
"code": "10OFF",
"name": "10% off",
"percentage": "10",
"fixedAmount": [],
"frequencyInterval": "3",
"maxRedemptionsPerCustomer": "null",
"maxRedemptions": "null",
"expiresAt": "null",
"limitedToPlans": [
"https:\/\/example.com\/"
],
"excludedFromPlans": [
"https:\/\/example.com\/"
],
"limitedToProducts": [
"https:\/\/example.com\/"
],
"excludedFromProducts": [
"https:\/\/example.com\/"
],
"isEnabled": "1"
}'
{
"id": "<string>",
"code": "10OFF",
"name": "10% off",
"type": "<any>",
"percentage": 10,
"fixedAmount": {},
"frequency": "<any>",
"frequencyInterval": 3,
"maxRedemptionsPerCustomer": "null",
"maxRedemptions": "null",
"expiresAt": "null",
"limitedToPlans": [
{
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"family": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"code": "basic-m2023",
"originProduct": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"productFamilies": [
{
"id": "ad8b3b9e-5b0a-4e1a-8b0a-4e1a8b0a4e1a",
"name": "Team Packages",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
}
],
"name": "Basic",
"description": "For small teams.",
"internalName": "Basic (Weekly)",
"number": "M-1234",
"type": "product",
"measurement": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"unit": {
"id": {},
"name": "Stück",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"code": "users",
"description": "The number of users.",
"aggregationType": "<any>",
"fairBilling": true,
"type": "<any>"
},
"invoiceVisibility": "always",
"costCentre": {
"id": "ad8f1c9c-4f0a-4e1a-8b1a-9c4d9c4d9c4d",
"name": "Cost Centre",
"code": "CC",
"type": "KOST1",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"taxGroup": {
"id": "00000000-0000-0000-0000-000000000000",
"internalDescription": "19%",
"reverseChargeType": "REVERSE_CHARGE",
"type": "standard"
},
"isArchived": true,
"customFields": {
"field1": "value1",
"field2": "value2"
}
},
"allowCheckout": true,
"status": "<any>",
"createdAt": "2023-11-07T05:31:56Z",
"name": "<string>",
"description": "<string>"
}
],
"excludedFromPlans": [
{
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"family": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"code": "basic-m2023",
"originProduct": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"productFamilies": [
{
"id": "ad8b3b9e-5b0a-4e1a-8b0a-4e1a8b0a4e1a",
"name": "Team Packages",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
}
],
"name": "Basic",
"description": "For small teams.",
"internalName": "Basic (Weekly)",
"number": "M-1234",
"type": "product",
"measurement": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"unit": {
"id": {},
"name": "Stück",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"code": "users",
"description": "The number of users.",
"aggregationType": "<any>",
"fairBilling": true,
"type": "<any>"
},
"invoiceVisibility": "always",
"costCentre": {
"id": "ad8f1c9c-4f0a-4e1a-8b1a-9c4d9c4d9c4d",
"name": "Cost Centre",
"code": "CC",
"type": "KOST1",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"taxGroup": {
"id": "00000000-0000-0000-0000-000000000000",
"internalDescription": "19%",
"reverseChargeType": "REVERSE_CHARGE",
"type": "standard"
},
"isArchived": true,
"customFields": {
"field1": "value1",
"field2": "value2"
}
},
"allowCheckout": true,
"status": "<any>",
"createdAt": "2023-11-07T05:31:56Z",
"name": "<string>",
"description": "<string>"
}
],
"limitedToProducts": [
{
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"productFamilies": [
{
"id": "ad8b3b9e-5b0a-4e1a-8b0a-4e1a8b0a4e1a",
"name": "Team Packages",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
}
],
"name": "Basic",
"description": "For small teams.",
"internalName": "Basic (Weekly)",
"number": "M-1234",
"type": "product",
"measurement": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"unit": {
"id": {},
"name": "Stück",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"code": "users",
"description": "The number of users.",
"aggregationType": "<any>",
"fairBilling": true,
"type": "<any>"
},
"invoiceVisibility": "always",
"costCentre": {
"id": "ad8f1c9c-4f0a-4e1a-8b1a-9c4d9c4d9c4d",
"name": "Cost Centre",
"code": "CC",
"type": "KOST1",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"taxGroup": {
"id": "00000000-0000-0000-0000-000000000000",
"internalDescription": "19%",
"reverseChargeType": "REVERSE_CHARGE",
"type": "standard"
},
"isArchived": true,
"customFields": {
"field1": "value1",
"field2": "value2"
}
}
],
"excludedFromProducts": [
{
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"productFamilies": [
{
"id": "ad8b3b9e-5b0a-4e1a-8b0a-4e1a8b0a4e1a",
"name": "Team Packages",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
}
],
"name": "Basic",
"description": "For small teams.",
"internalName": "Basic (Weekly)",
"number": "M-1234",
"type": "product",
"measurement": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"unit": {
"id": {},
"name": "Stück",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"code": "users",
"description": "The number of users.",
"aggregationType": "<any>",
"fairBilling": true,
"type": "<any>"
},
"invoiceVisibility": "always",
"costCentre": {
"id": "ad8f1c9c-4f0a-4e1a-8b1a-9c4d9c4d9c4d",
"name": "Cost Centre",
"code": "CC",
"type": "KOST1",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"taxGroup": {
"id": "00000000-0000-0000-0000-000000000000",
"internalDescription": "19%",
"reverseChargeType": "REVERSE_CHARGE",
"type": "standard"
},
"isArchived": true,
"customFields": {
"field1": "value1",
"field2": "value2"
}
}
],
"isEnabled": true,
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00",
"reedemptions": true
}
Update a coupon.
Required permissions:coupon:write
curl -X PUT \
/coupons/{id} \
--header "Content-Type: application/json" \
--header "Authorization: Bearer <token>" \
--data '{
"code": "10OFF",
"name": "10% off",
"percentage": "10",
"fixedAmount": [],
"frequencyInterval": "3",
"maxRedemptionsPerCustomer": "null",
"maxRedemptions": "null",
"expiresAt": "null",
"limitedToPlans": [
"https:\/\/example.com\/"
],
"excludedFromPlans": [
"https:\/\/example.com\/"
],
"limitedToProducts": [
"https:\/\/example.com\/"
],
"excludedFromProducts": [
"https:\/\/example.com\/"
],
"isEnabled": "1"
}'
{
"id": "<string>",
"code": "10OFF",
"name": "10% off",
"type": "<any>",
"percentage": 10,
"fixedAmount": {},
"frequency": "<any>",
"frequencyInterval": 3,
"maxRedemptionsPerCustomer": "null",
"maxRedemptions": "null",
"expiresAt": "null",
"limitedToPlans": [
{
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"family": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"code": "basic-m2023",
"originProduct": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"productFamilies": [
{
"id": "ad8b3b9e-5b0a-4e1a-8b0a-4e1a8b0a4e1a",
"name": "Team Packages",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
}
],
"name": "Basic",
"description": "For small teams.",
"internalName": "Basic (Weekly)",
"number": "M-1234",
"type": "product",
"measurement": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"unit": {
"id": {},
"name": "Stück",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"code": "users",
"description": "The number of users.",
"aggregationType": "<any>",
"fairBilling": true,
"type": "<any>"
},
"invoiceVisibility": "always",
"costCentre": {
"id": "ad8f1c9c-4f0a-4e1a-8b1a-9c4d9c4d9c4d",
"name": "Cost Centre",
"code": "CC",
"type": "KOST1",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"taxGroup": {
"id": "00000000-0000-0000-0000-000000000000",
"internalDescription": "19%",
"reverseChargeType": "REVERSE_CHARGE",
"type": "standard"
},
"isArchived": true,
"customFields": {
"field1": "value1",
"field2": "value2"
}
},
"allowCheckout": true,
"status": "<any>",
"createdAt": "2023-11-07T05:31:56Z",
"name": "<string>",
"description": "<string>"
}
],
"excludedFromPlans": [
{
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"family": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"code": "basic-m2023",
"originProduct": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"productFamilies": [
{
"id": "ad8b3b9e-5b0a-4e1a-8b0a-4e1a8b0a4e1a",
"name": "Team Packages",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
}
],
"name": "Basic",
"description": "For small teams.",
"internalName": "Basic (Weekly)",
"number": "M-1234",
"type": "product",
"measurement": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"unit": {
"id": {},
"name": "Stück",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"code": "users",
"description": "The number of users.",
"aggregationType": "<any>",
"fairBilling": true,
"type": "<any>"
},
"invoiceVisibility": "always",
"costCentre": {
"id": "ad8f1c9c-4f0a-4e1a-8b1a-9c4d9c4d9c4d",
"name": "Cost Centre",
"code": "CC",
"type": "KOST1",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"taxGroup": {
"id": "00000000-0000-0000-0000-000000000000",
"internalDescription": "19%",
"reverseChargeType": "REVERSE_CHARGE",
"type": "standard"
},
"isArchived": true,
"customFields": {
"field1": "value1",
"field2": "value2"
}
},
"allowCheckout": true,
"status": "<any>",
"createdAt": "2023-11-07T05:31:56Z",
"name": "<string>",
"description": "<string>"
}
],
"limitedToProducts": [
{
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"productFamilies": [
{
"id": "ad8b3b9e-5b0a-4e1a-8b0a-4e1a8b0a4e1a",
"name": "Team Packages",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
}
],
"name": "Basic",
"description": "For small teams.",
"internalName": "Basic (Weekly)",
"number": "M-1234",
"type": "product",
"measurement": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"unit": {
"id": {},
"name": "Stück",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"code": "users",
"description": "The number of users.",
"aggregationType": "<any>",
"fairBilling": true,
"type": "<any>"
},
"invoiceVisibility": "always",
"costCentre": {
"id": "ad8f1c9c-4f0a-4e1a-8b1a-9c4d9c4d9c4d",
"name": "Cost Centre",
"code": "CC",
"type": "KOST1",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"taxGroup": {
"id": "00000000-0000-0000-0000-000000000000",
"internalDescription": "19%",
"reverseChargeType": "REVERSE_CHARGE",
"type": "standard"
},
"isArchived": true,
"customFields": {
"field1": "value1",
"field2": "value2"
}
}
],
"excludedFromProducts": [
{
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"productFamilies": [
{
"id": "ad8b3b9e-5b0a-4e1a-8b0a-4e1a8b0a4e1a",
"name": "Team Packages",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
}
],
"name": "Basic",
"description": "For small teams.",
"internalName": "Basic (Weekly)",
"number": "M-1234",
"type": "product",
"measurement": {
"id": "ad8f1c2c-3b1c-4b0a-8b0a-0b0b0b0b0b0b",
"unit": {
"id": {},
"name": "Stück",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"code": "users",
"description": "The number of users.",
"aggregationType": "<any>",
"fairBilling": true,
"type": "<any>"
},
"invoiceVisibility": "always",
"costCentre": {
"id": "ad8f1c9c-4f0a-4e1a-8b1a-9c4d9c4d9c4d",
"name": "Cost Centre",
"code": "CC",
"type": "KOST1",
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00"
},
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"taxGroup": {
"id": "00000000-0000-0000-0000-000000000000",
"internalDescription": "19%",
"reverseChargeType": "REVERSE_CHARGE",
"type": "standard"
},
"isArchived": true,
"customFields": {
"field1": "value1",
"field2": "value2"
}
}
],
"isEnabled": true,
"createdAt": "2021-01-01T00:00:00+00:00",
"updatedAt": "2021-01-01T00:00:00+00:00",
"reedemptions": true
}
Value for the Authorization header parameter.
Coupon identifier
The updated Coupon resource
Coupon resource updated
Was this page helpful?