Organization Invitations
These are all methods on the Organization class that allow you to manage the invitations to an organization.
getPendingInvitations()
function getPendingInvitations(params?: GetPendingInvitationsParams): Promise<OrganizationInvitation[]>;
Retrieves a list of organization invitations that have not yet been accepted.
GetPendingInvitationsParams
Name | Type | Description |
---|---|---|
limit | number | Limit of the results returned. |
offset | number | The offset of results to start the retrieval. |
Returns
Type | Description |
---|---|
Promise<OrganizationInvitation[]> | This method returns a Promise which resolves with a list of OrganizationInvitation objects. |
inviteMember()
function inviteMember(params: InviteMemberParams): Promise<OrganizationInvitation>;
Creates and sends an invitation to the target email address for becoming a member with the role passed on the function parameters.
InviteMemberParams
Name | Type | Description |
---|---|---|
emailAddress | string | The email address to invite. |
role | 'admin' | 'basic_member' | 'guest_member' | The role of the new member. |
Returns
Type | Description |
---|---|
Promise<OrganizationInvitation> | This method returns a Promise which resolves to the OrganizationInvitation for the created invitation. |
inviteMembers()
function inviteMembers(params: InviteMembersParams): Promise<OrganizationInvitation[]>;
Creates and sends an invitation to the target email addresses for becoming a member with the role passed on the function parameters.
InviteMembersParams
Name | Type | Description |
---|---|---|
emailAddresses | string[] | The email addresses to invite. |
role | 'admin' | 'basic_member' | 'guest_member' | The role of the new members. |
Returns
Type | Description |
---|---|
Promise<OrganizationInvitation[]> | This method returns a Promise which resolves to a list of OrganizationInvitation s for the created invitations. |