/user/_user

The _user module exports the user method to route User API requests.

  • add
  • admin
  • cookie
  • delete
  • key
  • list
  • log
  • login
  • register
  • token
  • update
  • verify

Requires

Methods

(async, inner) user(req, res)

The Mapp API uses the user method to lookup and route User API requests.

The route method assigns the host param from /utils/reqHost before the request and response arguments are passed a User API method identified by the method param.

The method request parameter must be an own member of the methods object, eg. admin, register, verify, add, delete, update, list, log, key, token, cookie, or login.

Parameters:
NameTypeDescription
reqObject

HTTP request.

resObject

HTTP response.

req.paramsObject

Request parameter.

Properties
NameTypeDescription
methodstring

Method request parameter.