Socket
Socket
Sign inDemoInstall

usergrid

Package Overview
Dependencies
52
Maintainers
4
Versions
15
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    usergrid

The official Node.js SDK for Usergrid


Version published
Maintainers
4
Created

Readme

Source

Codacy Badge Travis CI Badge

usergrid-nodejs

Node.js SDK 2.0 for Usergrid

Currently a work in progress; documentation and implementation are subject to change.

Current release

Release Candidate 0, available here or on npm

Bugs

Please open an issue

Known Issues

  • AuthFallback is incomplete; currently there is no ad-hoc implementation for authentication (e.g. you cannot pass a instance of UsergridAuth, nor can you force a call to be made unauthenticated if there is a stored token)
  • Authentication header is missing from certain API calls that don't leverage the UsergridRequest class. Recommend refactoring UsergridRequest to support all types of API calls (including login, logout, reset password)
  • Assets are not implemented yet
  • Many missing tests around authentication and passing a UsergridClient as a separate instance
  • Easy (clean) way to load the UsergridClient module without referencing the full path
  • Any other functionality that is missing or expected, please open an issue

Installation

Install from npm, specifying the version >= 2.0.0-rc.0:

npm install usergrid >=2.0.0-rc.0

If you want to run the latest build, simply:

npm install r3mus/usergrid-nodejs

(though you will need to run npm install to keep it up to date)

Usage

Note: This section is left intentionally light. In its current release candidate state, this SDK is only recommended for developers familiar with Usergrid, Node.js, and preferably Mocha tests. For full usage and implementation, have a look in /tests.

There are two fundamental ways to use the new Node SDK:

  1. Singleton pattern:

     var Usergrid = require('usergrid')
     Usergrid.init({
         orgId: ...,
         appId: ...
     }
     
     // or from a config file, see config.sample.json
     
     var Usergrid = require('usergrid')
     Usergrid.init() // defaults to use config.json
    
  2. Instance pattern (primarily used when connecting to multiple Usergrid targets):

     var UsergridClient = require('./node_modules/usergrid/lib/client')
     var client = new UsergridClient(config)
    

FAQs

Last updated on 11 Jan 2016

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc