/auth
Search
⌃K
Comment on page

getOrgMemberships( )

Function to return all of the organizations that a user has joined. The App must have organizations enabled.

Usage

const { data } = await client.user.getOrgMemberships({
userID: 'user.1234',
});
​
console.log('Org Memberships: ', data);

Return Value

{
data?: {
clientID: string;
organizationID: string;
userID: string;
roles: string[];
}[];
error: ErrorMessage | null;
headers: Object;
statusCode: number;
}

Configuration

userID

String that represents a user's ID.
const { data } = await client.user.getOrgMemberships({
userID: 'user.1234',
});
​
console.log('Org Memberships: ', data);