Filter(mapping=None, *, ignore_unknown_fields=False, **kwargs)
A filter for a budget, limiting the scope of the cost to calculate.
This message has oneof
_ fields (mutually exclusive fields).
For each oneof, at most one member field can be set at the same time.
Setting any member of the oneof automatically clears all other
members.
.. _oneof: https://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields
Attributes | |
---|---|
Name | Description |
projects |
MutableSequence[str]
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.
|
resource_ancestors |
MutableSequence[str]
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.
|
credit_types |
MutableSequence[str]
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 |
credit_types_treatment |
google.cloud.billing.budgets_v1.types.Filter.CreditTypesTreatment
Optional. If not set, default behavior is INCLUDE_ALL_CREDITS .
|
services |
MutableSequence[str]
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.
|
subaccounts |
MutableSequence[str]
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.
|
labels |
MutableMapping[str, google.protobuf.struct_pb2.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.*
|
calendar_period |
google.cloud.billing.budgets_v1.types.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. This field is a member of oneof _ usage_period .
|
custom_period |
google.cloud.billing.budgets_v1.types.CustomPeriod
Optional. Specifies to track usage from any start date (required) to any end date (optional). This time period is static, it does not recur. This field is a member of oneof _ usage_period .
|
Classes
CreditTypesTreatment
CreditTypesTreatment(value)
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>
__.
Values:
CREDIT_TYPES_TREATMENT_UNSPECIFIED (0):
No description available.
INCLUDE_ALL_CREDITS (1):
All types of credit are subtracted from the
gross cost to determine the spend for threshold
calculations.
EXCLUDE_ALL_CREDITS (2):
All types of credit are added to the net cost
to determine the spend for threshold
calculations.
INCLUDE_SPECIFIED_CREDITS (3):
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.
LabelsEntry
LabelsEntry(mapping=None, *, ignore_unknown_fields=False, **kwargs)
The abstract base class for a message.
Parameters | |
---|---|
Name | Description |
kwargs |
dict
Keys and values corresponding to the fields of the message. |
mapping |
Union[dict,
A dictionary or message to be used to determine the values for this message. |
ignore_unknown_fields |
Optional(bool)
If True, do not raise errors for unknown fields. Only applied if |