Invites a user to a workspace.

POSThttps://api.awork.com/api/v1/invitations
POST https://api.awork.com/api/v1/invitations

Authentication

AuthorizationBearer

Send your token in the Authorization: Bearer <token> header. See Authentication for API keys and OAuth.

Request body Required

The invitation details.

application/json

workspaceIdstring or nullOptional
format: uuid

The id of the workspace to invite the user to. If not set, a new workspace will be created.

invitationFlowstring or nullOptional

The current invitation flow. Use 'invite' for an invitation from a system admin, 'new_user_new_workspace' for an invitation when creating a workspace for a new user or 'existing_user_new_workspace' when creating a workspace for an existing user.

roleIdstring or nullOptional
format: uuid

The id of the role to which the new user should be added.

connectInviteCodestring or nullOptional

The awork connect invite code.

passcodestring or nullOptional

The bot prevention passcode.

emailstring or nullOptional

The email of the user to be invited.

passwordstring or nullOptional

The Password of the user to be invited.

firstNamestring or nullOptional

The first name of the user to be invited.

lastNamestring or nullOptional

The last name of the user to be invited.

titlestring or nullOptional

The title of the user to be invited.

positionstring or nullOptional

The position of the user to be invited.

genderstring or nullOptional

The gender of the user to be invited. Can be 'male', 'female' or 'other'.

skipSendingEmailbooleanOptional

If set to true, skips sending the welcome email. Important for batch invites.

teamIdsarray of string or nullOptional

The list of team ids where the user should be assigned to.

bookedSeatsinteger or nullOptional
format: int32

The amount of booked seats.

productsobjectOptional

The product seats requested for an invited workspace member.

Show 2 properties
pmProductbooleanRequired

Whether the member receives a PM seat.

planstringRequired
minLength: 1 pattern: ^(None|Starter|Plus|Pro|Max|Ultra)$

The AI tier, or None for a member with only PM.

Responses

200 OK

application/json

invitationCodestring or nullOptional

The invitation code that is used to confirm the invitation. The code is valid for 24 hours.

passwordResetCodestring or nullOptional

A code that is used to reset the user's password.

userIdstringOptional
format: uuid

The id of the user that has been invited.

workspaceobjectOptional

The workspace GET model.

Show 40 properties
namestring or nullOptional
maxLength: 1000

The workspace name. Optional.

descriptionstring or nullOptional
maxLength: 1000

The workspace description. Optional.

languagestring or nullOptional
maxLength: 25

The workspace language. Optional.

timezonestring or nullOptional
maxLength: 100

The IANA timezone used for workspace-wide calendar actions. Optional.

typestring or nullOptional
maxLength: 25

The workspace type / industry set during onboarding. Optional.

sizestring or nullOptional
maxLength: 100

The workspace size. Optional.

goalsarray of string or nullOptional
maxItems: 25

The workspace team goals. Optional.

selfAttributionstring or nullOptional
maxLength: 100

The way the workspace creator learned awork, set during the onboarding. Optional.

previousToolstring or nullOptional
maxLength: 100

The project management tool used before awork, set during the onboarding. Optional.

aiUsagestring or nullOptional
maxLength: 100

How the team uses AI, set during the onboarding. Optional.

departmentstring or nullOptional
maxLength: 100

The workspace creator's department, set during the onboarding. Optional.

allowSocialLoginbooleanRequired

Whether the social login via apple and google is allowed.

allowCredentialsLoginbooleanRequired

Whether the user can login with username and password.

allowAutomaticScimUserBookingboolean or nullOptional

Whether the SCIM integration should be able to book additional user seats when provisioning and activating new users, or should return BadRequest. Only admins are allowed to change this setting.

sameDomainSignupEnabledboolean or nullOptional

Whether same domain signup feature is enabled. Only admins are allowed to change this setting.

sameDomainSignupRoleIdstring or nullOptional
format: uuid

Default Role for users who sign up through same domain signup. Only admins are allowed to change this setting.

sameDomainSignupDomainsarray of string or nullOptional

Domains enabled for same domain signup feature. Only admins are allowed to change this setting.

requireMfabooleanOptional

Whether the workspace requires multi-factor authentication for all users.

skipCreateDefaultWorkspaceDataboolean or nullOptional

Whether to skip the creation of default workspace data.

productsarray of string or nullOptional

The products available in this workspace. Read-only.

idstringOptional
format: uuid

The id of the workspace.

subdomainsarray of object or nullOptional

The workspace's subdomains. Read-only.

Show 2 properties
namestring or nullOptional

The subdomain hostname.

isDefaultbooleanOptional

Whether this is the default subdomain of the workspace.

memberCountinteger or nullOptional
format: int32

The amount of workspace members. Only visible when the user is authenticated. Read-only.

lastUsedbooleanOptional

Whether this is the workspace the current user last logged in with.

lastLoginstring or nullOptional
format: date-time

The date and time the user last logged in with this workspace, or the workspace was last accessed.

accountIdsarray of string or nullOptional

The ids of identities assigned to this workspace. Read-only.

hasImagebooleanOptional

Whether the workspace has uploaded a workspace image.

createdOnstringOptional
format: date-time

The date this workspace was created.

createdBystring or nullOptional
format: uuid

The id of the user who created this workspace. Only set after the first invitation succeeded.

updatedOnstringOptional
format: date-time

The date this workspace was last modified.

updatedBystring or nullOptional
format: uuid

The id of the user who last updated this workspace. Only set after the first invitation succeeded.

isTestWorkspacebooleanOptional

Whether the workspace is a test workspace.

isApprovedbooleanOptional

Whether the user accepted the invitation to the workspace.

allowSSOLoginbooleanOptional

Whether the user can login via an external SSO provider.

isScimActivatedbooleanOptional

Whether the workspace has SCIM user provisioning enabled.

virtualMRRnumber or nullOptional
format: double

The virtual MRR calculated during onborading.

isMobileSignupboolean or nullOptional

The type of sign-up set during the onboarding. Can be: web, mobile, ...

isFreeMailboolean or nullOptional

Whether the domain of the account of the workspace creator is a freemail or a business domain.

isJoinablebooleanOptional

Whether this workspace has same domain sign up enabled and the account's email matches the permitted domains.

isFullboolean or nullOptional

Whether this workspace is full and no more users can join. Used in same domain sign up flow.

400 Bad Request

application/json

codestringRequired
minLength: 1

The error code.

descriptionstringRequired
minLength: 1

The description of the error.

linkstringRequired
minLength: 1

The link to the API documentation page.

detailsarray of string or nullOptional

A list of details describing the error.

validationErrorsarray of object or nullOptional

If a validation error occurred, this contains the validation errors for each property.

Show 2 properties
propertystring or nullOptional

The name of the property that failed validation.

messagestring or nullOptional

The reason why this property failed validation.

traceIdstring or nullOptional

The request trace id for tracking the request.

404 Not Found

application/json

codestringRequired
minLength: 1

The error code.

descriptionstringRequired
minLength: 1

The description of the error.

linkstringRequired
minLength: 1

The link to the API documentation page.

detailsarray of string or nullOptional

A list of details describing the error.

validationErrorsarray of object or nullOptional

If a validation error occurred, this contains the validation errors for each property.

Show 2 properties
propertystring or nullOptional

The name of the property that failed validation.

messagestring or nullOptional

The reason why this property failed validation.

traceIdstring or nullOptional

The request trace id for tracking the request.

Search documentation