Refund / Cancel an Order
When a customer returns items or cancels an order, use the Refund API to reverse the transaction and restore points to the customer’s balance.What This Is
This use case explains how to process refunds or cancellations for completed orders, ensuring that:- Points redeemed during the original order are restored
- Points earned from the original order are deducted
- The customer’s balance is accurately updated
Why It Matters
- Maintains accurate customer point balances
- Prevents point manipulation or fraud
- Ensures fair treatment of customers during returns
- Required for proper financial reconciliation
How to Implement It
Use the Refund Transaction API to reverse a completed order:Required Fields
- customerId: The unique identifier for the customer
- refundTransactionId: A unique identifier for this refund transaction
- reverseTransactionId: The original order ID that is being refunded
- transactionTime: The timestamp when the refund occurred
- refundAmount: The amount being refunded to the customer
What Gameball Does Behind the Scenes
- Reverses the original order transaction
- Restores any points that were redeemed during the original order
- Deducts any points that were earned from the original order
- Updates the customer’s balance accordingly
- Records the refund in the transaction history
Key Takeaways for Developers
- Always use a unique
refundTransactionIdfor each refund - The
reverseTransactionIdmust match an existing order ID - Refunds should be processed as soon as the return is confirmed
- Partial refunds are supported—adjust the
refundAmountaccordingly - The refund amount should match the original order’s
totalPaidvalue for full refunds
Related Resources
Refund Transaction API
Complete API reference for refund transactions