@open-age/client

1.2.4 • Public • Published

directory-client

Client to interact with the user

config

add following section to the config/{env}.config file

"providers": {
    "directory": {
        "url": "http://api.openage.in/directory/v1/api", // prod url
        "role": {
            "key": "<presistant token>"
        }
    }
}

usage

Get a role by key

const client = require('@open-age/client')

const roleKey = 'xxx....xxx' // role key of the user

// impersonates the user
const role = await client.directory.roles.get(roleKey)

Package Sidebar

Install

npm i @open-age/client

Weekly Downloads

10

Version

1.2.4

License

WTFPL

Unpacked Size

19.9 kB

Total Files

20

Last publish

Collaborators

  • sunny-parkash