Standard JS API client for DoSomething.org services.


stars 🌟issues ⚠️updated 🛠created 🐣size 🏋️‍♀️
Minified + gzip package size for @dosomething/gateway in KB


Gateway (JS)

This is a simple JavaScript API client for DoSomething.org service, modeled after the Gateway PHP API client.


Install your own copy of Gateway JS using npm:

npm install @dosomething/gateway --save


Include the bundled dist/gateway.js in your page, or require it using a module bundler.


  • Set valid ENV variables in your project. See: .env.example.
  • Require the server module @dosomething/gateway/server.


 * Browser
 * somefile.js

import { RestApiClient, PhoenixAshes } from '@dosomething/gateway';

console.log(new RestApiClient());
console.log(new PhoenixAshes());

 * Server
 * somefile.js

 const { GatewayClient } = require('@dosomething/gateway/server');

 const gatewayClient = GatewayClient.getNewInstance();

If you find any bugs or have a feature request, please open an issue on github!

The npm package download data comes from npm's download counts api and package details come from npms.io.