CLI
Minimal CLI for local DX. Emit test messages and forward deliveries to a local process while you iterate on verify logic.
Local DX
Trigger emits via the API. Listen binds 127.0.0.1 and forwards only to loopback. Verify checks Standard Webhooks HMAC from stdin.
Install / run
From the repo (or any checkout that includes cli/outemit.mjs):
bash
# run directly
node cli/outemit.mjs --helpoutemit trigger
POST a message to /api/v1/messages using your API key. Equivalent to the Getting started curl, with flags.
bash
export OUTEMIT_API_KEY=sk_test_...
export OUTEMIT_BASE_URL=https://outemit.dev # optional
node cli/outemit.mjs trigger \
--app app_01HXYZ \
--type invoice.paid \
--payload '{"id":"inv_1","amount":4900}' \
--idempotency demo-1outemit listen --forward
Local helper that prints a target URL and forwards inbound POST bodies to your app. Use it with a tunnel that points at the listen port, or point a Test endpoint at http://localhost:<port> directly.
bash
# listen on :4242 and forward to your receiver
node cli/outemit.mjs listen --forward http://127.0.0.1:3000/webhooks --port 4242
# then set the Outemit Test endpoint URL to:
# http://localhost:4242/ (or your tunnel URL → :4242)The listen process binds 127.0.0.1 and will only forward to localhost / 127.0.0.1 / ::1.
outemit verify
Pipe the exact raw body Outemit signed. Prints the expected v1 signature, or checks --sig.
bash
printf '%s' '{"ok":true}' | node cli/outemit.mjs verify \
--secret whsec_... \
--id evt_01HABC \
--timestamp 1700000000 \
--sig 'v1,...'Environment variables
OUTEMIT_API_KEY– required fortriggerOUTEMIT_BASE_URL– defaulthttps://outemit.devOUTEMIT_APP_ID– default app id for trigger