In this tutorial, you'll learn how to create a checkout in Shopify with the REST Admin API's [`Checkout`](/docs/api/admin-rest/latest/resources/checkout) resource. When you create a checkout with the Checkout API, Shopify processes the checkouts and handles payouts to the merchants for you. Your sales channel app can provide checkout links to Shopify's web checkout for each product. Your sales channel will use Shopify's web checkout instead of building your own native checkout form. ## Requirements - You've finished the channels [Getting started](/docs/apps/build/sales-channels/start-building) tutorial. ## Step 1: Create a checkout To create a checkout and return the web URL for a single product, send the following POST request to the `admin/checkouts.json` endpoint: ``` curl curl -X POST -H "X-Shopify-Access-Token: 35df6efd065b8ce72dca9493e5ec34c5" -H "Content-Type: application/json" "https://{shop}.myshopify.com/admin/api/2025-01/checkouts.json" -d @checkout.json ``` ``` json { "checkout": { "line_items": [ { "variant_id": 26756068422, "quantity": 1 } ] } } ``` In response, the request returns the `Checkout` object including the `web_url` parameter: ``` https://checkout.shopify.com/123456/checkouts/70b2b9d661c32de41fb130cd04e085c2 ``` You can redirect a customer to this URL for Shopify's web checkout for this product. ## Step 2: Throttle REST Admin API requests (Optional) Requests to the REST Admin API's [`Checkout`](/docs/api/admin-rest/latest/resources/checkout) resource that exceed the throttle limit return a `429 too many requests` status code and an empty JSON body with the following: - Response header `X-Checkout-Queue` set to `true` - Response header `X-Checkout-Queue-Token` set to the queue token value - `_checkout_queue_token` cookie set to the queue token value When a client receives this response, it needs to send requests to the polling endpoint to move ahead in the queue. To learn how to send requests to the polling endpoint, refer to [Poll the checkout queue](/docs/apps/build/sales-channels/checkout-api/checkout-queue-polling). ## Next steps - [Complete a sales channel checkout with the Checkout API](/docs/apps/build/sales-channels/checkout-api/complete-payment).