whoAmI #
Returns informations about the user who is currently loggedin.
whoAmI(callback) #
Arguments | Type | Description |
---|---|---|
callback | function | Callback handling the response |
Callback Response #
Returns an instantiated User object.
Usage #
// Using callbacks (NodeJS or Web Browser)
kuzzle.whoAmI(function (err, result) {
// "result" is a User object
});
// Using promises (NodeJS only)
kuzzle.whoAmIPromise()
.then(res => {
// "res" is a User object
});
Edit this page on Github(opens new window)