Class: Google::Cloud::Billing::Budgets::V1::Filter

Inherits:
Object
  • Object
show all
Extended by:
Protobuf::MessageExts::ClassMethods
Includes:
Protobuf::MessageExts
Defined in:
proto_docs/google/cloud/billing/budgets/v1/budget_model.rb

Overview

A filter for a budget, limiting the scope of the cost to calculate.

Defined Under Namespace

Modules: CreditTypesTreatment Classes: LabelsEntry

Instance Attribute Summary collapse

Instance Attribute Details

#calendar_period::Google::Cloud::Billing::Budgets::V1::CalendarPeriod

Returns Optional. Specifies to track usage for recurring calendar period. For example, assume that CalendarPeriod.QUARTER is set. The budget tracks usage from April 1 to June 30, when the current calendar month is April, May, June. After that, it tracks usage from July 1 to September 30 when the current calendar month is July, August, September, so on.

Returns:

  • (::Google::Cloud::Billing::Budgets::V1::CalendarPeriod)

    Optional. Specifies to track usage for recurring calendar period. For example, assume that CalendarPeriod.QUARTER is set. The budget tracks usage from April 1 to June 30, when the current calendar month is April, May, June. After that, it tracks usage from July 1 to September 30 when the current calendar month is July, August, September, so on.



306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
# File 'proto_docs/google/cloud/billing/budgets/v1/budget_model.rb', line 306

class Filter
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Protobuf::ListValue]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Specifies how credits are applied when determining the spend for
  # threshold calculations. Budgets track the total cost minus any applicable
  # selected credits.
  # [See the documentation for a list of credit
  # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type).
  module CreditTypesTreatment
    CREDIT_TYPES_TREATMENT_UNSPECIFIED = 0

    # All types of credit are subtracted from the gross cost to determine the
    # spend for threshold calculations.
    INCLUDE_ALL_CREDITS = 1

    # All types of credit are added to the net cost to determine the spend for
    # threshold calculations.
    EXCLUDE_ALL_CREDITS = 2

    # [Credit
    # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type)
    # specified in the credit_types field are subtracted from the
    # gross cost to determine the spend for threshold calculations.
    INCLUDE_SPECIFIED_CREDITS = 3
  end
end

#credit_types::Array<::String>

Returns Optional. If Filter.credit_types_treatment is INCLUDE_SPECIFIED_CREDITS, this is a list of credit types to be subtracted from gross cost to determine the spend for threshold calculations. See a list of acceptable credit type values.

If Filter.credit_types_treatment is not INCLUDE_SPECIFIED_CREDITS, this field must be empty.

Returns:



306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
# File 'proto_docs/google/cloud/billing/budgets/v1/budget_model.rb', line 306

class Filter
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Protobuf::ListValue]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Specifies how credits are applied when determining the spend for
  # threshold calculations. Budgets track the total cost minus any applicable
  # selected credits.
  # [See the documentation for a list of credit
  # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type).
  module CreditTypesTreatment
    CREDIT_TYPES_TREATMENT_UNSPECIFIED = 0

    # All types of credit are subtracted from the gross cost to determine the
    # spend for threshold calculations.
    INCLUDE_ALL_CREDITS = 1

    # All types of credit are added to the net cost to determine the spend for
    # threshold calculations.
    EXCLUDE_ALL_CREDITS = 2

    # [Credit
    # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type)
    # specified in the credit_types field are subtracted from the
    # gross cost to determine the spend for threshold calculations.
    INCLUDE_SPECIFIED_CREDITS = 3
  end
end

#credit_types_treatment::Google::Cloud::Billing::Budgets::V1::Filter::CreditTypesTreatment

Returns Optional. If not set, default behavior is INCLUDE_ALL_CREDITS.

Returns:



306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
# File 'proto_docs/google/cloud/billing/budgets/v1/budget_model.rb', line 306

class Filter
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Protobuf::ListValue]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Specifies how credits are applied when determining the spend for
  # threshold calculations. Budgets track the total cost minus any applicable
  # selected credits.
  # [See the documentation for a list of credit
  # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type).
  module CreditTypesTreatment
    CREDIT_TYPES_TREATMENT_UNSPECIFIED = 0

    # All types of credit are subtracted from the gross cost to determine the
    # spend for threshold calculations.
    INCLUDE_ALL_CREDITS = 1

    # All types of credit are added to the net cost to determine the spend for
    # threshold calculations.
    EXCLUDE_ALL_CREDITS = 2

    # [Credit
    # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type)
    # specified in the credit_types field are subtracted from the
    # gross cost to determine the spend for threshold calculations.
    INCLUDE_SPECIFIED_CREDITS = 3
  end
