Skip to main content

Create refund

Use batchCreateRefund to create refunds.

The call is asynchronous, and the query for jobStatus should be used to check the result of the refund.
Payments, gift cards, and store credit will be adjusted as necessary when processing refunds

Request:

mutation BatchCreateRefund {
batchCreateRefund(input: {
externalReference: "EXT-123",
fees: [
{
amount: 0,
type: DELIVERY
}
],
orderId: 3123789,
reasonId: 1,
rows: [
{
amount: 2,
orderRowId: 112211,
quantity: null
}
]
}
) {
id
status
}
}

Response:

{
"data": {
"batchCreateRefund": {
"id": 495,
"status": "waiting"
}
}
}

Check status of your job

Request:

query status {
jobStatus(id: 495) {
id
status
}
}

Response:

{
"data": {
"jobStatus": {
"id": 495,
"status": "completed"
}
}
}