/** * @type UrlMapping: The URL mapping information for a URL that a shopper clicked or typed in. * * @property resourceType: The type of resource that corresponds to the requested URL. If you set up a URL redirect in Business Manager, resourceType returns the corresponding destination type value from the redirect. If there\'s a URI redirect, resourceType isn\'t returned. The URL redirect feature is available from B2C Commerce version 24.3. * - **Min Length:** 1 * - **Max Length:** 256 * * @property resourceSubType: If the resourceType is CONTENT_ASSET, this field tells you whether the resource is a standard content asset or a Page Designer content asset. This output is available from B2C Commerce version 24.2. * - **Min Length:** 1 * - **Max Length:** 256 * * @property resourceId: The identifier for the resource that corresponds to the requested URL. If you set up a URL redirect in Business Manager, resourceId returns the corresponding destination ID value from the redirect. If there\'s a URI redirect, resourceId isn\'t returned. The URL redirect feature is available from B2C Commerce version 24.3. * - **Min Length:** 1 * - **Max Length:** 256 * * @property refinements: The refinement filters that correspond to the URL and resourceType. Refinements are returned only if all of these conditions are met - a) the resourceType is CATEGORY, b) refinements are included in the urlSegment, and c) the refinements are configured in Business Manager. This field returns a key-value pair of refinement name and refinement value. If there’s a matching URL redirect for the requested URL. the refinements output isn’t returned. The URL redirect feature is available from B2C Commerce version 24.3. * * @property statusCode: This field is populated only if you set up a URL redirect in Business Manager. It specifies whether the redirect is temporary (302 or 307) or permanent (301). See [Create a Redirect from a B2C Commerce URL.](https://help.salesforce.com/s/articleView?id=cc.b2c_creating_a_redirect_from_a_digital_url.htm&type=5) This parameter is available from B2C Commerce version 24.3. * * @property destinationUrl: This field is populated if the urlSegment resolves to a redirect. Specifies the URL you want to redirect to as an absolute or relative URL. The destinationUrl is based on your configuration in Business Manager. It\'s either a calculated value indicating the Commerce Cloud object (product, category, or content asset) URL or your specified URL. Note that an object\'s path may not necessarily match your headless storefront URLs but can be used as a reference for calculating the destinationUrl. See [Create a Redirect from a B2C Commerce URL.](https://help.salesforce.com/s/articleView?id=cc.b2c_creating_a_redirect_from_a_digital_url.htm&type=5). Available from B2C Commerce 24.3. * - **Min Length:** 1 * - **Max Length:** 2048 * * @property copySourceParams: This field is populated only if you set up a URL redirect in Business Manager. It’s a flag that shows whether the parameters of the source URL have been copied to the destination URL. This parameter is available from B2C Commerce version 24.3. * * @property additionalUrlParams: This field is populated only if you set up a URL redirect in Business Manager. It returns the parameters you want to add to the end of the URL. This parameter is available from B2C Commerce version 24.3. * - **Min Length:** 1 * - **Max Length:** 2048 * * @property productCategoryId: This field is populated only if you set up a URL redirect in Business Manager. It identifies the destination product\'s category ID. This field is returned only when the destination type is product. This parameter is available from B2C Commerce version 24.3. * - **Min Length:** 1 * - **Max Length:** 256 * * @property onlineFrom: The date and time from which the URL redirect is active. If null, the redirect has no start date constraint. This field is populated only if you set up a URL redirect in Business Manager. This parameter is available from B2C Commerce version 26.8. * * @property onlineTo: The date and time until which the URL redirect is active. If null, the redirect has no end date constraint. This field is populated only if you set up a URL redirect in Business Manager. This parameter is available from B2C Commerce version 26.8. * */ export type UrlMapping = { resourceType?: UrlMappingResourceTypeEnum; resourceSubType?: UrlMappingResourceSubTypeEnum; resourceId?: string; refinements?: { [key: string]: any; }; statusCode?: number; destinationUrl?: string; copySourceParams?: boolean; additionalUrlParams?: string; productCategoryId?: string; onlineFrom?: string | null; onlineTo?: string | null; } & { [key: string]: any; }; export type UrlMappingResourceTypeEnum = 'CATEGORY' | 'PRODUCT' | 'CONTENT_ASSET'; export type UrlMappingResourceSubTypeEnum = 'STANDARD_CONTENT_ASSET' | 'PAGE_DESIGNER_CONTENT_ASSET';