1. Test the events using webhook.site

Before you start setting up your webhook endpoint, you can test the events using webhook.site. Webhook.site is a tool that allows you to test your webhook endpoints without setting up a server. It provides you with a unique URL that you can use to receive webhook events.

Once you obtain the URL, go to the Fungies Dashboard and create a webhook. Create a webhook

Navigate to the newly created webhook and click the Test button in the top right corner. You will see a modal where you can choose the event type and data to send. Test webhook

Now you can click Send button and see the event data in the webhook.site dashboard. webhook.site request

Sending test event does not affect any production data. Test data will include testMode key set to true.

2. Test the webhook endpoint handler using the ngrok

In order to test your webhook endpoint handler locally, you can use ngrok to create a secure tunnel to your localhost server. Ngrok is a tool that creates a secure tunnel to your localhost server. It allows you to expose your local server to the internet. You can find more information at https://ngrok.com.

To use ngrok, you need to download it, install and run the following command in your terminal:

ngrok http 8081

Ngrok will provide you with a public URL that you can use to access your local server. You shoud see something like this:

Session Status                online
Forwarding                    http://*****.ngrok.io -> localhost:8081
Forwarding                    https://*****.ngrok.io -> localhost:8081

Copy the https://... url and use it to register your webhook endpoint in the next step.