| Send | Permission | Community scope |
|---|---|---|
Authorization: Bearer <apiKey> | updateRedemptionTransactionStatus | Community scope is derived from the key; do not send a community identifier. |
| Scenario | Apidog example |
|---|---|
| Move to Refunded and credit coins once | refund |
| Change status without a coin refund | statusOnly |
{
"transactionId": "ORD202607220001",
"statusID": "sts_refunded",
"refundCoins": true,
"remark": "Refunded by API hardening proof"
}code = REDEMPTION_TRANSACTION_REFUNDED{
"status": "success",
"code": "REDEMPTION_TRANSACTION_REFUNDED",
"message": "Update redemption order status or refund successfully",
"data": {
"transactionId": "ORD202607220001",
"statusID": "sts_refunded",
"status": {
"_id": "sts_refunded",
"name": "Refunded",
"category": "refunded",
"color": "#EB5757"
},
"refund": {
"requested": true,
"credited": 100,
"alreadyRefunded": false
}
}
}code, never message text.| HTTP | Machine code | What the caller should do | Retry? |
|---|---|---|---|
| 400 | REDEMPTION_REQUEST_INVALID | Select a refunded-category status or set refundCoins=false. | No, fix first |
| 401 | AUTHENTICATION_REQUIRED | Add the Authorization header. | No, fix first |
| 401 | AUTHENTICATION_FAILED | Authentication could not be completed. | Retry once |
| 403 | API_KEY_PERMISSION_DENIED | Request the updateRedemptionTransactionStatus permission; no resource data is returned. | No, fix first |
| 404 | REDEMPTION_TRANSACTION_NOT_FOUND | Refresh transactionId. | After refreshing the ID |
| 500 | INTERNAL_ERROR | Retry with exponential backoff and the same request context, then escalate. | Yes, with backoff |
curl --location --request PUT 'https://api.returning.ai/v1/redemption-transactions/status' \
--header 'Content-Type: application/json' \
--data '{
"transactionId": "ORD202507013831",
"statusID": "695dcc370ab8622381f27918",
"refundCoins": false
}'{
"status": "success",
"message": "Transaction status updated successfully",
"data": {
"transactionId": "ORD20260102ffc6",
"statusId": "695e2f8b3358520a2ecf86e4",
"status": {
"_id": "695e2f8b3358520a2ecf86e4",
"name": "Shipping",
"category": "incomplete",
"color": "#3EA1FD"
}
}
}