Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

couchdb-user-accounts

danilaplee12MIT0.0.0

A couchdb user account library for user per database pattern

couchdb, user, account, model

readme

couchdb-user-account model

build status

This is a user account model module for applications looking to leverage couchdb _users database to manage application users as well as create a database per user and properly set the security properties giving the user account sole access to their datastore.

Requirements

Install

npm install couchdb-user-account

Usage

var account = require('couchdb-user-account')({
  protocol: 'http',
  host: 'localhost:5984',
  auth: 'foo:bar'
})

// register account

account.register({
  name: "foo",
  password: "beep",
  email: "foo@beep.com"
}, function(err, res) {
  console.log(res);
})

API

TODO

  • register
  • login
  • remove
  • setup
  • findByEmail
  • changePassword
  • createCode

Test

npm test

Support

  • create an issue on github