Skip to main content

Order
API

The API for interacting with the order confirmation, available on the Thank You page.

Anchor to orderconfirmationapiOrderConfirmationApi

The API object provided to purchase.thank-you extension targets.

<>
required

Order information that's available post-checkout.

Was this section helpful?

Note

This documentation has moved to customer accounts. Refer to Order API

Was this section helpful?

Order confirmation

Preact

import '@shopify/ui-extensions/preact';
import {render} from 'preact';

export default function extension() {
render(<Extension />, document.body);
}

function Extension() {
const {id} =
shopify.orderConfirmation.value.order;

if (id) {
return (
<s-banner>
Please include your order confirmation ID
({id}) in support requests
</s-banner>
);
}

return null;
}