Developers
API referenceBusiness sign in

Returns

Cancel a return before drop-off

POST/returns/{returnId}/cancel

Scope returns.writeLIVE keys only

Before drop-off only. A wallet charge is given back and an invoice reservation released. A return the customer already paid for is cancelled by Qoene support (409 RETURN_PAID_BY_CUSTOMER).

Request

Path parameters

Path parameters
NameInTypeDescription
returnIdRequiredpathstringPattern ^(?:QD-RET-[A-F0-9]{24}|QDRET[A-Z0-9]{3,31})$

Body ReturnDecisionRequest

Request body
FieldTypeDescription
reasonRequiredstring5–500 characters, shown to the customer.5–500 characters

Response

Success responses
StatusMeaning
200Cancelled

The body is { "status": "success", "data": … }. Fields of data (ReturnResult):

Response data
FieldTypeDescription
returnRequiredReturnAn e-commerce return: a reverse parcel linked to the original. The customer's phone and the drop-off code are never returned.

Errors

Errors use the error envelope { "status": "error", "message", "code"?, "details"? }.

Error responses
StatusWhen
400The request is not valid. A field is missing or invalid, or the Idempotency-Key header is missing or malformed.
401Missing, invalid, expired or revoked API key. The API key is missing, invalid, expired or revoked.
403The key lacks the scope, or the operation needs a LIVE key. The key lacks the scope, or this call needs a LIVE key (LIVE_KEY_REQUIRED), or the Business owner is not verified (SENDER_VERIFICATION_REQUIRED).
404Not found for this Business and environment. IDs from another Business or environment are always 404. Not found for this Business and environment. IDs from another Business or the other environment are always 404.
409Idempotency key reused with another body, or the resource changed state. The idempotency key was used with a different body, a reference is already taken, or the resource changed state.
429Too many requests. See the RateLimit headers. Too many requests. Wait for Retry-After, then retry with the same idempotency key.