Creating a Budget Alert Rule
Create an alert rule for a budget in Billing and Cost Management.
- Open the navigation menu and click Billing & Cost Management. Under Cost Management, click Budgets.
- On the Budgets page, select the budget scope, if necessary.
- Click the name of the budget that you want to create an alert for.
- On the budget details page, in the Budget Alert Rules section, click Create Budget Alert Rule.
- In the Create Budget Alert Rule dialog box, configure the alert rule:
- For Threshold Metric, select a threshold for the alert:
-
Actual Spend watches the actual amount you spent in the compartment per month.
-
Forecast Spend watches resource usage and alerts you when it appears that the budget will be exceeded.
The forecast algorithm is of linear extrapolation and the formula is as follows:
(Actual Spend / Days processed from the start of the budget period) * Days of the budget period
The forecast algorithm requires at least three days of consumption to trigger, and the forecast spend is evaluated hourly.
-
- Select an option for Threshold Type:
- Percentage of Budget: A percentage of the monthly budget, which must be greater than 0 but no greater than 10,000.
- Absolute Amount: A fixed amount.
The label of the next text field changes depending on which option you select.
- Enter a value for either Threshold % or Threshold Amount.
- Optionally, in the Email Recipients field, enter one or more email addresses to receive the alerts. Separate multiple addresses by using a comma, semicolon, space, tab, or new line.
- Optionally, enter the body of the email alert in the Email Message field. The text of the email message can't exceed 1,000 characters. This message is included with metadata about the budget, including the budget name, the compartment, and the amount of the monthly budget. You can use this message, for example, to provide instructions to the recipient, that explain how to request a budget increase or to remind users about corporate policies.
- For Threshold Metric, select a threshold for the alert:
- Click Create.
The alert rule appears in the list of Budget Alert Rules.
Use the oci budgets alert-rule create command and required parameters to create a budget alert rule:
oci budgets alert-rule create --budget-id budget_ocid --threshold threshold threshold-type --threshold_type --type type [OPTIONS]
For a complete list of parameters and variable options for CLI commands, see the Command Line Reference.
Run the CreateAlertRule operation to create a budget alert rule.