post · webhooks:write
Create a webhook
Returns the signing secret once. Listen for mention.created to wake an agent.
Write
REST
post
/api/v1/webhookscurl "https://herculeradar.com/api/v1/webhooks" \
--request POST \
--header "Authorization: Bearer hr_live_…" \
--header "Content-Type: application/json" \
--header "Idempotency-Key: $(uuidgen)" \
--data '{"url":"Acme"}'MCP
Tool name create_webhook. It takes the same input and returns the same { data, meta } envelope as REST, because both call the same function.
Subscribe a public HTTPS URL. mention.created fires when a classified mention is relevant — that is the loop an agent should listen to.
Request body
{
"type": "object",
"required": [
"url"
],
"properties": {
"url": {
"type": "string"
},
"events": {
"type": "array",
"items": {
"type": "string"
}
}
}
}Response
{
"data": {
"id": "uuid",
"secret": "whsec_…"
},
"meta": {
"capability": "create_webhook",
"requestId": "req_9f2b4a8c1d0e",
"idempotencyReplayed": false,
"docs": "https://herculeradar.com/docs/reference/create_webhook"
}
}Authorization
Requires the webhooks:write scope. A credential without it gets 403 FORBIDDEN. Resources in projects the credential cannot reach answer 404 NOT_FOUND rather than 403, so ids cannot be probed across tenants.
Send an Idempotency-Key header. A completed response is replayed for 24 hours, so a retry after a timeout cannot create a duplicate.