import * as pulumi from "@pulumi/pulumi"; /** * This resource provides the Alert Rule resource in Oracle Cloud Infrastructure Budget service. * Api doc link for the resource: https://docs.oracle.com/iaas/api/#/en/budgets/latest/AlertRule * * Example terraform configs related to the resource : https://github.com/oracle/terraform-provider-oci/tree/master/examples/budget * * Creates a new Alert Rule. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as oci from "@pulumi/oci"; * * const testAlertRule = new oci.budget.Rule("test_alert_rule", { * budgetId: testBudget.id, * threshold: alertRuleThreshold, * thresholdType: alertRuleThresholdType, * type: alertRuleType, * definedTags: { * "Operations.CostCenter": "42", * }, * description: alertRuleDescription, * displayName: alertRuleDisplayName, * freeformTags: { * Department: "Finance", * }, * message: alertRuleMessage, * recipients: alertRuleRecipients, * }); * ``` * * ## Import * * AlertRules can be imported using the `id`, e.g. * * ```sh * $ pulumi import oci:Budget/rule:Rule test_alert_rule "budgets/{budgetId}/alertRules/{alertRuleId}" * ``` */ export declare class Rule extends pulumi.CustomResource { /** * Get an existing Rule resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input, state?: RuleState, opts?: pulumi.CustomResourceOptions): Rule; /** * Returns true if the given object is an instance of Rule. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is Rule; /** * The unique budget OCID. */ readonly budgetId: pulumi.Output; /** * (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). Example: `{"Operations.CostCenter": "42"}` */ readonly definedTags: pulumi.Output<{ [key: string]: string; }>; /** * (Updatable) The description of the alert rule. */ readonly description: pulumi.Output; /** * (Updatable) The name of the alert rule. Avoid entering confidential information. */ readonly displayName: pulumi.Output; /** * (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). Example: `{"Department": "Finance"}` */ readonly freeformTags: pulumi.Output<{ [key: string]: string; }>; /** * (Updatable) The message to be sent to the recipients when the alert rule is triggered. */ readonly message: pulumi.Output; /** * (Updatable) The audience that receives the alert when it triggers. An empty string is interpreted as null. */ readonly recipients: pulumi.Output; /** * The current state of the alert rule. */ readonly state: pulumi.Output; /** * (Updatable) The threshold for triggering the alert, expressed as a whole number or decimal value. If the thresholdType is ABSOLUTE, the threshold can have at most 12 digits before the decimal point, and up to two digits after the decimal point. If the thresholdType is PERCENTAGE, the maximum value is 10000 and can have up to two digits after the decimal point. */ readonly threshold: pulumi.Output; /** * (Updatable) The type of threshold. */ readonly thresholdType: pulumi.Output; /** * The time when the budget was created. */ readonly timeCreated: pulumi.Output; /** * The time when the budget was updated. */ readonly timeUpdated: pulumi.Output; /** * (Updatable) The type of the alert. Valid values are ACTUAL (the alert triggers based on actual usage), or FORECAST (the alert triggers based on predicted usage). * * ** IMPORTANT ** * Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values */ readonly type: pulumi.Output; /** * The version of the alert rule. Starts from 1 and increments by 1. */ readonly version: pulumi.Output; /** * Create a Rule resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: RuleArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering Rule resources. */ export interface RuleState { /** * The unique budget OCID. */ budgetId?: pulumi.Input; /** * (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). Example: `{"Operations.CostCenter": "42"}` */ definedTags?: pulumi.Input<{ [key: string]: pulumi.Input; } | undefined>; /** * (Updatable) The description of the alert rule. */ description?: pulumi.Input; /** * (Updatable) The name of the alert rule. Avoid entering confidential information. */ displayName?: pulumi.Input; /** * (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). Example: `{"Department": "Finance"}` */ freeformTags?: pulumi.Input<{ [key: string]: pulumi.Input; } | undefined>; /** * (Updatable) The message to be sent to the recipients when the alert rule is triggered. */ message?: pulumi.Input; /** * (Updatable) The audience that receives the alert when it triggers. An empty string is interpreted as null. */ recipients?: pulumi.Input; /** * The current state of the alert rule. */ state?: pulumi.Input; /** * (Updatable) The threshold for triggering the alert, expressed as a whole number or decimal value. If the thresholdType is ABSOLUTE, the threshold can have at most 12 digits before the decimal point, and up to two digits after the decimal point. If the thresholdType is PERCENTAGE, the maximum value is 10000 and can have up to two digits after the decimal point. */ threshold?: pulumi.Input; /** * (Updatable) The type of threshold. */ thresholdType?: pulumi.Input; /** * The time when the budget was created. */ timeCreated?: pulumi.Input; /** * The time when the budget was updated. */ timeUpdated?: pulumi.Input; /** * (Updatable) The type of the alert. Valid values are ACTUAL (the alert triggers based on actual usage), or FORECAST (the alert triggers based on predicted usage). * * ** IMPORTANT ** * Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values */ type?: pulumi.Input; /** * The version of the alert rule. Starts from 1 and increments by 1. */ version?: pulumi.Input; } /** * The set of arguments for constructing a Rule resource. */ export interface RuleArgs { /** * The unique budget OCID. */ budgetId: pulumi.Input; /** * (Updatable) Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). Example: `{"Operations.CostCenter": "42"}` */ definedTags?: pulumi.Input<{ [key: string]: pulumi.Input; } | undefined>; /** * (Updatable) The description of the alert rule. */ description?: pulumi.Input; /** * (Updatable) The name of the alert rule. Avoid entering confidential information. */ displayName?: pulumi.Input; /** * (Updatable) Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see [Resource Tags](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm). Example: `{"Department": "Finance"}` */ freeformTags?: pulumi.Input<{ [key: string]: pulumi.Input; } | undefined>; /** * (Updatable) The message to be sent to the recipients when the alert rule is triggered. */ message?: pulumi.Input; /** * (Updatable) The audience that receives the alert when it triggers. An empty string is interpreted as null. */ recipients?: pulumi.Input; /** * (Updatable) The threshold for triggering the alert, expressed as a whole number or decimal value. If the thresholdType is ABSOLUTE, the threshold can have at most 12 digits before the decimal point, and up to two digits after the decimal point. If the thresholdType is PERCENTAGE, the maximum value is 10000 and can have up to two digits after the decimal point. */ threshold: pulumi.Input; /** * (Updatable) The type of threshold. */ thresholdType: pulumi.Input; /** * (Updatable) The type of the alert. Valid values are ACTUAL (the alert triggers based on actual usage), or FORECAST (the alert triggers based on predicted usage). * * ** IMPORTANT ** * Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values */ type: pulumi.Input; } //# sourceMappingURL=rule.d.ts.map