The Wix Account Invites API enables you to invite individuals to join your Wix account as team members, so you can expand your team and delegate account responsibilities efficiently. With this API, you can send email invitations, granting new team members specific roles and access privileges within your account. Learn more about Managing your Team.
The account invite lifecycle outlines the stages involved in sending, managing, and accepting invitations for individuals to become team members in a Wix account.
To use the AccountInvites API, install the @wix/user-management
package using npm or Yarn:
npm install @wix/user-management
or
yarn add @wix/user-management
Then import { accountInvites }
from @wix/user-management
:
import { accountInvites } from "@wix/user-management";
This article shares some typical use cases you can support, as well as an example flow that supports each use case. You're certainly not limited to these use cases, but they can be a helpful jumping off point as you plan your implementation.
If your company has multiple employees, you can invite them to join your Wix account, whether or not they already have a Wix account.
Call Create Invite with the employees email addresses, the roles to assign (referred to here as policies), and any specific assets they should not have access to (referred to here as resources). If no assets are specified, the employee will be given access to all assets in the account.
When the employee accepts the invitation, their user ID is created (if relevant) and assigned as a team member of your account.