Home > widget-integration > RecommendationAPI > PAGE_PARAM_MAP

RecommendationAPI.PAGE_PARAM_MAP property

Maps platform page types to API parameter values for page-specific recommendations.

This mapping converts internal page identifiers to the format expected by the Boost recommendation API's pg parameter. The API uses these values to optimize recommendations based on the current page context.

Signature:

PAGE_PARAM_MAP: {
		product: string;
		cart: string;
		checkout: string;
		search: string;
		home: string;
		collection: string;
	};

Example

Extend to add custom page types:

class CustomRecommendationAPI extends RecommendationAPI {
  PAGE_PARAM_MAP = {
    ...super.PAGE_PARAM_MAP,
    'landing': 'landing_page',
    'about': 'info_page'
  };
}