Set up the Stripe webhook

Updated Nov 28, 20263 min read
English
On this page

A Stripe webhook makes Deskwoot save every charge, refund and subscription change, and every new customer, the moment it happens. This guide walks you through every click, with screenshots from the actual Stripe Dashboard.

What the webhook changes

  • Without a webhook, the Details tab of a conversation still reads payments and subscriptions live from Stripe whenever the conversation opens, and Stripe customers are imported as contacts once a day. Nothing is saved in Deskwoot between those reads, and a brand new Stripe customer only becomes a contact with the next daily import.
  • With a webhook, Stripe pushes events to Deskwoot the moment they happen on your account, and Deskwoot saves each charge, refund and subscription change right away.

Step 1: Copy your webhook URL from Deskwoot

The Stripe panel in Deskwoot with Customer events in real time: Step 1. Webhook URL with its Copy button, then Step 2. Webhook signing secret
  1. In Deskwoot, open Settings > Integrations > Stripe.
  2. In the box Customer events in real time, find your personal Webhook URL under Step 1. Webhook URL. It looks like https://deskwoot.com/api/webhooks/stripe-customer/<your-integration-id>.
  3. Click Copy next to it.

Step 2: Open the Stripe Webhooks page

  1. Log in to dashboard.stripe.com.
  2. In the bottom left corner, click Developers (1.).
  3. In the menu that opens, click Webhooks (2.).
Stripe's Developers menu, with Developers at the bottom and Webhooks highlighted above it

Step 3: Create a destination and select the 8 events

  1. On the Webhooks page, click the button to create a new event destination. The wizard Create an event destination opens.
  2. Leave Event destination scope on Your account (1.).
  3. Leave Payload style on Snapshot and the API version on the Stripe default.
  4. Under Events, switch to the All events tab (2.).
  5. In the search field (3.) find and check each of these 8 events:
    • charge.succeeded
    • charge.refunded
    • customer.created
    • customer.updated
    • customer.subscription.created
    • customer.subscription.updated
    • customer.subscription.deleted
    • invoice.paid
  6. Click Continue (4.).
Stripe wizard Create an event destination with the Your account scope, the All events tab, the event search field and the Continue button marked 1 to 4

Step 4: Choose the destination type

  1. Pick Webhook endpoint (it is usually selected already).
  2. Click Continue.
Stripe wizard Choose where you want to send events with Webhook endpoint selected and the Continue button highlighted

Step 5: Configure the destination

  1. Type Deskwoot as the Destination name.
  2. Paste the Webhook URL you copied in Step 1 into the Endpoint URL field. The description is optional.
  3. Click Create destination.
Stripe form Configure destination with arrows at the Destination name field set to Deskwoot, the filled Endpoint URL field and the Create destination button

Step 6: Reveal and copy the signing secret

Stripe now shows your new destination with the Active badge. On the right, under Destination details, find the Signing secret box:

  1. Click the eye icon to reveal the secret.
  2. Copy the value that starts with whsec_.
Destination details of the new Stripe destination with the Signing secret box (whsec_...) highlighted

Step 7: Paste the secret back into Deskwoot

  1. Back in Deskwoot, open Settings > Integrations > Stripe.
  2. Paste the whsec_ value into the field under Step 2. Webhook signing secret.
  3. Click Save.

The status of the Customer events in real time box switches from "Not set up" to "Set up".

Step 8: Send a test event

  1. Back on the destination's page in Stripe, click Send test events at the top right.
  2. Send a charge.succeeded event.

Within a few seconds the Event deliveries tab shows it with a 200 response. You're done.

From now on Stripe sends new charges, refunds, subscription changes and new customers to Deskwoot the moment they happen, and Deskwoot saves them right away instead of waiting for the daily contact import.

Troubleshooting

  • The test webhook returns a 4xx error. Open Deskwoot under Settings > Integrations > Stripe and confirm the signing secret matches exactly what Stripe showed you, with no leading or trailing spaces. The secret must match for signature verification to succeed.
  • The endpoint shows a 412 Precondition Failed. Deskwoot has the integration but no signing secret saved yet. Paste the whsec_ value into the Webhook signing secret field and save.
  • Events arrive but customers still do not appear in Deskwoot. Most likely the events you selected do not include charge.succeeded or customer.created. Open the destination in Stripe, click Edit destination, and confirm the full event list above is selected.

Frequently asked questions

Do I need the webhook?
No, it is optional. Without it, the Details tab still reads payments and subscriptions live from Stripe, and Stripe customers are imported as contacts once a day. With it, Deskwoot saves each charge, refund and subscription change, and new customers, the moment they happen.
What does a 412 Precondition Failed mean?
Deskwoot has your Stripe integration but no signing secret saved yet. Paste the whsec_ value under Step 2. Webhook signing secret and save.

Was this guide helpful?

Keep reading

Still need help?

Fynn answers from these guides in the chat, and you can reach the team there too.