UNPKG

@kontent-ai/delivery-sdk

Version:
36 lines (35 loc) 1.6 kB
import { Contracts } from '../../contracts'; import { IDeliveryClientConfig } from '../../config'; import { ClientTypes, IDeliveryNetworkResponse, ILanguagesQueryConfig, ISyncInitQueryConfig, Responses } from '../../models'; import { QueryService } from '../../services'; import { BaseQuery } from '../common/base-query.class'; export declare class InitializeSyncQuery<TClientTypes extends ClientTypes> extends BaseQuery<TClientTypes, Responses.IInitializeSyncResponse, ISyncInitQueryConfig, Contracts.IInitializeSyncContract> { protected config: IDeliveryClientConfig; protected queryService: QueryService<TClientTypes>; protected readonly endpoint: string; protected _queryConfig: ILanguagesQueryConfig; constructor(config: IDeliveryClientConfig, queryService: QueryService<TClientTypes>); /** * Gets only item of given type * @param type Codename of type to get */ type(type: string): this; /** * Gets only item from given collection * @param collection Codename of collection to get */ collection(collection: string): this; /** * Language codename * @param languageCodename Codename of the language */ languageParameter(languageCodename: string): this; toPromise(): Promise<IDeliveryNetworkResponse<Responses.IInitializeSyncResponse, Contracts.IInitializeSyncContract>>; getUrl(): string; /** * Used to configure query * @param queryConfig Query configuration */ queryConfig(queryConfig: ISyncInitQueryConfig): this; map(json: any): Responses.IInitializeSyncResponse; }