bachs CLI
Forward live webhook events to your local machine. No tunnel, no public URL, no third-party account.
Install
pip install bachs-cli
# or, without installing:
pipx run bachs-cli listen --forward-to localhost:3000/webhooks
Use
bachs login --api-key sk_sandbox_...
bachs listen --forward-to localhost:3000/webhooks
Every delivery prints as it arrives — event type, the status your handler returned, and how long it took:
Ready! Forwarding sandbox events to http://localhost:3000/webhooks
Your webhook signing secret is whsec_a1b2c3... (^C to quit)
Session whls_8f2e… · 26 event type(s)
✓ collection.succeeded evt_3ab4e0d5 200 [42ms]
✗ refund.paid evt_7c1f22a9 500 [131ms]
Narrow it down:
bachs listen --forward-to localhost:3000/webhooks --events collection.succeeded,refund.paid
Redeliver something that already happened. This needs no session and no socket — it works against your registered endpoints too:
bachs events replay evt_3ab4e0d5d27445cf8a52ab3d8cb8f0b1
How it works
The connection is opened outbound from your machine, so nothing needs to reach you: no public URL, no inbound port, and it works behind NAT and corporate firewalls.
Each session gets its own signing secret, printed when it starts. Payloads are genuinely signed with it, so your verification code is exercised for real — and your production endpoint's secret never leaves production.
A session is a webhook destination like any other, so event filtering, delivery records and the dashboard all work the same way.
Environments
The API key prefix picks the environment: sk_sandbox_ for sandbox,
sk_live_ for production. There is no --env flag to get out of step with the
key you are using.
Notes
- Deliveries to a session are not retried. If your handler is down or your laptop is asleep, the event is dropped and shown as failed — you are watching the terminal, and a backlog arriving tomorrow would not help.
- Credentials are stored at
~/.config/bachs/config.json, mode 0600. SetBACHS_API_KEYinstead if you would rather not write a key to disk.
Metadata
Release files for bachs-cli 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| bachs_cli-0.1.0.tar.gz | 10.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| bachs_cli-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 21.1 kB
Release files / bachs_cli-0.1.0.tar.gz
| Download URL | bachs_cli-0.1.0.tar.gz |
|---|---|
| Size | 10.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
db62a76c035d36c2464472ccfcd9bb7c971246f7b6ebfdfa71d2c5804be6087c
|
|
BLAKE2b-256 checksum How to use checksums |
6798939bed14f4d0aa378da928ca1e567b710b49c3282f408e745790e4815663
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.11
|
Release files / bachs_cli-0.1.0-py3-none-any.whl
| Download URL | bachs_cli-0.1.0-py3-none-any.whl |
|---|---|
| Size | 10.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ed46ec148b1036ffb8e0f8f3c6d1e73cfd474b621812c2f911b62469930cdd04
|
|
BLAKE2b-256 checksum How to use checksums |
9509e9c9d899694a60c1838246b658e0145f5202ba0a4b1c5158dc8b378fe40c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.11
|