couchdb-user-accounts
v0.0.0
Published
A couchdb user account library for user per database pattern
Downloads
3
Readme
couchdb-user-account model
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
- NodeJS http://nodejs.org
- CouchDb http://couchdb.apache.org
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: "[email protected]"
}, function(err, res) {
console.log(res);
})
API
TODO
- register
- login
- remove
- setup
- findByEmail
- changePassword
- createCode
Test
npm test
Support
- create an issue on github