close

Filter

Connector for Salesforce Commerce Cloud Manual / Version 2304

Table Of Contents

9. Commerce Adapter Properties

sfcc.default-locale
Type java.util.Locale
Default  
Description

The default locale for accessing the commerce system if no locale parameter was passed into request.

sfcc.image-view-type-large
Type java.lang.String
Default large
Description

Configure the view type name of image groups used for large product images.

sfcc.image-view-type-small
Type java.lang.String
Default small
Description

Configure the view type name of image groups used for small product images.

sfcc.link.link-templates
Type java.util.Map<java.lang.String,java.lang.String>
Default  
Description

Map of link templates. Only lookup keys lowercase and without "_" are valid.

Known default lookup keys are defined in StorefrontRefKeysCommerceLed.

These patterns can include tokens which will be replaced. These tokens must be well known. The following tokens are predefined:

  • {storefrontUrl} ... the current store front URL

  • {storeId} ... the current store id

  • {locale} ... the current locale in java format, eg. en_US

  • {language} ... the current language in java format, eg. en

  • {catalogId} ... the current catalog id

  • {categoryId} ... the current category id

  • {productId} ... the current product id

  • {seoSegment} ... the current seo segment path (can contain path delimiters)

  • {storefrontUrl} ... the current store front URL

  • {customerGroup} ... the current user group, if available

  • {previewDate} ... the preview date, if available

sfcc.link.link-templates.categorylinkfragment
Type java.lang.String
Default <!--VTL $include.url('Search-Show','cgid','{categoryId}') VTL-->
Description

Used to generate category page links into CoreMedia fragments.

sfcc.link.link-templates.categorypreviewurl
Type java.lang.String
Default {storefrontUrl}/Sites-{storeId}-Site/{locale}/CM-RedirectUrl?link=Search-Show,cgid,{categoryId},preview,true&__siteDate={previewDate}&__customerGroup={customerGroup}
Description

Used to build the preview URL to a category page.

sfcc.link.link-templates.cmajaxlinkfragment
Type java.lang.String
Default <!--VTL $include.url('CM-Dynamic','url','{url}') VTL-->
Description

Used to generate ajax urls to CoreMedia contents into CoreMedia fragments.

sfcc.link.link-templates.cmcontentlinkfragment
Type java.lang.String
Default <!--VTL $include.url('CM-Content','contentId','{seoPath}') VTL-->
Description

Used to build links to shop pages displaying CoreMedia Articles and Channels into CoreMedia fragments.

sfcc.link.link-templates.cmcontentpreviewurl
Type java.lang.String
Default {storefrontUrl}/Sites-{storeId}-Site/{locale}/CM-RedirectUrl?link=CM-Content,contentId,{seoSegment},preview,true&__siteDate={previewDate}&__customerGroup={customerGroup}
Description

Used to build the preview URL to a shop page which displays a CoreMedia content.

sfcc.link.link-templates.externalpagepreviewurl
Type java.lang.String
Default {storefrontUrl}/Sites-{storeId}-Site/{locale}/CM-RedirectUrl?link=Page-Show,cid,{pageId},preview,true&__siteDate={previewDate}&__customerGroup={customerGroup}
Description

Used to build the preview URL to a shop page.

sfcc.link.link-templates.homepagelinkfragment
Type java.lang.String
Default <!--VTL $include.url('Home-Show') VTL-->
Description

Used to the link to the home page.

sfcc.link.link-templates.homepagepreviewurl
Type java.lang.String
Default {storefrontUrl}/Sites-{storeId}-Site/{locale}/CM-RedirectUrl?link=Home-Show,preview,true&__siteDate={previewDate}&__customerGroup={customerGroup}
Description

Used to build the preview URL to the shop home page.

sfcc.link.link-templates.productlinkfragment
Type java.lang.String
Default <!--VTL $include.url('Product-Show','pid','{productId}') VTL-->
Description

Used to build product detail page links into CoreMedia fragments.

