JSPM

openrest

1.3.621
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 1
  • Score
    100M100P100Q88207F
  • License Apache-2.0

OpenRest Node.js Module (https://www.openrest.com)

Package Exports

  • openrest

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (openrest) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

OpenRest

OpenRest (founded early 2011) is a cloud-based service that enables restaurant owners to easily create online ordering websites, mobile websites and native mobile apps. As of September 2014, a total of almost a thousand restaurants power their online ordering systems with OpenRest.

OpenRest offers an open API for developers. The OpenRest API is exposed as a standard web service communicating JSON over HTTPS.

This module will allow for Node.JS developers easy integration with the OpenRest API.

Quick Example

var openrest = require("openrest");

openrest.request({
    request:{
        type:"get_organization",
        organizationId:"5670039316205915"
    },
    callback:function(e) {
        if (e.error) {
            console.error(e.errorMessage);
            return;
        }

        var organization = e.value;
    }
});

Download

The source is available for download from GitHub. Alternatively, you can install using Node Package Manager (npm): npm install openrest

Usage

Request

openrest.request(params);

Send a request to the server.

Arguments

params - Object with two members:

  • request - The request to send. For a list of possible requests, see here.
  • callback(result) - Callback called when result is received from the server.