The Stripe source enables you to receive Stripe webhook events in Knock and map them to actions like triggering workflows, identifying users, and managing tenants. Knock provides a pre-built integration with webhook verification and event-to-action mappings ready to use.
- A Stripe account with access to the Developers section
- A Knock account with at least one workflow configured
Create the source in Knock
Navigate to Integrations > Sources in your Knock dashboard and click "Create source." Select Stripe from the list of pre-built integrations.
Copy the webhook URL
Copy the webhook URL for the Knock environment you want to configure.
Add the webhook endpoint in Stripe
In your Stripe Dashboard, go to Developers > Webhooks and click "Add endpoint." Paste the Knock webhook URL and select the event types you want to receive.
Copy the signing secret
After creating the endpoint in Stripe, click on it to reveal the Signing secret. Copy this value.
Paste the signing secret in Knock
Back in the Knock dashboard, paste the Stripe signing secret into the source configuration. Knock uses this to verify that incoming webhooks are from Stripe.
Review event mappings
Review the pre-configured event-to-action mappings and enable the ones relevant to your use case.
The Stripe source comes with mappings for common Stripe webhook event types. You can enable or disable each mapping independently.
| Stripe event | Suggested action | Description |
|---|
customer.created | Identify user | Creates or updates a user in Knock when a new Stripe customer is created |
customer.updated | Identify user | Updates user properties in Knock when customer details change |
customer.subscription.created | Trigger workflow | Notifies users when a new subscription starts |
customer.subscription.updated | Trigger workflow | Notifies users of subscription changes (upgrades, downgrades) |
customer.subscription.deleted | Trigger workflow | Notifies users when a subscription is canceled |
invoice.paid | Trigger workflow | Sends a payment confirmation notification |
invoice.payment_failed | Trigger workflow | Alerts users to failed payment attempts |
charge.refunded | Trigger workflow | Notifies users when a refund is processed |
You can modify any of the pre-configured mappings or create new ones for additional Stripe event types. When customizing field mappings, use dot notation to reference nested fields in the Stripe webhook payload (e.g. data.object.customer_email).
For details on building custom event-action mappings and field mapping, see the custom webhooks documentation.