## Regenerate a worker webhook token **post** `/api/workers/{workerId}/webhook/regenerate-token` Issue a new shared token for the webhook, invalidating the previous one. The webhook URL is preserved. Only the worker creator can regenerate the token. ### Path Parameters - `workerId: string` ### Returns - `Webhook object { token, url }` - `token: string` Shared secret sent in the `X-Handinger-Token` header on each delivery. `null` when no webhook is configured. - `url: string` HTTPS endpoint that receives webhook deliveries when a task completes. `null` when no webhook is configured. ### Example ```http curl https://handinger.com/api/workers/$WORKER_ID/webhook/regenerate-token \ -X POST \ -H "Authorization: Bearer $HANDINGER_API_KEY" ``` #### Response ```json { "token": "whk_01HZY31W2SZJ8MJ2FQTR3M1K9D", "url": "https://example.com/handinger-webhook" } ```