Dashboard
Alerts

Create Alert

Create Alert

POST/v2/alerts

Create an alert. The signing secret plaintext is returned in this response only — store it now or rotate it later.

Request Body

scope_levelstring · team | group | orchestration | agent | threadrequired
scope_idstring · uuidrequired
event_typestringrequired
action_typestringoptional
webhookobjectrequired

Webhook config supplied by the caller on create.

webhook.urlstring · urirequired
namestringoptional
enabledbooleanoptional
group_idobjectoptional
Request
curl --request POST \
  --url https://api.brainbaselabs.com/v2/alerts \
  --header 'Authorization: Bearer YOUR_API_KEY' \
  --header 'Content-Type: application/json' \
  --data '{
  "scope_level": "team",
  "scope_id": "5d3fe357-12dd-4f62-b004-6d1fb3b8454f",
  "event_type": "string",
  "action_type": "webhook",
  "webhook": {
    "url": "http://example.com"
  },
  "name": "",
  "enabled": true,
  "group_id": "306db4e0-7449-4501-b76f-075576fe2d8f"
}'
Response
json
{
  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "team_id": "810007d0-bec5-486c-b5d1-28fcd8a079ba",
  "group_id": "306db4e0-7449-4501-b76f-075576fe2d8f",
  "scope_level": "team",
  "scope_id": "5d3fe357-12dd-4f62-b004-6d1fb3b8454f",
  "event_type": "string",
  "action_type": "webhook",
  "webhook": {
    "url": "string",
    "secret_prefix": "string"
  },
  "name": "string",
  "enabled": true,
  "created_by": "ee824cad-d7a6-4f48-87dc-e8461a9201c4",
  "signing_secret": "string"
}