import ProfileController from 'itslanguage/administrative-sdk/profile/profile-controller.js'
ProfileController
Controller class for the Profile model.
Constructor Summary
Public Constructor | ||
public |
constructor(connection: Connection) |
Member Summary
Private Members | ||
private |
Object to use for making a connection to the REST API and Websocket server. |
Method Summary
Public Methods | ||
public |
getProfile(userId: string): Promise<Profile> Get the profile of the given user active in the current active Organisation derived from the OAuth2 scope. |
|
public |
getProfiles(): Promise<Profile[]> Get and return all profiles of all users in the current active Organisation derived from the OAuth2 scope. |
Public Constructors
public constructor(connection: Connection) source
Params:
Name | Type | Attribute | Description |
connection | Connection | Object to use for making a connection to the REST API and Websocket server. |
Private Members
private _connection: Connection source
Object to use for making a connection to the REST API and Websocket server.
Public Methods
public getProfile(userId: string): Promise<Profile> source
Get the profile of the given user active in the current active Organisation derived from the OAuth2 scope.
Params:
Name | Type | Attribute | Description |
userId | string | Specify a User identifier. |
Throw:
Promise.<Error> |
userId parameter of type "string" is required. |
Promise.<Error> |
If no result could not be found. |