Page

Page represents the structure and data of the published page displayed through commercetools Frontend.

Get page structure and data

Response Representation: PageDataResponse. It returns the structure and data of the published page displayed from commercetools Frontend.'

GET
https://PROJECT_NAME-COMPANY_NAME.frontastic.TLD/frontastic/page

Returns the structure and data of the published page displayed from commercetools Frontend.

Headers:

  • Frontastic-Path - ^/.*$ - Required
  • Accept - application/json - Required
  • Frontastic-Locale - Locale - Required
  • Commercetools-Frontend-Extension-Version - Extension version - Required
Path parameters:
PROJECT_NAME
String

Project Name

COMPANY_NAME
String

Company Name

TLD
String

The top-level domain for the environment, which includes .live, .io, and .rocks. For more information, see Hosts.

Response:
200PageDataResponseasapplication/json
Request Example:cURL
curl --get https://PROJECT_NAME-COMPANY_NAME.frontastic.TLD/frontastic/page -i \
--header 'Frontastic-Path: ${FRONTASTIC_PATH}'\
--header 'Accept: ${ACCEPT}'\
--header 'extension-version: ${EXTENSION_VERSION}'\
--header 'Frontastic-Locale: ${FRONTASTIC_LOCALE}'
200 Response Example: PageDataResponsejson
{
"page": {
"pageId": "4e530bb93d40a78d11a26e2b04271rk3",
"sections": {
"footer": {
"sectionId": "footer",
"layoutElements": []
},
"head": {
"sectionId": "head",
"layoutElements": []
},
"main": {
"sectionId": "main",
"layoutElements": [
{
"layoutElementId": "bfe4d755-e641-4791-9c57-d1010eacec84",
"configuration": {
"size": 12,
"mobile": true,
"tablet": true,
"desktop": true
},
"tastics": [
{
"tasticId": "48185ef7-2cd2-4593-ac82-1909d0f64731",
"tasticType": "example/star-wars/character-search",
"configuration": {
"mobile": true,
"tablet": true,
"desktop": true,
"data": null
}
}
]
}
]
}
},
"state": "default"
},
"pageFolder": {
"pageFolderId": "4e830bb93d40a78011a26e2f04223532",
"isDynamic": false,
"pageFolderType": "landingpage",
"configuration": {
"path": "star-wars",
"pathTranslations": []
},
"dataSourceConfigurations": [],
"name": "star-wars",
"ancestorIdsMaterializedPath": "/4e530bb9fd40a78011a26e7b041e8cc3",
"depth": 1,
"sort": 0
},
"data": {
"dataSources": {}
}
}