Skip to content

AcceptInvitation Container

Processes company invitation acceptance from email links and displays the result to the user.

Version: 1.2.0

The AcceptInvitation container provides the following configuration options:

ParameterTypeReq?Description
routeMyAccountfunctionNoReturns the URL for the customer account page. Used for the ‘Go to My Account’ button after successful invitation acceptance.
routeLoginfunctionNoReturns the URL for the login page. Used when the user is not authenticated and needs to sign in.
isAuthenticatedbooleanNoIndicates the current authentication status. When true, the container renders the acceptance flow; when false, it prompts the user to log in first.
labelsobjectNoOptional labels for overriding the default text. Supports keys: title, loadingText, successTitle, successMessage, errorTitle, myAccountButton, loginButton.

This container does not expose any customizable slots.

The following example demonstrates how to use the AcceptInvitation container:

import { render as provider } from '@dropins/storefront-company-management/render.js';
import { AcceptInvitation } from '@dropins/storefront-company-management/containers/AcceptInvitation.js';
await provider.render(AcceptInvitation, {
routeMyAccount: () => `/customer/account`,
routeLogin: () => `/customer/login`,
isAuthenticated
})(block);