Skip to main content
GET
/
api
/
v1
/
orders
/
{id}
JavaScript
import CheckoutIntents from 'checkout-intents';

const client = new CheckoutIntents({
  apiKey: process.env['CHECKOUT_INTENTS_API_KEY'], // This is the default and can be omitted
});

const order = await client.orders.retrieve('id');

console.log(order.id);
import os
from checkout_intents import CheckoutIntents

client = CheckoutIntents(
    api_key=os.environ.get("CHECKOUT_INTENTS_API_KEY"),  # This is the default and can be omitted
)
order = client.orders.retrieve(
    "id",
)
print(order.id)
package com.rye.example;

import com.rye.client.CheckoutIntentsClient;
import com.rye.client.okhttp.CheckoutIntentsOkHttpClient;
import com.rye.models.orders.Order;
import com.rye.models.orders.OrderRetrieveParams;

public final class Main {
    private Main() {}

    public static void main(String[] args) {
        CheckoutIntentsClient client = CheckoutIntentsOkHttpClient.fromEnv();

        Order order = client.orders().retrieve("id");
    }
}
curl https://staging.api.rye.com/api/v1/orders/$ID \
    -H "Authorization: Bearer $CHECKOUT_INTENTS_API_KEY"
<?php

$curl = curl_init();

curl_setopt_array($curl, [
  CURLOPT_URL => "https://staging.api.rye.com/api/v1/orders/{id}",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "Authorization: <api-key>"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://staging.api.rye.com/api/v1/orders/{id}"

	req, _ := http.NewRequest("GET", url, nil)

	req.Header.Add("Authorization", "<api-key>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(string(body))

}
require 'uri'
require 'net/http'

url = URI("https://staging.api.rye.com/api/v1/orders/{id}")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'

response = http.request(request)
puts response.read_body
{
  "id": "<string>",
  "checkoutIntentId": "ci_aaa8af5c5aae4c0e8ef0172c26c65c13",
  "createdAt": "2026-03-25T00:00:00Z",
  "updatedAt": "2026-03-27T00:00:00Z",
  "cancellation": {
    "reason": {
      "message": "<string>"
    },
    "marketplaceOrderId": "<string>",
    "checkoutIntentId": "<string>",
    "createdAt": "2023-11-07T05:31:56Z",
    "id": "<string>",
    "state": "requested"
  },
  "referenceId": "order-1234"
}
{
  "name": "<string>",
  "message": "<string>",
  "stack": "<string>"
}
{
  "name": "<string>",
  "message": "<string>",
  "stack": "<string>"
}

Authorizations

Authorization
string
header
required

Rye API key

Path Parameters

id
string
required

The order id

Response

The order

Represents a completed order. Orders are created after a checkout intent reaches the completed state.

id
string
required
checkoutIntentId
string
required

ID of the checkout intent that was responsible for creating this order.

Example:

"ci_aaa8af5c5aae4c0e8ef0172c26c65c13"

createdAt
string
required

Timestamp the order was persisted to Rye.

Example:

"2026-03-25T00:00:00Z"

updatedAt
string
required

Timestamp the order was last updated at

Example:

"2026-03-27T00:00:00Z"

cancellation
object
required

The cancellation for this order, or null if none has been requested. Populated by joining the separate cancellations collection on the order's marketplace order id.

referenceId
string

The referenceId you supplied on the checkout intent, echoed back so you can reconcile this order against your own records. Absent when none was supplied.

Example:

"order-1234"