{
"colors": {
"primary": "#000000",
"secondary": "#ffffff"
},
"properties": {
"storeName": "The Heat Clinic"
}
}
Most of the entities within the Content Services are Profile Discriminated. This under the hood is simply a type of catalog which provides all the same benefits; sparse overrides, hierarchical inheritance and sandboxing. Content and Theme Fields can be defined at the tenant level and overridden at the application level.
To resolve specific content from a storefront context, all requests go through the ContentItemResolverEndpoint#resolveContentItems
endpoint. This method takes a ContentResolverRequest
allowing for various forms of content item lookup. Content can be retrieved based on one of the following: content zone name, content item name, id, model or uri. At this time, the endpoint does not support lookup by multiple factors. Results can either be paged or unpaged depending on the type of Pageable
that is passed in (NarrowedPageable
or UnnumberedPageable
)
Depending on how the storefront application is structured, looking up a piece of content by Uri could result in collisions with product and category Uris. For this reason, it is recommended to utilize the Catalog Browse Services CatalogBrowseEndpoint#readBrowseEntityDetails
endpoint.
The ThemeFieldResolverEndpoint#resolveThemeFields
endpoint is responsible for retrieving all theme fields for a given application context. The response is a simple JSON structure where the top level keys are the field group names and the values are the actual fields in the group. The following is a simple example:
{
"colors": {
"primary": "#000000",
"secondary": "#ffffff"
},
"properties": {
"storeName": "The Heat Clinic"
}
}