How to expose a local n8n webhook
Send an external HTTPS webhook to your local n8n workflow with Tubu while keeping the editor private.
Set up a local test webhook
Start with n8n available at http://127.0.0.1:5678, Caddy installed, and a Tubu API key from the quick start. Create a disposable workflow with one Webhook node. Set its method to POST and its path to tubu-demo.
Save this config as Caddyfile. It forwards the exact test path to n8n and returns 404 for other requests, including requests for the editor.
http://:8080 {
bind 127.0.0.1
handle /webhook-test/tubu-demo {
reverse_proxy 127.0.0.1:5678
}
handle {
respond 404
}
}caddy run --config Caddyfile --adapter caddyfileSend an event through the tunnel
In another shell, set TUBU_TOKEN to your API key. Replace my-n8n.tubu.dev with an available hostname and keep the tunnel running.
npx tubu-cli http 8080 --domain my-n8n.tubu.devIn the Webhook node, select Listen for Test Event. Send this sample to your public hostname and check for the JSON payload in the editor.
curl -i https://my-n8n.tubu.dev/webhook-test/tubu-demo \
-H 'Content-Type: application/json' \
--data '{"event":"test"}'If the request fails, check that n8n is listening for the test event, the method and path match the node, and the publisher can reach Caddy on port 8080. Open the public root URL and /rest to confirm both return 404.
Use the published workflow URL
Enable authentication supported by your sender and retain provider signature verification when applicable. Publish the workflow, replace the Caddy path with /webhook/tubu-demo, and reload Caddy. Update the provider to use that path on your public HTTPS hostname. Send a provider test event and confirm it appears under Executions.
If n8n needs to generate the public URL itself, follow its reverse proxy configuration guide for your version. For a hostname you need to keep, see how to reserve a Tubu domain.
Stop the Tubu publisher when you no longer need the endpoint. See the n8n Webhook node documentation for URL and authentication options.