Skip to content

Getting Started: Local Development

The HookBridge CLI (hb) lets you receive webhooks on your local machine. Paste a HookBridge URL into your webhook provider (Stripe, GitHub, etc.), run hb listen, and webhooks are forwarded to your local server in real time.

See the CLI Installation guide for all options including Homebrew, binary downloads, and go install.

The quickest method on macOS or Linux:

Terminal window
brew install hookbridge/tap/hb

Verify the installation:

Terminal window
hb version

Authenticate with your HookBridge API key:

Terminal window
hb login

You will be prompted to enter your API key. The CLI verifies the key and saves credentials locally. See Config File for the location on each platform.

You can also pass the key non-interactively:

Terminal window
hb login --api-key YOUR_API_KEY

Start your local server, then run:

Terminal window
hb listen --port 3000

The CLI will:

  1. Find or create a CLI-mode inbound endpoint in your project.
  2. Print a Webhook URL — copy this into your webhook provider’s settings.
  3. Connect and wait for webhooks.
HookBridge CLI v1.0.0
Endpoint: CLI Endpoint (ie_abc123)
Webhook URL: https://receive.hookbridge.io/v1/webhooks/receive/ie_abc123/sk_xyz789
Paste this URL into your webhook provider's settings.
Forwarding to http://localhost:3000
Ready. Waiting for webhooks...

From another terminal, send a test request to the Webhook URL printed above:

Terminal window
curl -X POST "https://receive.hookbridge.io/v1/webhooks/receive/YOUR_ENDPOINT_ID/YOUR_SECRET" \
-H "Content-Type: application/json" \
-d '{"event":"test","data":{"id":"123"}}'

You should see the webhook arrive in your CLI output:

12:34:01 POST → 200 89ms application/json (42 bytes)

Replace the test curl with a real webhook provider:

  1. Go to your provider’s webhook settings (Stripe Dashboard, GitHub repo settings, etc.).
  2. Set the webhook URL to the Webhook URL from hb listen.
  3. Trigger an event in the provider.
  4. Watch the webhook arrive in your terminal and hit your local server.

The Webhook URL is stable across sessions — you do not need to update your provider settings each time you restart the CLI.

To view webhooks without forwarding them to a local server:

Terminal window
hb listen --no-forward

To see full headers and body for each webhook:

Terminal window
hb listen --port 3000 --verbose
Personalize Examples

Enter your credentials to populate code examples throughout the docs.