@idfy/sdk
Version:
Node.js SDK for Idfy REST API
17 lines (16 loc) • 708 B
TypeScript
/// <reference types="node" />
export declare class HttpRequestor {
static lastRequest?: any;
static get<T>(url: string, token?: string): Promise<T>;
static getBuffer(url: string, token?: string): Promise<Buffer>;
static post<T>(url: string, body: any, token?: string): Promise<T>;
static postForm<T>(url: string, form: {
[key: string]: any;
}, token?: string): Promise<T>;
static patch<T>(url: string, body: any, token?: string): Promise<T>;
static put<T>(url: string, body: any, token?: string): Promise<T>;
static delete(url: string, token?: string): Promise<void>;
private static makeRequest;
private static buildError;
private static isSuccess;
}