Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

@open-age/directory-client

openage29WTFPL2.2.4

a client to connect to open-age directory

api, open-age, directory, client

readme

directory-client

Client to interact with the user

config

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

"providers": {
    "directory": {
        // "url": "http://ems-api-dev.m-sas.com", // test url
        "url": "http://directory-api.mindfulsas.com", // prod url
        "tenantKey": null,
        "tenantCode": "aqua"
    }
}

usage

Get a role by key


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

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

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