end

#custom_period::Google::Cloud::Billing::Budgets::V1::CustomPeriod

Returns Optional. Specifies to track usage from any start date (required) to any end date (optional). This time period is static, it does not recur.

Returns:



306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
# File 'proto_docs/google/cloud/billing/budgets/v1/budget_model.rb', line 306

class Filter
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Protobuf::ListValue]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Specifies how credits are applied when determining the spend for
  # threshold calculations. Budgets track the total cost minus any applicable
  # selected credits.
  # [See the documentation for a list of credit
  # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type).
  module CreditTypesTreatment
    CREDIT_TYPES_TREATMENT_UNSPECIFIED = 0

    # All types of credit are subtracted from the gross cost to determine the
    # spend for threshold calculations.
    INCLUDE_ALL_CREDITS = 1

    # All types of credit are added to the net cost to determine the spend for
    # threshold calculations.
    EXCLUDE_ALL_CREDITS = 2

    # [Credit
    # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type)
    # specified in the credit_types field are subtracted from the
    # gross cost to determine the spend for threshold calculations.
    INCLUDE_SPECIFIED_CREDITS = 3
  end
end

#labels::Google::Protobuf::Map{::String => ::Google::Protobuf::ListValue}

Returns Optional. A single label and value pair specifying that usage from only this set of labeled resources should be included in the budget. If omitted, the report includes all labeled and unlabeled usage.

An object containing a single "key": value pair. Example: { "name": "wrench" }.

Currently, multiple entries or multiple values per entry are not allowed..

Returns:

  • (::Google::Protobuf::Map{::String => ::Google::Protobuf::ListValue})

    Optional. A single label and value pair specifying that usage from only this set of labeled resources should be included in the budget. If omitted, the report includes all labeled and unlabeled usage.

    An object containing a single "key": value pair. Example: { "name": "wrench" }.

    Currently, multiple entries or multiple values per entry are not allowed.



306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
# File 'proto_docs/google/cloud/billing/budgets/v1/budget_model.rb', line 306

class Filter
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Protobuf::ListValue]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Specifies how credits are applied when determining the spend for
  # threshold calculations. Budgets track the total cost minus any applicable
  # selected credits.
  # [See the documentation for a list of credit
  # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type).
  module CreditTypesTreatment
    CREDIT_TYPES_TREATMENT_UNSPECIFIED = 0

    # All types of credit are subtracted from the gross cost to determine the
    # spend for threshold calculations.
    INCLUDE_ALL_CREDITS = 1

    # All types of credit are added to the net cost to determine the spend for
    # threshold calculations.
    EXCLUDE_ALL_CREDITS = 2

    # [Credit
    # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type)
    # specified in the credit_types field are subtracted from the
    # gross cost to determine the spend for threshold calculations.
    INCLUDE_SPECIFIED_CREDITS = 3
  end
end

#projects::Array<::String>

Returns Optional. A set of projects of the form projects/{project}, specifying that usage from only this set of projects should be included in the budget. If omitted, the report includes all usage for the billing account, regardless of which project the usage occurred on.

Returns:

  • (::Array<::String>)

    Optional. A set of projects of the form projects/{project}, specifying that usage from only this set of projects should be included in the budget. If omitted, the report includes all usage for the billing account, regardless of which project the usage occurred on.



306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
# File 'proto_docs/google/cloud/billing/budgets/v1/budget_model.rb', line 306

class Filter
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Protobuf::ListValue]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Specifies how credits are applied when determining the spend for
  # threshold calculations. Budgets track the total cost minus any applicable
  # selected credits.
  # [See the documentation for a list of credit
  # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type).
  module CreditTypesTreatment
    CREDIT_TYPES_TREATMENT_UNSPECIFIED = 0

    # All types of credit are subtracted from the gross cost to determine the
    # spend for threshold calculations.
    INCLUDE_ALL_CREDITS = 1

    # All types of credit are added to the net cost to determine the spend for
    # threshold calculations.
    EXCLUDE_ALL_CREDITS = 2

    # [Credit
    # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type)
    # specified in the credit_types field are subtracted from the
    # gross cost to determine the spend for threshold calculations.
    INCLUDE_SPECIFIED_CREDITS = 3
  end
end

#resource_ancestors::Array<::String>

Returns Optional. A set of folder and organization names of the form folders/{folderId} or organizations/{organizationId}, specifying that usage from only this set of folders and organizations should be included in the budget. If omitted, the budget includes all usage that the billing account pays for. If the folder or organization contains projects that are paid for by a different Cloud Billing account, the budget doesn't apply to those projects.

