Create User and Send Email Magic Link
A 3-step recipe with Stytch. We can help you get access.
Recipe · 3 steps
Create User and Send Email Magic Link
with Stytch · Identity & Access Management
Create a user, email a magic link, and authenticate the clicked token.
- Add a new consumer user to Stytch using the supplied email address, returning the user_id used by later steps.
- Send a login or signup email magic link to the user's email address so they can authenticate by clicking through.
- Authenticate the magic link token captured from the clicked link to mint an authenticated session for the user.
What you'll need to have ready
- email: The email address to create the user under and send the magic link to.
- login_magic_link_url: The URL the user is redirected to after clicking a login magic link.
- signup_magic_link_url: The URL the user is redirected to after clicking a signup magic link.
- session_duration_minutes: Optional session lifetime in minutes for the authenticated session.
- token: The magic link token extracted from the URL the user clicked.
For your developer
Arazzo workflow stytch:create-user-magic-link, 3 operations: api_user_v1_Create → api_magic_v1_magic_links_email_Send → api_magic_v1_Authenticate. Specs on APIs.io.