Invite User; Email, Role ID, Login Type, LDAP Username, Instances
When LDAP SSO is enabled for the account, invitations with login_type sso must include ldap_username. The username must exist in the LDAP directory and must not belong to another user or pending invitation.
instances grants the invited user access to the listed agents and simulations at signup. Each item has an id and a type of agent or simulation, and the list holds at most 500 items. A simulation must be listed together with its agent. Unknown instance IDs, or IDs outside the account, return 400. instances is ignored for roles with access to all instances.
If a pending invitation exists for the email, it is re-sent with its original role and access; role_id and instances in the request are not applied.
| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
About
This endpoint creates a pending invitation for a new user. When called, this endpoint sends an email invitation with a signup link and assigns default roles or access settings if configured. Invited users can log in using either password authentication or SSO, depending on your organization’s login setup.
Example
- Invite user with SSO
curl -X POST "https://api.picussecurity.com/v1/users/invite" \
-H "Access-Token: YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"email": "[email protected]",
"role_id": 2,
"login_type": "sso"
}'{
"id": 1234
}- Invite user with password login
curl -X POST "https://api.picussecurity.com/v1/users/invite" \
-H "Access-Token: YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"email": "[email protected]",
"role_id": 3,
"login_type": "password"
}'{
"id": 1235
}| Field Name | Type | Options |
|---|---|---|
| string | - | |
| role_id | uint | - |
| login_type | string | sso, password |