curl --request POST \
--url {protocol}://{host}/v2/loyalties/tier-structures/{tierStructureId}/draft \
--header 'Authorization: Bearer <token>' \
--header 'X-App-Id: <api-key>' \
--header 'X-App-Token: <api-key>'{
"id": "<string>",
"name": "<string>",
"expiration": {
"fixed_duration": {
"period": {
"value": 123
}
},
"calendar_expiration": {
"calendar_dates": [
{
"day": 16,
"month": 6
}
]
},
"sliding_expiration": {
"earning_activity": true,
"spending_activity": true,
"custom_activity": true,
"custom_activity_types": [
"<string>"
],
"period": {
"value": 123
}
}
},
"downgrade": {
"grace_period": {
"value": 123,
"round_up": true
}
},
"metadata": {},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"object": "<string>",
"point_balance": {
"card_definition_id": "<string>"
},
"point_earned": {
"card_definition_id": "<string>",
"period": {
"value": 123
}
}
}{
"code": 123,
"key": "<string>",
"message": "<string>",
"details": "<string>",
"request_id": "<string>"
}{
"code": 123,
"key": "<string>",
"message": "<string>",
"details": "<string>",
"request_id": "<string>"
}{
"code": 123,
"key": "<string>",
"message": "<string>",
"details": "<string>",
"request_id": "<string>"
}{
"code": 123,
"key": "<string>",
"message": "<string>",
"details": "<string>",
"request_id": "<string>"
}Move tier structure to draft
⚠️ BETA endpoint
This is a work-in-progress documentation of a BETA endpoint. The parameters, fields, request and response bodies, and other data may subject to change. If you want to share feedback or improvements, contact Voucherify support or your Technical Account Manager.
Moves the tier structure back to the DRAFT status. Allowed state transition:
ACTIVE -> DRAFT. No request body.
A valid request URL is required to generate request examples{
"id": "<string>",
"name": "<string>",
"expiration": {
"fixed_duration": {
"period": {
"value": 123
}
},
"calendar_expiration": {
"calendar_dates": [
{
"day": 16,
"month": 6
}
]
},
"sliding_expiration": {
"earning_activity": true,
"spending_activity": true,
"custom_activity": true,
"custom_activity_types": [
"<string>"
],
"period": {
"value": 123
}
}
},
"downgrade": {
"grace_period": {
"value": 123,
"round_up": true
}
},
"metadata": {},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"object": "<string>",
"point_balance": {
"card_definition_id": "<string>"
},
"point_earned": {
"card_definition_id": "<string>",
"period": {
"value": 123
}
}
}{
"code": 123,
"key": "<string>",
"message": "<string>",
"details": "<string>",
"request_id": "<string>"
}{
"code": 123,
"key": "<string>",
"message": "<string>",
"details": "<string>",
"request_id": "<string>"
}{
"code": 123,
"key": "<string>",
"message": "<string>",
"details": "<string>",
"request_id": "<string>"
}{
"code": 123,
"key": "<string>",
"message": "<string>",
"details": "<string>",
"request_id": "<string>"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Unique tier structure identifier.
^lts_[a-f0-9]+$Response
The drafted tier structure.
Tier structure resource.
Unique tier structure identifier.
^lts_[a-f0-9]+$Display name of the tier structure.
Tier qualification tracking model.
POINT_BALANCE, POINT_EARNED Tier membership expiration settings.
Show child attributes
Show child attributes
Downgrade behavior applied when tier membership expires.
Show child attributes
Show child attributes
Free-form key/value object holding custom attributes. Defaults to {}.
Current lifecycle status of the tier structure.
DRAFT, ACTIVE, INACTIVE, DELETED Creation timestamp (ISO 8601).
Last update timestamp (ISO 8601), or null if never updated.
Object type discriminator. Always tier_structure.
"tier_structure"Point balance tracking settings. Present only when type is POINT_BALANCE;
omitted otherwise.
Show child attributes
Show child attributes
Points earned tracking settings. Present only when type is POINT_EARNED;
omitted otherwise.
Show child attributes
Show child attributes
Was this page helpful?

