Skip to content

Commit

Permalink
feat(billingbudgets): update the API
Browse files Browse the repository at this point in the history
#### billingbudgets:v1beta1
The following keys were added:
- schemas.GoogleCloudBillingBudgetsV1beta1AllUpdatesRule.properties.monitoringNotificationChannels.description
- schemas.GoogleCloudBillingBudgetsV1beta1AllUpdatesRule.properties.monitoringNotificationChannels.items.type
- schemas.GoogleCloudBillingBudgetsV1beta1AllUpdatesRule.properties.monitoringNotificationChannels.type

The following keys were changed:
- schemas.GoogleCloudBillingBudgetsV1beta1AllUpdatesRule.description
- schemas.GoogleCloudBillingBudgetsV1beta1AllUpdatesRule.properties.pubsubTopic.description
- schemas.GoogleCloudBillingBudgetsV1beta1AllUpdatesRule.properties.schemaVersion.description
- schemas.GoogleCloudBillingBudgetsV1beta1Budget.properties.allUpdatesRule.description
- schemas.GoogleCloudBillingBudgetsV1beta1Filter.properties.subaccounts.description
  • Loading branch information
yoshi-automation authored and sofisl committed Jul 16, 2020
1 parent 36ff967 commit e476479
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 11 deletions.
19 changes: 13 additions & 6 deletions discovery/billingbudgets-v1beta1.json
Original file line number Diff line number Diff line change
Expand Up @@ -256,19 +256,26 @@
}
}
},
"revision": "20200704",
"revision": "20200711",
"rootUrl": "https://billingbudgets.googleapis.com/",
"schemas": {
"GoogleCloudBillingBudgetsV1beta1AllUpdatesRule": {
"description": "AllUpdatesRule defines notifications that are sent on every update to the\nbilling account's spend, regardless of the thresholds defined using\nthreshold rules.",
"description": "AllUpdatesRule defines notifications that are sent based on budget spend\nand thresholds.",
"id": "GoogleCloudBillingBudgetsV1beta1AllUpdatesRule",
"properties": {
"monitoringNotificationChannels": {
"description": "Optional. Targets to send notifications to when a threshold is exceeded. This is in\naddition to default recipients who have billing account roles.\nThe value is the full REST resource name of a monitoring notification\nchannel with the form\n`projects/{project_id}/notificationChannels/{channel_id}`. A maximum of 5\nchannels are allowed. See\nhttps://cloud.google.com/billing/docs/how-to/budgets-notification-recipients\nfor more details.",
"items": {
"type": "string"
},
"type": "array"
},
"pubsubTopic": {
"description": "Required. The name of the Cloud Pub/Sub topic where budget related messages will be\npublished, in the form `projects/{project_id}/topics/{topic_id}`. Updates\nare sent at regular intervals to the topic.\nThe topic needs to be created before the budget is created; see\nhttps://cloud.google.com/billing/docs/how-to/budgets#manage-notifications\nfor more details.\nCaller is expected to have\n`pubsub.topics.setIamPolicy` permission on the topic when it's set for a\nbudget, otherwise, the API call will fail with PERMISSION_DENIED. See\nhttps://cloud.google.com/pubsub/docs/access-control for more details on\nPub/Sub roles and permissions.",
"description": "Required. The name of the Cloud Pub/Sub topic where budget related messages will be\npublished, in the form `projects/{project_id}/topics/{topic_id}`. Updates\nare sent at regular intervals to the topic.\nThe topic needs to be created before the budget is created; see\nhttps://cloud.google.com/billing/docs/how-to/budgets#manage-notifications\nfor more details.\nCaller is expected to have\n`pubsub.topics.setIamPolicy` permission on the topic when it's set for a\nbudget, otherwise, the API call will fail with PERMISSION_DENIED. See\nhttps://cloud.google.com/billing/docs/how-to/budgets-programmatic-notifications\nfor more details on Pub/Sub roles and permissions.",
"type": "string"
},
"schemaVersion": {
"description": "Required. The schema version of the notification.\nOnly \"1.0\" is accepted. It represents the JSON schema as defined in\nhttps://cloud.google.com/billing/docs/how-to/budgets#notification_format",
"description": "Required. The schema version of the notification sent to `pubsub_topic`.\nOnly \"1.0\" is accepted. It represents the JSON schema as defined in\nhttps://cloud.google.com/billing/docs/how-to/budgets-programmatic-notifications#notification_format",
"type": "string"
}
},
Expand All @@ -280,7 +287,7 @@
"properties": {
"allUpdatesRule": {
"$ref": "GoogleCloudBillingBudgetsV1beta1AllUpdatesRule",
"description": "Optional. Rules to apply to all updates to the actual spend, regardless\nof the thresholds set in `threshold_rules`."
"description": "Optional. Rules to apply to notifications sent based on budget spend and thresholds."
},
"amount": {
"$ref": "GoogleCloudBillingBudgetsV1beta1BudgetAmount",
Expand Down Expand Up @@ -381,7 +388,7 @@
"type": "array"
},
"subaccounts": {
"description": "Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying\nthat usage from only this set of subaccounts should be included in the\nbudget. If a subaccount is set to the name of the resller account, usage\nfrom the reseller account will be included. If omitted, the report will\ninclude usage from the reseller account and all subaccounts, if they exist.",
"description": "Optional. A set of subaccounts of the form `billingAccounts/{account_id}`, specifying\nthat usage from only this set of subaccounts should be included in the\nbudget. If a subaccount is set to the name of the parent account,\nusage from the parent account will be included. If omitted, the\nreport will include usage from the parent account and all\nsubaccounts, if they exist.",
"items": {
"type": "string"
},
Expand Down
14 changes: 9 additions & 5 deletions src/apis/billingbudgets/v1beta1.ts
Original file line number Diff line number Diff line change
Expand Up @@ -128,15 +128,19 @@ export namespace billingbudgets_v1beta1 {
}

/**
* AllUpdatesRule defines notifications that are sent on every update to the billing account's spend, regardless of the thresholds defined using threshold rules.
* AllUpdatesRule defines notifications that are sent based on budget spend and thresholds.
*/
export interface Schema$GoogleCloudBillingBudgetsV1beta1AllUpdatesRule {
/**
* Required. The name of the Cloud Pub/Sub topic where budget related messages will be published, in the form `projects/{project_id}/topics/{topic_id}`. Updates are sent at regular intervals to the topic. The topic needs to be created before the budget is created; see https://cloud.google.com/billing/docs/how-to/budgets#manage-notifications for more details. Caller is expected to have `pubsub.topics.setIamPolicy` permission on the topic when it's set for a budget, otherwise, the API call will fail with PERMISSION_DENIED. See https://cloud.google.com/pubsub/docs/access-control for more details on Pub/Sub roles and permissions.
* Optional. Targets to send notifications to when a threshold is exceeded. This is in addition to default recipients who have billing account roles. The value is the full REST resource name of a monitoring notification channel with the form `projects/{project_id}/notificationChannels/{channel_id}`. A maximum of 5 channels are allowed. See https://cloud.google.com/billing/docs/how-to/budgets-notification-recipients for more details.
*/
monitoringNotificationChannels?: string[] | null;
/**
* Required. The name of the Cloud Pub/Sub topic where budget related messages will be published, in the form `projects/{project_id}/topics/{topic_id}`. Updates are sent at regular intervals to the topic. The topic needs to be created before the budget is created; see https://cloud.google.com/billing/docs/how-to/budgets#manage-notifications for more details. Caller is expected to have `pubsub.topics.setIamPolicy` permission on the topic when it's set for a budget, otherwise, the API call will fail with PERMISSION_DENIED. See https://cloud.google.com/billing/docs/how-to/budgets-programmatic-notifications for more details on Pub/Sub roles and permissions.
*/
pubsubTopic?: string | null;
/**
* Required. The schema version of the notification. Only "1.0" is accepted. It represents the JSON schema as defined in https://cloud.google.com/billing/docs/how-to/budgets#notification_format
* Required. The schema version of the notification sent to `pubsub_topic`. Only "1.0" is accepted. It represents the JSON schema as defined in https://cloud.google.com/billing/docs/how-to/budgets-programmatic-notifications#notification_format
*/
schemaVersion?: string | null;
}
Expand All @@ -145,7 +149,7 @@ export namespace billingbudgets_v1beta1 {
*/
export interface Schema$GoogleCloudBillingBudgetsV1beta1Budget {
/**
* Optional. Rules to apply to all updates to the actual spend, regardless of the thresholds set in `threshold_rules`.
* Optional. Rules to apply to notifications sent based on budget spend and thresholds.
*/
allUpdatesRule?: Schema$GoogleCloudBillingBudgetsV1beta1AllUpdatesRule;
/**
Expand Down Expand Up @@ -216,7 +220,7 @@ export namespace billingbudgets_v1beta1 {
*/
services?: string[] | null;
/**
* 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 resller account, usage from the reseller account will be included. If omitted, the report will include usage from the reseller account and all subaccounts, if they exist.
* 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 will be included. If omitted, the report will include usage from the parent account and all subaccounts, if they exist.
*/
subaccounts?: string[] | null;
}
Expand Down

0 comments on commit e476479

Please # to comment.