REST API
Webhooks
Manage a team's outbound webhook endpoints and read their deliveries.
See Outbound webhooks for events, payloads and signatures. User tokens only; any team member can manage endpoints.
Endpoint object
{
"id": "4e7b…",
"team_id": "8d41…",
"url": "https://example.com/hooks/aperture",
"description": "Ops alerts",
"enabled": true,
"events": ["execution.failed", "job.deployment_failed"],
"project_ids": null,
"schedule": null,
"secret": "<redacted>",
"inserted_at": "…",
"updated_at": "…",
"deliveries": [
{ "id": "…", "status": "success", "http_code": "200", "inserted_at": "…" }
]
}deliveries lists every attempt, newest first. The secret is never returned.
GET /webhooks/{team_id}
Lists the team's endpoints with their deliveries.
POST /webhooks
{
"webhook": {
"team_id": "8d41…",
"url": "https://example.com/hooks/aperture",
"secret": "whsec_<base64 of 32 random bytes>",
"enabled": true,
"events": ["execution.failed"],
"project_ids": [],
"description": "Ops alerts"
}
}| Field | Required | Notes |
|---|---|---|
team_id | yes | |
url | yes | Must be https:// on the hosted service. |
secret | yes | You generate it. Use whsec_ followed by base64 of 32 random bytes. |
enabled | yes | |
events | yes | Event names; they aren't validated, so check spelling. |
project_ids | no | Empty or omitted for the whole team. |
schedule | with cron.tick | Cron expression (UTC). |
description | no |
200 with the endpoint. When the endpoint is enabled, cron.tick and
schedule must be set together, otherwise 400.
Generate a secret, for example:
echo "whsec_$(openssl rand -base64 32)"PUT /webhooks/{id}
Same body as create, with only the fields to change.
DELETE /webhooks/{id}
204. Also stops any scheduled cron.tick deliveries.