Skip to main content

Function: getUser()

getUser(catalogDir): (id) => Promise<User>

Defined in: users.ts:24

Returns a user from EventCatalog.

Parameters

ParameterType
catalogDirstring

Returns

Function

Parameters

ParameterType
idstring

Returns

Promise<User>

Example

import utils from '@eventcatalog/utils';

const { getUser } = utils('/path/to/eventcatalog');

// Gets the user with the given id
const user = await getUser('eventcatalog-core-user');