Refund an order
curl --request POST \
--url https://api.wava.co/v1/orders/refund/{orderId} \
--header 'Content-Type: application/json' \
--header 'merchant-key: <api-key>' \
--data '
{
"id_external": "order-12345"
}
'const options = {
method: 'POST',
headers: {'merchant-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({id_external: 'order-12345'})
};
fetch('https://api.wava.co/v1/orders/refund/{orderId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.wava.co/v1/orders/refund/{orderId}"
payload = { "id_external": "order-12345" }
headers = {
"merchant-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"result": "Refund processed successfully"
}{
"code": 4011,
"api_code": "INVALID_ORDER_STATUS",
"message": "Order cannot be cancelled in its current status",
"description": "Only pending or processing orders can be cancelled",
"error": true
}{
"code": 4007,
"api_code": "INVALID_MERCHANT_KEY",
"message": "Invalid merchant key",
"description": "The provided merchant key is invalid or expired",
"error": true
}{
"code": 4010,
"api_code": "ORDER_NOT_FOUND",
"message": "Order not found",
"description": "The specified order does not exist or you don't have access to it",
"error": true
}{
"code": 4011,
"api_code": "INVALID_ORDER_STATUS",
"message": "Cannot refund orders older than 96 hours",
"description": "Refunds must be requested within 96 hours of purchase",
"error": true
}{
"code": 7001,
"api_code": "INTERNAL_SERVER_ERROR",
"message": "Internal server error",
"description": "An unexpected error occurred while processing your request",
"error": true
}Orders
Refund an order
Process a full refund for a confirmed order. Refunds must be requested within 96 hours of the original purchase. Partial refunds are not currently supported.
POST
/
orders
/
refund
/
{orderId}
Refund an order
curl --request POST \
--url https://api.wava.co/v1/orders/refund/{orderId} \
--header 'Content-Type: application/json' \
--header 'merchant-key: <api-key>' \
--data '
{
"id_external": "order-12345"
}
'const options = {
method: 'POST',
headers: {'merchant-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({id_external: 'order-12345'})
};
fetch('https://api.wava.co/v1/orders/refund/{orderId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.wava.co/v1/orders/refund/{orderId}"
payload = { "id_external": "order-12345" }
headers = {
"merchant-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"result": "Refund processed successfully"
}{
"code": 4011,
"api_code": "INVALID_ORDER_STATUS",
"message": "Order cannot be cancelled in its current status",
"description": "Only pending or processing orders can be cancelled",
"error": true
}{
"code": 4007,
"api_code": "INVALID_MERCHANT_KEY",
"message": "Invalid merchant key",
"description": "The provided merchant key is invalid or expired",
"error": true
}{
"code": 4010,
"api_code": "ORDER_NOT_FOUND",
"message": "Order not found",
"description": "The specified order does not exist or you don't have access to it",
"error": true
}{
"code": 4011,
"api_code": "INVALID_ORDER_STATUS",
"message": "Cannot refund orders older than 96 hours",
"description": "Refunds must be requested within 96 hours of purchase",
"error": true
}{
"code": 7001,
"api_code": "INTERNAL_SERVER_ERROR",
"message": "Internal server error",
"description": "An unexpected error occurred while processing your request",
"error": true
}Authorizations
Merchant key for store identification. Required for all API requests.
merchant-key: YOUR_MERCHANT_KEY
Path Parameters
Order ID to refund.
Required range:
x >= 1Example:
12345
Body
application/json
External order ID for additional validation.
Example:
"order-12345"
Response
Refund processed successfully
Example:
"Refund processed successfully"