This is the early access documentation preview for Custom Views. This documentation might not be in sync with our official documentation.

Page

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

Get page structure and data

GET
https://{project}-{customer}.frontastic.io/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
Path parameters:
project
String

Project Name

customer
String

Customer Name

Response:
200PageDataResponseasapplication/json
Request Example:cURL
curl --get https://{project}-{customer}.frontastic.io/frontastic/page -i \
--header 'Frontastic-Path: ${FRONTASTIC_PATH}'\
--header 'Accept: ${ACCEPT}'\
--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": {}
}
}