Skip to main content


GitHub Licensenpm versionnpm minified sizenpm total downloads


WIP Package!

Promise based HTTP request API


The api package is a Promise based HTTP/s request API, with a simple syntax.

⏰ Short Example

// Let't create our API
const api = new API({
baseURL: '', // Base Route to the Host
timeout: 10000, // After which amount of time a request times out
options: { credentials: 'include' } // Http/s Request Options from type RequestInit

// Now we can create our first Request to ''
const response = await api.get('/hello');
data: {hello: "Jeff"}; // Response Data
timedout: false; // If Request has timedout
status: 200; // Response Status Code
raw: Response; // Raw Response from type Response
type: "application/json"; // Response Type