UNPKG

@updatedev/js

Version:

Update JavaScript SDK

20 lines 937 B
import { GetToken } from '../types/options'; import { ApiResponse, CoreRequestOptions, RequestOptions } from '../types/request'; export declare class RequestClient { private baseUrl; private getAuthorizationToken?; private headers?; private baseBody?; constructor({ baseUrl, headers, getAuthorizationToken, baseBody, }: { baseUrl: string; headers?: Record<string, string | undefined>; getAuthorizationToken?: GetToken; baseBody?: Record<string, string | undefined>; }); private _getDefinedObject; _buildQueryString(params: Record<string, string | number | boolean | null | undefined> | undefined): string; _execute(url: string, options: RequestInit): Promise<ApiResponse>; _requestCore<T = any>(options: CoreRequestOptions): Promise<ApiResponse<T>>; request<T = unknown>(options: RequestOptions): Promise<ApiResponse<T>>; } //# sourceMappingURL=request.d.ts.map