Manage test orders with the REST Admin API

You can use the REST Admin API to create test orders and transactions to validate your app's behavior.

To avoid platform fees, follow this recommended workflow for testing orders:

  1. Create an order with an authorized transaction.
  2. Get a transaction ID to use as a parent ID when capturing the transaction.
  3. Capture the transaction and set the test property to true on the order.

Other methods, such as using a manual payment gateway and the cash on delivery payment method, don't create a test order and are subject to platform fees.

Before you begin

To best understand this guide, you can familiarize yourself with the concepts of orders and transactions. Transactions are associated to orders and occur each time there is an exchange of money. Transactions are processed by payment providers, and involve the transfer of money from the issuer account (the customer's credit card) to the acquirer (the merchant's bank account). For more information, see Getting paid.

Create an order

To test orders, create an order with an authorization transaction by sending a POST request to the Order resource. Include the transactions object in the body of the request:

POST https://{shop}.myshopify.com/admin/api/2021-07/orders.json

View response