1.0.2 • Published 8 months ago

@dabble/rest-client v1.0.2

Weekly downloads
-
License
MIT
Repository
-
Last release
8 months ago

A library for working with JSON REST APIs. This function creates a REST API client that can be used to make requests to the specified URL. It returns an object with methods for making GET, POST, PUT, PATCH, and DELETE requests.

Examples:

const api = createRestAPI('https://api.example.com');
const data = await api.get('/users').send();
const user = await api.post('/users').body({ name: 'Alice' }).send();
const user = await api.post('/users').send({ name: 'Alice' });
await api.delete('/users').query({ id: 123 }).send();
1.0.2

8 months ago

1.0.1

12 months ago

1.0.0

12 months ago

0.1.8

2 years ago

0.1.7

2 years ago

0.1.6

2 years ago

0.1.5

2 years ago

0.1.4

2 years ago

0.1.3

2 years ago

0.1.1

2 years ago

0.1.0

2 years ago