A valid request URL is required to generate request examples{
"transaction": {
"id": "<string>",
"card_id": "<string>",
"program_id": "<string>",
"member_id": "<string>",
"card_definition_id": "<string>",
"card_type": "INDIVIDUAL",
"details": {
"reason": "<string>",
"rejection": {
"reason": "<string>",
"details": "<string>"
},
"metadata": {},
"points": {
"total": 123,
"expiration_date": "2023-12-25",
"date": "2023-12-25"
},
"bucket": {
"id": "<string>",
"points": {
"total": 123
},
"expiration_date": "2023-12-25"
},
"buckets": [
{
"id": "<string>",
"points": {
"total": 123
},
"expiration_date": "2023-12-25"
}
],
"date": "2023-12-25",
"reward": {
"id": "<string>"
},
"reward_transaction": {
"id": "<string>"
},
"card_transaction": {
"id": "<string>"
},
"purchase": {
"card_transaction": {
"id": "<string>"
},
"reward_transaction": {
"id": "<string>"
}
},
"order": {
"id": "<string>"
},
"order_transaction": {
"id": "<string>"
},
"target_card": {
"id": "<string>"
},
"purchase_transaction": {
"id": "<string>"
}
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"object": "<string>"
},
"message": "<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>"
}{
"code": 123,
"key": "<string>",
"message": "<string>",
"details": "<string>",
"request_id": "<string>"
}{
"code": 123,
"key": "<string>",
"message": "<string>",
"details": "<string>",
"request_id": "<string>"
}Add or subtract card points
⚠️ 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.
Manually adjusts the points balance of the member’s card. A positive points value
creates an ADMIN_CREDIT card transaction (points addition - the added points get
an expiration date calculated from the card definition’s points expiration
settings); a negative value creates an ADMIN_DEBIT card transaction (points
subtraction). When points is 0, no transaction is created and the result status
is NO_CHANGE.
The transaction is created with status PENDING and processed asynchronously.
Both the program and the member must be in ACTIVE status (423 otherwise). Returns
404 when the program, member or card does not exist.
curl --request POST \
--url {protocol}://{host}/v2/loyalties/programs/{programId}/members/{memberId}/cards/{cardId}/points \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'X-App-Id: <api-key>' \
--header 'X-App-Token: <api-key>' \
--data '
{
"points": 0,
"reason": "<string>"
}
'{
"transaction": {
"id": "<string>",
"card_id": "<string>",
"program_id": "<string>",
"member_id": "<string>",
"card_definition_id": "<string>",
"card_type": "INDIVIDUAL",
"details": {
"reason": "<string>",
"rejection": {
"reason": "<string>",
"details": "<string>"
},
"metadata": {},
"points": {
"total": 123,
"expiration_date": "2023-12-25",
"date": "2023-12-25"
},
"bucket": {
"id": "<string>",
"points": {
"total": 123
},
"expiration_date": "2023-12-25"
},
"buckets": [
{
"id": "<string>",
"points": {
"total": 123
},
"expiration_date": "2023-12-25"
}
],
"date": "2023-12-25",
"reward": {
"id": "<string>"
},
"reward_transaction": {
"id": "<string>"
},
"card_transaction": {
"id": "<string>"
},
"purchase": {
"card_transaction": {
"id": "<string>"
},
"reward_transaction": {
"id": "<string>"
}
},
"order": {
"id": "<string>"
},
"order_transaction": {
"id": "<string>"
},
"target_card": {
"id": "<string>"
},
"purchase_transaction": {
"id": "<string>"
}
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"object": "<string>"
},
"message": "<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>"
}{
"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
Loyalty program ID (format lprg_[a-f0-9]+).
^lprg_[a-f0-9]+$Program member ID (format lmbr_[a-f0-9]+).
^lmbr_[a-f0-9]+$Loyalty card ID (format lcrd_[a-f0-9]+).
^lcrd_[a-f0-9]+$Body
Request body for a manual card points adjustment. No additional properties are allowed.
Number of points to adjust. Positive values add points (ADMIN_CREDIT
transaction), negative values subtract points (ADMIN_DEBIT transaction),
zero results in no transaction (NO_CHANGE). Required.
-9007199254740991 <= x <= 9007199254740991Optional reason for the adjustment, stored in the transaction details.
255Response
Result of the points adjustment.
Result of a manual card points adjustment.
The created card transaction (ADMIN_CREDIT or ADMIN_DEBIT), or null when no transaction was created (status NO_CHANGE).
Show child attributes
Show child attributes
TRANSACTION_CREATED when a transaction was created, NO_CHANGE when the requested points amount was zero.
TRANSACTION_CREATED, NO_CHANGE Human-readable result message - "Points addition transaction created", "Points subtraction transaction created" or "Provided amount is zero, transaction was not created".
Was this page helpful?

