ROKIConnect
Connectors Start API SDKs Migrate MCP Portal ES
DocumentationManaging the webhook endpoint by API

Managing the webhook endpoint by API

Everything the portal's Webhooks tab does, with the secret key. One endpoint per environment: sk_test_* manages sandbox, sk_live_* production.

Call Does Idempotency-Key
GET /webhooks
Read the endpoint (secret masked)
-
POST /webhooks
Create (201, full whsec_* once) or change the URL (200, masked)
required
POST /webhooks/rotate-secret
New secret, shown once
required
POST /webhooks/disable / enable
Pause / resume delivery
-
POST /webhooks/test
Send a signed webhook.test ping
-
GET /webhooks/deliveries
Recent delivery attempts (status, page, per_page)
-

Verified 2026-10-28: GET /webhooks and GET /webhooks/deliveries answer 404 webhook_not_found when none is configured, and the documented shapes when one is (read in production, read only). POST /webhooks without a key answers 422 idempotency_key_required, and with an http:// URL 422 webhook_url_https. Create, rotate, disable, enable and test were not run: on a merchant with a live integration they would replace its URL or break its signature verification.

What to get right:

A connector can now set itself up end to end: GET /me to show "Connected as {business_name} (sandbox|live)", POST /webhooks with its own callback URL, store the whsec_*, then POST /webhooks/test to prove the signature check accepts ROKI's real signature.