v1

latestOpenAPI 3.0.32026-07-24153644.3 KB
RewardsService

Confirm the utilization of one or more rewards for a specified customer.

This endpoint is designed to validate the use of the cashback that was previously locked. Upon confirmation, the cashback is recorded as used and becomes unavailable for rollback.

To utilize this endpoint, you need to provide the lock_token generated during the locking process, along with the cashback value used and the unique identifier generated for the purchase. The purchase identifier must match the one intended for submission to Dito.

Optionally, you can use custom data to send data that will be used in the segmentation of the cashack consumption event.

Certain restrictions apply when committing. For instance, the cashback balance used must not be negative, the reward must not be expired, the lock must not have been generated more than 24 hours ago, and other similar criteria.

post/api/v1alpha1/rewards:commit

Headers

Brandstring required

The brand label provided by us.

Request body

lockIdstring

Deprecated.

lockTokenstring required

Lock identifier generated for rewards.

valueUsedstring required

Cashback value used on the order.

orderIdstring required

Order ID.

customDataobject

Custom data, a map of string to string value.

Example request

{
  "lockToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjYXNoYmFja192YWx1ZV9pbl9jZW50cyI6MTAwLCJjdXN0b21lcl9pZCI6ImN1c3RvbWVySWQiLCJleHAiOjE3MDU0MjQ5MTEsImxvY2tfaWQiOiIxMjMiLCJvcmRlcl92YWx1ZV9pbl9jZW50cyI6NTAwMDAwfQ.aNRtKU5S0FR2_JhZzDvc4DdqWKND5wriRTNX_aC9xzs",
  "orderId": "ORDER123121"
}

Response

A successful response.

object required