XM

Retrieve Global Components By Channel ID

Global elements are components that appear on every page of a website, such as header and footer. This API retrieves channel-specific global elements for your site. When there are no global components for the specified channel, a blank array is returned in the success response.

Path:

GET https://{baseurl}/api-xpm/v2/global-component/live

Headers

Content-Type : application/json

x-site-context : { "date": "2020-08-28T02:35:27.787Z", "channel": 12, "account": 5f493c9f30ec2a0007a94fc8", "stage": "sandbox" }

Parameters

Type : query

Name : The channel ID.

Required: true

Sample Request

GET https://{baseurl}/api-xpm/v2/global-component/live?channel=12

Sample Response

Response Code: 200

Message: OK

Description: You will see this message when the global elements/components are successfully retrieved. When there are no global components for the specified channel, a blank array is returned.

[
{
"_id": "60e7221924524d65d97e3b32",
"id": "Component",
"params": {
"buttonOK": "OK",
"buttonCancel": "Cancel"
}
}
]

Change Log

  • Jun - 2021 (multichannel features)