UNPKG

@umbraco/headless-client

Version:
25 lines (24 loc) 1.12 kB
import { ContentDeliveryFilterOptions, ContentTypeOptions, CultureOptions, DepthOptions, HyperlinksOption, PageOptions } from './RequestOptions'; /** @internal */ export declare enum EndpointSource { CDN = 0, Media = 1, ContentManagement = 2 } /** * This class describes how and endpoint might will look, * it's not possible to change value * @internal */ export declare class Endpoint<R = any> { readonly source: EndpointSource; readonly path: string; readonly urlParams: any; readonly method: 'get' | 'GET' | 'post' | 'POST' | 'put' | 'PUT' | 'delete' | 'DELETE'; readonly options?: DepthOptions | PageOptions | HyperlinksOption | ContentTypeOptions | CultureOptions | ContentDeliveryFilterOptions | undefined; constructor(source: EndpointSource, path: string, urlParams: any, method: 'get' | 'GET' | 'post' | 'POST' | 'put' | 'PUT' | 'delete' | 'DELETE', options?: DepthOptions | PageOptions | HyperlinksOption | ContentTypeOptions | CultureOptions | ContentDeliveryFilterOptions | undefined); /** * Replace path with urlParams */ getPath: () => string; }