Request

Retrieves a list of orders that either have the same reference ID or belong to the same guest. You must include either the referenceId of the order or the guestRef as a query string parameter in the URI of the request, but not both.

In the response, items.ref contains the order reference. Use the order reference to interact with a specific order, for example, to retrieve it, update it, or create a data extension for it.

Security
BasicAuth
Query
referenceIdstring

A unique identifier generated by your organization to reference the order. For flight orders, this is often the PNR. Specify either referenceId or guestRef in the query parameters, not both.

Example:referenceId=B94TXY-1
guestRefstring

The guest reference. This is a unique identifier of the guest record. If you don't know the guest reference, first retrieve guests using the Sitecore CDP Guest REST API. Specify either referenceId or guestRef in the query parameters, not both.

offsetobject(Offset)

Collection responses use offset pagination. The offset query parameter is used to exclude from a response the first N items of the entire resource collection.

Default:"0"
Example:offset=0
limitobject, [ 10 .. 100 ](Limit)

Collection responses use offset pagination. This query parameter lets you adjust the maximum number of collection items to return for a single request.

Default:"10"
Example:limit=40
expandArray of strings

You can expand items in a collection by setting expand=true. This eliminates the need to send multiple follow-up requests (one for the collection and another for each of its items). This also helps you check if the data you intend to create already exists.

Example:expand=true
sortstring

You can sort search results by the date and time when the order was created (created) or made (orderedAt). You can only use orderedAt if you list orders using guestRef.

curl -i -X GET \
  -u '<username>:<password>' \
  'https://api-engage-ap.sitecorecloud.io/v2.1/orders?referenceId=B94TXY-1&guestRef=string&offset=0&limit=40&expand=true&sort=string'

Responses

Successful operation

Bodyapplication/json
offsetinteger, (int32)

The request's offset.

Example:0
limitinteger, (int32)

The request's limit.

Example:10
firstobject(OrderLinkFirst)

The request's first list of orders URL.

lastobject(OrderLinkLast)

The request's last list of orders URL.

nextobject(OrdersNext)

The request's next list of orders URL.

hrefstring

The request's URL.

Example:"https://api-engage-eu.sitecorecloud.io/v2.1/orders?guestRef=cadd106a-feff-42b2-90fb-a6ed136ece51/contacts?offset=0&limit=10"
itemsArray of objects(OrderHref)
Response
{ "offset": 0, "limit": 10, "first": { "href": "https://api-engage-eu.sitecorecloud.io/v2.1/orders?guestRef=2d7de9df-45a2-45ea-872c-30e45139007d&offset=1&limit=10" }, "last": { "href": "https://api-engage-eu.sitecorecloud.io/v2.1/orders?guestRef=2d7de9df-45a2-45ea-872c-30e45139007d&offset=1&limit=10" }, "next": { "href": "https://api-engage-eu.sitecorecloud.io/v2.1/orders?guestRef=2d7de9df-45a2-45ea-872c-30e45139007d&offset=1&limit=10" }, "href": "https://api-engage-eu.sitecorecloud.io/v2.1/orders?guestRef=cadd106a-feff-42b2-90fb-a6ed136ece51/contacts?offset=0&limit=10", "items": [ { … } ] }