Actions31
- User API Actions
- Organization API Actions
- Allowlist API Actions
- Domain API Actions
- Session API Actions
- Invitation API Actions
Invitation API → Create Invitation
AI-generatedSummary
Create an invitation for a specified email address using Clerk's Invitation API.
Inputs
- invitationEmailAddress (required) — The email address to send the invitation to.
- redirectUrl — The URL to redirect the user to after accepting the invitation.
- ignoreExisting — Whether to ignore existing invitations for the same email address.
Output shape
a single record containing the invitation details
The response will include information about the created invitation. Make sure to handle possible errors such as already existing invitations based on the 'ignoreExisting' parameter.
Examples
Example 1: Create an invitation for a new user
Set 'invitationEmailAddress' to 'newuser@example.com', 'redirectUrl' to 'https://example.com/welcome', and 'ignoreExisting' to true.