curl -X PATCH https://agentgate.mynewapi.com/v1/webhooks/wh_abc123 \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"events": ["run.completed", "run.failed", "run.cancelled"],
"enabled": true
}'
{
"id": "wh_abc123",
"url": "https://your-app.com/webhooks/agentgate",
"events": ["run.completed", "run.failed", "run.cancelled"],
"enabled": true,
"description": "Production webhook",
"createdAt": "2024-01-15T10:30:00Z",
"updatedAt": "2024-01-15T11:00:00Z"
}
Update webhook configuration
curl -X PATCH https://agentgate.mynewapi.com/v1/webhooks/wh_abc123 \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"events": ["run.completed", "run.failed", "run.cancelled"],
"enabled": true
}'
{
"id": "wh_abc123",
"url": "https://your-app.com/webhooks/agentgate",
"events": ["run.completed", "run.failed", "run.cancelled"],
"enabled": true,
"description": "Production webhook",
"createdAt": "2024-01-15T10:30:00Z",
"updatedAt": "2024-01-15T11:00:00Z"
}
curl -X PATCH https://agentgate.mynewapi.com/v1/webhooks/wh_abc123 \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"events": ["run.completed", "run.failed", "run.cancelled"],
"enabled": true
}'
{
"id": "wh_abc123",
"url": "https://your-app.com/webhooks/agentgate",
"events": ["run.completed", "run.failed", "run.cancelled"],
"enabled": true,
"description": "Production webhook",
"createdAt": "2024-01-15T10:30:00Z",
"updatedAt": "2024-01-15T11:00:00Z"
}