Skip to main content
Sitecore Documentation
  • Learn
  • Downloads
  • Changelog
  • Roadmap
CDPCloud Portal
Sitecore CDP Developer Documentation
  • Developing with Sitecore CDP
    • Base URL
        • Using link expansion
    • Response codes
    • REST API Guest v2.1
    • REST API Guest data extension v2.1
    • REST API Order v2.1
    • REST API Order contact v2.1
    • REST API Order consumer v2.1
    • REST API Order data extension v2.1
    • REST API Order item data extension v2.1
    • REST API Audience export
  1. REST APIs
  1. REST APIs
  2. Linking to objects

Linking to objects

REST resources that reference other resources, such as an account referencing its parent directory, represent the reference as a link. A link is an object nested within an existing resource representation that has an href attribute. The href attribute is the fully qualified location URI of the linked resource.

A link object:

{
    "href": "<baseURL>/v2/someCollection/{ref}"
}

This JSON object structure is called a link because it provides a similar functionality to more familiar HTML anchors that are often called hyperlinks or links for short. You can use the href attribute within the link object to interact with that resource, if required.

This someCollection resource has more than one link: the resource itself and the items in the resource collection:

{
  "href": "<baseURL>/v2/someCollection",
  "offset": 0,
  "limit": 10,
  "items" : [
    {
      "href": "<baseURL>/v2/someCollection/37e60a14-9198-4b38-8bc3-f3924e2b6fe4"
    },
    {
      "href": "<baseURL>/v2/someCollection/D1548691-47DF-41B6-A7B7-77516A76D62C"
    }
  ]
}
If you have suggestions for improving this article, let us know!

Documentation Assistant

This assistant uses AI to generate responses based on Sitecore documentation. While it has access to official sources, answers may be incomplete or inaccurate and should not be considered official advice or support.
Powered by
k
kapa.ai
Protected by reCAPTCHA

© Copyright 2026, Sitecore A/S or a Sitecore affiliated company.
All rights reserved.

Privacy policySitecore Trust CenterTerms of use