CheaprEats JavaScript SDK

Usage no npm install needed!

<script type="module">
  import cheapreatsSdk from 'https://cdn.skypack.dev/@cheapreats/sdk';


CheaprEats Node.js SDK

npm version Documentation

CheaprEats Node.js SDK

$ npm install @cheapreats/sdk

Using the Published SDK Version

const CE = require('@cheapreats/sdk');

Using the SDK Locally

Locally importing is used typically while testing new SDK method implementations.

const CE = require('./index');

Example Usage

const CE = require('./index');
// const CE = require("cheapreats-node-sdk")


.then(verification_request_id => console.log("SMS Sent", verification_request_id))
.catch(e => console.log(e));

Auto-generating code for New Mutation

The npm run add:mutation <Object>.<methodName> command auto-generates code for the Object and methodName passed.

For example - npm run add:mutation Category.batchArchive

Publishing to NPM

Ensure that package version in feature branch is ahead of master branch, otherwise publish will fail


By default package is automatically published anytime a change is made on master


If package is to be published manually, execute following commands:

  • npm run build
  • npm publish
  • npm run generate-docs (Publishes docs)