Initiate Refunds

In this example we take you through how to refund using the Seller API

GraphQL How Sellers can work with refunds

What you’ll learn

In this how to we take you through how Sellers can use the GraphQL API to:

  • Initiate a Refund (or Cancellation)
  • Mark a Refund Request as Returned
  • Retrieve the status of their refund requests

Prerequisite Reading

Before attempting to use the GraphQL API to work with Refunds and Cancellations, the reader should familiarize themselves with the end to end refunds process documented here.

This outlines not only the various refund processes, but also defines the key terms and concepts involved.

The Legacy Seller API

Seller initiated refund functionality is not (and will not), be supported the Legacy Seller API.

What steps can the Seller perform

The Seller can perform the following steps in the Refund or Cancellation process:

  • Initiate a Refund Request (this is the same whether it’s Cancellation or Refund)
  • Update the Refund Request as returned
  • Retrieve the Seller Refund Requests

These functions map to the following GraphQL Mutations and Queries:


APIDescriptionResults In…
refundRequestCreateInitiates either the Cancellation or Return ProcessResults in the Creation of a RefundRequest with the Status of: AWAITING
refundRequestReturnAcknowledges the Return of ItemsResults in the the status of the RefundRequest being updated to: RETURNED
updatedRefundRequestsUsed to return all Refund Requests updated from a given timestampResults in a object array of Refund Requests for that Seller (which can be empty)

An example of the Cancellation flow (pre-dispatch) is shown below, outlining the API Calls the Seller is authorized to make.


Cancellation Process Flow


Obtaining Refund Requests

The Seller can then use the updatedRefundRequests to obtain a list of their refund requests filtered by last updated date.

API Collections

We have provided API collections for both Postman and Insomnia to get you started, please visit the Seller API Collections page to download and get started.