Browse the docs

GET /hooks

Lists the webhook routes macros listen on, with their methods, auth, reach, macros and the last request.

Details #

Each row has the route, the accepted methods, the auth kinds in use, the widest reach, whether a route waits for a reply, the macros that listen, the local url, a lanUrl for network routes, and last, the most recent request (time, method, status, sender, query and body preview). Needs the token on loopback.

[{ "route": "build-done", "methods": ["POST"], "auth": ["token"], "reach": "local", "reply": "accepted",
   "macros": [{ "id": "m_1", "name": "Notify", "enabled": true }], "url": "http://127.0.0.1:48080/hooks/build-done" }]

Per-route keys are managed beside it: GET /webhooks/key?route=, POST /webhooks/rotate {route} (the old key stops at once), POST /webhooks/key {route, key} (restores one), GET / DELETE /webhooks/lockouts, and GET /webhooks/relay (the internet relay's state, plus held, expired and replay while the server holds requests for this Mac) with DELETE /webhooks/held to discard them.

Parameters #

curl --unix-socket "$SWITCHBOARD_HOME/engine.sock" -X GET http://localhost/hooks

The webhook routes macros listen on, with methods, auth, reach and the last request. The Unix socket needs no token; loopback 127.0.0.1:48080 needs Authorization: Bearer <api-token>.

See also #