# Billing Budgets V1beta1 API - Class Google::Cloud::Billing::Budgets::V1beta1::Budget (v0.17.0)

0.17.0 (latest) 0.16.1 0.15.0 0.14.1 0.13.0 0.12.1 0.11.2 0.10.0 0.9.0 0.8.0 0.7.0 0.6.5 Reference documentation and code samples for the Billing Budgets V1beta1 API class Google::Cloud::Billing::Budgets::V1beta1::Budget.

A budget is a plan that describes what you expect to spend on Cloud
projects, plus the rules to execute as spend is tracked against that plan,
(for example, send an alert when 90% of the target spend is met).
The budget time period is configurable, with options such as month (default),
quarter, year, or custom time period.

## Inherits

- Object

## Extended By

- Google::Protobuf::MessageExts::ClassMethods

## Includes

- Google::Protobuf::MessageExts

## Methods

### #all_updates_rule

    def all_updates_rule() -> ::Google::Cloud::Billing::Budgets::V1beta1::AllUpdatesRule

**Returns**

- ([::Google::Cloud::Billing::Budgets::V1beta1::AllUpdatesRule](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-billing-budgets-v1beta1/latest/Google-Cloud-Billing-Budgets-V1beta1-AllUpdatesRule)) --- Optional. Rules to apply to notifications sent based on budget spend and thresholds.

### #all_updates_rule=

    def all_updates_rule=(value) -> ::Google::Cloud::Billing::Budgets::V1beta1::AllUpdatesRule

**Parameter**

- **value** ([::Google::Cloud::Billing::Budgets::V1beta1::AllUpdatesRule](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-billing-budgets-v1beta1/latest/Google-Cloud-Billing-Budgets-V1beta1-AllUpdatesRule)) --- Optional. Rules to apply to notifications sent based on budget spend and thresholds.
**Returns**

- ([::Google::Cloud::Billing::Budgets::V1beta1::AllUpdatesRule](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-billing-budgets-v1beta1/latest/Google-Cloud-Billing-Budgets-V1beta1-AllUpdatesRule)) --- Optional. Rules to apply to notifications sent based on budget spend and thresholds.

### #amount

    def amount() -> ::Google::Cloud::Billing::Budgets::V1beta1::BudgetAmount

**Returns**

- ([::Google::Cloud::Billing::Budgets::V1beta1::BudgetAmount](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-billing-budgets-v1beta1/latest/Google-Cloud-Billing-Budgets-V1beta1-BudgetAmount)) --- Required. Budgeted amount.

### #amount=

    def amount=(value) -> ::Google::Cloud::Billing::Budgets::V1beta1::BudgetAmount

**Parameter**

- **value** ([::Google::Cloud::Billing::Budgets::V1beta1::BudgetAmount](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-billing-budgets-v1beta1/latest/Google-Cloud-Billing-Budgets-V1beta1-BudgetAmount)) --- Required. Budgeted amount.
**Returns**

- ([::Google::Cloud::Billing::Budgets::V1beta1::BudgetAmount](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-billing-budgets-v1beta1/latest/Google-Cloud-Billing-Budgets-V1beta1-BudgetAmount)) --- Required. Budgeted amount.

### #budget_filter

    def budget_filter() -> ::Google::Cloud::Billing::Budgets::V1beta1::Filter

**Returns**

- ([::Google::Cloud::Billing::Budgets::V1beta1::Filter](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-billing-budgets-v1beta1/latest/Google-Cloud-Billing-Budgets-V1beta1-Filter)) --- Optional. Filters that define which resources are used to compute the actual spend against the budget amount, such as projects, services, and the budget's time period, as well as other filters.

### #budget_filter=

    def budget_filter=(value) -> ::Google::Cloud::Billing::Budgets::V1beta1::Filter

**Parameter**

- **value** ([::Google::Cloud::Billing::Budgets::V1beta1::Filter](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-billing-budgets-v1beta1/latest/Google-Cloud-Billing-Budgets-V1beta1-Filter)) --- Optional. Filters that define which resources are used to compute the actual spend against the budget amount, such as projects, services, and the budget's time period, as well as other filters.
**Returns**

- ([::Google::Cloud::Billing::Budgets::V1beta1::Filter](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-billing-budgets-v1beta1/latest/Google-Cloud-Billing-Budgets-V1beta1-Filter)) --- Optional. Filters that define which resources are used to compute the actual spend against the budget amount, such as projects, services, and the budget's time period, as well as other filters.

### #display_name

    def display_name() -> ::String

**Returns**

- (::String) --- User data for display name in UI. Validation: \<= 60 chars.

### #display_name=

    def display_name=(value) -> ::String

**Parameter**

- **value** (::String) --- User data for display name in UI. Validation: \<= 60 chars.
**Returns**

- (::String) --- User data for display name in UI. Validation: \<= 60 chars.

### #etag

    def etag() -> ::String

**Returns**

- (::String) --- Optional. Etag to validate that the object is unchanged for a read-modify-write operation. An empty etag will cause an update to overwrite other changes.

### #etag=

    def etag=(value) -> ::String

**Parameter**

- **value** (::String) --- Optional. Etag to validate that the object is unchanged for a read-modify-write operation. An empty etag will cause an update to overwrite other changes.
**Returns**

- (::String) --- Optional. Etag to validate that the object is unchanged for a read-modify-write operation. An empty etag will cause an update to overwrite other changes.

### #name

    def name() -> ::String

**Returns**

- (::String) --- Output only. Resource name of the budget. The resource name implies the scope of a budget. Values are of the form `billingAccounts/{billingAccountId}/budgets/{budgetId}`.

### #threshold_rules

    def threshold_rules() -> ::Array<::Google::Cloud::Billing::Budgets::V1beta1::ThresholdRule>

**Returns**

- (::Array\<[::Google::Cloud::Billing::Budgets::V1beta1::ThresholdRule](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-billing-budgets-v1beta1/latest/Google-Cloud-Billing-Budgets-V1beta1-ThresholdRule)\>) --- Optional. Rules that trigger alerts (notifications of thresholds being crossed) when spend exceeds the specified percentages of the budget.


  Optional for `pubsubTopic` notifications.

  Required if using email notifications.

### #threshold_rules=

    def threshold_rules=(value) -> ::Array<::Google::Cloud::Billing::Budgets::V1beta1::ThresholdRule>

**Parameter**

- **value** (::Array\<[::Google::Cloud::Billing::Budgets::V1beta1::ThresholdRule](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-billing-budgets-v1beta1/latest/Google-Cloud-Billing-Budgets-V1beta1-ThresholdRule)\>) --- Optional. Rules that trigger alerts (notifications of thresholds being crossed) when spend exceeds the specified percentages of the budget.


  Optional for `pubsubTopic` notifications.

  Required if using email notifications.
**Returns**

- (::Array\<[::Google::Cloud::Billing::Budgets::V1beta1::ThresholdRule](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-billing-budgets-v1beta1/latest/Google-Cloud-Billing-Budgets-V1beta1-ThresholdRule)\>) --- Optional. Rules that trigger alerts (notifications of thresholds being crossed) when spend exceeds the specified percentages of the budget.


  Optional for `pubsubTopic` notifications.

  Required if using email notifications.