google-cloud-billing-v1 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.yardopts +12 -0
- data/AUTHENTICATION.md +166 -0
- data/LICENSE.md +201 -0
- data/README.md +24 -0
- data/lib/google/cloud/billing/v1/cloud_billing/client.rb +955 -0
- data/lib/google/cloud/billing/v1/cloud_billing/credentials.rb +52 -0
- data/lib/google/cloud/billing/v1/cloud_billing/paths.rb +45 -0
- data/lib/google/cloud/billing/v1/cloud_billing.rb +20 -0
- data/lib/google/cloud/billing/v1/cloud_billing_pb.rb +84 -0
- data/lib/google/cloud/billing/v1/cloud_billing_services_pb.rb +127 -0
- data/lib/google/cloud/billing/v1/cloud_catalog/client.rb +326 -0
- data/lib/google/cloud/billing/v1/cloud_catalog/credentials.rb +52 -0
- data/lib/google/cloud/billing/v1/cloud_catalog/paths.rb +45 -0
- data/lib/google/cloud/billing/v1/cloud_catalog.rb +20 -0
- data/lib/google/cloud/billing/v1/cloud_catalog_pb.rb +113 -0
- data/lib/google/cloud/billing/v1/cloud_catalog_services_pb.rb +50 -0
- data/lib/google/cloud/billing/v1/version.rb +28 -0
- data/lib/google/cloud/billing/v1.rb +20 -0
- data/lib/google/cloud/common_resources_pb.rb +15 -0
- data/lib/google-cloud-billing-v1.rb +1 -0
- data/proto_docs/README.md +4 -0
- data/proto_docs/google/api/field_behavior.rb +59 -0
- data/proto_docs/google/api/resource.rb +247 -0
- data/proto_docs/google/cloud/billing/v1/cloud_billing.rb +217 -0
- data/proto_docs/google/cloud/billing/v1/cloud_catalog.rb +319 -0
- data/proto_docs/google/iam/v1/iam_policy.rb +79 -0
- data/proto_docs/google/iam/v1/policy.rb +156 -0
- data/proto_docs/google/protobuf/field_mask.rb +237 -0
- data/proto_docs/google/protobuf/timestamp.rb +116 -0
- data/proto_docs/google/type/money.rb +43 -0
- metadata +199 -0
@@ -0,0 +1,217 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2020 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
|
20
|
+
module Google
|
21
|
+
module Cloud
|
22
|
+
module Billing
|
23
|
+
module V1
|
24
|
+
# A billing account in [GCP Console](https://console.cloud.google.com/).
|
25
|
+
# You can assign a billing account to one or more projects.
|
26
|
+
# @!attribute [rw] name
|
27
|
+
# @return [String]
|
28
|
+
# The resource name of the billing account. The resource name has the form
|
29
|
+
# `billingAccounts/\\\{billing_account_id\}`. For example,
|
30
|
+
# `billingAccounts/012345-567890-ABCDEF` would be the resource name for
|
31
|
+
# billing account `012345-567890-ABCDEF`.
|
32
|
+
# @!attribute [r] open
|
33
|
+
# @return [Boolean]
|
34
|
+
# Output only. True if the billing account is open, and will therefore be charged for any
|
35
|
+
# usage on associated projects. False if the billing account is closed, and
|
36
|
+
# therefore projects associated with it will be unable to use paid services.
|
37
|
+
# @!attribute [rw] display_name
|
38
|
+
# @return [String]
|
39
|
+
# The display name given to the billing account, such as `My Billing
|
40
|
+
# Account`. This name is displayed in the GCP Console.
|
41
|
+
# @!attribute [rw] master_billing_account
|
42
|
+
# @return [String]
|
43
|
+
# If this account is a
|
44
|
+
# [subaccount](https://cloud.google.com/billing/docs/concepts), then this
|
45
|
+
# will be the resource name of the master billing account that it is being
|
46
|
+
# resold through.
|
47
|
+
# Otherwise this will be empty.
|
48
|
+
class BillingAccount
|
49
|
+
include Google::Protobuf::MessageExts
|
50
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
51
|
+
end
|
52
|
+
|
53
|
+
# Encapsulation of billing information for a GCP Console project. A project
|
54
|
+
# has at most one associated billing account at a time (but a billing account
|
55
|
+
# can be assigned to multiple projects).
|
56
|
+
# @!attribute [rw] name
|
57
|
+
# @return [String]
|
58
|
+
# The resource name for the `ProjectBillingInfo`; has the form
|
59
|
+
# `projects/\\\{project_id\}/billingInfo`. For example, the resource name for the
|
60
|
+
# billing information for project `tokyo-rain-123` would be
|
61
|
+
# `projects/tokyo-rain-123/billingInfo`. This field is read-only.
|
62
|
+
# @!attribute [rw] project_id
|
63
|
+
# @return [String]
|
64
|
+
# The ID of the project that this `ProjectBillingInfo` represents, such as
|
65
|
+
# `tokyo-rain-123`. This is a convenience field so that you don't need to
|
66
|
+
# parse the `name` field to obtain a project ID. This field is read-only.
|
67
|
+
# @!attribute [rw] billing_account_name
|
68
|
+
# @return [String]
|
69
|
+
# The resource name of the billing account associated with the project, if
|
70
|
+
# any. For example, `billingAccounts/012345-567890-ABCDEF`.
|
71
|
+
# @!attribute [rw] billing_enabled
|
72
|
+
# @return [Boolean]
|
73
|
+
# True if the project is associated with an open billing account, to which
|
74
|
+
# usage on the project is charged. False if the project is associated with a
|
75
|
+
# closed billing account, or no billing account at all, and therefore cannot
|
76
|
+
# use paid services. This field is read-only.
|
77
|
+
class ProjectBillingInfo
|
78
|
+
include Google::Protobuf::MessageExts
|
79
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
80
|
+
end
|
81
|
+
|
82
|
+
# Request message for `GetBillingAccount`.
|
83
|
+
# @!attribute [rw] name
|
84
|
+
# @return [String]
|
85
|
+
# Required. The resource name of the billing account to retrieve. For example,
|
86
|
+
# `billingAccounts/012345-567890-ABCDEF`.
|
87
|
+
class GetBillingAccountRequest
|
88
|
+
include Google::Protobuf::MessageExts
|
89
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
90
|
+
end
|
91
|
+
|
92
|
+
# Request message for `ListBillingAccounts`.
|
93
|
+
# @!attribute [rw] page_size
|
94
|
+
# @return [Integer]
|
95
|
+
# Requested page size. The maximum page size is 100; this is also the
|
96
|
+
# default.
|
97
|
+
# @!attribute [rw] page_token
|
98
|
+
# @return [String]
|
99
|
+
# A token identifying a page of results to return. This should be a
|
100
|
+
# `next_page_token` value returned from a previous `ListBillingAccounts`
|
101
|
+
# call. If unspecified, the first page of results is returned.
|
102
|
+
# @!attribute [rw] filter
|
103
|
+
# @return [String]
|
104
|
+
# Options for how to filter the returned billing accounts.
|
105
|
+
# Currently this only supports filtering for
|
106
|
+
# [subaccounts](https://cloud.google.com/billing/docs/concepts) under a
|
107
|
+
# single provided reseller billing account.
|
108
|
+
# (e.g. "master_billing_account=billingAccounts/012345-678901-ABCDEF").
|
109
|
+
# Boolean algebra and other fields are not currently supported.
|
110
|
+
class ListBillingAccountsRequest
|
111
|
+
include Google::Protobuf::MessageExts
|
112
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
113
|
+
end
|
114
|
+
|
115
|
+
# Response message for `ListBillingAccounts`.
|
116
|
+
# @!attribute [rw] billing_accounts
|
117
|
+
# @return [Array<Google::Cloud::Billing::V1::BillingAccount>]
|
118
|
+
# A list of billing accounts.
|
119
|
+
# @!attribute [rw] next_page_token
|
120
|
+
# @return [String]
|
121
|
+
# A token to retrieve the next page of results. To retrieve the next page,
|
122
|
+
# call `ListBillingAccounts` again with the `page_token` field set to this
|
123
|
+
# value. This field is empty if there are no more results to retrieve.
|
124
|
+
class ListBillingAccountsResponse
|
125
|
+
include Google::Protobuf::MessageExts
|
126
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
127
|
+
end
|
128
|
+
|
129
|
+
# Request message for `CreateBillingAccount`.
|
130
|
+
# @!attribute [rw] billing_account
|
131
|
+
# @return [Google::Cloud::Billing::V1::BillingAccount]
|
132
|
+
# Required. The billing account resource to create.
|
133
|
+
# Currently CreateBillingAccount only supports subaccount creation, so
|
134
|
+
# any created billing accounts must be under a provided master billing
|
135
|
+
# account.
|
136
|
+
class CreateBillingAccountRequest
|
137
|
+
include Google::Protobuf::MessageExts
|
138
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
139
|
+
end
|
140
|
+
|
141
|
+
# Request message for `UpdateBillingAccount`.
|
142
|
+
# @!attribute [rw] name
|
143
|
+
# @return [String]
|
144
|
+
# Required. The name of the billing account resource to be updated.
|
145
|
+
# @!attribute [rw] account
|
146
|
+
# @return [Google::Cloud::Billing::V1::BillingAccount]
|
147
|
+
# Required. The billing account resource to replace the resource on the server.
|
148
|
+
# @!attribute [rw] update_mask
|
149
|
+
# @return [Google::Protobuf::FieldMask]
|
150
|
+
# The update mask applied to the resource.
|
151
|
+
# Only "display_name" is currently supported.
|
152
|
+
class UpdateBillingAccountRequest
|
153
|
+
include Google::Protobuf::MessageExts
|
154
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
155
|
+
end
|
156
|
+
|
157
|
+
# Request message for `ListProjectBillingInfo`.
|
158
|
+
# @!attribute [rw] name
|
159
|
+
# @return [String]
|
160
|
+
# Required. The resource name of the billing account associated with the projects that
|
161
|
+
# you want to list. For example, `billingAccounts/012345-567890-ABCDEF`.
|
162
|
+
# @!attribute [rw] page_size
|
163
|
+
# @return [Integer]
|
164
|
+
# Requested page size. The maximum page size is 100; this is also the
|
165
|
+
# default.
|
166
|
+
# @!attribute [rw] page_token
|
167
|
+
# @return [String]
|
168
|
+
# A token identifying a page of results to be returned. This should be a
|
169
|
+
# `next_page_token` value returned from a previous `ListProjectBillingInfo`
|
170
|
+
# call. If unspecified, the first page of results is returned.
|
171
|
+
class ListProjectBillingInfoRequest
|
172
|
+
include Google::Protobuf::MessageExts
|
173
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
174
|
+
end
|
175
|
+
|
176
|
+
# Request message for `ListProjectBillingInfoResponse`.
|
177
|
+
# @!attribute [rw] project_billing_info
|
178
|
+
# @return [Array<Google::Cloud::Billing::V1::ProjectBillingInfo>]
|
179
|
+
# A list of `ProjectBillingInfo` resources representing the projects
|
180
|
+
# associated with the billing account.
|
181
|
+
# @!attribute [rw] next_page_token
|
182
|
+
# @return [String]
|
183
|
+
# A token to retrieve the next page of results. To retrieve the next page,
|
184
|
+
# call `ListProjectBillingInfo` again with the `page_token` field set to this
|
185
|
+
# value. This field is empty if there are no more results to retrieve.
|
186
|
+
class ListProjectBillingInfoResponse
|
187
|
+
include Google::Protobuf::MessageExts
|
188
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
189
|
+
end
|
190
|
+
|
191
|
+
# Request message for `GetProjectBillingInfo`.
|
192
|
+
# @!attribute [rw] name
|
193
|
+
# @return [String]
|
194
|
+
# Required. The resource name of the project for which billing information is
|
195
|
+
# retrieved. For example, `projects/tokyo-rain-123`.
|
196
|
+
class GetProjectBillingInfoRequest
|
197
|
+
include Google::Protobuf::MessageExts
|
198
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
199
|
+
end
|
200
|
+
|
201
|
+
# Request message for `UpdateProjectBillingInfo`.
|
202
|
+
# @!attribute [rw] name
|
203
|
+
# @return [String]
|
204
|
+
# Required. The resource name of the project associated with the billing information
|
205
|
+
# that you want to update. For example, `projects/tokyo-rain-123`.
|
206
|
+
# @!attribute [rw] project_billing_info
|
207
|
+
# @return [Google::Cloud::Billing::V1::ProjectBillingInfo]
|
208
|
+
# The new billing information for the project. Read-only fields are ignored;
|
209
|
+
# thus, you can leave empty all fields except `billing_account_name`.
|
210
|
+
class UpdateProjectBillingInfoRequest
|
211
|
+
include Google::Protobuf::MessageExts
|
212
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
213
|
+
end
|
214
|
+
end
|
215
|
+
end
|
216
|
+
end
|
217
|
+
end
|
@@ -0,0 +1,319 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2020 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
|
20
|
+
module Google
|
21
|
+
module Cloud
|
22
|
+
module Billing
|
23
|
+
module V1
|
24
|
+
# Encapsulates a single service in Google Cloud Platform.
|
25
|
+
# @!attribute [rw] name
|
26
|
+
# @return [String]
|
27
|
+
# The resource name for the service.
|
28
|
+
# Example: "services/DA34-426B-A397"
|
29
|
+
# @!attribute [rw] service_id
|
30
|
+
# @return [String]
|
31
|
+
# The identifier for the service.
|
32
|
+
# Example: "DA34-426B-A397"
|
33
|
+
# @!attribute [rw] display_name
|
34
|
+
# @return [String]
|
35
|
+
# A human readable display name for this service.
|
36
|
+
# @!attribute [rw] business_entity_name
|
37
|
+
# @return [String]
|
38
|
+
# The business under which the service is offered.
|
39
|
+
# Ex. "businessEntities/GCP", "businessEntities/Maps"
|
40
|
+
class Service
|
41
|
+
include Google::Protobuf::MessageExts
|
42
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
43
|
+
end
|
44
|
+
|
45
|
+
# Encapsulates a single SKU in Google Cloud Platform
|
46
|
+
# @!attribute [rw] name
|
47
|
+
# @return [String]
|
48
|
+
# The resource name for the SKU.
|
49
|
+
# Example: "services/DA34-426B-A397/skus/AA95-CD31-42FE"
|
50
|
+
# @!attribute [rw] sku_id
|
51
|
+
# @return [String]
|
52
|
+
# The identifier for the SKU.
|
53
|
+
# Example: "AA95-CD31-42FE"
|
54
|
+
# @!attribute [rw] description
|
55
|
+
# @return [String]
|
56
|
+
# A human readable description of the SKU, has a maximum length of 256
|
57
|
+
# characters.
|
58
|
+
# @!attribute [rw] category
|
59
|
+
# @return [Google::Cloud::Billing::V1::Category]
|
60
|
+
# The category hierarchy of this SKU, purely for organizational purpose.
|
61
|
+
# @!attribute [rw] service_regions
|
62
|
+
# @return [Array<String>]
|
63
|
+
# List of service regions this SKU is offered at.
|
64
|
+
# Example: "asia-east1"
|
65
|
+
# Service regions can be found at https://cloud.google.com/about/locations/
|
66
|
+
# @!attribute [rw] pricing_info
|
67
|
+
# @return [Array<Google::Cloud::Billing::V1::PricingInfo>]
|
68
|
+
# A timeline of pricing info for this SKU in chronological order.
|
69
|
+
# @!attribute [rw] service_provider_name
|
70
|
+
# @return [String]
|
71
|
+
# Identifies the service provider.
|
72
|
+
# This is 'Google' for first party services in Google Cloud Platform.
|
73
|
+
class Sku
|
74
|
+
include Google::Protobuf::MessageExts
|
75
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
76
|
+
end
|
77
|
+
|
78
|
+
# Represents the category hierarchy of a SKU.
|
79
|
+
# @!attribute [rw] service_display_name
|
80
|
+
# @return [String]
|
81
|
+
# The display name of the service this SKU belongs to.
|
82
|
+
# @!attribute [rw] resource_family
|
83
|
+
# @return [String]
|
84
|
+
# The type of product the SKU refers to.
|
85
|
+
# Example: "Compute", "Storage", "Network", "ApplicationServices" etc.
|
86
|
+
# @!attribute [rw] resource_group
|
87
|
+
# @return [String]
|
88
|
+
# A group classification for related SKUs.
|
89
|
+
# Example: "RAM", "GPU", "Prediction", "Ops", "GoogleEgress" etc.
|
90
|
+
# @!attribute [rw] usage_type
|
91
|
+
# @return [String]
|
92
|
+
# Represents how the SKU is consumed.
|
93
|
+
# Example: "OnDemand", "Preemptible", "Commit1Mo", "Commit1Yr" etc.
|
94
|
+
class Category
|
95
|
+
include Google::Protobuf::MessageExts
|
96
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
97
|
+
end
|
98
|
+
|
99
|
+
# Represents the pricing information for a SKU at a single point of time.
|
100
|
+
# @!attribute [rw] effective_time
|
101
|
+
# @return [Google::Protobuf::Timestamp]
|
102
|
+
# The timestamp from which this pricing was effective within the requested
|
103
|
+
# time range. This is guaranteed to be greater than or equal to the
|
104
|
+
# start_time field in the request and less than the end_time field in the
|
105
|
+
# request. If a time range was not specified in the request this field will
|
106
|
+
# be equivalent to a time within the last 12 hours, indicating the latest
|
107
|
+
# pricing info.
|
108
|
+
# @!attribute [rw] summary
|
109
|
+
# @return [String]
|
110
|
+
# An optional human readable summary of the pricing information, has a
|
111
|
+
# maximum length of 256 characters.
|
112
|
+
# @!attribute [rw] pricing_expression
|
113
|
+
# @return [Google::Cloud::Billing::V1::PricingExpression]
|
114
|
+
# Expresses the pricing formula. See `PricingExpression` for an example.
|
115
|
+
# @!attribute [rw] aggregation_info
|
116
|
+
# @return [Google::Cloud::Billing::V1::AggregationInfo]
|
117
|
+
# Aggregation Info. This can be left unspecified if the pricing expression
|
118
|
+
# doesn't require aggregation.
|
119
|
+
# @!attribute [rw] currency_conversion_rate
|
120
|
+
# @return [Float]
|
121
|
+
# Conversion rate used for currency conversion, from USD to the currency
|
122
|
+
# specified in the request. This includes any surcharge collected for billing
|
123
|
+
# in non USD currency. If a currency is not specified in the request this
|
124
|
+
# defaults to 1.0.
|
125
|
+
# Example: USD * currency_conversion_rate = JPY
|
126
|
+
class PricingInfo
|
127
|
+
include Google::Protobuf::MessageExts
|
128
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
129
|
+
end
|
130
|
+
|
131
|
+
# Expresses a mathematical pricing formula. For Example:-
|
132
|
+
#
|
133
|
+
# `usage_unit: GBy`
|
134
|
+
# `tiered_rates:`
|
135
|
+
# `[start_usage_amount: 20, unit_price: $10]`
|
136
|
+
# `[start_usage_amount: 100, unit_price: $5]`
|
137
|
+
#
|
138
|
+
# The above expresses a pricing formula where the first 20GB is free, the
|
139
|
+
# next 80GB is priced at $10 per GB followed by $5 per GB for additional
|
140
|
+
# usage.
|
141
|
+
# @!attribute [rw] usage_unit
|
142
|
+
# @return [String]
|
143
|
+
# The short hand for unit of usage this pricing is specified in.
|
144
|
+
# Example: usage_unit of "GiBy" means that usage is specified in "Gibi Byte".
|
145
|
+
# @!attribute [rw] usage_unit_description
|
146
|
+
# @return [String]
|
147
|
+
# The unit of usage in human readable form.
|
148
|
+
# Example: "gibi byte".
|
149
|
+
# @!attribute [rw] base_unit
|
150
|
+
# @return [String]
|
151
|
+
# The base unit for the SKU which is the unit used in usage exports.
|
152
|
+
# Example: "By"
|
153
|
+
# @!attribute [rw] base_unit_description
|
154
|
+
# @return [String]
|
155
|
+
# The base unit in human readable form.
|
156
|
+
# Example: "byte".
|
157
|
+
# @!attribute [rw] base_unit_conversion_factor
|
158
|
+
# @return [Float]
|
159
|
+
# Conversion factor for converting from price per usage_unit to price per
|
160
|
+
# base_unit, and start_usage_amount to start_usage_amount in base_unit.
|
161
|
+
# unit_price / base_unit_conversion_factor = price per base_unit.
|
162
|
+
# start_usage_amount * base_unit_conversion_factor = start_usage_amount in
|
163
|
+
# base_unit.
|
164
|
+
# @!attribute [rw] display_quantity
|
165
|
+
# @return [Float]
|
166
|
+
# The recommended quantity of units for displaying pricing info. When
|
167
|
+
# displaying pricing info it is recommended to display:
|
168
|
+
# (unit_price * display_quantity) per display_quantity usage_unit.
|
169
|
+
# This field does not affect the pricing formula and is for display purposes
|
170
|
+
# only.
|
171
|
+
# Example: If the unit_price is "0.0001 USD", the usage_unit is "GB" and
|
172
|
+
# the display_quantity is "1000" then the recommended way of displaying the
|
173
|
+
# pricing info is "0.10 USD per 1000 GB"
|
174
|
+
# @!attribute [rw] tiered_rates
|
175
|
+
# @return [Array<Google::Cloud::Billing::V1::PricingExpression::TierRate>]
|
176
|
+
# The list of tiered rates for this pricing. The total cost is computed by
|
177
|
+
# applying each of the tiered rates on usage. This repeated list is sorted
|
178
|
+
# by ascending order of start_usage_amount.
|
179
|
+
class PricingExpression
|
180
|
+
include Google::Protobuf::MessageExts
|
181
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
182
|
+
|
183
|
+
# The price rate indicating starting usage and its corresponding price.
|
184
|
+
# @!attribute [rw] start_usage_amount
|
185
|
+
# @return [Float]
|
186
|
+
# Usage is priced at this rate only after this amount.
|
187
|
+
# Example: start_usage_amount of 10 indicates that the usage will be priced
|
188
|
+
# at the unit_price after the first 10 usage_units.
|
189
|
+
# @!attribute [rw] unit_price
|
190
|
+
# @return [Google::Type::Money]
|
191
|
+
# The price per unit of usage.
|
192
|
+
# Example: unit_price of amount $10 indicates that each unit will cost $10.
|
193
|
+
class TierRate
|
194
|
+
include Google::Protobuf::MessageExts
|
195
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
196
|
+
end
|
197
|
+
end
|
198
|
+
|
199
|
+
# Represents the aggregation level and interval for pricing of a single SKU.
|
200
|
+
# @!attribute [rw] aggregation_level
|
201
|
+
# @return [ENUM(AggregationLevel)]
|
202
|
+
# @!attribute [rw] aggregation_interval
|
203
|
+
# @return [ENUM(AggregationInterval)]
|
204
|
+
# @!attribute [rw] aggregation_count
|
205
|
+
# @return [Integer]
|
206
|
+
# The number of intervals to aggregate over.
|
207
|
+
# Example: If aggregation_level is "DAILY" and aggregation_count is 14,
|
208
|
+
# aggregation will be over 14 days.
|
209
|
+
class AggregationInfo
|
210
|
+
include Google::Protobuf::MessageExts
|
211
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
212
|
+
|
213
|
+
# The level at which usage is aggregated to compute cost.
|
214
|
+
# Example: "ACCOUNT" aggregation level indicates that usage for tiered
|
215
|
+
# pricing is aggregated across all projects in a single account.
|
216
|
+
module AggregationLevel
|
217
|
+
AGGREGATION_LEVEL_UNSPECIFIED = 0
|
218
|
+
|
219
|
+
ACCOUNT = 1
|
220
|
+
|
221
|
+
PROJECT = 2
|
222
|
+
end
|
223
|
+
|
224
|
+
# The interval at which usage is aggregated to compute cost.
|
225
|
+
# Example: "MONTHLY" aggregation interval indicates that usage for tiered
|
226
|
+
# pricing is aggregated every month.
|
227
|
+
module AggregationInterval
|
228
|
+
AGGREGATION_INTERVAL_UNSPECIFIED = 0
|
229
|
+
|
230
|
+
DAILY = 1
|
231
|
+
|
232
|
+
MONTHLY = 2
|
233
|
+
end
|
234
|
+
end
|
235
|
+
|
236
|
+
# Request message for `ListServices`.
|
237
|
+
# @!attribute [rw] page_size
|
238
|
+
# @return [Integer]
|
239
|
+
# Requested page size. Defaults to 5000.
|
240
|
+
# @!attribute [rw] page_token
|
241
|
+
# @return [String]
|
242
|
+
# A token identifying a page of results to return. This should be a
|
243
|
+
# `next_page_token` value returned from a previous `ListServices`
|
244
|
+
# call. If unspecified, the first page of results is returned.
|
245
|
+
class ListServicesRequest
|
246
|
+
include Google::Protobuf::MessageExts
|
247
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
248
|
+
end
|
249
|
+
|
250
|
+
# Response message for `ListServices`.
|
251
|
+
# @!attribute [rw] services
|
252
|
+
# @return [Array<Google::Cloud::Billing::V1::Service>]
|
253
|
+
# A list of services.
|
254
|
+
# @!attribute [rw] next_page_token
|
255
|
+
# @return [String]
|
256
|
+
# A token to retrieve the next page of results. To retrieve the next page,
|
257
|
+
# call `ListServices` again with the `page_token` field set to this
|
258
|
+
# value. This field is empty if there are no more results to retrieve.
|
259
|
+
class ListServicesResponse
|
260
|
+
include Google::Protobuf::MessageExts
|
261
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
262
|
+
end
|
263
|
+
|
264
|
+
# Request message for `ListSkus`.
|
265
|
+
# @!attribute [rw] parent
|
266
|
+
# @return [String]
|
267
|
+
# Required. The name of the service.
|
268
|
+
# Example: "services/DA34-426B-A397"
|
269
|
+
# @!attribute [rw] start_time
|
270
|
+
# @return [Google::Protobuf::Timestamp]
|
271
|
+
# Optional inclusive start time of the time range for which the pricing
|
272
|
+
# versions will be returned. Timestamps in the future are not allowed.
|
273
|
+
# The time range has to be within a single calendar month in
|
274
|
+
# America/Los_Angeles timezone. Time range as a whole is optional. If not
|
275
|
+
# specified, the latest pricing will be returned (up to 12 hours old at
|
276
|
+
# most).
|
277
|
+
# @!attribute [rw] end_time
|
278
|
+
# @return [Google::Protobuf::Timestamp]
|
279
|
+
# Optional exclusive end time of the time range for which the pricing
|
280
|
+
# versions will be returned. Timestamps in the future are not allowed.
|
281
|
+
# The time range has to be within a single calendar month in
|
282
|
+
# America/Los_Angeles timezone. Time range as a whole is optional. If not
|
283
|
+
# specified, the latest pricing will be returned (up to 12 hours old at
|
284
|
+
# most).
|
285
|
+
# @!attribute [rw] currency_code
|
286
|
+
# @return [String]
|
287
|
+
# The ISO 4217 currency code for the pricing info in the response proto.
|
288
|
+
# Will use the conversion rate as of start_time.
|
289
|
+
# Optional. If not specified USD will be used.
|
290
|
+
# @!attribute [rw] page_size
|
291
|
+
# @return [Integer]
|
292
|
+
# Requested page size. Defaults to 5000.
|
293
|
+
# @!attribute [rw] page_token
|
294
|
+
# @return [String]
|
295
|
+
# A token identifying a page of results to return. This should be a
|
296
|
+
# `next_page_token` value returned from a previous `ListSkus`
|
297
|
+
# call. If unspecified, the first page of results is returned.
|
298
|
+
class ListSkusRequest
|
299
|
+
include Google::Protobuf::MessageExts
|
300
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
301
|
+
end
|
302
|
+
|
303
|
+
# Response message for `ListSkus`.
|
304
|
+
# @!attribute [rw] skus
|
305
|
+
# @return [Array<Google::Cloud::Billing::V1::Sku>]
|
306
|
+
# The list of public SKUs of the given service.
|
307
|
+
# @!attribute [rw] next_page_token
|
308
|
+
# @return [String]
|
309
|
+
# A token to retrieve the next page of results. To retrieve the next page,
|
310
|
+
# call `ListSkus` again with the `page_token` field set to this
|
311
|
+
# value. This field is empty if there are no more results to retrieve.
|
312
|
+
class ListSkusResponse
|
313
|
+
include Google::Protobuf::MessageExts
|
314
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
315
|
+
end
|
316
|
+
end
|
317
|
+
end
|
318
|
+
end
|
319
|
+
end
|
@@ -0,0 +1,79 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2020 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
|
20
|
+
module Google
|
21
|
+
module Iam
|
22
|
+
module V1
|
23
|
+
# Request message for `SetIamPolicy` method.
|
24
|
+
# @!attribute [rw] resource
|
25
|
+
# @return [String]
|
26
|
+
# REQUIRED: The resource for which the policy is being specified.
|
27
|
+
# `resource` is usually specified as a path. For example, a Project
|
28
|
+
# resource is specified as `projects/\\\{project\}`.
|
29
|
+
# @!attribute [rw] policy
|
30
|
+
# @return [Google::Iam::V1::Policy]
|
31
|
+
# REQUIRED: The complete policy to be applied to the `resource`. The size of
|
32
|
+
# the policy is limited to a few 10s of KB. An empty policy is a
|
33
|
+
# valid policy but certain Cloud Platform services (such as Projects)
|
34
|
+
# might reject them.
|
35
|
+
class SetIamPolicyRequest
|
36
|
+
include Google::Protobuf::MessageExts
|
37
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
38
|
+
end
|
39
|
+
|
40
|
+
# Request message for `GetIamPolicy` method.
|
41
|
+
# @!attribute [rw] resource
|
42
|
+
# @return [String]
|
43
|
+
# REQUIRED: The resource for which the policy is being requested.
|
44
|
+
# `resource` is usually specified as a path. For example, a Project
|
45
|
+
# resource is specified as `projects/\\\{project\}`.
|
46
|
+
class GetIamPolicyRequest
|
47
|
+
include Google::Protobuf::MessageExts
|
48
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
49
|
+
end
|
50
|
+
|
51
|
+
# Request message for `TestIamPermissions` method.
|
52
|
+
# @!attribute [rw] resource
|
53
|
+
# @return [String]
|
54
|
+
# REQUIRED: The resource for which the policy detail is being requested.
|
55
|
+
# `resource` is usually specified as a path. For example, a Project
|
56
|
+
# resource is specified as `projects/\\\{project\}`.
|
57
|
+
# @!attribute [rw] permissions
|
58
|
+
# @return [Array<String>]
|
59
|
+
# The set of permissions to check for the `resource`. Permissions with
|
60
|
+
# wildcards (such as '*' or 'storage.*') are not allowed. For more
|
61
|
+
# information see
|
62
|
+
# [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
|
63
|
+
class TestIamPermissionsRequest
|
64
|
+
include Google::Protobuf::MessageExts
|
65
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
66
|
+
end
|
67
|
+
|
68
|
+
# Response message for `TestIamPermissions` method.
|
69
|
+
# @!attribute [rw] permissions
|
70
|
+
# @return [Array<String>]
|
71
|
+
# A subset of `TestPermissionsRequest.permissions` that the caller is
|
72
|
+
# allowed.
|
73
|
+
class TestIamPermissionsResponse
|
74
|
+
include Google::Protobuf::MessageExts
|
75
|
+
extend Google::Protobuf::MessageExts::ClassMethods
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
79
|
+
end
|