Skip to main content

Using the locate order contact function in Sitecore CDP REST API

Abstract

Provides a cURL command to locate an order contact in Sitecore CDP REST API (Data model 2.0).

You can use the Order Contact REST API to perform the locate order contact function to locate the contact on an order. The response returns the orderContactRef which you can then use when you retrieve an order contact.

To locate an order contact in the Sitecore CDP, use the following:

GET: https://apiEndpoint/v2/orders/orderRef/contacts

Attribute

Description

Type

orderRef

The reference of the order.

string

$ curl -H "Accept: application/json" \
        "https://{apiEndpoint}/v2/orders/056621C2-C955-492D-B7EE-C77C6BDDFDEE/contacts"

The following is a 200 response:

{
    "href": "https://{apiEndpoint}/v2/orders/056621C2-C955-492D-B7EE-C77C6BDDFDEE/contacts",
    "offset": 0,
    "limit": 10,
    "items" : [{
        "href": "https://{apiEndpoint}/v2/orderContacts/F8D1F0D5-365D-46B7-BECF-D041E93A5705"
    }]
}