@apptus/esales-api
Version:
Library for making requests to Elevate 4 API v3
52 lines (44 loc) • 2.02 kB
text/typescript
import type {
ContentListPage, ContentListPageBody, Navigation, NavigationPageBody, PrimaryList, PrimaryListPageBody,
ProductListParams, ProductParams, RecommendationListPage, RecommendationListPageBody
} from './common/mod.ts';
export interface LandingPageParams extends ProductParams, ProductListParams {
/** A search phrase used to further refine the result */
q?: string;
/**
* Required if the `Referer` header is missing, used to identify the current page.
* Any string is accepted, but using URLs is a good practice to follow.
*/
pageReference?: string;
/**
* Whether or not the response should include a navigation object (including breadcrumbs),
* i.e. when navigation is handled through Elevate. Defaults to false if omitted.
*/
includeNavigation?: boolean;
}
export interface LandingPageBody extends PrimaryListPageBody,
NavigationPageBody, RecommendationListPageBody, ContentListPageBody {}
export interface LandingPage extends RecommendationListPage, ContentListPage {
/** A product list with facets, sort orders and hit count */
primaryList?: PrimaryList;
/** Navigation, can be `undefined` if disabled */
navigation?: Navigation;
/** String key/value map with custom data added via the Admin page import API */
customData: Record<string, string>;
/** Is `true` if the returned page's settings were overridden from the Elevate API or the Elevate app */
published: boolean;
/** SEO information */
seo: SearchEngineOptimization;
}
export interface SearchEngineOptimization {
/** Preamble text for the current page */
preamble?: string;
/** Description for the current page, use with: `<meta type="description" content="{VALUE}">` */
metaDescription?: string;
/** Title for the current page, use with: `<title>{VALUE}</title>` */
pageTitle?: string;
/** Preferred URL for the current page, use with `<link rel="canonical" href="{VALUE}">` */
canonicalPath?: string;
/** Main heading for the current page */
pageHeading?: string;
}