Skip to main content
Cloud has the newest features. Some may not be in a release yet; the newest release is Identity & Access Management 7.3.0.

Invite parent organization's users API

Download OpenAPI (YAML)Version v1

Base URL: https://api.asgardeo.io/t/{root-organization-name}/o/api/server/v1

The WSO2 Identity Platform - Parent Organization's User Invitation API (version v1).

Download the OpenAPI definition (YAML)

Security schemes​

OAuth2: oauth2

authorizationCode flow, token URL https://api.asgardeo.io/t/{root-organization-name}/oauth2/token, authorization URL https://api.asgardeo.io/t/{root-organization-name}/oauth2/authorize

Parent Organization User Invitation​

Invite a parent organization user to a child organization​

POST /guests/invite

Initiates an invitation to a user in the parent organization to onboard to the child organization. This will be initiated from the child organization.

Scope(Permission) required: internal_org_guest_mgt_invite_add

Request body (required): application/json

Details that need to initiate an invitation

Schema: InvitationRequestBody

5 properties
NameTypeRequiredDescription
usernamesarray of stringYes

List of usernames of the users who will be invited to the organization. This can be an email or an alphanumeric username.

userDomainstring

Userstore domain of the inviting user in the parent organization. If not provided, DEFAULT userstore will be used by default.

rolesarray of string

Role assignments which the user will be assigned to.

groupsarray of string

Group assignments which the user will be assigned to.

propertiesarray of Property

Custom properties of invitation which can be used in runtime but doesn't persist as invitation information.

Responses

CodeDescriptionSchema
201

Successful Response

InvitationSuccessListResponse
400

Bad Request

Error
500

Internal Server Error

Error

introspect an invitation's confirmation code​

POST /guests/invitation/introspect

This API can be used to introspect the confirmation code. This will be invoked from the application with the access token of the user which was logged into the application and switched to the organization where the user resides in.

Scope(Permission) required: internal_org_guest_mgt_invite_list

Request body (required): application/json

Details that need to introspect an invitation

Schema: IntrospectRequestBody

1 property
NameTypeRequiredDescription
confirmationCodestringYes

Responses

CodeDescriptionSchema
200

Successful Response

IntrospectSuccessResponse
400

Bad Request

Error
401

Unauthorized

Error
403

Forbidden

Error
500

Internal Server Error

Error

Accepts an invitation from a user in the parent organization​

POST /guests/invitation/accept

After user clicks on the link provided, the redirected application should invoke this API. This API is a public API and this should be invoked with the confirmation code which is appended to the notification.

Scope(Permission) required: None

Request body (required): application/json

Details that need to confirm an invitation

Schema: AcceptanceRequestBody

1 property
NameTypeRequiredDescription
confirmationCodestringYes

Responses

CodeDescriptionSchema
204

No Content

400

Bad Request

Error
500

Internal Server Error

Error

Invitation Management​

List down the user invitations​

GET /guests/invitations

List down the invitations triggered from the current organization. This should be invoked from an access token issued from an administrator of that organization.

Scope(Permission) required: internal_org_guest_mgt_invite_list

Parameters

NameInTypeRequiredDescription
filterquerystring

Filtering the invitation based on the status. Status can be PENDING or EXPIRED.

limitqueryinteger

Maximum number of records to return This parameter is not supported yet.

offsetqueryinteger

Starting index of the pagination This parameter is not supported yet.

sortOrderquerystring

Sort order of the returned records. Either ASC or DESC This parameter is not supported yet.

Allowed values: ASC, DESC

sortByquerystring

Sort by a specific field This parameter is not supported yet.

Responses

CodeDescriptionSchema
200

Successful Response

InvitationsListResponse
401

Unauthorized

Error
403

Forbidden

Error
500

Internal Server Error

Error

Delete an invitation​

DEL /guests/invitations/{invitationId}

Based on the requirements the invitations which are initiated by the same organization can be deleted. This should be invoked from an access token issued from an administrator of that organization.

Scope(Permission) required: internal_org_guest_mgt_invite_delete

Parameters

NameInTypeRequiredDescription
invitationIdpathstringYes

ID of the invitation to delete

Responses

CodeDescriptionSchema
204

Successful Response and if the resource not found

400

Bad Request

Error
401

Unauthorized

Error
403

Forbidden

Error
500

Internal Server Error

Error

Schemas​

InvitationRequestBody​

Type: object

5 properties
NameTypeRequiredDescription
usernamesarray of stringYes

List of usernames of the users who will be invited to the organization. This can be an email or an alphanumeric username.

userDomainstring

Userstore domain of the inviting user in the parent organization. If not provided, DEFAULT userstore will be used by default.

rolesarray of string

Role assignments which the user will be assigned to.

groupsarray of string

Group assignments which the user will be assigned to.

propertiesarray of Property

Custom properties of invitation which can be used in runtime but doesn't persist as invitation information.

InvitationSuccessListResponse​

Type: array of InvitationSuccessResponse

InvitationSuccessResponse​

Type: object

7 properties
NameTypeRequiredDescription
usernamestringYes

Username of the user who will be invited to the organization. This can be an email or an alphanumeric username.

resultobjectYes

Role assignments which the user will be assigned to.

result.statusstring
result.errorCodestring
result.errorMessagestring
result.errorDescriptionstring
confirmationCodestring

Confirmation code for the invitation when internally managed notifications are disabled.

IntrospectRequestBody​

Type: object

1 property
NameTypeRequiredDescription
confirmationCodestringYes

IntrospectSuccessResponse​

Type: object

5 properties
NameTypeRequiredDescription
confirmationCodestringYes

Confirmation code of the invitation which needs to be introspected.

usernamestringYes

Username of the user who will be invited to the organization. This can be an email or an alphanumeric username.

userOrganizationstringYes

Organization which the user is residing.

initiatedOrganizationstringYes

Organization which the invitation is initiated.

statusstringYes

Status of the invitation.

AcceptanceRequestBody​

Type: object

1 property
NameTypeRequiredDescription
confirmationCodestringYes

InvitationsListResponse​

Type: object

1 property
NameTypeRequiredDescription
invitationsarray of InvitationResponse

InvitationResponse​

Type: object

7 properties
NameTypeRequiredDescription
idstringYes
usernamestringYes
emailstringYes
rolesarray of RoleAssignmentResponse
groupsarray of GroupAssignmentResponse
statusstringYes
expiredAtstring

GroupAssignmentResponse​

Type: object

2 properties
NameTypeRequiredDescription
displayNamestring
idstring

RoleAssignmentResponse​

Type: object

3 properties
NameTypeRequiredDescription
displayNamestring
idstring
audienceobject

Audience​

Type: object

3 properties
NameTypeRequiredDescription
valuestring
displaystring
typestring

Property​

Type: object

2 properties
NameTypeRequiredDescription
keystring
valuestring

Error​

Type: object

4 properties
NameTypeRequiredDescription
codestringYes

An error code.

messagestringYes

An error message.

descriptionstring

An error description.

traceIdstring

An error trace identifier.

Was this page helpful?