PUT/v2/organizations/{id}/invite

Create an organization invitation link

Creates an invitation link for a user to join an organization, and can send the invitation to an email address. Provide the required roleType; optionally include the invitee's email and name.

1 parameter · 3 body fields
idintegerrequired
The integer identifier of the organization to invite a user to.

Invitation details for a user joining the organization.

emailstringoptional
Email to send invitation to
namestringoptional
Name of invited user
roleTypestringrequired
The role to assign to the invitee: `MEMBER`, `OWNER`, or `MAINTAINER`.
Allowed:MEMBEROWNERMAINTAINER

5 status codes
200Returns the invitation details, including its code, creation time, identifier, role, and any supplied invitee details.
codestringrequired
createdAtstringrequired
createdByobjectoptional
idintegerrequired
invitedUserEmailstringoptional
invitedUserNamestringoptional
typestringrequired
Allowed:MEMBEROWNERMAINTAINER
400Returned when the request is invalid, such as when `roleType` is missing or a field fails validation.
codestringrequired
Allowed:unauthenticatedapi_access_forbiddenapi_key_not_foundinvalid_api_keyinvalid_project_api_keyproject_api_key_expiredbad_credentialsmfa_enabledinvalid_otp_codemfa_not_enabledcan_not_revoke_own_permissionsdata_corrupted
paramsarray<object>optional
401Returned when the request is not authenticated.
codestringrequired
Allowed:unauthenticatedapi_access_forbiddenapi_key_not_foundinvalid_api_keyinvalid_project_api_keyproject_api_key_expiredbad_credentialsmfa_enabledinvalid_otp_codemfa_not_enabledcan_not_revoke_own_permissionsdata_corrupted
paramsarray<object>optional
403Returned when the authenticated user does not have permission to create an organization invitation.
codestringrequired
Allowed:unauthenticatedapi_access_forbiddenapi_key_not_foundinvalid_api_keyinvalid_project_api_keyproject_api_key_expiredbad_credentialsmfa_enabledinvalid_otp_codemfa_not_enabledcan_not_revoke_own_permissionsdata_corrupted
paramsarray<object>optional
404Returned when the specified organization does not exist.
codestringrequired
Allowed:unauthenticatedapi_access_forbiddenapi_key_not_foundinvalid_api_keyinvalid_project_api_keyproject_api_key_expiredbad_credentialsmfa_enabledinvalid_otp_codemfa_not_enabledcan_not_revoke_own_permissionsdata_corrupted
paramsarray<object>optional

Error handling

A 400 indicates an invalid request, a 401 indicates missing or invalid authentication, a 403 indicates insufficient access, and a 404 indicates the organization was not found. roleType is required and must be MEMBER, OWNER, or MAINTAINER; email must use a valid email format and be at most 250 characters, and name must be at most 250 characters. The id path parameter must identify an existing organization.