Get a page
get
/ccstore/v1/pages/{path: .*}
Returns the page for the specified path.
The response includes elements contained on that page, other pages available on it, along with the layout, dimensions and widgets used on the page.
The response includes elements contained on that page, other pages available on it, along with the layout, dimensions and widgets used on the page.
An example of the usage of this would be, when a page is loaded to be viewed by a user, to retrieve the Ids of other pages available to the user, or to view what elements and widgets are being used on that layout.
For product or category page responses, productTypes information is also returned as part of the data.
This endpoint can perform specific functionality that only works when running the storefront on a preview server. See Store Preview for more information. You can configure this behavior using the request parameters.
Request
Supported Media Types
- application/json
Path Parameters
Query Parameters
-
cacheableDataOnly(optional): string
Boolean flag to set whether to only cacheable data (for example cacheableDataOnly=true). It can be used only if dataOnly is false.Default Value:
false
-
currentDataOnly(optional): string
Boolean flag to set whether to only return current data (for example currentDataOnly=true). It can be used only if dataOnly is false.Default Value:
false
-
dataOnly(optional): string
Boolean flag to set whether to only return data (for example dataOnly=false).
-
disableMinify(optional): string
Applicable to preview only. Boolean flag to return minified or non minified Javascript links in layout information (for example disableMinify=true).Default Value:
false
-
layoutOnly(optional): string
Boolean flag to set whether to only return layout data (for example layoutOnly=true). It can be used only if dataOnly is false.Default Value:
false
-
pageParam(optional): string
Page param (for example pageParam=cat90016).
-
productTypesRequired(optional): string
Boolean flag to indicate whether productTypes data is needed in the response. This parameter will be useful only on product and category pages, as productTypes is currently returned in those pages.Default Value:
true
-
usePageId(optional): string
Applicable to preview only. Specifies the ID for a page to preview, rather than the default.
-
usePreviewData(optional): string
Applicable to preview only. Boolean flag to determine whether to use preview data.Default Value:
false
Response
Supported Media Types
- application/json
200 Response
The following model is returned when an operation is successful:
Root Schema : getPage_response
Type:
Show Source
object
-
canonicalRoute(optional):
string
The canonical route for home, article, product and category pages.
-
description(optional):
string
The page description.
-
isPreview(optional):
boolean
Whether the server is in preview mode.
-
keywords(optional):
string
The keywords for the page.
-
regions(optional):
array regions
The region data for all the regions of a page.
-
route(optional):
string
The page route.
-
title(optional):
string
The page title.
Example Response (application/json)
{
"route":"/category",
"regions":[
{
"width":12,
"name":"productListingRegion",
"widgets":[
{
"customTranslations":{
},
"localeResources":{
"en":{
"namespace":"ns.productlisting",
"resources":{
"goToPageText":"Go to page",
"viewingOptionsText":"Viewing options",
"dYMTermText":"\"__label__\"",
"goToPreviousPageText":"Go to previous page",
"resultsText":"Results: __startIndex__ - __endIndex__ (of __totalProducts__)",
"priceRangeText":"Price Range",
"viewByText":"View By:",
"salePriceText":"Sale price",
"sortByText":"Sort By:",
"onSaleText":"Sale",
"goToLastPageText":"Go to last page",
"matchingProductsText":"Matching products",
"listViewLoadedText":"Collection page displayed in list view",
"goToNextPageText":"Go to next page",
"dYMTermTextHasNext":"\"__label__\", ",
"sortByPriceDescText":"Price high to low",
"listText":"List",
"didYouMeanText":"Did you mean? ",
"gridText":"Grid",
"dYMTermAriaLabel":"Alternative search suggestions",
"sortByPriceAscText":"Price low to high",
"clickToViewText":"Click to view page ",
"activePageText":"Active page is ",
"returnedResultsText":" Returned results",
"searchResultsText":"Search results",
"wasText":"Was",
"sortByRelevanceText":"Default",
"goToFirstPageText":"Go to first page",
"refineResultsText":"Refine results",
"listPriceText":"List price",
"toText":"To",
"gridViewLoadedText":"Collection page displayed in grid view"
}
}
},
"hidden":null,
"isPreview":true,
"numberOnPage":1,
"instanceName":"Product Listing Widget",
"displayName":"Product Listing",
"global":null,
"locale":"en",
"listType":"product",
"shouldUseStyleBased":"true",
"pages":[
"category"
],
"elementsSrc":"",
"id":"productListingInst",
"imports":[
"site",
"category",
"categoryId",
"cart",
"links",
"productTypes",
"passwordPolicies",
"user",
"dimensionId"
],
"i18nresources":"productlisting",
"assetMappings":{
"/locales/ru/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/ru/ns.productlisting.json",
"/locales/pt/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/pt/ns.productlisting.json",
"/locales/nl/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/nl/ns.productlisting.json",
"/locales/ja/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/ja/ns.productlisting.json",
"/fragments/all-fragments.template":"http://localhost:9080/file/v1/widget/productListing/fragments/all-fragments.template",
"/less/widget.less":"http://localhost:9080/file/widget/productListing/less/widget.less",
"/locales/cs/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/cs/ns.productlisting.json",
"/locales/zh-TW/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/zh-TW/ns.productlisting.json",
"/locales/fi/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/fi/ns.productlisting.json",
"/templates/display.template":"http://localhost:9080/file/widget/productListing/templates/display.template",
"/locales/ko/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/ko/ns.productlisting.json",
"/locales/it/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/it/ns.productlisting.json",
"/locales/pt-BR/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/pt-BR/ns.productlisting.json",
"/locales/el/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/el/ns.productlisting.json",
"/locales/fr/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/fr/ns.productlisting.json",
"/config/config.json":"http://localhost:9080/file/widget/productListing/config/config.json",
"/locales/en/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/en/ns.productlisting.json",
"/locales/th/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/th/ns.productlisting.json",
"/templates/paginationControls.template":"http://localhost:9080/file/widget/productListing/templates/paginationControls.template",
"/locales/pl/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/pl/ns.productlisting.json",
"/locales/hu/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/hu/ns.productlisting.json",
"/locales/es/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/es/ns.productlisting.json",
"/locales/sv/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/sv/ns.productlisting.json",
"/config/locales/en.json":"http://localhost:9080/file/widget/productListing/config/locales/en.json",
"/locales/zh-CN/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/zh-CN/ns.productlisting.json",
"/locales/da/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/da/ns.productlisting.json",
"/locales/tr/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/tr/ns.productlisting.json",
"/locales/de/ns.productlisting.json":"http://localhost:9080/file/widget/productListing/locales/de/ns.productlisting.json",
"/js/product-listing.js":"http://localhost:9080/file/widget/productListing/js/product-listing.js"
},
"javascript":"product-listing",
"templateUrl":"http://localhost:9080/file/widget/productListing/templates/display.template",
"templateSrc":"",
"pageIds":[
"categoryPage"
],
"elementsJs":{
},
"typeId":"productListing",
"editableWidget":true,
"gridWidth":"4"
}
],
"type":101,
"height":300
}
],
"keywords":"Apparel",
"isPreview":true,
"canonicalRoute":"/apparel/category/cat90016",
"metaTags":[
],
"description":"Apparel",
"title":"Apparel"
}
Default Response
The error response. The following are the internal error codes thrown by this API when the request processing fails in Oracle Commerce Cloud:
Error Code | Description | Possible Fix |
---|---|---|
42001 | Page not found | Check the page ID is correct and the layout exists. |
The following model is returned when an operation is unsuccessful:
Root Schema : errorModel
Type:
Show Source
object
-
devMessage(optional):
string
An optional non-localized message containing technical information for developers
-
errorCode(optional):
string
The numerical code identifying the error
-
errors(optional):
array errors
An optional list of errors if multiple errors were encountered
-
message(optional):
string
The localized message describing the error
-
moreInfo(optional):
string
An optional non-localized message with more information
-
o:errorPath(optional):
string
An optional machine readable description of where the error occurred
-
status(optional):
string
The HTTP status code
-
type(optional):
string
The URI to the HTTP state code definition
Nested Schema : errors
Type:
array
An optional list of errors if multiple errors were encountered
Show Source
Nested Schema : items
Type:
Show Source
object
-
devMessage(optional):
string
An optional non-localized message containing technical information for developers
-
errorCode(optional):
string
The numerical code identifying the error
-
message(optional):
string
The localized message describing the error
-
moreInfo(optional):
string
An optional non-localized message with more information
-
o:errorPath(optional):
string
An optional machine readable description of where the error occurred
-
status(optional):
string
The HTTP status code