Returns:

  • (::Array<::String>)

    Optional. A set of folder and organization names of the form folders/{folderId} or organizations/{organizationId}, specifying that usage from only this set of folders and organizations should be included in the budget. If omitted, the budget includes all usage that the billing account pays for. If the folder or organization contains projects that are paid for by a different Cloud Billing account, the budget doesn't apply to those projects.



306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
# File 'proto_docs/google/cloud/billing/budgets/v1/budget_model.rb', line 306

class Filter
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Protobuf::ListValue]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Specifies how credits are applied when determining the spend for
  # threshold calculations. Budgets track the total cost minus any applicable
  # selected credits.
  # [See the documentation for a list of credit
  # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type).
  module CreditTypesTreatment
    CREDIT_TYPES_TREATMENT_UNSPECIFIED = 0

    # All types of credit are subtracted from the gross cost to determine the
    # spend for threshold calculations.
    INCLUDE_ALL_CREDITS = 1

    # All types of credit are added to the net cost to determine the spend for
    # threshold calculations.
    EXCLUDE_ALL_CREDITS = 2

    # [Credit
    # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type)
    # specified in the credit_types field are subtracted from the
    # gross cost to determine the spend for threshold calculations.
    INCLUDE_SPECIFIED_CREDITS = 3
  end
end

#services::Array<::String>

Returns Optional. A set of services of the form services/{service_id}, specifying that usage from only this set of services should be included in the budget. If omitted, the report includes usage for all the services. The service names are available through the Catalog API: https://cloud.google.com/billing/v1/how-tos/catalog-api.

Returns:

  • (::Array<::String>)

    Optional. A set of services of the form services/{service_id}, specifying that usage from only this set of services should be included in the budget. If omitted, the report includes usage for all the services. The service names are available through the Catalog API: https://cloud.google.com/billing/v1/how-tos/catalog-api.



306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
# File 'proto_docs/google/cloud/billing/budgets/v1/budget_model.rb', line 306

class Filter
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Protobuf::ListValue]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Specifies how credits are applied when determining the spend for
  # threshold calculations. Budgets track the total cost minus any applicable
  # selected credits.
  # [See the documentation for a list of credit
  # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type).
  module CreditTypesTreatment
    CREDIT_TYPES_TREATMENT_UNSPECIFIED = 0

    # All types of credit are subtracted from the gross cost to determine the
    # spend for threshold calculations.
    INCLUDE_ALL_CREDITS = 1

    # All types of credit are added to the net cost to determine the spend for
    # threshold calculations.
    EXCLUDE_ALL_CREDITS = 2

    # [Credit
    # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type)
    # specified in the credit_types field are subtracted from the
    # gross cost to determine the spend for threshold calculations.
    INCLUDE_SPECIFIED_CREDITS = 3
  end
end

#subaccounts::Array<::String>

Returns Optional. A set of subaccounts of the form billingAccounts/{account_id}, specifying that usage from only this set of subaccounts should be included in the budget. If a subaccount is set to the name of the parent account, usage from the parent account is included. If the field is omitted, the report includes usage from the parent account and all subaccounts, if they exist.

Returns:

  • (::Array<::String>)

    Optional. A set of subaccounts of the form billingAccounts/{account_id}, specifying that usage from only this set of subaccounts should be included in the budget. If a subaccount is set to the name of the parent account, usage from the parent account is included. If the field is omitted, the report includes usage from the parent account and all subaccounts, if they exist.



306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
# File 'proto_docs/google/cloud/billing/budgets/v1/budget_model.rb', line 306

class Filter
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Protobuf::ListValue]
  class LabelsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Specifies how credits are applied when determining the spend for
  # threshold calculations. Budgets track the total cost minus any applicable
  # selected credits.
  # [See the documentation for a list of credit
  # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type).
  module CreditTypesTreatment
    CREDIT_TYPES_TREATMENT_UNSPECIFIED = 0

    # All types of credit are subtracted from the gross cost to determine the
    # spend for threshold calculations.
    INCLUDE_ALL_CREDITS = 1

    # All types of credit are added to the net cost to determine the spend for
    # threshold calculations.
    EXCLUDE_ALL_CREDITS = 2

    # [Credit
    # types](https://cloud.google.com/billing/docs/how-to/export-data-bigquery-tables#credits-type)
    # specified in the credit_types field are subtracted from the
    # gross cost to determine the spend for threshold calculations.
    INCLUDE_SPECIFIED_CREDITS = 3
  end
end