Connect Stytch to Brew so user and team events fire automations. Send a welcome email when a Consumer user signs up, welcome the workspace owner when a new B2B org is created, or notify owners when a teammate is added or removed.Documentation Index
Fetch the complete documentation index at: https://docs.brew.new/llms.txt
Use this file to discover all available pages before exploring further.
What you can do
- Trigger automations from Stytch events. Kick off email flows from Consumer (B2C) or B2B auth events
- Auto-sync contacts into your audience. Every Stytch event upserts the user / member into Brew with
stytch_*custom fields you can filter and segment on - Pick Consumer or B2B at connect time. Brew filters events to the vertical you select, so Consumer connections won’t fire B2B events and vice versa
- Cover lifecycle + team workflows in one place. Onboarding, invites, role changes, offboarding, SCIM provisioning
Stytch webhooks require the B2B Pro tier for B2B projects. Consumer webhooks ship on all paid Stytch plans.
How it works
- Brew mints a unique webhook URL for your brand and you paste it into your Stytch Dashboard.
- Stytch signs every webhook with your endpoint’s signing secret. Brew verifies via the Standard Webhooks (Svix) spec on receipt.
- Brew filters events to the project type you selected (Consumer or B2B) and to
direct.*events only —dashboard.*andscim.*source events are dropped so manual operator clicks don’t accidentally email customers. - For each verified event Brew (a) starts every matching automation and (b) upserts the Stytch user / member into your audience with
stytch_*custom fields.
Setup
Generate your Brew webhook URL
In Brew, open Integrations, click the Stytch card, and click Generate URL. Copy the URL Brew generates.
Pick your Stytch project type
Choose Consumer (B2C) or B2B in the Brew connect form. Brew uses your selection to filter which events fire automations for this brand.
Add an endpoint in Stytch
Open stytch.com/dashboard, go to Webhooks → + Add Endpoint, and paste the Brew URL into the Endpoint URL field.
Subscribe to the events Brew supports
For Consumer projects: enable
direct.user.create, direct.user.update, and direct.user.delete.For B2B projects: enable direct.organization.create, direct.member.create, direct.member.update, direct.member.delete, and direct.scim_connection.create.Click Create.Reveal the Signing Secret
On the endpoint settings page Stytch shows next, reveal the Signing Secret. The value starts with
whsec_.Paste the Signing Secret into Brew
Paste the
whsec_… secret into the Brew connect form and click Connect. Brew verifies every webhook using the Standard Webhooks (Svix) spec.Brew only processes
direct.* events (real API / SDK calls). Dashboard- and SCIM-source events are dropped so manual operator clicks don’t accidentally email your customers.Triggering automations
Once connected, Stytch events show up as available triggers in the automation builder. Open the Manage tab in the Stytch integration to enable the specific events you want to fire automations.Supported events
Brew supports the following 8 Stytch events: Consumer (B2C)direct.user.createdirect.user.updatedirect.user.delete
direct.organization.createdirect.member.createdirect.member.updatedirect.member.deletedirect.scim_connection.create
Common patterns
| Goal | Stytch event |
|---|---|
| Welcome a new Consumer user | direct.user.create |
| Sync profile changes into Brew contacts | direct.user.update |
| Send a farewell email on account deletion | direct.user.delete |
| Welcome the workspace owner | direct.organization.create |
| Welcome the new teammate | direct.member.create |
| Confirm a role change | direct.member.update |
| Offboarding email | direct.member.delete |
| Ops alert when SCIM is wired | direct.scim_connection.create |
Personalization
| Variable | Example |
|---|---|
{{@trigger:output.payload.firstName}} | Alex |
{{@trigger:output.payload.lastName}} | Morgan |
{{@trigger:output.payload.organizationName}} | Acme Inc. |
{{@trigger:output.payload.role}} | admin |
Troubleshooting
An event arrived but no automation fired
An event arrived but no automation fired
Brew provisions every Stytch event disabled-by-default. Open the Stytch integration in Brew, go to the Manage tab, and toggle the event ON. Then make sure at least one of your automations uses it as a trigger and is set to Published.
Consumer events don't fire (or B2B events don't fire)
Consumer events don't fire (or B2B events don't fire)
Each Stytch connection is scoped to one project type — Consumer or B2B. If you need both, connect Stytch twice (one connection per project type). Check which project type you picked during setup on the Stytch integration page.
Stytch shows 401 on every delivery
Stytch shows 401 on every delivery
The signing secret in Brew doesn’t match the one in Stytch’s Dashboard — usually because it was rotated in one place but not the other. Reveal the current secret on the Stytch endpoint settings page and re-run setup step 6 in Brew.
Dashboard or SCIM events show up as rejected
Dashboard or SCIM events show up as rejected
Working as intended. Brew only processes
direct.* events so manual operator actions in the Stytch Dashboard, or SCIM-driven provisioning changes, don’t accidentally fire customer-facing emails.Requirements
- A Stytch account on any paid plan (B2B webhooks require B2B Pro or higher)
- Admin access to your Stytch Dashboard so you can add a webhook endpoint and reveal the Signing Secret
Need Help?
Our team is ready to support you at every step of your journey with Brew. Choose the option that works best for you:- Self-Service Tools
- Talk to Our Team
Search Documentation
Type in the “Ask any question” search bar at the top left to instantly find relevant documentation pages.
ChatGPT/Claude Integration
Click “Open in ChatGPT” at the top right of any page to analyze documentation with ChatGPT or Claude for deeper insights.