Skip to main content
POST
/
auth
/
invite
Invite user
curl --request POST \
  --url https://server26-dot-royalti-project.uc.r.appspot.com/auth/invite \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "email": "jsmith@example.com",
  "sendEmail": true,
  "message": "<string>",
  "firstName": "<string>",
  "lastName": "<string>",
  "redirect_url": "<string>",
  "role": "<string>"
}'
{
  "message": "Successful, Email verification Instructions have been sent to your email"
}
/auth/invite Description:
The /auth/invite endpoint allows administrators to invite new users to the system by providing their email address and specifying their permissions. Optionally, a redirect URL can be provided to redirect users after they accept the invitation.
Method:
POST
Security:
  • Basic Authentication required
Query Parameters
ParameterTypeDescriptionRequired
workspaceIdstringThe workspaceId/userId of the inviteeNo
userIdstringThe ID of the user to inviteNo
Request Payload:
ParameterTypeDescription
emailstringThe email address of the user to be invited.
sendEmailbooleanThis sends an invite email to the user, by default it is true.
message (Optional)stringThis adds a message to invite email to the user
firstName (Optional)stringThe first name of the user to be invited.
lastName (Optional)stringThe last name of the user to be invited.
redirect_url (Optional)stringThe URL to redirect the user to after they accept the invitation.
role (Optional)stringThe role of the invited user.
To prevent duplicate email addresses, a user can only be associated with one tenant user record within a workspace

Authentication

This endpoint requires authentication. Include your bearer token in the Authorization header.

Query Parameters

ParameterTypeInRequiredDescription
userIdstringqueryThe workspaceId/userId of the invitee

Request Body

Request Schema

FieldTypeRequiredDescription
emailstringThe email address of the user to be invited
sendEmailbooleanThis sends an invite email to the user, by default it is true
messagestringThis adds a message to invite email to the user
firstNamestringThe first name of the user to be invited
lastNamestringThe last name of the user to be invited
redirect_urlstringThe URL to redirect the user to after they accept the invitation
rolestringThe role of the invited user

Responses

✅ 201 - Success - Existing User Invite

⚠️ 400 - Error - Missing Fields

⚠️ 401 - Unauthorized

⚠️ 404 - Not Found

❌ 500 - Internal Server Error

Tags

Auth

Authorizations

Authorization
string
header
required

JWT Authorization header using the Bearer scheme. Format: "Bearer {token}"

Query Parameters

userId
string

The workspaceId/userId of the invitee

Body

application/json
email
string<email>
required

The email address of the user to be invited

sendEmail
boolean
default:true

This sends an invite email to the user, by default it is true

message
string

This adds a message to invite email to the user

firstName
string

The first name of the user to be invited

lastName
string

The last name of the user to be invited

redirect_url
string

The URL to redirect the user to after they accept the invitation

role
string

The role of the invited user

Response

Success - Existing User Invite

message
string
I