Skip to content
😴 Lazy integrations tool for RESTful interfaces to aid POC development and streamline integrations
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.oratory
lib
.editorconfig
.gitignore Update build process Oct 16, 2018
.travis.yml
LICENSE Add LICENSE Apr 28, 2019
README.md
package-lock.json Update prettier to version 1.17.1 (#20) May 15, 2019
package.json

README.md

Drowsy is a universal REST client that makes integrating with services so wonderfully simple, you'll probably forget you're talking to an API after all. Think gRPC or SOAP, but for REST.

Description

This is the perfect tool for any prototype project or proof-of-concept application needing to integrate quickly with RESTful APIs, but it's also ideally suited as a convenience tool in larger projects that too rely on RESTful interfaces. Gone are the days of defining an API client with a restricted set of methods, and gone too are the days of boilerplate request handling in small and large code bases alike.

Drowsy just needs to know the hostname for the API you wish to consume, and off you go.

Featured on Changelog

Examples

Below is a super simple example demonstrating how easy it can be to retrieve the first page of public Gists currently available on GitHub.

const github = drowsy(request, "https://api.github.com/");

github.getGists({
  headers: {
    "User-Agent": "Octo-app"
  }
});

By calling the method getGists you're infact performing a GET request to the endpoint "/gists" through the handler provided (in this case, Request). The handler returns a Promise that will, hopefully, resolve in a timely fashion with the first page of public Gists found on GitHub.

License

This awesome project is released under the MIT License. Enjoy responsibly ✌️

You can’t perform that action at this time.