UNPKG

neverrekt-kucoin

Version:
43 lines (42 loc) 1.16 kB
import { AxiosInstance, AxiosRequestConfig } from "axios"; export declare namespace KucoinSDK { type Params = { SECRET: string; KEY: string; PASSPHRASE?: string; isTest?: boolean; }; type Instance = { SECRET: string; KEY: string; prefix: string; axios: AxiosInstance; }; namespace Request { type Args = { type?: "private"; method: "GET" | "POST" | "PUT" | "DELETE"; endpoint: string; }; type MapItem = { key: string; required?: boolean; }; type Map = MapItem[]; } namespace Http { type Params<KV> = KV; type Config = { [key: string]: any; }; type Data<D> = D; type Response<R> = R & { parsedBody?: Data<any>; }; type ParamError = boolean | string; type Action<Response> = (endpoint: string, params: KucoinSDK.Http.Params<any>, config: AxiosRequestConfig) => Promise<Response>; type Reducer<Response> = { [key: string]: Action<Response>; }; } }