Introduction
APIs
- Authentication
- Customers
- Accounts
- Aliases
- Event Schemas
- Usage Meters
- AddOns
- Licenses
- Feature
- (Deprecated) Price Plans
- Price Plan V2
- Settings
- Price Experimentation
- Jobs
- Event Ingestion
- Entitlements
- Event Management
- Metrics
- Credits
- Invoices
- Payments
- Wallet
- InvoiceGroups
- Alerts
- Reports
Alerts
Create an alert
Create an alert
POST
/
alerts
curl --request POST \
--url https://api.togai.com/alerts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"alertTemplateId": "abcd-efgh-ijkl-mnop",
"interval": "30",
"entityDetails": {
"usageMeterId": "um.1zYnCiM9Bpg.lv25y"
},
"ownerDetails": {
"accountId": "account_1"
},
"parameters": {
"threshold": 10
}
}'
{
"id": "alert.1zYnCiM9Bpg.lv25y",
"version": 1,
"alertId": "alert.1zYnCiM9Bpg.lv25y",
"description": "Alert1 Description",
"cronInterval": "30",
"ownerDetails": {
"accountId": "account_1"
},
"entityDetails": {
"usageMeterId": "um.1zYnCiM9Bpg.lv25y"
},
"parameters": {
"threshold": 10
},
"status": "ACTIVE",
"createdAt": "2020-01-01T00:00:00Z",
"updatedAt": "2020-01-01T00:00:00Z"
}
Authorizations
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Body
application/json
Payload to install an alert
The body is of type object
.
Response
200
application/json
Response for install alert request
The response is of type object
.
curl --request POST \
--url https://api.togai.com/alerts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"alertTemplateId": "abcd-efgh-ijkl-mnop",
"interval": "30",
"entityDetails": {
"usageMeterId": "um.1zYnCiM9Bpg.lv25y"
},
"ownerDetails": {
"accountId": "account_1"
},
"parameters": {
"threshold": 10
}
}'
{
"id": "alert.1zYnCiM9Bpg.lv25y",
"version": 1,
"alertId": "alert.1zYnCiM9Bpg.lv25y",
"description": "Alert1 Description",
"cronInterval": "30",
"ownerDetails": {
"accountId": "account_1"
},
"entityDetails": {
"usageMeterId": "um.1zYnCiM9Bpg.lv25y"
},
"parameters": {
"threshold": 10
},
"status": "ACTIVE",
"createdAt": "2020-01-01T00:00:00Z",
"updatedAt": "2020-01-01T00:00:00Z"
}
Assistant
Responses are generated using AI and may contain mistakes.