sfcc.link.link-templates.productpreviewurl
Type java.lang.String
Default {storefrontUrl}/Sites-{storeId}-Site/{locale}/CM-RedirectUrl?link=Product-Show,pid,{productId},preview,true&__siteDate={previewDate}&__customerGroup={customerGroup}
Description

Used to build the preview URL to a product detail page.

sfcc.link.link-templates.shoppagelinkfragment
Type java.lang.String
Default <!--VTL $include.url('Page-Show','cid','{seoPath}') VTL-->
Description

Used to build URLs to shop pages into CoreMedia fragments.

sfcc.link.storefront-url
Type java.lang.String
Default  
Description

Base URL of the commerce storefront

sfcc.link.storefront-url-for
Type java.util.Map<java.lang.String,java.lang.String>
Default  
Description

Storefront URLs, which are used to build storefront links to shop pages and resources for different environments. The structure of the Map should be: key=environment, value=url.

The multi environment support needs to be activated via `metadata.custom-entity-param-names=environment`.

Examples:

sfcc.link.storefront-url-for.us=https://sandbox-us.demandware.net/on/demandware.store/
sfcc.link.storefront-url-for.de=https://sandbox-de.demandware.net/on/demandware.store/

The environment name for the custom entity param must be configured on the client side (CAE, Studio, etc.) global configuration example: `commerce.hub.data.customEntityParams.environment=us`

You may also configure multiple storefront URLs for different sites/environments via the commerce settings struct:

   commerce (Struct)      customEntityParams (Struct)        environment=siteus (String) 

Keep the lookup keys simple. Use lowercase with no special characters

Be aware you need to configure the environment values on the client site first, otherwise lookups can't work and will fail. There is no default fallback, as this could lead to even more confusion.

sfcc.oauth.client-id
Type java.lang.String
Default  
Description

ClientID used for all Data and Shop REST API Calls to the Salesforce Commerce System. Used to set permissions for the ClientID on Shop and Data API - for example, which resources the ClientID is allowed to access

sfcc.oauth.client-password
Type java.lang.String
Default  
Description

Password used together with the clientId.

sfcc.oauth.host
Type java.lang.String
Default account.demandware.com
Description

Host name of central SFCC endpoint for authentication.

No need to customize.

sfcc.oauth.path
Type java.lang.String
Default /dw/oauth2/access_token
Description

Path to retrieve access token.

sfcc.oauth.protocol
Type java.lang.String
Default https
Description

Protocol used to request access token.

sfcc.oauth.retry-delay
Type java.time.Duration
Default 5s
Description

The time after which a retry is attempted to fetch an ocapi access token. Until then, all requests that require an access token will end with an IllegalStateException in log.

sfcc.ocapi.custom-attributes-for
Type java.util.Map<java.lang.String,java.util.List<java.lang.String>>
Default  
Description

Configure attribute names, which are transmitted to the client as customAttributes. The key is the name of the OCAPI Document in lowercase and removed "_" (com.coremedia.commerce.adapter.sfcc.ocapi.AbstractOCDocument.getOcType()).

The value is a comma separated list of attributes, which shall be available on the client side via com.coremedia.livecontext.ecommerce.common.CommerceBean#getCustomAttributes.

The value is transmitted as String representation of the JSON Object.

Example:

sfcc.ocapi.custom-attributes-for.product=image_groups,c_isSale
sfcc.ocapi.custom-expand-parameters-for
Type java.util.Map<java.lang.String,java.util.List<java.lang.String>>
Default  
Description

Configure expand parameter names, which are requested from the commerce system via the "expand" parameter. The keys should be defined in lower case without special characters.

The value is a list of expand parameter values.

Example:

sfcc.ocapi.custom-expand-parameters-for.products=images,prices,variations
sfcc.ocapi.custom-localized-attributes-for
Type java.util.Map<java.lang.String,java.util.List<java.lang.String>>
Default  
Description

Same as customAttributesFor but for localized properties. Only the value for the current locale of the request is transmitted to the client.

