We recently got a question about whether webhook events are associated with a specific environment. In other words, is there an event type whose webhook events are not triggered in the sandbox, or are all event types supported regardless of the environment?
The answer is that you can subscribe to the events you specify when creating a webhook, for example:
In the examples above, you will receive notifications of all events or just the transaction events. The list of all events that support notifications is provided in the Event Types page.
To create a webhook, send a POST request to the /webhooks endpoint, as described in the Webhooks Management API reference page. Note that webhook configurations created by the /webhooksendpoint are functional only in a production environment. If you want to test webhooks in the sandbox environment, configure a webhook object within your simulated transaction.