@yidun/livedetect-sdk-h5
Version:
活体检测 H5
13 lines (12 loc) • 464 B
TypeScript
export interface CreateRequestOptions {
apiServer: string;
method?: 'get' | 'post';
timeout?: number;
headers?: Record<string, string>;
}
export interface RequestOptions extends CreateRequestOptions {
url: string;
data?: Record<string, any>;
}
declare function createRequest(baseOpts: CreateRequestOptions, netCollector?: Function): <T>(opts: Omit<RequestOptions, 'apiServer'>, callback?: Function) => Promise<T>;
export { createRequest };