Skip to main content

rejectRMA

Requires at least one of the permissions purchase:debit_note:approve or sales:credit_note:approve.

Rejects a return request with a reason. A completed or cancelled return cannot be rejected, a return that already has a live credit note is refused, and so is a purchase return that has already posted stock or a debit note. Needs the approve permission of the return's direction.

Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.

Example:

mutation RejectRMA($reason: String!, $returnId: String!) {
rejectRMA(reason: $reason, returnId: $returnId) {
id
returnNumber
rmaNumber
status
}
}

Variables:

{
"reason": "string",
"returnId": "string"
}

Response:

{
"data": {
"rejectRMA": {
"id": "string",
"returnNumber": "string",
"rmaNumber": "string",
"status": "string"
}
}
}
rejectRMA(
reason: String!
returnId: String!
): ReturnResponse!

Arguments​

rejectRMA.reason ● String! non-null scalar​

Why the return is rejected.

rejectRMA.returnId ● String! non-null scalar​

The ID of the return.

Type​

ReturnResponse object​

A return created through the RMA flow.