Webhooks are a system of automated notifications indicating that an event has occurred in your gateway. Rather than requiring you to pull information via our API, webhooks push information to your designated destination when important events occur.

Webhooks allow you to develop a workflow for how your server responds to the information provided in a notification (e.g. setting up your server to send an email to any customers whose subscriptions have expired).

Types of webhooks

You can create webhooks for:

  • Subscription status changes
  • Disbursements to your account
  • Disputes on transactions
  • Braintree Marketplace sub-merchant account status changes
  • Grant API payment method status changes

Creating webhooks

In order to configure webhooks, your user’s role must include the Manage Webhooks role permission.

To create a webhook:

  1. Log into the Control Panel
  2. Click on the gear icon in the top right corner
  3. Click API from the drop-down menu
  4. Click on the Webhooks tab
  5. Click the Create New Webhook button
  6. Provide your destination URL and make your notification selections
  7. Click the Create Webhook button

After creating the webhook in the Control Panel, you'll need to set up your server to parse the webhook. See our developer docs for details.

Testing webhooks

Once you’ve set up a webhook, you can send a test webhook to make sure your endpoint is configured correctly. To test a webhook:

  1. Log into the Control Panel
  2. Click on the gear icon in the top right corner
  3. Click API from the drop-down menu
  4. Click on the Webhooks tab
  5. Click the Check URL link located to the right of the webhook you'd like to test

For more details on the notification received for test webhooks, see our developer docs.

note

Be careful when testing webhooks in your production environment – if your webhook handling code doesn’t look for the kind of webhooks it receives, it could lead to unexpected behavior.

Still have questions?

If you can’t find an answer, contact us