sfcc.ocapi.data.customer-groups.count
Type java.lang.Integer
Default  
Description

Optional count for retrieving only a subset of all customer groups. If not set, the default behaviour of the salesforce Data API will apply.

sfcc.ocapi.host
Type java.lang.String
Default  
Description

Host name (FQDN) of your SFCC Instance.

sfcc.ocapi.load-all-sku-images
Type java.lang.Boolean
Default false
Description

Set to true if your base products often have no images assigned. With this flag enabled also SKU image groups are loaded alongside with the product data. If no image is assigned to a product a sku image is used as fallback. Note that this may increase the data footprint between commerce system and adapter. see "all_images" below SFCC Documentation

sfcc.ocapi.protocol
Type java.lang.String
Default https
Description

Protocol used for OCAPI REST communication.

sfcc.ocapi.sandbox
Type java.lang.Boolean
Default false
Description

Set to true if integrating with a sandbox instance. Adjust base paths for REST API requests

On sandbox instances the base paths must be prefixed with '/s/{siteId}' see: SFCC Documentation

sfcc.ocapi.version
Type java.lang.String
Default v21_9
Description

Version of OCAPI Rest Service used.

sfcc.search-limit
Type java.lang.Integer
Default 200
Description

The default search limit as supported by the SFCC backend.

sfcc.single-value-search-facets
Type java.util.List<java.lang.String>
Default  
Description

List of facet keys. These facets only support single values to be selected.

cache.capacities
Type java.util.Map<java.lang.String,java.lang.Long>
Default  
Description

Number of cache entries per cache class until cache eviction takes place. The keys must match the cache classes as defined by the cache keys. Please refer to javadoc of com.coremedia.cache.CacheKey.

cache.timeout-seconds
Type java.util.Map<java.lang.String,java.lang.Long>
Default  
Description

TTL in seconds until certain cache entries are invalidated.

entities.message-store.files
Type java.util.Map<java.lang.String,java.lang.Long>
Default  
Description

The number of request/response pairs to cache persistently. The keys must be valid cache classes as configured for the data lookup service, e.g., catalog, catalogs, category, categories, etc.

entities.message-store.root
Type org.springframework.core.io.Resource
Default  
Description

Root resource to persistently store messages. If this property is not set, no messages will be persisted. Configure a value to enable persistent caching of messages.

entities.products.register-parent-dependency
Type java.lang.Boolean
Default true
Description

Controls if a parent dependency is registered for a non-base product so that it is invalidated together with its base product.

entities.recompute-on-invalidation
Type java.lang.Boolean
Default false
Description

Whether to recompute entities proactively on invalidation.

entities.send-invalidations
Type java.lang.Boolean
Default true
Description

Whether or not to propagate invalidations of entities to the clients.

metadata.additional-metadata
Type java.util.Map<java.lang.String,java.lang.String>
Default  
Description

Map of additional metadata.

Can be used as customization hook. All properties starting with "metadata.additional-metadata.*" are transmitted to the generic client on the CMS side.

metadata.custom-attributes-format
Type com.coremedia.commerce.adapter.base.entities.CustomAttributesFormat
Default  
Description

Format of the custom attribute values.

The keys are always plain strings.

Used to identify the deserialization format on the CMS side.

metadata.custom-entity-param-names
Type java.util.Collection<java.lang.String>
Default  
Description

List of parameter names, which values need to be transmitted with every entity request from the CMS side.

metadata.replacement-tokens
Type java.util.Map<java.lang.String,java.lang.String>
Default  
Description

Map of key value pairs.

Used as replacement map for example for link building in the generic client on the CMS side.

metadata.vendor
Type java.lang.String
Default  
Description

Name of the vendor.

Used to identify the connected vendor on the CMS side.

Table 9.1. SFCC Commerce Adapter related Properties


Search Results

Table Of Contents
warning

Your Internet Explorer is no longer supported.

Please use Mozilla Firefox, Google Chrome, or Microsoft Edge.