UNPKG

@itwin/core-frontend

Version:
41 lines 1.38 kB
/** @internal */ export interface RequestBasicCredentials { user: string; password: string; } /** Error object that's thrown if the status is *not* in the range of 200-299 (inclusive). * @internal */ export declare class HttpResponseError extends Error { status: number; responseText?: string | undefined; constructor(status: number, responseText?: string | undefined); } /** @internal */ export interface RequestOptions { retryCount?: number; headers?: any; timeout?: number; auth?: RequestBasicCredentials; } /** @internal */ export declare function request(url: string, responseType: "arraybuffer", options?: RequestOptions): Promise<ArrayBuffer>; /** @internal */ export declare function request(url: string, responseType: "json", options?: RequestOptions): Promise<any>; /** @internal */ export declare function request(url: string, responseType: "text", options?: RequestOptions): Promise<string>; /** * @internal * @deprecated in 4.0 - will not be removed until after 2026-06-13. Use [[DownloadProgressInfo]]. */ export interface ProgressInfo { percent?: number; total?: number; loaded: number; } /** * @internal * @deprecated in 4.0 - will not be removed until after 2026-06-13. Use [[OnDownloadProgress]]. */ export type ProgressCallback = (progress: ProgressInfo) => void; //# sourceMappingURL=Request.d.ts.map