Skip to main content
Register an HTTPS endpoint for an org, and InstaBox POSTs a signed JSON event to it when one of the org’s machines or snapshots changes state. You do not need to poll GET /v1/machines/{id}.
  • Without --event, the endpoint subscribes to every type. The types are under Reference.
  • create and rotate print the signing secret (whsec_…) once.
  • The URL must be public https. Redirects are not followed.
  • The dashboard’s Webhooks page does the same, with a delivery log.
The org’s owner or admin can, signed in or with an API key of that org. machines:read lists and reads deliveries, machines:write creates, updates, rotates, tests, and retries, and machines:delete deletes. With INSTABOX_API_KEY set, --org defaults to the key’s org. GET /v1/orgs lists your orgs, and an API key sees only its own.Every webhooks subcommand takes --json or -o json, including events, rm, test, and retry. The routes are under /v1/orgs/{id}/webhooks in the API reference.

Verify the signature

Requests follow Standard Webhooks, so its libraries verify them.
After a rotation, the header lists two signatures for 24 hours. Accept either, and compare in constant time.

Answer each delivery in time

Answer 2xx within 10 seconds of connecting: reply first, then do the work.
  • Order: one machine’s events arrive in order, also across retries. A later event waits while an earlier one is retried. Events of different machines interleave, so order those by createdAt.
  • Retries: any other answer, and a timeout, is retried after 5 s, 5 min, 30 min, 2 h, 5 h, 10 h, and 10 h. Then the delivery fails. A delivery still pending 3 days after its event fails as expired. instabox webhooks retry sends a finished one again.
  • Log: deliveries are kept 30 days.
An endpoint that fails every attempt for 5 days is disabled, and the workspace’s owner and admins get an email. To turn it back on, run instabox webhooks update ID --enable.

Reference

Events

Event body

reason says what moved the machine. Its values include user, idle, archive, wake, and system (observed by the server, such as a crash).

Lifecycle

The states these events report.

Auto-pause and max-run

Why a machine pauses when idle or at a plan limit.