Cost Alerts
List cost alerts
Returns all cost alerts for a workspace.
Needs a token with viewCosts on the workspace.
query Parameters
workspaceId^wsp_[A-Za-z0-9_-]{2… · requiredpageThe page to return, counted from 1. A page below 1 reads page 1; one past the last returns no items.
limitItems per page, from 1 to 100. A larger value is clamped to 100, a smaller one to 1.
List cost alerts › Responses
Success
Create cost alert
Creates a new cost alert. thresholdType sets what thresholdValue measures: absolute, the increase in cost against comparisonPeriod, in the alert's currency; percentageIncrease, that increase as a percentage; budgetPercentage, the month-to-date spend, from the 1st of the month through the last settled day, reaching thresholdValue in the alert's currency; tagCoverageBelow, the workspace's tag coverage falling below thresholdValue percent. budgetPercentage references no budget; its name is kept for compatibility.
Needs a token with manageAlerts on the workspace.
Headers
Idempotency-KeyA unique value, at most 255 printable ASCII characters, such as a UUID, that makes retrying this create safe. A retry with the same key and the same request within 24 hours answers the first response again, marked Idempotent-Replayed: true, and creates nothing; the same key with another request answers 422 idempotency_key_reused. A key is kept only for a create that succeeded. Without it, every request creates.
Create cost alert › Request Body
workspaceId^wsp_[A-Za-z0-9_-]{2… · requirednamethresholdTypethresholdValue^-?[0-9]+(\.[0-9]{1,… · requiredminimumAmount^-?[0-9]+(\.[0-9]{1,…providerIdsfilterappIdsevaluationFrequencyMinutesCreate cost alert › Responses
Created
id^alrt_[A-Za-z0-9_-]{… · requirednameGet cost alert
Returns a specific cost alert.
Needs a token with viewCosts on the workspace.
path Parameters
alertId^alrt_[A-Za-z0-9_-]{… · requiredquery Parameters
workspaceId^wsp_[A-Za-z0-9_-]{2… · requiredGet cost alert › Responses
Success
id^alrt_[A-Za-z0-9_-]{… · requirednamethresholdTypethresholdValue^-?[0-9]+(\.[0-9]{1,… · requiredappIdsevaluationFrequencyMinutesstatuscreatedAtproviderIdsfiltercomparisonPeriodminimumAmount^-?[0-9]+(\.[0-9]{1,…lastEvaluatedAtupdatedAtUpdate cost alert
Updates a cost alert and returns it as stored. thresholdType sets what thresholdValue measures: absolute, the increase in cost against comparisonPeriod, in the alert's currency; percentageIncrease, that increase as a percentage; budgetPercentage, the month-to-date spend, from the 1st of the month through the last settled day, reaching thresholdValue in the alert's currency; tagCoverageBelow, the workspace's tag coverage falling below thresholdValue percent. budgetPercentage references no budget; its name is kept for compatibility.
Needs a token with manageAlerts on the workspace.
path Parameters
alertId^alrt_[A-Za-z0-9_-]{… · requiredquery Parameters
workspaceId^wsp_[A-Za-z0-9_-]{2… · requiredHeaders
If-MatchApplies the write only while the resource still has this ETag, and answers 412 precondition_failed otherwise. Without it, the last write wins.
Update cost alert › Request Body
namethresholdValue^-?[0-9]+(\.[0-9]{1,…clearComparisonPeriodminimumAmount^-?[0-9]+(\.[0-9]{1,…clearMinimumAmountproviderIdsfilterclearFilterappIdsevaluationFrequencyMinutesUpdate cost alert › Responses
Success
id^alrt_[A-Za-z0-9_-]{… · requirednamethresholdTypethresholdValue^-?[0-9]+(\.[0-9]{1,… · requiredappIdsevaluationFrequencyMinutesstatuscreatedAtproviderIdsfiltercomparisonPeriodminimumAmount^-?[0-9]+(\.[0-9]{1,…lastEvaluatedAtupdatedAtDelete cost alert
Deletes a cost alert.
Needs a token with manageAlerts on the workspace.
path Parameters
alertId^alrt_[A-Za-z0-9_-]{… · requiredquery Parameters
workspaceId^wsp_[A-Za-z0-9_-]{2… · requiredHeaders
If-MatchApplies the write only while the resource still has this ETag, and answers 412 precondition_failed otherwise. Without it, the last write wins.
Delete cost alert › Responses
No Content
Get cost alert events
Returns triggered events for a cost alert.
Needs a token with viewCosts on the workspace.
path Parameters
alertId^alrt_[A-Za-z0-9_-]{… · requiredquery Parameters
workspaceId^wsp_[A-Za-z0-9_-]{2… · requiredpageThe page to return, counted from 1. A page below 1 reads page 1; one past the last returns no items.
limitItems per page, from 1 to 100. A larger value is clamped to 100, a smaller one to 1.
Get cost alert events › Responses
Success
Pause cost alert
Pauses evaluation of a cost alert.
Needs a token with manageAlerts on the workspace.
path Parameters
alertId^alrt_[A-Za-z0-9_-]{… · requiredquery Parameters
workspaceId^wsp_[A-Za-z0-9_-]{2… · requiredHeaders
If-MatchApplies the write only while the resource still has this ETag, and answers 412 precondition_failed otherwise. Without it, the last write wins.
Pause cost alert › Responses
No Content
Resume cost alert
Resumes evaluation of a paused cost alert.
Needs a token with manageAlerts on the workspace.
path Parameters
alertId^alrt_[A-Za-z0-9_-]{… · requiredquery Parameters
workspaceId^wsp_[A-Za-z0-9_-]{2… · requiredHeaders
If-MatchApplies the write only while the resource still has this ETag, and answers 412 precondition_failed otherwise. Without it, the last write wins.
Resume cost alert › Responses
No Content