SaneAuth.server()

Handle the addon logic for the sane backend

This example machine is part of machinepack-boilerplate, used to introduce everyone to machines.

Usage

Hover over inputs/exits for more info.

var SaneAuth = require('sane-auth');


// Handle the addon logic for the sane backend

SaneAuth.server({

name: 'user',

attributes: 'name:string age:number',

}).exec({

// An unexpected error occurred.

error: function (err) {

 

},

// OK.

success: function (result) {

 

},

});

Inputs

name

Name of the resource

'user'
attributes

extra attributes that will be generated

'name:string age:number'

Exits

error

An unexpected error occurred.

success

OK.

{ addNpmPackages: [ {} ], commands: [ '' ] }