UNPKG

papara-wrapper

Version:
18 lines (17 loc) 591 B
import { AxiosRequestConfig } from 'axios'; import { PaparaResponse } from './interfaces'; export default class PaparaHttp { private get BASE_URL(); private testEnv; private axios; constructor({ API_KEY, debug, testEnv }: { API_KEY: string; debug?: boolean; testEnv?: boolean; }); get<T>(path: string, config?: AxiosRequestConfig): Promise<PaparaResponse<T>>; post<T>(path: string, body: { [key: string]: any; }, config?: AxiosRequestConfig): Promise<PaparaResponse<T>>; put<T>(path: string): Promise<PaparaResponse<T>>; }