GoRunner

Revoke the public webhook URL and issue a new one

Requires scope workflow:write
POST
/api/workflows/{id}/webhook/rotate

This is the revocation path for the webhook token. The token is a bearer capability: POST /api/webhooks/{token} is UNAUTHENTICATED, so anyone who has the URL can start production runs of this workflow. Once it leaks, rotating is the only way to take it back.

The old address stops working the instant this returns — anything still sending to it starts receiving 404. Re-point every producer at the new URL before rotating, or accept the gap.

What a caller must know:

  • Only a workflow whose triggerType is webhook has a URL to rotate; anything else is a 409 CONFLICT, not a silent no-op.
  • The new token is returned ONCE here as webhookToken. It is also readable afterwards from GET /api/workflows/{id} — but only by a credential holding workflow:run; below that the field is redacted, and the workflow LIST never carries it at all.
  • The full public URL is the API's public base + /api/webhooks/ + the token.
  • Rotating does NOT re-register the new URL with a self-registering trigger piece; re-publish to do that.
  • No request body is read.

Authorization

bearerAuth
AuthorizationBearer <token>

An API token: Authorization: Bearer grt_…. Mint one in the app under Settings → Workspace → API tokens; the raw value is shown once. Scopes confine the token — see x-permission on each operation.

In: header

Path Parameters

id*string

Workflow id (UUID).

Formatuuid

Header Parameters

Idempotency-Key?string

Opt-in replay protection, ≤255 characters. A retry carrying the same key and the same method+path+query+body replays the original response with Idempotency-Replayed: true instead of rotating a second time (which would strand the URL the first response returned). Same key with a different request is 422; a key whose first request is still in flight is 409. Records live 24h.

Lengthlength <= 255

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/api/workflows/497f6eca-6276-4993-bfeb-53cbbbba6f08/webhook/rotate"
{  "data": {    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",    "webhookToken": "string"  }}