Select programming language for code examples

linkRelationships

Throughout the API, many resources will have a relationships property containing another resource which they are associated with. When creating or modifying a relationship, you will be introduced to what's called a "resource identifier object", or linkage for short.

A "resource identifier object" is an object that identifies an individual resource. The linkage object must contain a type and an id of the individual resource for the relationship.

A relationship may contain additional metadata via a top-level meta property, for example, a license's machine relationship includes count metadata.

Some resources accept embedded relationships. For example, during machine activation, you can send an array of embedded components inside of the machine's component relationship, i.e. not only type and id, but also the component's attributes. Another example would be release constraints.

Example resource identifier object

{
"data": {
"type": "policies",
"id": "76805397-9b46-4dcf-ad90-177a0f0969e2"
}
}