Localhost environment
Last updated
Last updated
This page describes how to handle Yoki webhooks on localhost so that merchant can debug subscription statuses coming from Yoki.
Short answer
Use https://webhookrelay.com/ to forward Yoki webhooks to localhost. In the Webhookrelay's dashboard go to Request Forwarding -> Buckets -> Forward To and choose Internal Destination. The flow is pretty well explained up there.
Long answer
Run webhook handler on localhost. Let's say, you receive requests on http://localhost:8088
Register on https://webhookrelay.com/
Go to webhookrelay's dashboard
Select Request Forwarding -> Buckets -> Forward To and choose Internal Destination.
Specify local URL to forward requests to (in this case http://localhost:8088):
Install the agent on local machine (commands for operating systems are given), press "Generate Auth Token", then run authenticate command. After completed, run forwarding command as per screenshot below.
After it is done, you'll see "Agent is connected and subscribed!". Press "Start forwarding".
You're done! You can now see the public webhook handler URL that you can give to Yoki to test integration locally. All requests will be forwarded to localhost:8088 (or any other URL).