blob: 28c1a7e43e84346c8876607623dab0d13812831c [file] [log] [blame]
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070075<h1><a href="servicemanagement_v1.html">Service Management API</a> . <a href="servicemanagement_v1.services.html">services</a> . <a href="servicemanagement_v1.services.configs.html">configs</a></h1>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070076<h2>Instance Methods</h2>
77<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070078 <code><a href="#create">create(serviceName, body=None, x__xgafv=None)</a></code></p>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070079<p class="firstline">Creates a new service configuration (version) for a managed service.</p>
80<p class="toc_element">
Bu Sun Kim65020912020-05-20 12:08:20 -070081 <code><a href="#get">get(serviceName, configId, view=None, x__xgafv=None)</a></code></p>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070082<p class="firstline">Gets a service configuration (version) for a managed service.</p>
83<p class="toc_element">
Bu Sun Kimd059ad82020-07-22 17:02:09 -070084 <code><a href="#list">list(serviceName, pageSize=None, pageToken=None, x__xgafv=None)</a></code></p>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070085<p class="firstline">Lists the history of the service configuration for a managed service,</p>
86<p class="toc_element">
87 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
88<p class="firstline">Retrieves the next page of results.</p>
89<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070090 <code><a href="#submit">submit(serviceName, body=None, x__xgafv=None)</a></code></p>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070091<p class="firstline">Creates a new service configuration (version) for a managed service based</p>
92<h3>Method Details</h3>
93<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -070094 <code class="details" id="create">create(serviceName, body=None, x__xgafv=None)</code>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -070095 <pre>Creates a new service configuration (version) for a managed service.
96This method only stores the service configuration. To roll out the service
97configuration to backend systems please call
98CreateServiceRollout.
99
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700100Only the 100 most recent service configurations and ones referenced by
101existing rollouts are kept for each service. The rest will be deleted
102eventually.
103
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700104Args:
Dan O'Mearadd494642020-05-01 07:42:23 -0700105 serviceName: string, Required. The name of the service. See the [overview](/service-management/overview)
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700106for naming requirements. For example: `example.googleapis.com`. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700107 body: object, The request body.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700108 The object takes the form of:
109
Sai Cheemalapatiea3a5e12016-10-12 14:05:53 -0700110{ # `Service` is the root object of Google service configuration schema. It
111 # describes basic information about a service, such as the name and the
112 # title, and delegates other aspects to sub-sections. Each sub-section is
113 # either a proto message or a repeated proto message that configures a
114 # specific aspect, such as auth. See each proto message definition for details.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700115 #
116 # Example:
117 #
118 # type: google.api.Service
Sai Cheemalapatiea3a5e12016-10-12 14:05:53 -0700119 # config_version: 3
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700120 # name: calendar.googleapis.com
121 # title: Google Calendar API
122 # apis:
Sai Cheemalapatiea3a5e12016-10-12 14:05:53 -0700123 # - name: google.calendar.v3.Calendar
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800124 # authentication:
125 # providers:
126 # - id: google_calendar_auth
127 # jwks_uri: https://www.googleapis.com/oauth2/v1/certs
128 # issuer: https://securetoken.google.com
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700129 # rules:
Bu Sun Kim65020912020-05-20 12:08:20 -0700130 # - selector: &quot;*&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800131 # requirements:
132 # provider_id: google_calendar_auth
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700133 &quot;enums&quot;: [ # A list of all enum types included in this API service. Enums
134 # referenced directly or indirectly by the `apis` are automatically
135 # included. Enums which are not referenced but shall be included
136 # should be listed here by name. Example:
137 #
138 # enums:
139 # - name: google.someapi.v1.SomeEnum
140 { # Enum type definition.
141 &quot;options&quot;: [ # Protocol buffer options.
142 { # A protocol buffer option, which can be attached to a message, field,
143 # enumeration, etc.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700144 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
145 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
146 # should be used. If the value is an enum, it should be stored as an int32
147 # value using the google.protobuf.Int32Value type.
148 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
149 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700150 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
151 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
152 # For custom options, it should be the fully-qualified name. For example,
153 # `&quot;google.api.http&quot;`.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700154 },
155 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700156 &quot;enumvalue&quot;: [ # Enum value definitions.
157 { # Enum value definition.
158 &quot;name&quot;: &quot;A String&quot;, # Enum value name.
159 &quot;options&quot;: [ # Protocol buffer options.
160 { # A protocol buffer option, which can be attached to a message, field,
161 # enumeration, etc.
162 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
163 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
164 # should be used. If the value is an enum, it should be stored as an int32
165 # value using the google.protobuf.Int32Value type.
166 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
167 },
168 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
169 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
170 # For custom options, it should be the fully-qualified name. For example,
171 # `&quot;google.api.http&quot;`.
172 },
173 ],
174 &quot;number&quot;: 42, # Enum value number.
175 },
176 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700177 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # The source context.
178 # protobuf element, like the file in which it is defined.
179 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
180 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
181 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700182 &quot;name&quot;: &quot;A String&quot;, # Enum type name.
183 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax.
184 },
185 ],
186 &quot;backend&quot;: { # `Backend` defines the backend configuration for a service. # API backend configuration.
187 &quot;rules&quot;: [ # A list of API backend rules that apply to individual API methods.
188 #
189 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
190 { # A backend rule provides configuration for an individual API element.
191 &quot;disableAuth&quot;: True or False, # When disable_auth is true, a JWT ID token won&#x27;t be generated and the
192 # original &quot;Authorization&quot; HTTP header will be preserved. If the header is
193 # used to carry the original token and is expected by the backend, this
194 # field must be set to true to preserve the header.
195 &quot;address&quot;: &quot;A String&quot;, # The address of the API backend.
196 #
197 # The scheme is used to determine the backend protocol and security.
198 # The following schemes are accepted:
199 #
200 # SCHEME PROTOCOL SECURITY
201 # http:// HTTP None
202 # https:// HTTP TLS
203 # grpc:// gRPC None
204 # grpcs:// gRPC TLS
205 #
206 # It is recommended to explicitly include a scheme. Leaving out the scheme
207 # may cause constrasting behaviors across platforms.
208 #
209 # If the port is unspecified, the default is:
210 # - 80 for schemes without TLS
211 # - 443 for schemes with TLS
212 #
213 # For HTTP backends, use protocol
214 # to specify the protocol version.
215 &quot;minDeadline&quot;: 3.14, # Minimum deadline in seconds needed for this method. Calls having deadline
216 # value lower than this will be rejected.
217 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
218 #
219 # Refer to selector for syntax details.
220 &quot;protocol&quot;: &quot;A String&quot;, # The protocol used for sending a request to the backend.
221 # The supported values are &quot;http/1.1&quot; and &quot;h2&quot;.
222 #
223 # The default value is inferred from the scheme in the
224 # address field:
225 #
226 # SCHEME PROTOCOL
227 # http:// http/1.1
228 # https:// http/1.1
229 # grpc:// h2
230 # grpcs:// h2
231 #
232 # For secure HTTP backends (https://) that support HTTP/2, set this field
233 # to &quot;h2&quot; for improved performance.
234 #
235 # Configuring this field to non-default values is only supported for secure
236 # HTTP backends. This field will be ignored for all other backends.
237 #
238 # See
239 # https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#alpn-protocol-ids
240 # for more details on the supported values.
241 &quot;operationDeadline&quot;: 3.14, # The number of seconds to wait for the completion of a long running
242 # operation. The default is no deadline.
243 &quot;pathTranslation&quot;: &quot;A String&quot;,
244 &quot;jwtAudience&quot;: &quot;A String&quot;, # The JWT audience is used when generating a JWT ID token for the backend.
245 # This ID token will be added in the HTTP &quot;authorization&quot; header, and sent
246 # to the backend.
247 &quot;deadline&quot;: 3.14, # The number of seconds to wait for a response from a request. The default
248 # varies based on the request protocol and deployment environment.
249 },
250 ],
251 },
252 &quot;systemTypes&quot;: [ # A list of all proto message types included in this API service.
253 # It serves similar purpose as [google.api.Service.types], except that
254 # these types are not needed by user-defined APIs. Therefore, they will not
255 # show up in the generated discovery doc. This field should only be used
256 # to define system APIs in ESF.
257 { # A protocol buffer message type.
258 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # The source context.
259 # protobuf element, like the file in which it is defined.
260 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
261 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
262 },
263 &quot;oneofs&quot;: [ # The list of types appearing in `oneof` definitions in this type.
264 &quot;A String&quot;,
265 ],
266 &quot;fields&quot;: [ # The list of fields.
267 { # A single field of a message type.
268 &quot;oneofIndex&quot;: 42, # The index of the field type in `Type.oneofs`, for message or enumeration
269 # types. The first type has index 1; zero means the type is not in the list.
270 &quot;name&quot;: &quot;A String&quot;, # The field name.
271 &quot;defaultValue&quot;: &quot;A String&quot;, # The string value of the default value of this field. Proto2 syntax only.
272 &quot;packed&quot;: True or False, # Whether to use alternative packed wire representation.
273 &quot;typeUrl&quot;: &quot;A String&quot;, # The field type URL, without the scheme, for message or enumeration
274 # types. Example: `&quot;type.googleapis.com/google.protobuf.Timestamp&quot;`.
275 &quot;cardinality&quot;: &quot;A String&quot;, # The field cardinality.
276 &quot;jsonName&quot;: &quot;A String&quot;, # The field JSON name.
277 &quot;kind&quot;: &quot;A String&quot;, # The field type.
278 &quot;options&quot;: [ # The protocol buffer options.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700279 { # A protocol buffer option, which can be attached to a message, field,
280 # enumeration, etc.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700281 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
282 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
283 # should be used. If the value is an enum, it should be stored as an int32
284 # value using the google.protobuf.Int32Value type.
285 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
286 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700287 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
288 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
289 # For custom options, it should be the fully-qualified name. For example,
290 # `&quot;google.api.http&quot;`.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700291 },
292 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700293 &quot;number&quot;: 42, # The field number.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700294 },
295 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700296 &quot;options&quot;: [ # The protocol buffer options.
Bu Sun Kim65020912020-05-20 12:08:20 -0700297 { # A protocol buffer option, which can be attached to a message, field,
298 # enumeration, etc.
299 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
300 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
301 # should be used. If the value is an enum, it should be stored as an int32
302 # value using the google.protobuf.Int32Value type.
303 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
304 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700305 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
306 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
307 # For custom options, it should be the fully-qualified name. For example,
308 # `&quot;google.api.http&quot;`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700309 },
310 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700311 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax.
312 &quot;name&quot;: &quot;A String&quot;, # The fully qualified message name.
Bu Sun Kim65020912020-05-20 12:08:20 -0700313 },
314 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700315 &quot;name&quot;: &quot;A String&quot;, # The service name, which is a DNS-like logical identifier for the
316 # service, such as `calendar.googleapis.com`. The service name
317 # typically goes through DNS verification to make sure the owner
318 # of the service also owns the DNS name.
319 &quot;sourceInfo&quot;: { # Source information used to create a Service Config # Output only. The source information for this configuration if available.
320 &quot;sourceFiles&quot;: [ # All files used during config generation.
321 {
322 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim65020912020-05-20 12:08:20 -0700323 },
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700324 ],
325 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700326 &quot;billing&quot;: { # Billing related configuration of the service. # Billing configuration.
327 #
328 # The following example shows how to configure monitored resources and metrics
329 # for billing, `consumer_destinations` is the only supported destination and
330 # the monitored resources need at least one label key
331 # `cloud.googleapis.com/location` to indicate the location of the billing
332 # usage, using different monitored resources between monitoring and billing is
333 # recommended so they can be evolved independently:
334 #
335 #
336 # monitored_resources:
337 # - type: library.googleapis.com/billing_branch
338 # labels:
339 # - key: cloud.googleapis.com/location
340 # description: |
341 # Predefined label to support billing location restriction.
342 # - key: city
343 # description: |
344 # Custom label to define the city where the library branch is located
345 # in.
346 # - key: name
347 # description: Custom label to define the name of the library branch.
348 # metrics:
349 # - name: library.googleapis.com/book/borrowed_count
350 # metric_kind: DELTA
351 # value_type: INT64
352 # unit: &quot;1&quot;
353 # billing:
354 # consumer_destinations:
355 # - monitored_resource: library.googleapis.com/billing_branch
356 # metrics:
357 # - library.googleapis.com/book/borrowed_count
358 &quot;consumerDestinations&quot;: [ # Billing configurations for sending metrics to the consumer project.
359 # There can be multiple consumer destinations per service, each one must have
360 # a different monitored resource type. A metric can be used in at most
361 # one consumer destination.
362 { # Configuration of a specific billing destination (Currently only support
363 # bill against consumer project).
364 &quot;metrics&quot;: [ # Names of the metrics to report to this billing destination.
365 # Each name must be defined in Service.metrics section.
366 &quot;A String&quot;,
367 ],
368 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in
369 # Service.monitored_resources section.
370 },
371 ],
372 },
373 &quot;monitoring&quot;: { # Monitoring configuration of the service. # Monitoring configuration.
374 #
375 # The example below shows how to configure monitored resources and metrics
376 # for monitoring. In the example, a monitored resource and two metrics are
377 # defined. The `library.googleapis.com/book/returned_count` metric is sent
378 # to both producer and consumer projects, whereas the
379 # `library.googleapis.com/book/num_overdue` metric is only sent to the
380 # consumer project.
381 #
382 # monitored_resources:
383 # - type: library.googleapis.com/Branch
384 # display_name: &quot;Library Branch&quot;
385 # description: &quot;A branch of a library.&quot;
386 # launch_stage: GA
387 # labels:
388 # - key: resource_container
389 # description: &quot;The Cloud container (ie. project id) for the Branch.&quot;
390 # - key: location
391 # description: &quot;The location of the library branch.&quot;
392 # - key: branch_id
393 # description: &quot;The id of the branch.&quot;
394 # metrics:
395 # - name: library.googleapis.com/book/returned_count
396 # display_name: &quot;Books Returned&quot;
397 # description: &quot;The count of books that have been returned.&quot;
398 # launch_stage: GA
399 # metric_kind: DELTA
400 # value_type: INT64
401 # unit: &quot;1&quot;
402 # labels:
403 # - key: customer_id
404 # description: &quot;The id of the customer.&quot;
405 # - name: library.googleapis.com/book/num_overdue
406 # display_name: &quot;Books Overdue&quot;
407 # description: &quot;The current number of overdue books.&quot;
408 # launch_stage: GA
409 # metric_kind: GAUGE
410 # value_type: INT64
411 # unit: &quot;1&quot;
412 # labels:
413 # - key: customer_id
414 # description: &quot;The id of the customer.&quot;
415 # monitoring:
416 # producer_destinations:
417 # - monitored_resource: library.googleapis.com/Branch
418 # metrics:
419 # - library.googleapis.com/book/returned_count
420 # consumer_destinations:
421 # - monitored_resource: library.googleapis.com/Branch
422 # metrics:
423 # - library.googleapis.com/book/returned_count
424 # - library.googleapis.com/book/num_overdue
425 &quot;producerDestinations&quot;: [ # Monitoring configurations for sending metrics to the producer project.
426 # There can be multiple producer destinations. A monitored resource type may
427 # appear in multiple monitoring destinations if different aggregations are
428 # needed for different sets of metrics associated with that monitored
429 # resource type. A monitored resource and metric pair may only be used once
430 # in the Monitoring configuration.
431 { # Configuration of a specific monitoring destination (the producer project
432 # or the consumer project).
433 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in
434 # Service.monitored_resources section.
435 &quot;metrics&quot;: [ # Types of the metrics to report to this monitoring destination.
436 # Each type must be defined in Service.metrics section.
437 &quot;A String&quot;,
438 ],
439 },
440 ],
441 &quot;consumerDestinations&quot;: [ # Monitoring configurations for sending metrics to the consumer project.
442 # There can be multiple consumer destinations. A monitored resource type may
443 # appear in multiple monitoring destinations if different aggregations are
444 # needed for different sets of metrics associated with that monitored
445 # resource type. A monitored resource and metric pair may only be used once
446 # in the Monitoring configuration.
447 { # Configuration of a specific monitoring destination (the producer project
448 # or the consumer project).
449 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in
450 # Service.monitored_resources section.
451 &quot;metrics&quot;: [ # Types of the metrics to report to this monitoring destination.
452 # Each type must be defined in Service.metrics section.
453 &quot;A String&quot;,
454 ],
455 },
456 ],
457 },
458 &quot;logging&quot;: { # Logging configuration of the service. # Logging configuration.
459 #
460 # The following example shows how to configure logs to be sent to the
461 # producer and consumer projects. In the example, the `activity_history`
462 # log is sent to both the producer and consumer projects, whereas the
463 # `purchase_history` log is only sent to the producer project.
464 #
465 # monitored_resources:
466 # - type: library.googleapis.com/branch
467 # labels:
468 # - key: /city
469 # description: The city where the library branch is located in.
470 # - key: /name
471 # description: The name of the branch.
472 # logs:
473 # - name: activity_history
474 # labels:
475 # - key: /customer_id
476 # - name: purchase_history
477 # logging:
478 # producer_destinations:
479 # - monitored_resource: library.googleapis.com/branch
480 # logs:
481 # - activity_history
482 # - purchase_history
483 # consumer_destinations:
484 # - monitored_resource: library.googleapis.com/branch
485 # logs:
486 # - activity_history
487 &quot;producerDestinations&quot;: [ # Logging configurations for sending logs to the producer project.
488 # There can be multiple producer destinations, each one must have a
489 # different monitored resource type. A log can be used in at most
490 # one producer destination.
491 { # Configuration of a specific logging destination (the producer project
492 # or the consumer project).
493 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in the
494 # Service.monitored_resources section.
495 &quot;logs&quot;: [ # Names of the logs to be sent to this destination. Each name must
496 # be defined in the Service.logs section. If the log name is
497 # not a domain scoped name, it will be automatically prefixed with
498 # the service name followed by &quot;/&quot;.
499 &quot;A String&quot;,
500 ],
501 },
502 ],
503 &quot;consumerDestinations&quot;: [ # Logging configurations for sending logs to the consumer project.
504 # There can be multiple consumer destinations, each one must have a
505 # different monitored resource type. A log can be used in at most
506 # one consumer destination.
507 { # Configuration of a specific logging destination (the producer project
508 # or the consumer project).
509 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in the
510 # Service.monitored_resources section.
511 &quot;logs&quot;: [ # Names of the logs to be sent to this destination. Each name must
512 # be defined in the Service.logs section. If the log name is
513 # not a domain scoped name, it will be automatically prefixed with
514 # the service name followed by &quot;/&quot;.
515 &quot;A String&quot;,
516 ],
517 },
518 ],
519 },
520 &quot;control&quot;: { # Selects and configures the service controller used by the service. The # Configuration for the service control plane.
521 # service controller handles features like abuse, quota, billing, logging,
522 # monitoring, etc.
523 &quot;environment&quot;: &quot;A String&quot;, # The service control environment to use. If empty, no control plane
524 # feature (like quota and billing) will be enabled.
525 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700526 &quot;usage&quot;: { # Configuration controlling usage of a service. # Configuration controlling usage of this service.
527 &quot;requirements&quot;: [ # Requirements that must be satisfied before a consumer project can use the
528 # service. Each requirement is of the form &lt;service.name&gt;/&lt;requirement-id&gt;;
529 # for example &#x27;serviceusage.googleapis.com/billing-enabled&#x27;.
530 &quot;A String&quot;,
531 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700532 &quot;serviceIdentity&quot;: { # The per-product per-project service identity for a service. # The configuration of a per-product per-project service identity.
533 #
534 #
535 # Use this field to configure per-product per-project service identity.
536 # Example of a service identity configuration.
537 #
538 # usage:
539 # service_identity:
540 # - service_account_parent: &quot;projects/123456789&quot;
541 # display_name: &quot;Cloud XXX Service Agent&quot;
542 # description: &quot;Used as the identity of Cloud XXX to access resources&quot;
543 &quot;serviceAccountParent&quot;: &quot;A String&quot;, # A service account project that hosts the service accounts.
544 #
545 # An example name would be:
546 # `projects/123456789`
547 &quot;description&quot;: &quot;A String&quot;, # Optional. A user-specified opaque description of the service account.
548 # Must be less than or equal to 256 UTF-8 bytes.
549 &quot;displayName&quot;: &quot;A String&quot;, # Optional. A user-specified name for the service account.
550 # Must be less than or equal to 100 UTF-8 bytes.
551 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700552 &quot;rules&quot;: [ # A list of usage rules that apply to individual API methods.
553 #
554 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
555 { # Usage configuration rules for the service.
556 #
557 # NOTE: Under development.
558 #
559 #
560 # Use this rule to configure unregistered calls for the service. Unregistered
561 # calls are calls that do not contain consumer project identity.
562 # (Example: calls that do not contain an API key).
563 # By default, API methods do not allow unregistered calls, and each method call
564 # must be identified by a consumer project identity. Use this rule to
565 # allow/disallow unregistered calls.
566 #
567 # Example of an API that wants to allow unregistered calls for entire service.
568 #
569 # usage:
570 # rules:
571 # - selector: &quot;*&quot;
572 # allow_unregistered_calls: true
573 #
574 # Example of a method that wants to allow unregistered calls.
575 #
576 # usage:
577 # rules:
578 # - selector: &quot;google.example.library.v1.LibraryService.CreateBook&quot;
579 # allow_unregistered_calls: true
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700580 &quot;skipServiceControl&quot;: True or False, # If true, the selected method should skip service control and the control
581 # plane features, such as quota and billing, will not be available.
582 # This flag is used by Google Cloud Endpoints to bypass checks for internal
583 # methods, such as service health check methods.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700584 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies. Use &#x27;*&#x27; to indicate all
585 # methods in all APIs.
586 #
587 # Refer to selector for syntax details.
588 &quot;allowUnregisteredCalls&quot;: True or False, # If true, the selected method allows unregistered calls, e.g. calls
589 # that don&#x27;t identify any user or application.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700590 },
591 ],
592 &quot;producerNotificationChannel&quot;: &quot;A String&quot;, # The full resource name of a channel used for sending notifications to the
593 # service producer.
594 #
595 # Google Service Management currently only supports
596 # [Google Cloud Pub/Sub](https://cloud.google.com/pubsub) as a notification
597 # channel. To use Google Cloud Pub/Sub as the channel, this must be the name
598 # of a Cloud Pub/Sub topic that uses the Cloud Pub/Sub topic name format
599 # documented in https://cloud.google.com/pubsub/docs/overview.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700600 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700601 &quot;types&quot;: [ # A list of all proto message types included in this API service.
602 # Types referenced directly or indirectly by the `apis` are
603 # automatically included. Messages which are not referenced but
604 # shall be included, such as types used by the `google.protobuf.Any` type,
605 # should be listed here by name. Example:
606 #
607 # types:
608 # - name: google.protobuf.Int32
609 { # A protocol buffer message type.
610 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # The source context.
611 # protobuf element, like the file in which it is defined.
612 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
613 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
614 },
615 &quot;oneofs&quot;: [ # The list of types appearing in `oneof` definitions in this type.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700616 &quot;A String&quot;,
617 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700618 &quot;fields&quot;: [ # The list of fields.
619 { # A single field of a message type.
620 &quot;oneofIndex&quot;: 42, # The index of the field type in `Type.oneofs`, for message or enumeration
621 # types. The first type has index 1; zero means the type is not in the list.
622 &quot;name&quot;: &quot;A String&quot;, # The field name.
623 &quot;defaultValue&quot;: &quot;A String&quot;, # The string value of the default value of this field. Proto2 syntax only.
624 &quot;packed&quot;: True or False, # Whether to use alternative packed wire representation.
625 &quot;typeUrl&quot;: &quot;A String&quot;, # The field type URL, without the scheme, for message or enumeration
626 # types. Example: `&quot;type.googleapis.com/google.protobuf.Timestamp&quot;`.
627 &quot;cardinality&quot;: &quot;A String&quot;, # The field cardinality.
628 &quot;jsonName&quot;: &quot;A String&quot;, # The field JSON name.
629 &quot;kind&quot;: &quot;A String&quot;, # The field type.
630 &quot;options&quot;: [ # The protocol buffer options.
631 { # A protocol buffer option, which can be attached to a message, field,
632 # enumeration, etc.
633 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
634 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
635 # should be used. If the value is an enum, it should be stored as an int32
636 # value using the google.protobuf.Int32Value type.
637 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
638 },
639 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
640 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
641 # For custom options, it should be the fully-qualified name. For example,
642 # `&quot;google.api.http&quot;`.
643 },
644 ],
645 &quot;number&quot;: 42, # The field number.
646 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700647 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700648 &quot;options&quot;: [ # The protocol buffer options.
649 { # A protocol buffer option, which can be attached to a message, field,
650 # enumeration, etc.
651 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
652 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
653 # should be used. If the value is an enum, it should be stored as an int32
654 # value using the google.protobuf.Int32Value type.
655 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
656 },
657 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
658 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
659 # For custom options, it should be the fully-qualified name. For example,
660 # `&quot;google.api.http&quot;`.
661 },
662 ],
663 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax.
664 &quot;name&quot;: &quot;A String&quot;, # The fully qualified message name.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700665 },
666 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700667 &quot;http&quot;: { # Defines the HTTP configuration for an API service. It contains a list of # HTTP configuration.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700668 # HttpRule, each specifying the mapping of an RPC method
669 # to one or more HTTP REST API methods.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700670 &quot;fullyDecodeReservedExpansion&quot;: True or False, # When set to true, URL path parameters will be fully URI-decoded except in
671 # cases of single segment matches in reserved expansion, where &quot;%2F&quot; will be
672 # left encoded.
673 #
674 # The default behavior is to not decode RFC 6570 reserved characters in multi
675 # segment matches.
Bu Sun Kim65020912020-05-20 12:08:20 -0700676 &quot;rules&quot;: [ # A list of HTTP configuration rules that apply to individual API methods.
677 #
678 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700679 { # # gRPC Transcoding
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700680 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700681 # gRPC Transcoding is a feature for mapping between a gRPC method and one or
682 # more HTTP REST endpoints. It allows developers to build a single API service
683 # that supports both gRPC APIs and REST APIs. Many systems, including [Google
684 # APIs](https://github.com/googleapis/googleapis),
685 # [Cloud Endpoints](https://cloud.google.com/endpoints), [gRPC
686 # Gateway](https://github.com/grpc-ecosystem/grpc-gateway),
687 # and [Envoy](https://github.com/envoyproxy/envoy) proxy support this feature
688 # and use it for large scale production services.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700689 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700690 # `HttpRule` defines the schema of the gRPC/REST mapping. The mapping specifies
691 # how different portions of the gRPC request message are mapped to the URL
692 # path, URL query parameters, and HTTP request body. It also controls how the
693 # gRPC response message is mapped to the HTTP response body. `HttpRule` is
694 # typically specified as an `google.api.http` annotation on the gRPC method.
695 #
696 # Each mapping specifies a URL path template and an HTTP method. The path
697 # template may refer to one or more fields in the gRPC request message, as long
698 # as each field is a non-repeated field with a primitive (non-message) type.
699 # The path template controls how fields of the request message are mapped to
700 # the URL path.
701 #
702 # Example:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800703 #
704 # service Messaging {
705 # rpc GetMessage(GetMessageRequest) returns (Message) {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700706 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -0700707 # get: &quot;/v1/{name=messages/*}&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700708 # };
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800709 # }
710 # }
711 # message GetMessageRequest {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700712 # string name = 1; // Mapped to URL path.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800713 # }
714 # message Message {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700715 # string text = 1; // The resource content.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800716 # }
717 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700718 # This enables an HTTP REST to gRPC mapping as below:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800719 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700720 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700721 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -0700722 # `GET /v1/messages/123456` | `GetMessage(name: &quot;messages/123456&quot;)`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700723 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700724 # Any fields in the request message which are not bound by the path template
725 # automatically become HTTP query parameters if there is no HTTP request body.
726 # For example:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800727 #
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400728 # service Messaging {
729 # rpc GetMessage(GetMessageRequest) returns (Message) {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700730 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -0700731 # get:&quot;/v1/messages/{message_id}&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700732 # };
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400733 # }
734 # }
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800735 # message GetMessageRequest {
736 # message SubMessage {
737 # string subfield = 1;
738 # }
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700739 # string message_id = 1; // Mapped to URL path.
740 # int64 revision = 2; // Mapped to URL query parameter `revision`.
741 # SubMessage sub = 3; // Mapped to URL query parameter `sub.subfield`.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800742 # }
743 #
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700744 # This enables a HTTP JSON to RPC mapping as below:
745 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700746 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700747 # -----|-----
Dan O'Mearadd494642020-05-01 07:42:23 -0700748 # `GET /v1/messages/123456?revision=2&amp;sub.subfield=foo` |
Bu Sun Kim65020912020-05-20 12:08:20 -0700749 # `GetMessage(message_id: &quot;123456&quot; revision: 2 sub: SubMessage(subfield:
750 # &quot;foo&quot;))`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700751 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700752 # Note that fields which are mapped to URL query parameters must have a
753 # primitive type or a repeated primitive type or a non-repeated message type.
754 # In the case of a repeated type, the parameter can be repeated in the URL
Dan O'Mearadd494642020-05-01 07:42:23 -0700755 # as `...?param=A&amp;param=B`. In the case of a message type, each field of the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700756 # message is mapped to a separate parameter, such as
Dan O'Mearadd494642020-05-01 07:42:23 -0700757 # `...?foo.a=A&amp;foo.b=B&amp;foo.c=C`.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700758 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700759 # For HTTP methods that allow a request body, the `body` field
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700760 # specifies the mapping. Consider a REST update method on the
761 # message resource collection:
762 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800763 # service Messaging {
764 # rpc UpdateMessage(UpdateMessageRequest) returns (Message) {
765 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -0700766 # patch: &quot;/v1/messages/{message_id}&quot;
767 # body: &quot;message&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800768 # };
769 # }
770 # }
771 # message UpdateMessageRequest {
772 # string message_id = 1; // mapped to the URL
773 # Message message = 2; // mapped to the body
774 # }
775 #
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700776 # The following HTTP JSON to RPC mapping is enabled, where the
777 # representation of the JSON in the request body is determined by
778 # protos JSON encoding:
779 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700780 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700781 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -0700782 # `PATCH /v1/messages/123456 { &quot;text&quot;: &quot;Hi!&quot; }` | `UpdateMessage(message_id:
783 # &quot;123456&quot; message { text: &quot;Hi!&quot; })`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700784 #
785 # The special name `*` can be used in the body mapping to define that
786 # every field not bound by the path template should be mapped to the
787 # request body. This enables the following alternative definition of
788 # the update method:
789 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800790 # service Messaging {
791 # rpc UpdateMessage(Message) returns (Message) {
792 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -0700793 # patch: &quot;/v1/messages/{message_id}&quot;
794 # body: &quot;*&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800795 # };
796 # }
797 # }
798 # message Message {
799 # string message_id = 1;
800 # string text = 2;
801 # }
802 #
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700803 #
804 # The following HTTP JSON to RPC mapping is enabled:
805 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700806 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700807 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -0700808 # `PATCH /v1/messages/123456 { &quot;text&quot;: &quot;Hi!&quot; }` | `UpdateMessage(message_id:
809 # &quot;123456&quot; text: &quot;Hi!&quot;)`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700810 #
811 # Note that when using `*` in the body mapping, it is not possible to
812 # have HTTP parameters, as all fields not bound by the path end in
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700813 # the body. This makes this option more rarely used in practice when
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700814 # defining REST APIs. The common usage of `*` is in custom methods
Bu Sun Kim65020912020-05-20 12:08:20 -0700815 # which don&#x27;t use the URL at all for transferring data.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700816 #
817 # It is possible to define multiple HTTP methods for one RPC by using
818 # the `additional_bindings` option. Example:
819 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800820 # service Messaging {
821 # rpc GetMessage(GetMessageRequest) returns (Message) {
822 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -0700823 # get: &quot;/v1/messages/{message_id}&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800824 # additional_bindings {
Bu Sun Kim65020912020-05-20 12:08:20 -0700825 # get: &quot;/v1/users/{user_id}/messages/{message_id}&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800826 # }
827 # };
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700828 # }
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800829 # }
830 # message GetMessageRequest {
831 # string message_id = 1;
832 # string user_id = 2;
833 # }
834 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700835 # This enables the following two alternative HTTP JSON to RPC mappings:
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700836 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700837 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700838 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -0700839 # `GET /v1/messages/123456` | `GetMessage(message_id: &quot;123456&quot;)`
840 # `GET /v1/users/me/messages/123456` | `GetMessage(user_id: &quot;me&quot; message_id:
841 # &quot;123456&quot;)`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700842 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700843 # ## Rules for HTTP mapping
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700844 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700845 # 1. Leaf request fields (recursive expansion nested messages in the request
846 # message) are classified into three categories:
847 # - Fields referred by the path template. They are passed via the URL path.
848 # - Fields referred by the HttpRule.body. They are passed via the HTTP
849 # request body.
850 # - All other fields are passed via the URL query parameters, and the
851 # parameter name is the field path in the request message. A repeated
852 # field can be represented as multiple query parameters under the same
853 # name.
Bu Sun Kim65020912020-05-20 12:08:20 -0700854 # 2. If HttpRule.body is &quot;*&quot;, there is no URL query parameter, all fields
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700855 # are passed via URL path and HTTP request body.
856 # 3. If HttpRule.body is omitted, there is no HTTP request body, all
857 # fields are passed via URL path and URL query parameters.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700858 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700859 # ### Path template syntax
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700860 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700861 # Template = &quot;/&quot; Segments [ Verb ] ;
862 # Segments = Segment { &quot;/&quot; Segment } ;
863 # Segment = &quot;*&quot; | &quot;**&quot; | LITERAL | Variable ;
864 # Variable = &quot;{&quot; FieldPath [ &quot;=&quot; Segments ] &quot;}&quot; ;
865 # FieldPath = IDENT { &quot;.&quot; IDENT } ;
866 # Verb = &quot;:&quot; LITERAL ;
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700867 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700868 # The syntax `*` matches a single URL path segment. The syntax `**` matches
869 # zero or more URL path segments, which must be the last part of the URL path
870 # except the `Verb`.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700871 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700872 # The syntax `Variable` matches part of the URL path as specified by its
873 # template. A variable template must not contain other variables. If a variable
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700874 # matches a single path segment, its template may be omitted, e.g. `{var}`
875 # is equivalent to `{var=*}`.
876 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700877 # The syntax `LITERAL` matches literal text in the URL path. If the `LITERAL`
878 # contains any reserved character, such characters should be percent-encoded
879 # before the matching.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -0700880 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700881 # If a variable contains exactly one path segment, such as `&quot;{var}&quot;` or
882 # `&quot;{var=*}&quot;`, when such a variable is expanded into a URL path on the client
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700883 # side, all characters except `[-_.~0-9a-zA-Z]` are percent-encoded. The
884 # server side does the reverse decoding. Such variables show up in the
885 # [Discovery
886 # Document](https://developers.google.com/discovery/v1/reference/apis) as
887 # `{var}`.
888 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700889 # If a variable contains multiple path segments, such as `&quot;{var=foo/*}&quot;`
890 # or `&quot;{var=**}&quot;`, when such a variable is expanded into a URL path on the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700891 # client side, all characters except `[-_.~/0-9a-zA-Z]` are percent-encoded.
Bu Sun Kim65020912020-05-20 12:08:20 -0700892 # The server side does the reverse decoding, except &quot;%2F&quot; and &quot;%2f&quot; are left
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700893 # unchanged. Such variables show up in the
894 # [Discovery
895 # Document](https://developers.google.com/discovery/v1/reference/apis) as
896 # `{+var}`.
897 #
898 # ## Using gRPC API Service Configuration
899 #
900 # gRPC API Service Configuration (service config) is a configuration language
901 # for configuring a gRPC service to become a user-facing product. The
902 # service config is simply the YAML representation of the `google.api.Service`
903 # proto message.
904 #
905 # As an alternative to annotating your proto file, you can configure gRPC
906 # transcoding in your service config YAML files. You do this by specifying a
907 # `HttpRule` that maps the gRPC method to a REST endpoint, achieving the same
908 # effect as the proto annotation. This can be particularly useful if you
909 # have a proto that is reused in multiple services. Note that any transcoding
910 # specified in the service config will override any matching transcoding
911 # configuration in the proto.
912 #
913 # Example:
914 #
915 # http:
916 # rules:
917 # # Selects a gRPC method and applies HttpRule to it.
918 # - selector: example.v1.Messaging.GetMessage
919 # get: /v1/messages/{message_id}/{sub.subfield}
920 #
921 # ## Special notes
922 #
923 # When gRPC Transcoding is used to map a gRPC to JSON REST endpoints, the
924 # proto to JSON conversion must follow the [proto3
925 # specification](https://developers.google.com/protocol-buffers/docs/proto3#json).
926 #
927 # While the single segment variable follows the semantics of
928 # [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.2 Simple String
929 # Expansion, the multi segment variable **does not** follow RFC 6570 Section
930 # 3.2.3 Reserved Expansion. The reason is that the Reserved Expansion
931 # does not expand special characters like `?` and `#`, which would lead
932 # to invalid URLs. As the result, gRPC Transcoding uses a custom encoding
933 # for multi segment variables.
934 #
935 # The path variables **must not** refer to any repeated or mapped field,
936 # because client libraries are not capable of handling such variable expansion.
937 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700938 # The path variables **must not** capture the leading &quot;/&quot; character. The reason
939 # is that the most common use case &quot;{var}&quot; does not capture the leading &quot;/&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700940 # character. For consistency, all path variables must share the same behavior.
941 #
942 # Repeated message fields must not be mapped to URL query parameters, because
943 # no client library can support such complicated mapping.
944 #
945 # If an API needs to use a JSON array for request or response body, it can map
946 # the request or response body to a repeated field. However, some gRPC
947 # Transcoding implementations may not support this feature.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700948 &quot;put&quot;: &quot;A String&quot;, # Maps to HTTP PUT. Used for replacing a resource.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700949 &quot;selector&quot;: &quot;A String&quot;, # Selects a method to which this rule applies.
950 #
951 # Refer to selector for syntax details.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700952 &quot;post&quot;: &quot;A String&quot;, # Maps to HTTP POST. Used for creating a resource or performing an action.
953 &quot;responseBody&quot;: &quot;A String&quot;, # Optional. The name of the response field whose value is mapped to the HTTP
954 # response body. When omitted, the entire response message will be used
955 # as the HTTP response body.
956 #
957 # NOTE: The referred field must be present at the top-level of the response
958 # message type.
959 &quot;body&quot;: &quot;A String&quot;, # The name of the request field whose value is mapped to the HTTP request
960 # body, or `*` for mapping all request fields not captured by the path
961 # pattern to the HTTP body, or omitted for not having any HTTP request body.
962 #
963 # NOTE: the referred field must be present at the top-level of the request
964 # message type.
965 &quot;patch&quot;: &quot;A String&quot;, # Maps to HTTP PATCH. Used for updating a resource.
966 &quot;additionalBindings&quot;: [ # Additional HTTP bindings for the selector. Nested bindings must
967 # not contain an `additional_bindings` field themselves (that is,
968 # the nesting may only be one level deep).
969 # Object with schema name: HttpRule
970 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700971 &quot;custom&quot;: { # A custom pattern is used for defining custom HTTP verb. # The custom pattern is used for specifying an HTTP method that is not
972 # included in the `pattern` field, such as HEAD, or &quot;*&quot; to leave the
973 # HTTP method unspecified for this rule. The wild-card rule is useful
974 # for services that provide content to Web (HTML) clients.
975 &quot;path&quot;: &quot;A String&quot;, # The path matched by this custom verb.
976 &quot;kind&quot;: &quot;A String&quot;, # The name of this custom HTTP verb.
977 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700978 &quot;allowHalfDuplex&quot;: True or False, # When this flag is set to true, HTTP requests will be allowed to invoke a
979 # half-duplex streaming method.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700980 &quot;delete&quot;: &quot;A String&quot;, # Maps to HTTP DELETE. Used for deleting a resource.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700981 &quot;get&quot;: &quot;A String&quot;, # Maps to HTTP GET. Used for listing and getting information about
982 # resources.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700983 },
984 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700985 },
986 &quot;logs&quot;: [ # Defines the logs used by this service.
987 { # A description of a log type. Example in YAML format:
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700988 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700989 # - name: library.googleapis.com/activity_history
990 # description: The history of borrowing and returning library items.
991 # display_name: Activity
992 # labels:
993 # - key: /customer_id
994 # description: Identifier of a library customer
995 &quot;description&quot;: &quot;A String&quot;, # A human-readable description of this log. This information appears in
996 # the documentation and can contain details.
997 &quot;labels&quot;: [ # The set of labels that are available to describe a specific log entry.
998 # Runtime requests that contain labels not specified here are
999 # considered invalid.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001000 { # A description of a label.
1001 &quot;valueType&quot;: &quot;A String&quot;, # The type of data that can be assigned to the label.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001002 &quot;description&quot;: &quot;A String&quot;, # A human-readable description for the label.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001003 &quot;key&quot;: &quot;A String&quot;, # The label key.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001004 },
1005 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001006 &quot;displayName&quot;: &quot;A String&quot;, # The human-readable name for this log. This information appears on
1007 # the user interface and should be concise.
1008 &quot;name&quot;: &quot;A String&quot;, # The name of the log. It must be less than 512 characters long and can
1009 # include the following characters: upper- and lower-case alphanumeric
1010 # characters [A-Za-z0-9], and punctuation characters including
1011 # slash, underscore, hyphen, period [/_-.].
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001012 },
1013 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001014 &quot;metrics&quot;: [ # Defines the metrics used by this service.
1015 { # Defines a metric type and its schema. Once a metric descriptor is created,
1016 # deleting or altering it stops data collection and makes the metric type&#x27;s
1017 # existing data unusable.
1018 #
1019 # The following are specific rules for service defined Monitoring metric
1020 # descriptors:
1021 #
1022 # * `type`, `metric_kind`, `value_type`, `description`, and `display_name`
1023 # fields are all required. The `unit` field must be specified
1024 # if the `value_type` is any of DOUBLE, INT64, DISTRIBUTION.
1025 # * Maximum of default 500 metric descriptors per service is allowed.
1026 # * Maximum of default 10 labels per metric descriptor is allowed.
1027 #
1028 # The default maximum limit can be overridden. Please follow
1029 # https://cloud.google.com/monitoring/quotas
1030 &quot;unit&quot;: &quot;A String&quot;, # The units in which the metric value is reported. It is only applicable
1031 # if the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The `unit`
1032 # defines the representation of the stored metric values.
1033 #
1034 # Different systems may scale the values to be more easily displayed (so a
1035 # value of `0.02KBy` _might_ be displayed as `20By`, and a value of
1036 # `3523KBy` _might_ be displayed as `3.5MBy`). However, if the `unit` is
1037 # `KBy`, then the value of the metric is always in thousands of bytes, no
1038 # matter how it may be displayed..
1039 #
1040 # If you want a custom metric to record the exact number of CPU-seconds used
1041 # by a job, you can create an `INT64 CUMULATIVE` metric whose `unit` is
1042 # `s{CPU}` (or equivalently `1s{CPU}` or just `s`). If the job uses 12,005
1043 # CPU-seconds, then the value is written as `12005`.
1044 #
1045 # Alternatively, if you want a custom metric to record data in a more
1046 # granular way, you can create a `DOUBLE CUMULATIVE` metric whose `unit` is
1047 # `ks{CPU}`, and then write the value `12.005` (which is `12005/1000`),
1048 # or use `Kis{CPU}` and write `11.723` (which is `12005/1024`).
1049 #
1050 # The supported units are a subset of [The Unified Code for Units of
1051 # Measure](http://unitsofmeasure.org/ucum.html) standard:
1052 #
1053 # **Basic units (UNIT)**
1054 #
1055 # * `bit` bit
1056 # * `By` byte
1057 # * `s` second
1058 # * `min` minute
1059 # * `h` hour
1060 # * `d` day
1061 # * `1` dimensionless
1062 #
1063 # **Prefixes (PREFIX)**
1064 #
1065 # * `k` kilo (10^3)
1066 # * `M` mega (10^6)
1067 # * `G` giga (10^9)
1068 # * `T` tera (10^12)
1069 # * `P` peta (10^15)
1070 # * `E` exa (10^18)
1071 # * `Z` zetta (10^21)
1072 # * `Y` yotta (10^24)
1073 #
1074 # * `m` milli (10^-3)
1075 # * `u` micro (10^-6)
1076 # * `n` nano (10^-9)
1077 # * `p` pico (10^-12)
1078 # * `f` femto (10^-15)
1079 # * `a` atto (10^-18)
1080 # * `z` zepto (10^-21)
1081 # * `y` yocto (10^-24)
1082 #
1083 # * `Ki` kibi (2^10)
1084 # * `Mi` mebi (2^20)
1085 # * `Gi` gibi (2^30)
1086 # * `Ti` tebi (2^40)
1087 # * `Pi` pebi (2^50)
1088 #
1089 # **Grammar**
1090 #
1091 # The grammar also includes these connectors:
1092 #
1093 # * `/` division or ratio (as an infix operator). For examples,
1094 # `kBy/{email}` or `MiBy/10ms` (although you should almost never
1095 # have `/s` in a metric `unit`; rates should always be computed at
1096 # query time from the underlying cumulative or delta value).
1097 # * `.` multiplication or composition (as an infix operator). For
1098 # examples, `GBy.d` or `k{watt}.h`.
1099 #
1100 # The grammar for a unit is as follows:
1101 #
1102 # Expression = Component { &quot;.&quot; Component } { &quot;/&quot; Component } ;
1103 #
1104 # Component = ( [ PREFIX ] UNIT | &quot;%&quot; ) [ Annotation ]
1105 # | Annotation
1106 # | &quot;1&quot;
1107 # ;
1108 #
1109 # Annotation = &quot;{&quot; NAME &quot;}&quot; ;
1110 #
1111 # Notes:
1112 #
1113 # * `Annotation` is just a comment if it follows a `UNIT`. If the annotation
1114 # is used alone, then the unit is equivalent to `1`. For examples,
1115 # `{request}/s == 1/s`, `By{transmitted}/s == By/s`.
1116 # * `NAME` is a sequence of non-blank printable ASCII characters not
1117 # containing `{` or `}`.
1118 # * `1` represents a unitary [dimensionless
1119 # unit](https://en.wikipedia.org/wiki/Dimensionless_quantity) of 1, such
1120 # as in `1/s`. It is typically used when none of the basic units are
1121 # appropriate. For example, &quot;new users per day&quot; can be represented as
1122 # `1/d` or `{new-users}/d` (and a metric value `5` would mean &quot;5 new
1123 # users). Alternatively, &quot;thousands of page views per day&quot; would be
1124 # represented as `1000/d` or `k1/d` or `k{page_views}/d` (and a metric
1125 # value of `5.3` would mean &quot;5300 page views per day&quot;).
1126 # * `%` represents dimensionless value of 1/100, and annotates values giving
1127 # a percentage (so the metric values are typically in the range of 0..100,
1128 # and a metric value `3` means &quot;3 percent&quot;).
1129 # * `10^2.%` indicates a metric contains a ratio, typically in the range
1130 # 0..1, that will be multiplied by 100 and displayed as a percentage
1131 # (so a metric value `0.03` means &quot;3 percent&quot;).
1132 &quot;displayName&quot;: &quot;A String&quot;, # A concise name for the metric, which can be displayed in user interfaces.
1133 # Use sentence case without an ending period, for example &quot;Request count&quot;.
1134 # This field is optional but it is recommended to be set for any metrics
1135 # associated with user-visible concepts, such as Quota.
1136 &quot;monitoredResourceTypes&quot;: [ # Read-only. If present, then a time
1137 # series, which is identified partially by
1138 # a metric type and a MonitoredResourceDescriptor, that is associated
1139 # with this metric type can only be associated with one of the monitored
1140 # resource types listed here.
1141 &quot;A String&quot;,
1142 ],
1143 &quot;metadata&quot;: { # Additional annotations that can be used to guide the usage of a metric. # Optional. Metadata which can be used to guide usage of the metric.
1144 &quot;samplePeriod&quot;: &quot;A String&quot;, # The sampling period of metric data points. For metrics which are written
1145 # periodically, consecutive data points are stored at this time interval,
1146 # excluding data loss due to errors. Metrics with a higher granularity have
1147 # a smaller sampling period.
1148 &quot;ingestDelay&quot;: &quot;A String&quot;, # The delay of data points caused by ingestion. Data points older than this
1149 # age are guaranteed to be ingested and available to be read, excluding
1150 # data loss due to errors.
1151 &quot;launchStage&quot;: &quot;A String&quot;, # Deprecated. Must use the MetricDescriptor.launch_stage instead.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001152 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001153 &quot;name&quot;: &quot;A String&quot;, # The resource name of the metric descriptor.
1154 &quot;valueType&quot;: &quot;A String&quot;, # Whether the measurement is an integer, a floating-point number, etc.
1155 # Some combinations of `metric_kind` and `value_type` might not be supported.
1156 &quot;launchStage&quot;: &quot;A String&quot;, # Optional. The launch stage of the metric definition.
1157 &quot;type&quot;: &quot;A String&quot;, # The metric type, including its DNS name prefix. The type is not
1158 # URL-encoded.
1159 #
1160 # All service defined metrics must be prefixed with the service name, in the
1161 # format of `{service name}/{relative metric name}`, such as
1162 # `cloudsql.googleapis.com/database/cpu/utilization`. The relative metric
1163 # name must follow:
1164 #
1165 # * Only upper and lower-case letters, digits, &#x27;/&#x27; and underscores &#x27;_&#x27; are
1166 # allowed.
1167 # * The maximum number of characters allowed for the relative_metric_name is
1168 # 100.
1169 #
1170 # All user-defined metric types have the DNS name
1171 # `custom.googleapis.com`, `external.googleapis.com`, or
1172 # `logging.googleapis.com/user/`.
1173 #
1174 # Metric types should use a natural hierarchical grouping. For example:
1175 #
1176 # &quot;custom.googleapis.com/invoice/paid/amount&quot;
1177 # &quot;external.googleapis.com/prometheus/up&quot;
1178 # &quot;appengine.googleapis.com/http/server/response_latencies&quot;
1179 &quot;description&quot;: &quot;A String&quot;, # A detailed description of the metric, which can be used in documentation.
1180 &quot;labels&quot;: [ # The set of labels that can be used to describe a specific
1181 # instance of this metric type.
1182 #
1183 # The label key name must follow:
1184 #
1185 # * Only upper and lower-case letters, digits and underscores (_) are
1186 # allowed.
1187 # * Label name must start with a letter or digit.
1188 # * The maximum length of a label name is 100 characters.
1189 #
1190 # For example, the
1191 # `appengine.googleapis.com/http/server/response_latencies` metric
1192 # type has a label for the HTTP response code, `response_code`, so
1193 # you can look at latencies for successful responses or just
1194 # for responses that failed.
1195 { # A description of a label.
1196 &quot;valueType&quot;: &quot;A String&quot;, # The type of data that can be assigned to the label.
1197 &quot;description&quot;: &quot;A String&quot;, # A human-readable description for the label.
1198 &quot;key&quot;: &quot;A String&quot;, # The label key.
1199 },
1200 ],
1201 &quot;metricKind&quot;: &quot;A String&quot;, # Whether the metric records instantaneous values, changes to a value, etc.
1202 # Some combinations of `metric_kind` and `value_type` might not be supported.
1203 },
1204 ],
1205 &quot;documentation&quot;: { # `Documentation` provides the information for describing a service. # Additional API documentation.
Bu Sun Kim65020912020-05-20 12:08:20 -07001206 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001207 # Example:
1208 # &lt;pre&gt;&lt;code&gt;documentation:
1209 # summary: &gt;
1210 # The Google Calendar API gives access
1211 # to most calendar features.
1212 # pages:
1213 # - name: Overview
1214 # content: &amp;#40;== include google/foo/overview.md ==&amp;#41;
1215 # - name: Tutorial
1216 # content: &amp;#40;== include google/foo/tutorial.md ==&amp;#41;
1217 # subpages;
1218 # - name: Java
1219 # content: &amp;#40;== include google/foo/tutorial_java.md ==&amp;#41;
1220 # rules:
1221 # - selector: google.calendar.Calendar.Get
1222 # description: &gt;
1223 # ...
1224 # - selector: google.calendar.Calendar.Put
1225 # description: &gt;
1226 # ...
1227 # &lt;/code&gt;&lt;/pre&gt;
1228 # Documentation is provided in markdown syntax. In addition to
1229 # standard markdown features, definition lists, tables and fenced
1230 # code blocks are supported. Section headers can be provided and are
1231 # interpreted relative to the section nesting of the context where
1232 # a documentation fragment is embedded.
1233 #
1234 # Documentation from the IDL is merged with documentation defined
1235 # via the config at normalization time, where documentation provided
1236 # by config rules overrides IDL provided.
1237 #
1238 # A number of constructs specific to the API platform are supported
1239 # in documentation text.
1240 #
1241 # In order to reference a proto element, the following
1242 # notation can be used:
1243 # &lt;pre&gt;&lt;code&gt;&amp;#91;fully.qualified.proto.name]&amp;#91;]&lt;/code&gt;&lt;/pre&gt;
1244 # To override the display text used for the link, this can be used:
1245 # &lt;pre&gt;&lt;code&gt;&amp;#91;display text]&amp;#91;fully.qualified.proto.name]&lt;/code&gt;&lt;/pre&gt;
1246 # Text can be excluded from doc using the following notation:
1247 # &lt;pre&gt;&lt;code&gt;&amp;#40;-- internal comment --&amp;#41;&lt;/code&gt;&lt;/pre&gt;
1248 #
1249 # A few directives are available in documentation. Note that
1250 # directives must appear on a single line to be properly
1251 # identified. The `include` directive includes a markdown file from
1252 # an external source:
1253 # &lt;pre&gt;&lt;code&gt;&amp;#40;== include path/to/file ==&amp;#41;&lt;/code&gt;&lt;/pre&gt;
1254 # The `resource_for` directive marks a message to be the resource of
1255 # a collection in REST view. If it is not specified, tools attempt
1256 # to infer the resource from the operations in a collection:
1257 # &lt;pre&gt;&lt;code&gt;&amp;#40;== resource_for v1.shelves.books ==&amp;#41;&lt;/code&gt;&lt;/pre&gt;
1258 # The directive `suppress_warning` does not directly affect documentation
1259 # and is documented together with service config validation.
1260 &quot;serviceRootUrl&quot;: &quot;A String&quot;, # Specifies the service root url if the default one (the service name
1261 # from the yaml file) is not suitable. This can be seen in any fully
1262 # specified service urls as well as sections that show a base that other
1263 # urls are relative to.
1264 &quot;overview&quot;: &quot;A String&quot;, # Declares a single overview page. For example:
1265 # &lt;pre&gt;&lt;code&gt;documentation:
1266 # summary: ...
1267 # overview: &amp;#40;== include overview.md ==&amp;#41;
1268 # &lt;/code&gt;&lt;/pre&gt;
1269 # This is a shortcut for the following declaration (using pages style):
1270 # &lt;pre&gt;&lt;code&gt;documentation:
1271 # summary: ...
1272 # pages:
1273 # - name: Overview
1274 # content: &amp;#40;== include overview.md ==&amp;#41;
1275 # &lt;/code&gt;&lt;/pre&gt;
1276 # Note: you cannot specify both `overview` field and `pages` field.
1277 &quot;documentationRootUrl&quot;: &quot;A String&quot;, # The URL to the root of documentation.
1278 &quot;rules&quot;: [ # A list of documentation rules that apply to individual API elements.
Bu Sun Kim65020912020-05-20 12:08:20 -07001279 #
1280 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001281 { # A documentation rule provides information about individual API elements.
1282 &quot;deprecationDescription&quot;: &quot;A String&quot;, # Deprecation description of the selected element(s). It can be provided if
1283 # an element is marked as `deprecated`.
1284 &quot;description&quot;: &quot;A String&quot;, # Description of the selected API(s).
1285 &quot;selector&quot;: &quot;A String&quot;, # The selector is a comma-separated list of patterns. Each pattern is a
1286 # qualified name of the element which may end in &quot;*&quot;, indicating a wildcard.
1287 # Wildcards are only allowed at the end and for a whole component of the
1288 # qualified name, i.e. &quot;foo.*&quot; is ok, but not &quot;foo.b*&quot; or &quot;foo.*.bar&quot;. A
1289 # wildcard will match one or more components. To specify a default for all
1290 # applicable elements, the whole pattern &quot;*&quot; is used.
Bu Sun Kim65020912020-05-20 12:08:20 -07001291 },
1292 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001293 &quot;pages&quot;: [ # The top level pages for the documentation set.
1294 { # Represents a documentation page. A page can contain subpages to represent
1295 # nested documentation set structure.
1296 &quot;content&quot;: &quot;A String&quot;, # The Markdown content of the page. You can use &lt;code&gt;&amp;#40;== include {path}
1297 # ==&amp;#41;&lt;/code&gt; to include content from a Markdown file.
1298 &quot;name&quot;: &quot;A String&quot;, # The name of the page. It will be used as an identity of the page to
1299 # generate URI of the page, text of the link to this page in navigation,
1300 # etc. The full page name (start from the root page name to this page
1301 # concatenated with `.`) can be used as reference to the page in your
1302 # documentation. For example:
1303 # &lt;pre&gt;&lt;code&gt;pages:
1304 # - name: Tutorial
1305 # content: &amp;#40;== include tutorial.md ==&amp;#41;
1306 # subpages:
1307 # - name: Java
1308 # content: &amp;#40;== include tutorial_java.md ==&amp;#41;
1309 # &lt;/code&gt;&lt;/pre&gt;
1310 # You can reference `Java` page using Markdown reference link syntax:
1311 # `Java`.
1312 &quot;subpages&quot;: [ # Subpages of this page. The order of subpages specified here will be
1313 # honored in the generated docset.
1314 # Object with schema name: Page
1315 ],
1316 },
1317 ],
1318 &quot;summary&quot;: &quot;A String&quot;, # A short summary of what the service does. Can only be provided by
1319 # plain text.
Bu Sun Kim65020912020-05-20 12:08:20 -07001320 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001321 &quot;configVersion&quot;: 42, # The semantic version of the service configuration. The config version
1322 # affects the interpretation of the service configuration. For example,
1323 # certain features are enabled by default for certain config versions.
1324 #
1325 # The latest config version is `3`.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001326 &quot;quota&quot;: { # Quota configuration helps to achieve fairness and budgeting in service # Quota configuration.
1327 # usage.
1328 #
1329 # The metric based quota configuration works this way:
1330 # - The service configuration defines a set of metrics.
1331 # - For API calls, the quota.metric_rules maps methods to metrics with
1332 # corresponding costs.
1333 # - The quota.limits defines limits on the metrics, which will be used for
1334 # quota checks at runtime.
1335 #
1336 # An example quota configuration in yaml format:
1337 #
1338 # quota:
1339 # limits:
1340 #
1341 # - name: apiWriteQpsPerProject
1342 # metric: library.googleapis.com/write_calls
1343 # unit: &quot;1/min/{project}&quot; # rate limit for consumer projects
1344 # values:
1345 # STANDARD: 10000
1346 #
1347 #
1348 # # The metric rules bind all methods to the read_calls metric,
1349 # # except for the UpdateBook and DeleteBook methods. These two methods
1350 # # are mapped to the write_calls metric, with the UpdateBook method
1351 # # consuming at twice rate as the DeleteBook method.
1352 # metric_rules:
1353 # - selector: &quot;*&quot;
1354 # metric_costs:
1355 # library.googleapis.com/read_calls: 1
1356 # - selector: google.example.library.v1.LibraryService.UpdateBook
1357 # metric_costs:
1358 # library.googleapis.com/write_calls: 2
1359 # - selector: google.example.library.v1.LibraryService.DeleteBook
1360 # metric_costs:
1361 # library.googleapis.com/write_calls: 1
1362 #
1363 # Corresponding Metric definition:
1364 #
1365 # metrics:
1366 # - name: library.googleapis.com/read_calls
1367 # display_name: Read requests
1368 # metric_kind: DELTA
1369 # value_type: INT64
1370 #
1371 # - name: library.googleapis.com/write_calls
1372 # display_name: Write requests
1373 # metric_kind: DELTA
1374 # value_type: INT64
1375 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001376 &quot;metricRules&quot;: [ # List of `MetricRule` definitions, each one mapping a selected method to one
1377 # or more metrics.
1378 { # Bind API methods to metrics. Binding a method to a metric causes that
1379 # metric&#x27;s configured quota behaviors to apply to the method call.
1380 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
1381 #
1382 # Refer to selector for syntax details.
1383 &quot;metricCosts&quot;: { # Metrics to update when the selected methods are called, and the associated
1384 # cost applied to each metric.
1385 #
1386 # The key of the map is the metric name, and the values are the amount
1387 # increased for the metric against which the quota limits are defined.
1388 # The value must not be negative.
1389 &quot;a_key&quot;: &quot;A String&quot;,
1390 },
1391 },
1392 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001393 &quot;limits&quot;: [ # List of `QuotaLimit` definitions for the service.
1394 { # `QuotaLimit` defines a specific limit that applies over a specified duration
1395 # for a limit type. There can be at most one limit for a duration and limit
1396 # type combination defined within a `QuotaGroup`.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001397 &quot;values&quot;: { # Tiered limit values. You must specify this as a key:value pair, with an
1398 # integer value that is the maximum number of requests allowed for the
1399 # specified unit. Currently only STANDARD is supported.
1400 &quot;a_key&quot;: &quot;A String&quot;,
1401 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001402 &quot;duration&quot;: &quot;A String&quot;, # Duration of this limit in textual notation. Must be &quot;100s&quot; or &quot;1d&quot;.
Bu Sun Kim65020912020-05-20 12:08:20 -07001403 #
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001404 # Used by group-based quotas only.
1405 &quot;freeTier&quot;: &quot;A String&quot;, # Free tier value displayed in the Developers Console for this limit.
1406 # The free tier is the number of tokens that will be subtracted from the
1407 # billed amount when billing is enabled.
1408 # This field can only be set on a limit with duration &quot;1d&quot;, in a billable
1409 # group; it is invalid on any other limit. If this field is not set, it
1410 # defaults to 0, indicating that there is no free tier for this service.
Bu Sun Kim65020912020-05-20 12:08:20 -07001411 #
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001412 # Used by group-based quotas only.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001413 &quot;displayName&quot;: &quot;A String&quot;, # User-visible display name for this limit.
1414 # Optional. If not set, the UI will provide a default display name based on
1415 # the quota configuration. This field can be used to override the default
1416 # display name generated from the configuration.
1417 &quot;description&quot;: &quot;A String&quot;, # Optional. User-visible, extended description for this quota limit.
1418 # Should be used only when more context is needed to understand this limit
1419 # than provided by the limit&#x27;s display name (see: `display_name`).
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001420 &quot;defaultLimit&quot;: &quot;A String&quot;, # Default number of tokens that can be consumed during the specified
1421 # duration. This is the number of tokens assigned when a client
1422 # application developer activates the service for his/her project.
1423 #
1424 # Specifying a value of 0 will block all requests. This can be used if you
1425 # are provisioning quota to selected consumers and blocking others.
1426 # Similarly, a value of -1 will indicate an unlimited quota. No other
1427 # negative values are allowed.
1428 #
1429 # Used by group-based quotas only.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001430 &quot;name&quot;: &quot;A String&quot;, # Name of the quota limit.
1431 #
1432 # The name must be provided, and it must be unique within the service. The
1433 # name can only include alphanumeric characters as well as &#x27;-&#x27;.
1434 #
1435 # The maximum length of the limit name is 64 characters.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001436 &quot;maxLimit&quot;: &quot;A String&quot;, # Maximum number of tokens that can be consumed during the specified
1437 # duration. Client application developers can override the default limit up
1438 # to this maximum. If specified, this value cannot be set to a value less
1439 # than the default limit. If not specified, it is set to the default limit.
1440 #
1441 # To allow clients to apply overrides with no upper bound, set this to -1,
1442 # indicating unlimited maximum quota.
1443 #
1444 # Used by group-based quotas only.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001445 &quot;metric&quot;: &quot;A String&quot;, # The name of the metric this quota limit applies to. The quota limits with
1446 # the same metric will be checked together during runtime. The metric must be
1447 # defined within the service config.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001448 &quot;unit&quot;: &quot;A String&quot;, # Specify the unit of the quota limit. It uses the same syntax as
1449 # Metric.unit. The supported unit kinds are determined by the quota
1450 # backend system.
1451 #
1452 # Here are some examples:
1453 # * &quot;1/min/{project}&quot; for quota per minute per project.
1454 #
1455 # Note: the order of unit components is insignificant.
1456 # The &quot;1&quot; at the beginning is required to follow the metric unit syntax.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001457 },
1458 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001459 },
1460 &quot;customError&quot;: { # Customize service error responses. For example, list any service # Custom error configuration.
1461 # specific protobuf types that can appear in error detail lists of
1462 # error responses.
1463 #
1464 # Example:
1465 #
1466 # custom_error:
1467 # types:
1468 # - google.foo.v1.CustomError
1469 # - google.foo.v1.AnotherError
1470 &quot;types&quot;: [ # The list of custom error detail types, e.g. &#x27;google.foo.v1.CustomError&#x27;.
1471 &quot;A String&quot;,
1472 ],
1473 &quot;rules&quot;: [ # The list of custom error rules that apply to individual API messages.
1474 #
1475 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
1476 { # A custom error rule.
1477 &quot;selector&quot;: &quot;A String&quot;, # Selects messages to which this rule applies.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001478 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001479 # Refer to selector for syntax details.
1480 &quot;isErrorType&quot;: True or False, # Mark this message as possible payload in error response. Otherwise,
1481 # objects of this type will be filtered when they appear in error payload.
1482 },
1483 ],
1484 },
1485 &quot;authentication&quot;: { # `Authentication` defines the authentication configuration for an API. # Auth configuration.
1486 #
1487 # Example for an API targeted for external use:
1488 #
1489 # name: calendar.googleapis.com
1490 # authentication:
1491 # providers:
1492 # - id: google_calendar_auth
1493 # jwks_uri: https://www.googleapis.com/oauth2/v1/certs
1494 # issuer: https://securetoken.google.com
1495 # rules:
1496 # - selector: &quot;*&quot;
1497 # requirements:
1498 # provider_id: google_calendar_auth
1499 &quot;rules&quot;: [ # A list of authentication rules that apply to individual API methods.
1500 #
1501 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
1502 { # Authentication rules for the service.
1503 #
1504 # By default, if a method has any authentication requirements, every request
1505 # must include a valid credential matching one of the requirements.
1506 # It&#x27;s an error to include more than one kind of credential in a single
1507 # request.
1508 #
1509 # If a method doesn&#x27;t have any auth requirements, request credentials will be
1510 # ignored.
1511 &quot;oauth&quot;: { # OAuth scopes are a way to define data and permissions on data. For example, # The requirements for OAuth credentials.
1512 # there are scopes defined for &quot;Read-only access to Google Calendar&quot; and
1513 # &quot;Access to Cloud Platform&quot;. Users can consent to a scope for an application,
1514 # giving it permission to access that data on their behalf.
1515 #
1516 # OAuth scope specifications should be fairly coarse grained; a user will need
1517 # to see and understand the text description of what your scope means.
1518 #
1519 # In most cases: use one or at most two OAuth scopes for an entire family of
1520 # products. If your product has multiple APIs, you should probably be sharing
1521 # the OAuth scope across all of those APIs.
1522 #
1523 # When you need finer grained OAuth consent screens: talk with your product
1524 # management about how developers will use them in practice.
1525 #
1526 # Please note that even though each of the canonical scopes is enough for a
1527 # request to be accepted and passed to the backend, a request can still fail
1528 # due to the backend requiring additional scopes or permissions.
1529 &quot;canonicalScopes&quot;: &quot;A String&quot;, # The list of publicly documented OAuth scopes that are allowed access. An
1530 # OAuth token containing any of these scopes will be accepted.
1531 #
1532 # Example:
1533 #
1534 # canonical_scopes: https://www.googleapis.com/auth/calendar,
1535 # https://www.googleapis.com/auth/calendar.read
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07001536 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001537 &quot;requirements&quot;: [ # Requirements for additional authentication providers.
1538 { # User-defined authentication requirements, including support for
1539 # [JSON Web Token
1540 # (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32).
1541 &quot;providerId&quot;: &quot;A String&quot;, # id from authentication provider.
1542 #
1543 # Example:
1544 #
1545 # provider_id: bookstore_auth
1546 &quot;audiences&quot;: &quot;A String&quot;, # NOTE: This will be deprecated soon, once AuthProvider.audiences is
1547 # implemented and accepted in all the runtime components.
1548 #
1549 # The list of JWT
1550 # [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3).
1551 # that are allowed to access. A JWT containing any of these audiences will
1552 # be accepted. When this setting is absent, only JWTs with audience
1553 # &quot;https://Service_name/API_name&quot;
1554 # will be accepted. For example, if no audiences are in the setting,
1555 # LibraryService API will only accept JWTs with the following audience
1556 # &quot;https://library-example.googleapis.com/google.example.library.v1.LibraryService&quot;.
1557 #
1558 # Example:
1559 #
1560 # audiences: bookstore_android.apps.googleusercontent.com,
1561 # bookstore_web.apps.googleusercontent.com
1562 },
1563 ],
1564 &quot;allowWithoutCredential&quot;: True or False, # If true, the service accepts API keys without any other credential.
Bu Sun Kim65020912020-05-20 12:08:20 -07001565 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
1566 #
1567 # Refer to selector for syntax details.
Bu Sun Kim65020912020-05-20 12:08:20 -07001568 },
1569 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001570 &quot;providers&quot;: [ # Defines a set of authentication providers that a service supports.
1571 { # Configuration for an authentication provider, including support for
1572 # [JSON Web Token
1573 # (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32).
1574 &quot;id&quot;: &quot;A String&quot;, # The unique identifier of the auth provider. It will be referred to by
1575 # `AuthRequirement.provider_id`.
1576 #
1577 # Example: &quot;bookstore_auth&quot;.
1578 &quot;issuer&quot;: &quot;A String&quot;, # Identifies the principal that issued the JWT. See
1579 # https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.1
1580 # Usually a URL or an email address.
1581 #
1582 # Example: https://securetoken.google.com
1583 # Example: 1234567-compute@developer.gserviceaccount.com
1584 &quot;jwksUri&quot;: &quot;A String&quot;, # URL of the provider&#x27;s public key set to validate signature of the JWT. See
1585 # [OpenID
1586 # Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata).
1587 # Optional if the key set document:
1588 # - can be retrieved from
1589 # [OpenID
1590 # Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html of
1591 # the issuer.
1592 # - can be inferred from the email domain of the issuer (e.g. a Google
1593 # service account).
1594 #
1595 # Example: https://www.googleapis.com/oauth2/v1/certs
1596 &quot;audiences&quot;: &quot;A String&quot;, # The list of JWT
1597 # [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3).
1598 # that are allowed to access. A JWT containing any of these audiences will
1599 # be accepted. When this setting is absent, JWTs with audiences:
1600 # - &quot;https://[service.name]/[google.protobuf.Api.name]&quot;
1601 # - &quot;https://[service.name]/&quot;
1602 # will be accepted.
1603 # For example, if no audiences are in the setting, LibraryService API will
1604 # accept JWTs with the following audiences:
1605 # -
1606 # https://library-example.googleapis.com/google.example.library.v1.LibraryService
1607 # - https://library-example.googleapis.com/
1608 #
1609 # Example:
1610 #
1611 # audiences: bookstore_android.apps.googleusercontent.com,
1612 # bookstore_web.apps.googleusercontent.com
1613 &quot;authorizationUrl&quot;: &quot;A String&quot;, # Redirect URL if JWT token is required but not present or is expired.
1614 # Implement authorizationUrl of securityDefinitions in OpenAPI spec.
1615 &quot;jwtLocations&quot;: [ # Defines the locations to extract the JWT.
1616 #
1617 # JWT locations can be either from HTTP headers or URL query parameters.
1618 # The rule is that the first match wins. The checking order is: checking
1619 # all headers first, then URL query parameters.
1620 #
1621 # If not specified, default to use following 3 locations:
1622 # 1) Authorization: Bearer
1623 # 2) x-goog-iap-jwt-assertion
1624 # 3) access_token query parameter
1625 #
1626 # Default locations can be specified as followings:
1627 # jwt_locations:
1628 # - header: Authorization
1629 # value_prefix: &quot;Bearer &quot;
1630 # - header: x-goog-iap-jwt-assertion
1631 # - query: access_token
1632 { # Specifies a location to extract JWT from an API request.
1633 &quot;query&quot;: &quot;A String&quot;, # Specifies URL query parameter name to extract JWT token.
1634 &quot;valuePrefix&quot;: &quot;A String&quot;, # The value prefix. The value format is &quot;value_prefix{token}&quot;
1635 # Only applies to &quot;in&quot; header type. Must be empty for &quot;in&quot; query type.
1636 # If not empty, the header value has to match (case sensitive) this prefix.
1637 # If not matched, JWT will not be extracted. If matched, JWT will be
1638 # extracted after the prefix is removed.
1639 #
1640 # For example, for &quot;Authorization: Bearer {JWT}&quot;,
1641 # value_prefix=&quot;Bearer &quot; with a space at the end.
1642 &quot;header&quot;: &quot;A String&quot;, # Specifies HTTP header name to extract JWT token.
1643 },
1644 ],
1645 },
1646 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001647 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001648 &quot;title&quot;: &quot;A String&quot;, # The product title for this service.
1649 &quot;producerProjectId&quot;: &quot;A String&quot;, # The Google project that owns this service.
1650 &quot;apis&quot;: [ # A list of API interfaces exported by this service. Only the `name` field
1651 # of the google.protobuf.Api needs to be provided by the configuration
1652 # author, as the remaining fields will be derived from the IDL during the
1653 # normalization process. It is an error to specify an API interface here
1654 # which cannot be resolved against the associated IDL files.
1655 { # Api is a light-weight descriptor for an API Interface.
1656 #
1657 # Interfaces are also described as &quot;protocol buffer services&quot; in some contexts,
1658 # such as by the &quot;service&quot; keyword in a .proto file, but they are different
1659 # from API Services, which represent a concrete implementation of an interface
1660 # as opposed to simply a description of methods and bindings. They are also
1661 # sometimes simply referred to as &quot;APIs&quot; in other contexts, such as the name of
1662 # this message itself. See https://cloud.google.com/apis/design/glossary for
1663 # detailed terminology.
1664 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # Source context for the protocol buffer service represented by this
1665 # message.
1666 # protobuf element, like the file in which it is defined.
1667 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
1668 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
1669 },
1670 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax of the service.
1671 &quot;methods&quot;: [ # The methods of this interface, in unspecified order.
1672 { # Method represents a method of an API interface.
1673 &quot;options&quot;: [ # Any metadata attached to the method.
1674 { # A protocol buffer option, which can be attached to a message, field,
1675 # enumeration, etc.
1676 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
1677 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
1678 # should be used. If the value is an enum, it should be stored as an int32
1679 # value using the google.protobuf.Int32Value type.
1680 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
1681 },
1682 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
1683 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
1684 # For custom options, it should be the fully-qualified name. For example,
1685 # `&quot;google.api.http&quot;`.
1686 },
1687 ],
1688 &quot;responseStreaming&quot;: True or False, # If true, the response is streamed.
1689 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax of this method.
1690 &quot;requestTypeUrl&quot;: &quot;A String&quot;, # A URL of the input message type.
1691 &quot;name&quot;: &quot;A String&quot;, # The simple name of this method.
1692 &quot;responseTypeUrl&quot;: &quot;A String&quot;, # The URL of the output message type.
1693 &quot;requestStreaming&quot;: True or False, # If true, the request is streamed.
1694 },
1695 ],
1696 &quot;name&quot;: &quot;A String&quot;, # The fully qualified name of this interface, including package name
1697 # followed by the interface&#x27;s simple name.
1698 &quot;version&quot;: &quot;A String&quot;, # A version string for this interface. If specified, must have the form
1699 # `major-version.minor-version`, as in `1.10`. If the minor version is
1700 # omitted, it defaults to zero. If the entire version field is empty, the
1701 # major version is derived from the package name, as outlined below. If the
1702 # field is not empty, the version in the package name will be verified to be
1703 # consistent with what is provided here.
1704 #
1705 # The versioning schema uses [semantic
1706 # versioning](http://semver.org) where the major version number
1707 # indicates a breaking change and the minor version an additive,
1708 # non-breaking change. Both version numbers are signals to users
1709 # what to expect from different versions, and should be carefully
1710 # chosen based on the product plan.
1711 #
1712 # The major version is also reflected in the package name of the
1713 # interface, which must end in `v&lt;major-version&gt;`, as in
1714 # `google.feature.v1`. For major versions 0 and 1, the suffix can
1715 # be omitted. Zero major versions must only be used for
1716 # experimental, non-GA interfaces.
1717 &quot;options&quot;: [ # Any metadata attached to the interface.
1718 { # A protocol buffer option, which can be attached to a message, field,
1719 # enumeration, etc.
1720 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
1721 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
1722 # should be used. If the value is an enum, it should be stored as an int32
1723 # value using the google.protobuf.Int32Value type.
1724 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
1725 },
1726 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
1727 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
1728 # For custom options, it should be the fully-qualified name. For example,
1729 # `&quot;google.api.http&quot;`.
1730 },
1731 ],
1732 &quot;mixins&quot;: [ # Included interfaces. See Mixin.
1733 { # Declares an API Interface to be included in this interface. The including
1734 # interface must redeclare all the methods from the included interface, but
1735 # documentation and options are inherited as follows:
1736 #
1737 # - If after comment and whitespace stripping, the documentation
1738 # string of the redeclared method is empty, it will be inherited
1739 # from the original method.
1740 #
1741 # - Each annotation belonging to the service config (http,
1742 # visibility) which is not set in the redeclared method will be
1743 # inherited.
1744 #
1745 # - If an http annotation is inherited, the path pattern will be
1746 # modified as follows. Any version prefix will be replaced by the
1747 # version of the including interface plus the root path if
1748 # specified.
1749 #
1750 # Example of a simple mixin:
1751 #
1752 # package google.acl.v1;
1753 # service AccessControl {
1754 # // Get the underlying ACL object.
1755 # rpc GetAcl(GetAclRequest) returns (Acl) {
1756 # option (google.api.http).get = &quot;/v1/{resource=**}:getAcl&quot;;
1757 # }
1758 # }
1759 #
1760 # package google.storage.v2;
1761 # service Storage {
1762 # // rpc GetAcl(GetAclRequest) returns (Acl);
1763 #
1764 # // Get a data record.
1765 # rpc GetData(GetDataRequest) returns (Data) {
1766 # option (google.api.http).get = &quot;/v2/{resource=**}&quot;;
1767 # }
1768 # }
1769 #
1770 # Example of a mixin configuration:
1771 #
1772 # apis:
1773 # - name: google.storage.v2.Storage
1774 # mixins:
1775 # - name: google.acl.v1.AccessControl
1776 #
1777 # The mixin construct implies that all methods in `AccessControl` are
1778 # also declared with same name and request/response types in
1779 # `Storage`. A documentation generator or annotation processor will
1780 # see the effective `Storage.GetAcl` method after inherting
1781 # documentation and annotations as follows:
1782 #
1783 # service Storage {
1784 # // Get the underlying ACL object.
1785 # rpc GetAcl(GetAclRequest) returns (Acl) {
1786 # option (google.api.http).get = &quot;/v2/{resource=**}:getAcl&quot;;
1787 # }
1788 # ...
1789 # }
1790 #
1791 # Note how the version in the path pattern changed from `v1` to `v2`.
1792 #
1793 # If the `root` field in the mixin is specified, it should be a
1794 # relative path under which inherited HTTP paths are placed. Example:
1795 #
1796 # apis:
1797 # - name: google.storage.v2.Storage
1798 # mixins:
1799 # - name: google.acl.v1.AccessControl
1800 # root: acls
1801 #
1802 # This implies the following inherited HTTP annotation:
1803 #
1804 # service Storage {
1805 # // Get the underlying ACL object.
1806 # rpc GetAcl(GetAclRequest) returns (Acl) {
1807 # option (google.api.http).get = &quot;/v2/acls/{resource=**}:getAcl&quot;;
1808 # }
1809 # ...
1810 # }
1811 &quot;root&quot;: &quot;A String&quot;, # If non-empty specifies a path under which inherited HTTP paths
1812 # are rooted.
1813 &quot;name&quot;: &quot;A String&quot;, # The fully qualified name of the interface which is included.
1814 },
1815 ],
1816 },
1817 ],
1818 &quot;id&quot;: &quot;A String&quot;, # A unique ID for a specific instance of this message, typically assigned
1819 # by the client for tracking purpose. Must be no longer than 63 characters
1820 # and only lower case letters, digits, &#x27;.&#x27;, &#x27;_&#x27; and &#x27;-&#x27; are allowed. If
1821 # empty, the server may choose to generate one instead.
1822 &quot;endpoints&quot;: [ # Configuration for network endpoints. If this is empty, then an endpoint
1823 # with the same name as the service is automatically generated to service all
1824 # defined APIs.
1825 { # `Endpoint` describes a network endpoint that serves a set of APIs.
1826 # A service may expose any number of endpoints, and all endpoints share the
1827 # same service configuration, such as quota configuration and monitoring
1828 # configuration.
1829 #
1830 # Example service configuration:
1831 #
1832 # name: library-example.googleapis.com
1833 # endpoints:
1834 # # Below entry makes &#x27;google.example.library.v1.Library&#x27;
1835 # # API be served from endpoint address library-example.googleapis.com.
1836 # # It also allows HTTP OPTIONS calls to be passed to the backend, for
1837 # # it to decide whether the subsequent cross-origin request is
1838 # # allowed to proceed.
1839 # - name: library-example.googleapis.com
1840 # allow_cors: true
1841 &quot;name&quot;: &quot;A String&quot;, # The canonical name of this endpoint.
1842 &quot;allowCors&quot;: True or False, # Allowing
1843 # [CORS](https://en.wikipedia.org/wiki/Cross-origin_resource_sharing), aka
1844 # cross-domain traffic, would allow the backends served from this endpoint to
1845 # receive and respond to HTTP OPTIONS requests. The response will be used by
1846 # the browser to determine whether the subsequent cross-origin request is
1847 # allowed to proceed.
1848 &quot;target&quot;: &quot;A String&quot;, # The specification of an Internet routable address of API frontend that will
1849 # handle requests to this [API
1850 # Endpoint](https://cloud.google.com/apis/design/glossary). It should be
1851 # either a valid IPv4 address or a fully-qualified domain name. For example,
1852 # &quot;8.8.8.8&quot; or &quot;myservice.appspot.com&quot;.
1853 &quot;aliases&quot;: [ # DEPRECATED: This field is no longer supported. Instead of using aliases,
1854 # please specify multiple google.api.Endpoint for each of the intended
1855 # aliases.
1856 #
1857 # Additional names that this endpoint will be hosted on.
1858 &quot;A String&quot;,
1859 ],
1860 },
1861 ],
1862 &quot;systemParameters&quot;: { # ### System parameter configuration # System parameter configuration.
1863 #
1864 # A system parameter is a special kind of parameter defined by the API
1865 # system, not by an individual API. It is typically mapped to an HTTP header
1866 # and/or a URL query parameter. This configuration specifies which methods
1867 # change the names of the system parameters.
1868 &quot;rules&quot;: [ # Define system parameters.
1869 #
1870 # The parameters defined here will override the default parameters
1871 # implemented by the system. If this field is missing from the service
1872 # config, default system parameters will be used. Default system parameters
1873 # and names is implementation-dependent.
1874 #
1875 # Example: define api key for all methods
1876 #
1877 # system_parameters
1878 # rules:
1879 # - selector: &quot;*&quot;
1880 # parameters:
1881 # - name: api_key
1882 # url_query_parameter: api_key
1883 #
1884 #
1885 # Example: define 2 api key names for a specific method.
1886 #
1887 # system_parameters
1888 # rules:
1889 # - selector: &quot;/ListShelves&quot;
1890 # parameters:
1891 # - name: api_key
1892 # http_header: Api-Key1
1893 # - name: api_key
1894 # http_header: Api-Key2
1895 #
1896 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
1897 { # Define a system parameter rule mapping system parameter definitions to
1898 # methods.
1899 &quot;parameters&quot;: [ # Define parameters. Multiple names may be defined for a parameter.
1900 # For a given method call, only one of them should be used. If multiple
1901 # names are used the behavior is implementation-dependent.
1902 # If none of the specified names are present the behavior is
1903 # parameter-dependent.
1904 { # Define a parameter&#x27;s name and location. The parameter may be passed as either
1905 # an HTTP header or a URL query parameter, and if both are passed the behavior
1906 # is implementation-dependent.
1907 &quot;name&quot;: &quot;A String&quot;, # Define the name of the parameter, such as &quot;api_key&quot; . It is case sensitive.
1908 &quot;httpHeader&quot;: &quot;A String&quot;, # Define the HTTP header name to use for the parameter. It is case
1909 # insensitive.
1910 &quot;urlQueryParameter&quot;: &quot;A String&quot;, # Define the URL query parameter name to use for the parameter. It is case
1911 # sensitive.
1912 },
1913 ],
1914 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies. Use &#x27;*&#x27; to indicate all
1915 # methods in all APIs.
1916 #
1917 # Refer to selector for syntax details.
1918 },
1919 ],
1920 },
1921 &quot;monitoredResources&quot;: [ # Defines the monitored resources used by this service. This is required
1922 # by the Service.monitoring and Service.logging configurations.
1923 { # An object that describes the schema of a MonitoredResource object using a
1924 # type name and a set of labels. For example, the monitored resource
1925 # descriptor for Google Compute Engine VM instances has a type of
1926 # `&quot;gce_instance&quot;` and specifies the use of the labels `&quot;instance_id&quot;` and
1927 # `&quot;zone&quot;` to identify particular VM instances.
1928 #
1929 # Different services can support different monitored resource types.
1930 #
1931 # The following are specific rules to service defined monitored resources for
1932 # Monitoring and Logging:
1933 #
1934 # * The `type`, `display_name`, `description`, `labels` and `launch_stage`
1935 # fields are all required.
1936 # * The first label of the monitored resource descriptor must be
1937 # `resource_container`. There are legacy monitored resource descritptors
1938 # start with `project_id`.
1939 # * It must include a `location` label.
1940 # * Maximum of default 5 service defined monitored resource descriptors
1941 # is allowed per service.
1942 # * Maximum of default 10 labels per monitored resource is allowed.
1943 #
1944 # The default maximum limit can be overridden. Please follow
1945 # https://cloud.google.com/monitoring/quotas
1946 &quot;name&quot;: &quot;A String&quot;, # Optional. The resource name of the monitored resource descriptor:
1947 # `&quot;projects/{project_id}/monitoredResourceDescriptors/{type}&quot;` where
1948 # {type} is the value of the `type` field in this object and
1949 # {project_id} is a project ID that provides API-specific context for
1950 # accessing the type. APIs that do not use project information can use the
1951 # resource name format `&quot;monitoredResourceDescriptors/{type}&quot;`.
1952 &quot;launchStage&quot;: &quot;A String&quot;, # Optional. The launch stage of the monitored resource definition.
1953 &quot;displayName&quot;: &quot;A String&quot;, # Optional. A concise name for the monitored resource type that might be
1954 # displayed in user interfaces. It should be a Title Cased Noun Phrase,
1955 # without any article or other determiners. For example,
1956 # `&quot;Google Cloud SQL Database&quot;`.
1957 &quot;labels&quot;: [ # Required. A set of labels used to describe instances of this monitored
1958 # resource type.
1959 # The label key name must follow:
1960 #
1961 # * Only upper and lower-case letters, digits and underscores (_) are
1962 # allowed.
1963 # * Label name must start with a letter or digit.
1964 # * The maximum length of a label name is 100 characters.
1965 #
1966 # For example, an individual Google Cloud SQL database is
1967 # identified by values for the labels `database_id` and `location`.
1968 { # A description of a label.
1969 &quot;valueType&quot;: &quot;A String&quot;, # The type of data that can be assigned to the label.
1970 &quot;description&quot;: &quot;A String&quot;, # A human-readable description for the label.
1971 &quot;key&quot;: &quot;A String&quot;, # The label key.
1972 },
1973 ],
1974 &quot;description&quot;: &quot;A String&quot;, # Optional. A detailed description of the monitored resource type that might
1975 # be used in documentation.
1976 &quot;type&quot;: &quot;A String&quot;, # Required. The monitored resource type. For example, the type
1977 # `cloudsql_database` represents databases in Google Cloud SQL.
1978 #
1979 # All service defined monitored resource types must be prefixed with the
1980 # service name, in the format of `{service name}/{relative resource name}`.
1981 # The relative resource name must follow:
1982 #
1983 # * Only upper and lower-case letters and digits are allowed.
1984 # * It must start with upper case character and is recommended to use Upper
1985 # Camel Case style.
1986 # * The maximum number of characters allowed for the relative_resource_name
1987 # is 100.
1988 #
1989 # Note there are legacy service monitored resources not following this rule.
1990 },
1991 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001992 &quot;context&quot;: { # `Context` defines which contexts an API requests. # Context configuration.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07001993 #
1994 # Example:
1995 #
Bu Sun Kim65020912020-05-20 12:08:20 -07001996 # context:
1997 # rules:
1998 # - selector: &quot;*&quot;
1999 # requested:
2000 # - google.rpc.context.ProjectContext
2001 # - google.rpc.context.OriginContext
2002 #
2003 # The above specifies that all methods in the API request
2004 # `google.rpc.context.ProjectContext` and
2005 # `google.rpc.context.OriginContext`.
2006 #
2007 # Available context types are defined in package
2008 # `google.rpc.context`.
2009 #
2010 # This also provides mechanism to whitelist any protobuf message extension that
2011 # can be sent in grpc metadata using “x-goog-ext-&lt;extension_id&gt;-bin” and
2012 # “x-goog-ext-&lt;extension_id&gt;-jspb” format. For example, list any service
2013 # specific protobuf types that can appear in grpc metadata as follows in your
2014 # yaml file:
2015 #
2016 # Example:
2017 #
2018 # context:
2019 # rules:
2020 # - selector: &quot;google.example.library.v1.LibraryService.CreateBook&quot;
2021 # allowed_request_extensions:
2022 # - google.foo.v1.NewExtension
2023 # allowed_response_extensions:
2024 # - google.foo.v1.NewExtension
2025 #
2026 # You can also specify extension ID instead of fully qualified extension name
2027 # here.
2028 &quot;rules&quot;: [ # A list of RPC context rules that apply to individual API methods.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002029 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002030 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
2031 { # A context rule provides information about the context for an individual API
2032 # element.
Bu Sun Kim65020912020-05-20 12:08:20 -07002033 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002034 #
2035 # Refer to selector for syntax details.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002036 &quot;requested&quot;: [ # A list of full type names of requested contexts.
2037 &quot;A String&quot;,
2038 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002039 &quot;provided&quot;: [ # A list of full type names of provided contexts.
2040 &quot;A String&quot;,
2041 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002042 &quot;allowedRequestExtensions&quot;: [ # A list of full type names or extension IDs of extensions allowed in grpc
2043 # side channel from client to backend.
2044 &quot;A String&quot;,
2045 ],
2046 &quot;allowedResponseExtensions&quot;: [ # A list of full type names or extension IDs of extensions allowed in grpc
2047 # side channel from backend to client.
2048 &quot;A String&quot;,
2049 ],
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002050 },
2051 ],
2052 },
2053}
2054
2055 x__xgafv: string, V1 error format.
2056 Allowed values
2057 1 - v1 error format
2058 2 - v2 error format
2059
2060Returns:
2061 An object of the form:
2062
Sai Cheemalapatiea3a5e12016-10-12 14:05:53 -07002063 { # `Service` is the root object of Google service configuration schema. It
2064 # describes basic information about a service, such as the name and the
2065 # title, and delegates other aspects to sub-sections. Each sub-section is
2066 # either a proto message or a repeated proto message that configures a
2067 # specific aspect, such as auth. See each proto message definition for details.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002068 #
2069 # Example:
2070 #
2071 # type: google.api.Service
Sai Cheemalapatiea3a5e12016-10-12 14:05:53 -07002072 # config_version: 3
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002073 # name: calendar.googleapis.com
2074 # title: Google Calendar API
2075 # apis:
Sai Cheemalapatiea3a5e12016-10-12 14:05:53 -07002076 # - name: google.calendar.v3.Calendar
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002077 # authentication:
2078 # providers:
2079 # - id: google_calendar_auth
2080 # jwks_uri: https://www.googleapis.com/oauth2/v1/certs
2081 # issuer: https://securetoken.google.com
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002082 # rules:
Bu Sun Kim65020912020-05-20 12:08:20 -07002083 # - selector: &quot;*&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002084 # requirements:
2085 # provider_id: google_calendar_auth
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002086 &quot;enums&quot;: [ # A list of all enum types included in this API service. Enums
2087 # referenced directly or indirectly by the `apis` are automatically
2088 # included. Enums which are not referenced but shall be included
2089 # should be listed here by name. Example:
2090 #
2091 # enums:
2092 # - name: google.someapi.v1.SomeEnum
2093 { # Enum type definition.
2094 &quot;options&quot;: [ # Protocol buffer options.
2095 { # A protocol buffer option, which can be attached to a message, field,
2096 # enumeration, etc.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002097 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
2098 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
2099 # should be used. If the value is an enum, it should be stored as an int32
2100 # value using the google.protobuf.Int32Value type.
2101 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
2102 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002103 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
2104 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
2105 # For custom options, it should be the fully-qualified name. For example,
2106 # `&quot;google.api.http&quot;`.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002107 },
2108 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002109 &quot;enumvalue&quot;: [ # Enum value definitions.
2110 { # Enum value definition.
2111 &quot;name&quot;: &quot;A String&quot;, # Enum value name.
2112 &quot;options&quot;: [ # Protocol buffer options.
2113 { # A protocol buffer option, which can be attached to a message, field,
2114 # enumeration, etc.
2115 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
2116 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
2117 # should be used. If the value is an enum, it should be stored as an int32
2118 # value using the google.protobuf.Int32Value type.
2119 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
2120 },
2121 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
2122 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
2123 # For custom options, it should be the fully-qualified name. For example,
2124 # `&quot;google.api.http&quot;`.
2125 },
2126 ],
2127 &quot;number&quot;: 42, # Enum value number.
2128 },
2129 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002130 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # The source context.
2131 # protobuf element, like the file in which it is defined.
2132 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
2133 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
2134 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002135 &quot;name&quot;: &quot;A String&quot;, # Enum type name.
2136 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax.
2137 },
2138 ],
2139 &quot;backend&quot;: { # `Backend` defines the backend configuration for a service. # API backend configuration.
2140 &quot;rules&quot;: [ # A list of API backend rules that apply to individual API methods.
2141 #
2142 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
2143 { # A backend rule provides configuration for an individual API element.
2144 &quot;disableAuth&quot;: True or False, # When disable_auth is true, a JWT ID token won&#x27;t be generated and the
2145 # original &quot;Authorization&quot; HTTP header will be preserved. If the header is
2146 # used to carry the original token and is expected by the backend, this
2147 # field must be set to true to preserve the header.
2148 &quot;address&quot;: &quot;A String&quot;, # The address of the API backend.
2149 #
2150 # The scheme is used to determine the backend protocol and security.
2151 # The following schemes are accepted:
2152 #
2153 # SCHEME PROTOCOL SECURITY
2154 # http:// HTTP None
2155 # https:// HTTP TLS
2156 # grpc:// gRPC None
2157 # grpcs:// gRPC TLS
2158 #
2159 # It is recommended to explicitly include a scheme. Leaving out the scheme
2160 # may cause constrasting behaviors across platforms.
2161 #
2162 # If the port is unspecified, the default is:
2163 # - 80 for schemes without TLS
2164 # - 443 for schemes with TLS
2165 #
2166 # For HTTP backends, use protocol
2167 # to specify the protocol version.
2168 &quot;minDeadline&quot;: 3.14, # Minimum deadline in seconds needed for this method. Calls having deadline
2169 # value lower than this will be rejected.
2170 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
2171 #
2172 # Refer to selector for syntax details.
2173 &quot;protocol&quot;: &quot;A String&quot;, # The protocol used for sending a request to the backend.
2174 # The supported values are &quot;http/1.1&quot; and &quot;h2&quot;.
2175 #
2176 # The default value is inferred from the scheme in the
2177 # address field:
2178 #
2179 # SCHEME PROTOCOL
2180 # http:// http/1.1
2181 # https:// http/1.1
2182 # grpc:// h2
2183 # grpcs:// h2
2184 #
2185 # For secure HTTP backends (https://) that support HTTP/2, set this field
2186 # to &quot;h2&quot; for improved performance.
2187 #
2188 # Configuring this field to non-default values is only supported for secure
2189 # HTTP backends. This field will be ignored for all other backends.
2190 #
2191 # See
2192 # https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#alpn-protocol-ids
2193 # for more details on the supported values.
2194 &quot;operationDeadline&quot;: 3.14, # The number of seconds to wait for the completion of a long running
2195 # operation. The default is no deadline.
2196 &quot;pathTranslation&quot;: &quot;A String&quot;,
2197 &quot;jwtAudience&quot;: &quot;A String&quot;, # The JWT audience is used when generating a JWT ID token for the backend.
2198 # This ID token will be added in the HTTP &quot;authorization&quot; header, and sent
2199 # to the backend.
2200 &quot;deadline&quot;: 3.14, # The number of seconds to wait for a response from a request. The default
2201 # varies based on the request protocol and deployment environment.
2202 },
2203 ],
2204 },
2205 &quot;systemTypes&quot;: [ # A list of all proto message types included in this API service.
2206 # It serves similar purpose as [google.api.Service.types], except that
2207 # these types are not needed by user-defined APIs. Therefore, they will not
2208 # show up in the generated discovery doc. This field should only be used
2209 # to define system APIs in ESF.
2210 { # A protocol buffer message type.
2211 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # The source context.
2212 # protobuf element, like the file in which it is defined.
2213 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
2214 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
2215 },
2216 &quot;oneofs&quot;: [ # The list of types appearing in `oneof` definitions in this type.
2217 &quot;A String&quot;,
2218 ],
2219 &quot;fields&quot;: [ # The list of fields.
2220 { # A single field of a message type.
2221 &quot;oneofIndex&quot;: 42, # The index of the field type in `Type.oneofs`, for message or enumeration
2222 # types. The first type has index 1; zero means the type is not in the list.
2223 &quot;name&quot;: &quot;A String&quot;, # The field name.
2224 &quot;defaultValue&quot;: &quot;A String&quot;, # The string value of the default value of this field. Proto2 syntax only.
2225 &quot;packed&quot;: True or False, # Whether to use alternative packed wire representation.
2226 &quot;typeUrl&quot;: &quot;A String&quot;, # The field type URL, without the scheme, for message or enumeration
2227 # types. Example: `&quot;type.googleapis.com/google.protobuf.Timestamp&quot;`.
2228 &quot;cardinality&quot;: &quot;A String&quot;, # The field cardinality.
2229 &quot;jsonName&quot;: &quot;A String&quot;, # The field JSON name.
2230 &quot;kind&quot;: &quot;A String&quot;, # The field type.
2231 &quot;options&quot;: [ # The protocol buffer options.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002232 { # A protocol buffer option, which can be attached to a message, field,
2233 # enumeration, etc.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002234 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
2235 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
2236 # should be used. If the value is an enum, it should be stored as an int32
2237 # value using the google.protobuf.Int32Value type.
2238 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
2239 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002240 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
2241 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
2242 # For custom options, it should be the fully-qualified name. For example,
2243 # `&quot;google.api.http&quot;`.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002244 },
2245 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002246 &quot;number&quot;: 42, # The field number.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002247 },
2248 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002249 &quot;options&quot;: [ # The protocol buffer options.
Bu Sun Kim65020912020-05-20 12:08:20 -07002250 { # A protocol buffer option, which can be attached to a message, field,
2251 # enumeration, etc.
2252 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
2253 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
2254 # should be used. If the value is an enum, it should be stored as an int32
2255 # value using the google.protobuf.Int32Value type.
2256 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
2257 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002258 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
2259 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
2260 # For custom options, it should be the fully-qualified name. For example,
2261 # `&quot;google.api.http&quot;`.
Bu Sun Kim65020912020-05-20 12:08:20 -07002262 },
2263 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002264 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax.
2265 &quot;name&quot;: &quot;A String&quot;, # The fully qualified message name.
Bu Sun Kim65020912020-05-20 12:08:20 -07002266 },
2267 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002268 &quot;name&quot;: &quot;A String&quot;, # The service name, which is a DNS-like logical identifier for the
2269 # service, such as `calendar.googleapis.com`. The service name
2270 # typically goes through DNS verification to make sure the owner
2271 # of the service also owns the DNS name.
2272 &quot;sourceInfo&quot;: { # Source information used to create a Service Config # Output only. The source information for this configuration if available.
2273 &quot;sourceFiles&quot;: [ # All files used during config generation.
2274 {
2275 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim65020912020-05-20 12:08:20 -07002276 },
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002277 ],
2278 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002279 &quot;billing&quot;: { # Billing related configuration of the service. # Billing configuration.
2280 #
2281 # The following example shows how to configure monitored resources and metrics
2282 # for billing, `consumer_destinations` is the only supported destination and
2283 # the monitored resources need at least one label key
2284 # `cloud.googleapis.com/location` to indicate the location of the billing
2285 # usage, using different monitored resources between monitoring and billing is
2286 # recommended so they can be evolved independently:
2287 #
2288 #
2289 # monitored_resources:
2290 # - type: library.googleapis.com/billing_branch
2291 # labels:
2292 # - key: cloud.googleapis.com/location
2293 # description: |
2294 # Predefined label to support billing location restriction.
2295 # - key: city
2296 # description: |
2297 # Custom label to define the city where the library branch is located
2298 # in.
2299 # - key: name
2300 # description: Custom label to define the name of the library branch.
2301 # metrics:
2302 # - name: library.googleapis.com/book/borrowed_count
2303 # metric_kind: DELTA
2304 # value_type: INT64
2305 # unit: &quot;1&quot;
2306 # billing:
2307 # consumer_destinations:
2308 # - monitored_resource: library.googleapis.com/billing_branch
2309 # metrics:
2310 # - library.googleapis.com/book/borrowed_count
2311 &quot;consumerDestinations&quot;: [ # Billing configurations for sending metrics to the consumer project.
2312 # There can be multiple consumer destinations per service, each one must have
2313 # a different monitored resource type. A metric can be used in at most
2314 # one consumer destination.
2315 { # Configuration of a specific billing destination (Currently only support
2316 # bill against consumer project).
2317 &quot;metrics&quot;: [ # Names of the metrics to report to this billing destination.
2318 # Each name must be defined in Service.metrics section.
2319 &quot;A String&quot;,
2320 ],
2321 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in
2322 # Service.monitored_resources section.
2323 },
2324 ],
2325 },
2326 &quot;monitoring&quot;: { # Monitoring configuration of the service. # Monitoring configuration.
2327 #
2328 # The example below shows how to configure monitored resources and metrics
2329 # for monitoring. In the example, a monitored resource and two metrics are
2330 # defined. The `library.googleapis.com/book/returned_count` metric is sent
2331 # to both producer and consumer projects, whereas the
2332 # `library.googleapis.com/book/num_overdue` metric is only sent to the
2333 # consumer project.
2334 #
2335 # monitored_resources:
2336 # - type: library.googleapis.com/Branch
2337 # display_name: &quot;Library Branch&quot;
2338 # description: &quot;A branch of a library.&quot;
2339 # launch_stage: GA
2340 # labels:
2341 # - key: resource_container
2342 # description: &quot;The Cloud container (ie. project id) for the Branch.&quot;
2343 # - key: location
2344 # description: &quot;The location of the library branch.&quot;
2345 # - key: branch_id
2346 # description: &quot;The id of the branch.&quot;
2347 # metrics:
2348 # - name: library.googleapis.com/book/returned_count
2349 # display_name: &quot;Books Returned&quot;
2350 # description: &quot;The count of books that have been returned.&quot;
2351 # launch_stage: GA
2352 # metric_kind: DELTA
2353 # value_type: INT64
2354 # unit: &quot;1&quot;
2355 # labels:
2356 # - key: customer_id
2357 # description: &quot;The id of the customer.&quot;
2358 # - name: library.googleapis.com/book/num_overdue
2359 # display_name: &quot;Books Overdue&quot;
2360 # description: &quot;The current number of overdue books.&quot;
2361 # launch_stage: GA
2362 # metric_kind: GAUGE
2363 # value_type: INT64
2364 # unit: &quot;1&quot;
2365 # labels:
2366 # - key: customer_id
2367 # description: &quot;The id of the customer.&quot;
2368 # monitoring:
2369 # producer_destinations:
2370 # - monitored_resource: library.googleapis.com/Branch
2371 # metrics:
2372 # - library.googleapis.com/book/returned_count
2373 # consumer_destinations:
2374 # - monitored_resource: library.googleapis.com/Branch
2375 # metrics:
2376 # - library.googleapis.com/book/returned_count
2377 # - library.googleapis.com/book/num_overdue
2378 &quot;producerDestinations&quot;: [ # Monitoring configurations for sending metrics to the producer project.
2379 # There can be multiple producer destinations. A monitored resource type may
2380 # appear in multiple monitoring destinations if different aggregations are
2381 # needed for different sets of metrics associated with that monitored
2382 # resource type. A monitored resource and metric pair may only be used once
2383 # in the Monitoring configuration.
2384 { # Configuration of a specific monitoring destination (the producer project
2385 # or the consumer project).
2386 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in
2387 # Service.monitored_resources section.
2388 &quot;metrics&quot;: [ # Types of the metrics to report to this monitoring destination.
2389 # Each type must be defined in Service.metrics section.
2390 &quot;A String&quot;,
2391 ],
2392 },
2393 ],
2394 &quot;consumerDestinations&quot;: [ # Monitoring configurations for sending metrics to the consumer project.
2395 # There can be multiple consumer destinations. A monitored resource type may
2396 # appear in multiple monitoring destinations if different aggregations are
2397 # needed for different sets of metrics associated with that monitored
2398 # resource type. A monitored resource and metric pair may only be used once
2399 # in the Monitoring configuration.
2400 { # Configuration of a specific monitoring destination (the producer project
2401 # or the consumer project).
2402 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in
2403 # Service.monitored_resources section.
2404 &quot;metrics&quot;: [ # Types of the metrics to report to this monitoring destination.
2405 # Each type must be defined in Service.metrics section.
2406 &quot;A String&quot;,
2407 ],
2408 },
2409 ],
2410 },
2411 &quot;logging&quot;: { # Logging configuration of the service. # Logging configuration.
2412 #
2413 # The following example shows how to configure logs to be sent to the
2414 # producer and consumer projects. In the example, the `activity_history`
2415 # log is sent to both the producer and consumer projects, whereas the
2416 # `purchase_history` log is only sent to the producer project.
2417 #
2418 # monitored_resources:
2419 # - type: library.googleapis.com/branch
2420 # labels:
2421 # - key: /city
2422 # description: The city where the library branch is located in.
2423 # - key: /name
2424 # description: The name of the branch.
2425 # logs:
2426 # - name: activity_history
2427 # labels:
2428 # - key: /customer_id
2429 # - name: purchase_history
2430 # logging:
2431 # producer_destinations:
2432 # - monitored_resource: library.googleapis.com/branch
2433 # logs:
2434 # - activity_history
2435 # - purchase_history
2436 # consumer_destinations:
2437 # - monitored_resource: library.googleapis.com/branch
2438 # logs:
2439 # - activity_history
2440 &quot;producerDestinations&quot;: [ # Logging configurations for sending logs to the producer project.
2441 # There can be multiple producer destinations, each one must have a
2442 # different monitored resource type. A log can be used in at most
2443 # one producer destination.
2444 { # Configuration of a specific logging destination (the producer project
2445 # or the consumer project).
2446 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in the
2447 # Service.monitored_resources section.
2448 &quot;logs&quot;: [ # Names of the logs to be sent to this destination. Each name must
2449 # be defined in the Service.logs section. If the log name is
2450 # not a domain scoped name, it will be automatically prefixed with
2451 # the service name followed by &quot;/&quot;.
2452 &quot;A String&quot;,
2453 ],
2454 },
2455 ],
2456 &quot;consumerDestinations&quot;: [ # Logging configurations for sending logs to the consumer project.
2457 # There can be multiple consumer destinations, each one must have a
2458 # different monitored resource type. A log can be used in at most
2459 # one consumer destination.
2460 { # Configuration of a specific logging destination (the producer project
2461 # or the consumer project).
2462 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in the
2463 # Service.monitored_resources section.
2464 &quot;logs&quot;: [ # Names of the logs to be sent to this destination. Each name must
2465 # be defined in the Service.logs section. If the log name is
2466 # not a domain scoped name, it will be automatically prefixed with
2467 # the service name followed by &quot;/&quot;.
2468 &quot;A String&quot;,
2469 ],
2470 },
2471 ],
2472 },
2473 &quot;control&quot;: { # Selects and configures the service controller used by the service. The # Configuration for the service control plane.
2474 # service controller handles features like abuse, quota, billing, logging,
2475 # monitoring, etc.
2476 &quot;environment&quot;: &quot;A String&quot;, # The service control environment to use. If empty, no control plane
2477 # feature (like quota and billing) will be enabled.
2478 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002479 &quot;usage&quot;: { # Configuration controlling usage of a service. # Configuration controlling usage of this service.
2480 &quot;requirements&quot;: [ # Requirements that must be satisfied before a consumer project can use the
2481 # service. Each requirement is of the form &lt;service.name&gt;/&lt;requirement-id&gt;;
2482 # for example &#x27;serviceusage.googleapis.com/billing-enabled&#x27;.
2483 &quot;A String&quot;,
2484 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002485 &quot;serviceIdentity&quot;: { # The per-product per-project service identity for a service. # The configuration of a per-product per-project service identity.
2486 #
2487 #
2488 # Use this field to configure per-product per-project service identity.
2489 # Example of a service identity configuration.
2490 #
2491 # usage:
2492 # service_identity:
2493 # - service_account_parent: &quot;projects/123456789&quot;
2494 # display_name: &quot;Cloud XXX Service Agent&quot;
2495 # description: &quot;Used as the identity of Cloud XXX to access resources&quot;
2496 &quot;serviceAccountParent&quot;: &quot;A String&quot;, # A service account project that hosts the service accounts.
2497 #
2498 # An example name would be:
2499 # `projects/123456789`
2500 &quot;description&quot;: &quot;A String&quot;, # Optional. A user-specified opaque description of the service account.
2501 # Must be less than or equal to 256 UTF-8 bytes.
2502 &quot;displayName&quot;: &quot;A String&quot;, # Optional. A user-specified name for the service account.
2503 # Must be less than or equal to 100 UTF-8 bytes.
2504 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002505 &quot;rules&quot;: [ # A list of usage rules that apply to individual API methods.
2506 #
2507 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
2508 { # Usage configuration rules for the service.
2509 #
2510 # NOTE: Under development.
2511 #
2512 #
2513 # Use this rule to configure unregistered calls for the service. Unregistered
2514 # calls are calls that do not contain consumer project identity.
2515 # (Example: calls that do not contain an API key).
2516 # By default, API methods do not allow unregistered calls, and each method call
2517 # must be identified by a consumer project identity. Use this rule to
2518 # allow/disallow unregistered calls.
2519 #
2520 # Example of an API that wants to allow unregistered calls for entire service.
2521 #
2522 # usage:
2523 # rules:
2524 # - selector: &quot;*&quot;
2525 # allow_unregistered_calls: true
2526 #
2527 # Example of a method that wants to allow unregistered calls.
2528 #
2529 # usage:
2530 # rules:
2531 # - selector: &quot;google.example.library.v1.LibraryService.CreateBook&quot;
2532 # allow_unregistered_calls: true
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002533 &quot;skipServiceControl&quot;: True or False, # If true, the selected method should skip service control and the control
2534 # plane features, such as quota and billing, will not be available.
2535 # This flag is used by Google Cloud Endpoints to bypass checks for internal
2536 # methods, such as service health check methods.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002537 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies. Use &#x27;*&#x27; to indicate all
2538 # methods in all APIs.
2539 #
2540 # Refer to selector for syntax details.
2541 &quot;allowUnregisteredCalls&quot;: True or False, # If true, the selected method allows unregistered calls, e.g. calls
2542 # that don&#x27;t identify any user or application.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002543 },
2544 ],
2545 &quot;producerNotificationChannel&quot;: &quot;A String&quot;, # The full resource name of a channel used for sending notifications to the
2546 # service producer.
2547 #
2548 # Google Service Management currently only supports
2549 # [Google Cloud Pub/Sub](https://cloud.google.com/pubsub) as a notification
2550 # channel. To use Google Cloud Pub/Sub as the channel, this must be the name
2551 # of a Cloud Pub/Sub topic that uses the Cloud Pub/Sub topic name format
2552 # documented in https://cloud.google.com/pubsub/docs/overview.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002553 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002554 &quot;types&quot;: [ # A list of all proto message types included in this API service.
2555 # Types referenced directly or indirectly by the `apis` are
2556 # automatically included. Messages which are not referenced but
2557 # shall be included, such as types used by the `google.protobuf.Any` type,
2558 # should be listed here by name. Example:
2559 #
2560 # types:
2561 # - name: google.protobuf.Int32
2562 { # A protocol buffer message type.
2563 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # The source context.
2564 # protobuf element, like the file in which it is defined.
2565 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
2566 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
2567 },
2568 &quot;oneofs&quot;: [ # The list of types appearing in `oneof` definitions in this type.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002569 &quot;A String&quot;,
2570 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002571 &quot;fields&quot;: [ # The list of fields.
2572 { # A single field of a message type.
2573 &quot;oneofIndex&quot;: 42, # The index of the field type in `Type.oneofs`, for message or enumeration
2574 # types. The first type has index 1; zero means the type is not in the list.
2575 &quot;name&quot;: &quot;A String&quot;, # The field name.
2576 &quot;defaultValue&quot;: &quot;A String&quot;, # The string value of the default value of this field. Proto2 syntax only.
2577 &quot;packed&quot;: True or False, # Whether to use alternative packed wire representation.
2578 &quot;typeUrl&quot;: &quot;A String&quot;, # The field type URL, without the scheme, for message or enumeration
2579 # types. Example: `&quot;type.googleapis.com/google.protobuf.Timestamp&quot;`.
2580 &quot;cardinality&quot;: &quot;A String&quot;, # The field cardinality.
2581 &quot;jsonName&quot;: &quot;A String&quot;, # The field JSON name.
2582 &quot;kind&quot;: &quot;A String&quot;, # The field type.
2583 &quot;options&quot;: [ # The protocol buffer options.
2584 { # A protocol buffer option, which can be attached to a message, field,
2585 # enumeration, etc.
2586 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
2587 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
2588 # should be used. If the value is an enum, it should be stored as an int32
2589 # value using the google.protobuf.Int32Value type.
2590 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
2591 },
2592 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
2593 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
2594 # For custom options, it should be the fully-qualified name. For example,
2595 # `&quot;google.api.http&quot;`.
2596 },
2597 ],
2598 &quot;number&quot;: 42, # The field number.
2599 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002600 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002601 &quot;options&quot;: [ # The protocol buffer options.
2602 { # A protocol buffer option, which can be attached to a message, field,
2603 # enumeration, etc.
2604 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
2605 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
2606 # should be used. If the value is an enum, it should be stored as an int32
2607 # value using the google.protobuf.Int32Value type.
2608 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
2609 },
2610 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
2611 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
2612 # For custom options, it should be the fully-qualified name. For example,
2613 # `&quot;google.api.http&quot;`.
2614 },
2615 ],
2616 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax.
2617 &quot;name&quot;: &quot;A String&quot;, # The fully qualified message name.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002618 },
2619 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002620 &quot;http&quot;: { # Defines the HTTP configuration for an API service. It contains a list of # HTTP configuration.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002621 # HttpRule, each specifying the mapping of an RPC method
2622 # to one or more HTTP REST API methods.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002623 &quot;fullyDecodeReservedExpansion&quot;: True or False, # When set to true, URL path parameters will be fully URI-decoded except in
2624 # cases of single segment matches in reserved expansion, where &quot;%2F&quot; will be
2625 # left encoded.
2626 #
2627 # The default behavior is to not decode RFC 6570 reserved characters in multi
2628 # segment matches.
Bu Sun Kim65020912020-05-20 12:08:20 -07002629 &quot;rules&quot;: [ # A list of HTTP configuration rules that apply to individual API methods.
2630 #
2631 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002632 { # # gRPC Transcoding
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002633 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002634 # gRPC Transcoding is a feature for mapping between a gRPC method and one or
2635 # more HTTP REST endpoints. It allows developers to build a single API service
2636 # that supports both gRPC APIs and REST APIs. Many systems, including [Google
2637 # APIs](https://github.com/googleapis/googleapis),
2638 # [Cloud Endpoints](https://cloud.google.com/endpoints), [gRPC
2639 # Gateway](https://github.com/grpc-ecosystem/grpc-gateway),
2640 # and [Envoy](https://github.com/envoyproxy/envoy) proxy support this feature
2641 # and use it for large scale production services.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002642 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002643 # `HttpRule` defines the schema of the gRPC/REST mapping. The mapping specifies
2644 # how different portions of the gRPC request message are mapped to the URL
2645 # path, URL query parameters, and HTTP request body. It also controls how the
2646 # gRPC response message is mapped to the HTTP response body. `HttpRule` is
2647 # typically specified as an `google.api.http` annotation on the gRPC method.
2648 #
2649 # Each mapping specifies a URL path template and an HTTP method. The path
2650 # template may refer to one or more fields in the gRPC request message, as long
2651 # as each field is a non-repeated field with a primitive (non-message) type.
2652 # The path template controls how fields of the request message are mapped to
2653 # the URL path.
2654 #
2655 # Example:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002656 #
2657 # service Messaging {
2658 # rpc GetMessage(GetMessageRequest) returns (Message) {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002659 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07002660 # get: &quot;/v1/{name=messages/*}&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002661 # };
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002662 # }
2663 # }
2664 # message GetMessageRequest {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002665 # string name = 1; // Mapped to URL path.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002666 # }
2667 # message Message {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002668 # string text = 1; // The resource content.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002669 # }
2670 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002671 # This enables an HTTP REST to gRPC mapping as below:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002672 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002673 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002674 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -07002675 # `GET /v1/messages/123456` | `GetMessage(name: &quot;messages/123456&quot;)`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002676 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002677 # Any fields in the request message which are not bound by the path template
2678 # automatically become HTTP query parameters if there is no HTTP request body.
2679 # For example:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002680 #
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -04002681 # service Messaging {
2682 # rpc GetMessage(GetMessageRequest) returns (Message) {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002683 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07002684 # get:&quot;/v1/messages/{message_id}&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002685 # };
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -04002686 # }
2687 # }
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002688 # message GetMessageRequest {
2689 # message SubMessage {
2690 # string subfield = 1;
2691 # }
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002692 # string message_id = 1; // Mapped to URL path.
2693 # int64 revision = 2; // Mapped to URL query parameter `revision`.
2694 # SubMessage sub = 3; // Mapped to URL query parameter `sub.subfield`.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002695 # }
2696 #
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002697 # This enables a HTTP JSON to RPC mapping as below:
2698 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002699 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002700 # -----|-----
Dan O'Mearadd494642020-05-01 07:42:23 -07002701 # `GET /v1/messages/123456?revision=2&amp;sub.subfield=foo` |
Bu Sun Kim65020912020-05-20 12:08:20 -07002702 # `GetMessage(message_id: &quot;123456&quot; revision: 2 sub: SubMessage(subfield:
2703 # &quot;foo&quot;))`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002704 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002705 # Note that fields which are mapped to URL query parameters must have a
2706 # primitive type or a repeated primitive type or a non-repeated message type.
2707 # In the case of a repeated type, the parameter can be repeated in the URL
Dan O'Mearadd494642020-05-01 07:42:23 -07002708 # as `...?param=A&amp;param=B`. In the case of a message type, each field of the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002709 # message is mapped to a separate parameter, such as
Dan O'Mearadd494642020-05-01 07:42:23 -07002710 # `...?foo.a=A&amp;foo.b=B&amp;foo.c=C`.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002711 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002712 # For HTTP methods that allow a request body, the `body` field
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002713 # specifies the mapping. Consider a REST update method on the
2714 # message resource collection:
2715 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002716 # service Messaging {
2717 # rpc UpdateMessage(UpdateMessageRequest) returns (Message) {
2718 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07002719 # patch: &quot;/v1/messages/{message_id}&quot;
2720 # body: &quot;message&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002721 # };
2722 # }
2723 # }
2724 # message UpdateMessageRequest {
2725 # string message_id = 1; // mapped to the URL
2726 # Message message = 2; // mapped to the body
2727 # }
2728 #
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002729 # The following HTTP JSON to RPC mapping is enabled, where the
2730 # representation of the JSON in the request body is determined by
2731 # protos JSON encoding:
2732 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002733 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002734 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -07002735 # `PATCH /v1/messages/123456 { &quot;text&quot;: &quot;Hi!&quot; }` | `UpdateMessage(message_id:
2736 # &quot;123456&quot; message { text: &quot;Hi!&quot; })`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002737 #
2738 # The special name `*` can be used in the body mapping to define that
2739 # every field not bound by the path template should be mapped to the
2740 # request body. This enables the following alternative definition of
2741 # the update method:
2742 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002743 # service Messaging {
2744 # rpc UpdateMessage(Message) returns (Message) {
2745 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07002746 # patch: &quot;/v1/messages/{message_id}&quot;
2747 # body: &quot;*&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002748 # };
2749 # }
2750 # }
2751 # message Message {
2752 # string message_id = 1;
2753 # string text = 2;
2754 # }
2755 #
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002756 #
2757 # The following HTTP JSON to RPC mapping is enabled:
2758 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002759 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002760 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -07002761 # `PATCH /v1/messages/123456 { &quot;text&quot;: &quot;Hi!&quot; }` | `UpdateMessage(message_id:
2762 # &quot;123456&quot; text: &quot;Hi!&quot;)`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002763 #
2764 # Note that when using `*` in the body mapping, it is not possible to
2765 # have HTTP parameters, as all fields not bound by the path end in
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002766 # the body. This makes this option more rarely used in practice when
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002767 # defining REST APIs. The common usage of `*` is in custom methods
Bu Sun Kim65020912020-05-20 12:08:20 -07002768 # which don&#x27;t use the URL at all for transferring data.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002769 #
2770 # It is possible to define multiple HTTP methods for one RPC by using
2771 # the `additional_bindings` option. Example:
2772 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002773 # service Messaging {
2774 # rpc GetMessage(GetMessageRequest) returns (Message) {
2775 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07002776 # get: &quot;/v1/messages/{message_id}&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002777 # additional_bindings {
Bu Sun Kim65020912020-05-20 12:08:20 -07002778 # get: &quot;/v1/users/{user_id}/messages/{message_id}&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002779 # }
2780 # };
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002781 # }
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08002782 # }
2783 # message GetMessageRequest {
2784 # string message_id = 1;
2785 # string user_id = 2;
2786 # }
2787 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002788 # This enables the following two alternative HTTP JSON to RPC mappings:
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002789 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002790 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002791 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -07002792 # `GET /v1/messages/123456` | `GetMessage(message_id: &quot;123456&quot;)`
2793 # `GET /v1/users/me/messages/123456` | `GetMessage(user_id: &quot;me&quot; message_id:
2794 # &quot;123456&quot;)`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002795 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002796 # ## Rules for HTTP mapping
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002797 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002798 # 1. Leaf request fields (recursive expansion nested messages in the request
2799 # message) are classified into three categories:
2800 # - Fields referred by the path template. They are passed via the URL path.
2801 # - Fields referred by the HttpRule.body. They are passed via the HTTP
2802 # request body.
2803 # - All other fields are passed via the URL query parameters, and the
2804 # parameter name is the field path in the request message. A repeated
2805 # field can be represented as multiple query parameters under the same
2806 # name.
Bu Sun Kim65020912020-05-20 12:08:20 -07002807 # 2. If HttpRule.body is &quot;*&quot;, there is no URL query parameter, all fields
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002808 # are passed via URL path and HTTP request body.
2809 # 3. If HttpRule.body is omitted, there is no HTTP request body, all
2810 # fields are passed via URL path and URL query parameters.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002811 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002812 # ### Path template syntax
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002813 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002814 # Template = &quot;/&quot; Segments [ Verb ] ;
2815 # Segments = Segment { &quot;/&quot; Segment } ;
2816 # Segment = &quot;*&quot; | &quot;**&quot; | LITERAL | Variable ;
2817 # Variable = &quot;{&quot; FieldPath [ &quot;=&quot; Segments ] &quot;}&quot; ;
2818 # FieldPath = IDENT { &quot;.&quot; IDENT } ;
2819 # Verb = &quot;:&quot; LITERAL ;
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002820 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002821 # The syntax `*` matches a single URL path segment. The syntax `**` matches
2822 # zero or more URL path segments, which must be the last part of the URL path
2823 # except the `Verb`.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002824 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002825 # The syntax `Variable` matches part of the URL path as specified by its
2826 # template. A variable template must not contain other variables. If a variable
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002827 # matches a single path segment, its template may be omitted, e.g. `{var}`
2828 # is equivalent to `{var=*}`.
2829 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002830 # The syntax `LITERAL` matches literal text in the URL path. If the `LITERAL`
2831 # contains any reserved character, such characters should be percent-encoded
2832 # before the matching.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07002833 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002834 # If a variable contains exactly one path segment, such as `&quot;{var}&quot;` or
2835 # `&quot;{var=*}&quot;`, when such a variable is expanded into a URL path on the client
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002836 # side, all characters except `[-_.~0-9a-zA-Z]` are percent-encoded. The
2837 # server side does the reverse decoding. Such variables show up in the
2838 # [Discovery
2839 # Document](https://developers.google.com/discovery/v1/reference/apis) as
2840 # `{var}`.
2841 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002842 # If a variable contains multiple path segments, such as `&quot;{var=foo/*}&quot;`
2843 # or `&quot;{var=**}&quot;`, when such a variable is expanded into a URL path on the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002844 # client side, all characters except `[-_.~/0-9a-zA-Z]` are percent-encoded.
Bu Sun Kim65020912020-05-20 12:08:20 -07002845 # The server side does the reverse decoding, except &quot;%2F&quot; and &quot;%2f&quot; are left
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002846 # unchanged. Such variables show up in the
2847 # [Discovery
2848 # Document](https://developers.google.com/discovery/v1/reference/apis) as
2849 # `{+var}`.
2850 #
2851 # ## Using gRPC API Service Configuration
2852 #
2853 # gRPC API Service Configuration (service config) is a configuration language
2854 # for configuring a gRPC service to become a user-facing product. The
2855 # service config is simply the YAML representation of the `google.api.Service`
2856 # proto message.
2857 #
2858 # As an alternative to annotating your proto file, you can configure gRPC
2859 # transcoding in your service config YAML files. You do this by specifying a
2860 # `HttpRule` that maps the gRPC method to a REST endpoint, achieving the same
2861 # effect as the proto annotation. This can be particularly useful if you
2862 # have a proto that is reused in multiple services. Note that any transcoding
2863 # specified in the service config will override any matching transcoding
2864 # configuration in the proto.
2865 #
2866 # Example:
2867 #
2868 # http:
2869 # rules:
2870 # # Selects a gRPC method and applies HttpRule to it.
2871 # - selector: example.v1.Messaging.GetMessage
2872 # get: /v1/messages/{message_id}/{sub.subfield}
2873 #
2874 # ## Special notes
2875 #
2876 # When gRPC Transcoding is used to map a gRPC to JSON REST endpoints, the
2877 # proto to JSON conversion must follow the [proto3
2878 # specification](https://developers.google.com/protocol-buffers/docs/proto3#json).
2879 #
2880 # While the single segment variable follows the semantics of
2881 # [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.2 Simple String
2882 # Expansion, the multi segment variable **does not** follow RFC 6570 Section
2883 # 3.2.3 Reserved Expansion. The reason is that the Reserved Expansion
2884 # does not expand special characters like `?` and `#`, which would lead
2885 # to invalid URLs. As the result, gRPC Transcoding uses a custom encoding
2886 # for multi segment variables.
2887 #
2888 # The path variables **must not** refer to any repeated or mapped field,
2889 # because client libraries are not capable of handling such variable expansion.
2890 #
Bu Sun Kim65020912020-05-20 12:08:20 -07002891 # The path variables **must not** capture the leading &quot;/&quot; character. The reason
2892 # is that the most common use case &quot;{var}&quot; does not capture the leading &quot;/&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002893 # character. For consistency, all path variables must share the same behavior.
2894 #
2895 # Repeated message fields must not be mapped to URL query parameters, because
2896 # no client library can support such complicated mapping.
2897 #
2898 # If an API needs to use a JSON array for request or response body, it can map
2899 # the request or response body to a repeated field. However, some gRPC
2900 # Transcoding implementations may not support this feature.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002901 &quot;put&quot;: &quot;A String&quot;, # Maps to HTTP PUT. Used for replacing a resource.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002902 &quot;selector&quot;: &quot;A String&quot;, # Selects a method to which this rule applies.
2903 #
2904 # Refer to selector for syntax details.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002905 &quot;post&quot;: &quot;A String&quot;, # Maps to HTTP POST. Used for creating a resource or performing an action.
2906 &quot;responseBody&quot;: &quot;A String&quot;, # Optional. The name of the response field whose value is mapped to the HTTP
2907 # response body. When omitted, the entire response message will be used
2908 # as the HTTP response body.
2909 #
2910 # NOTE: The referred field must be present at the top-level of the response
2911 # message type.
2912 &quot;body&quot;: &quot;A String&quot;, # The name of the request field whose value is mapped to the HTTP request
2913 # body, or `*` for mapping all request fields not captured by the path
2914 # pattern to the HTTP body, or omitted for not having any HTTP request body.
2915 #
2916 # NOTE: the referred field must be present at the top-level of the request
2917 # message type.
2918 &quot;patch&quot;: &quot;A String&quot;, # Maps to HTTP PATCH. Used for updating a resource.
2919 &quot;additionalBindings&quot;: [ # Additional HTTP bindings for the selector. Nested bindings must
2920 # not contain an `additional_bindings` field themselves (that is,
2921 # the nesting may only be one level deep).
2922 # Object with schema name: HttpRule
2923 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002924 &quot;custom&quot;: { # A custom pattern is used for defining custom HTTP verb. # The custom pattern is used for specifying an HTTP method that is not
2925 # included in the `pattern` field, such as HEAD, or &quot;*&quot; to leave the
2926 # HTTP method unspecified for this rule. The wild-card rule is useful
2927 # for services that provide content to Web (HTML) clients.
2928 &quot;path&quot;: &quot;A String&quot;, # The path matched by this custom verb.
2929 &quot;kind&quot;: &quot;A String&quot;, # The name of this custom HTTP verb.
2930 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002931 &quot;allowHalfDuplex&quot;: True or False, # When this flag is set to true, HTTP requests will be allowed to invoke a
2932 # half-duplex streaming method.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002933 &quot;delete&quot;: &quot;A String&quot;, # Maps to HTTP DELETE. Used for deleting a resource.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002934 &quot;get&quot;: &quot;A String&quot;, # Maps to HTTP GET. Used for listing and getting information about
2935 # resources.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002936 },
2937 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002938 },
2939 &quot;logs&quot;: [ # Defines the logs used by this service.
2940 { # A description of a log type. Example in YAML format:
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002941 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002942 # - name: library.googleapis.com/activity_history
2943 # description: The history of borrowing and returning library items.
2944 # display_name: Activity
2945 # labels:
2946 # - key: /customer_id
2947 # description: Identifier of a library customer
2948 &quot;description&quot;: &quot;A String&quot;, # A human-readable description of this log. This information appears in
2949 # the documentation and can contain details.
2950 &quot;labels&quot;: [ # The set of labels that are available to describe a specific log entry.
2951 # Runtime requests that contain labels not specified here are
2952 # considered invalid.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002953 { # A description of a label.
2954 &quot;valueType&quot;: &quot;A String&quot;, # The type of data that can be assigned to the label.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002955 &quot;description&quot;: &quot;A String&quot;, # A human-readable description for the label.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002956 &quot;key&quot;: &quot;A String&quot;, # The label key.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002957 },
2958 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002959 &quot;displayName&quot;: &quot;A String&quot;, # The human-readable name for this log. This information appears on
2960 # the user interface and should be concise.
2961 &quot;name&quot;: &quot;A String&quot;, # The name of the log. It must be less than 512 characters long and can
2962 # include the following characters: upper- and lower-case alphanumeric
2963 # characters [A-Za-z0-9], and punctuation characters including
2964 # slash, underscore, hyphen, period [/_-.].
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07002965 },
2966 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002967 &quot;metrics&quot;: [ # Defines the metrics used by this service.
2968 { # Defines a metric type and its schema. Once a metric descriptor is created,
2969 # deleting or altering it stops data collection and makes the metric type&#x27;s
2970 # existing data unusable.
2971 #
2972 # The following are specific rules for service defined Monitoring metric
2973 # descriptors:
2974 #
2975 # * `type`, `metric_kind`, `value_type`, `description`, and `display_name`
2976 # fields are all required. The `unit` field must be specified
2977 # if the `value_type` is any of DOUBLE, INT64, DISTRIBUTION.
2978 # * Maximum of default 500 metric descriptors per service is allowed.
2979 # * Maximum of default 10 labels per metric descriptor is allowed.
2980 #
2981 # The default maximum limit can be overridden. Please follow
2982 # https://cloud.google.com/monitoring/quotas
2983 &quot;unit&quot;: &quot;A String&quot;, # The units in which the metric value is reported. It is only applicable
2984 # if the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The `unit`
2985 # defines the representation of the stored metric values.
2986 #
2987 # Different systems may scale the values to be more easily displayed (so a
2988 # value of `0.02KBy` _might_ be displayed as `20By`, and a value of
2989 # `3523KBy` _might_ be displayed as `3.5MBy`). However, if the `unit` is
2990 # `KBy`, then the value of the metric is always in thousands of bytes, no
2991 # matter how it may be displayed..
2992 #
2993 # If you want a custom metric to record the exact number of CPU-seconds used
2994 # by a job, you can create an `INT64 CUMULATIVE` metric whose `unit` is
2995 # `s{CPU}` (or equivalently `1s{CPU}` or just `s`). If the job uses 12,005
2996 # CPU-seconds, then the value is written as `12005`.
2997 #
2998 # Alternatively, if you want a custom metric to record data in a more
2999 # granular way, you can create a `DOUBLE CUMULATIVE` metric whose `unit` is
3000 # `ks{CPU}`, and then write the value `12.005` (which is `12005/1000`),
3001 # or use `Kis{CPU}` and write `11.723` (which is `12005/1024`).
3002 #
3003 # The supported units are a subset of [The Unified Code for Units of
3004 # Measure](http://unitsofmeasure.org/ucum.html) standard:
3005 #
3006 # **Basic units (UNIT)**
3007 #
3008 # * `bit` bit
3009 # * `By` byte
3010 # * `s` second
3011 # * `min` minute
3012 # * `h` hour
3013 # * `d` day
3014 # * `1` dimensionless
3015 #
3016 # **Prefixes (PREFIX)**
3017 #
3018 # * `k` kilo (10^3)
3019 # * `M` mega (10^6)
3020 # * `G` giga (10^9)
3021 # * `T` tera (10^12)
3022 # * `P` peta (10^15)
3023 # * `E` exa (10^18)
3024 # * `Z` zetta (10^21)
3025 # * `Y` yotta (10^24)
3026 #
3027 # * `m` milli (10^-3)
3028 # * `u` micro (10^-6)
3029 # * `n` nano (10^-9)
3030 # * `p` pico (10^-12)
3031 # * `f` femto (10^-15)
3032 # * `a` atto (10^-18)
3033 # * `z` zepto (10^-21)
3034 # * `y` yocto (10^-24)
3035 #
3036 # * `Ki` kibi (2^10)
3037 # * `Mi` mebi (2^20)
3038 # * `Gi` gibi (2^30)
3039 # * `Ti` tebi (2^40)
3040 # * `Pi` pebi (2^50)
3041 #
3042 # **Grammar**
3043 #
3044 # The grammar also includes these connectors:
3045 #
3046 # * `/` division or ratio (as an infix operator). For examples,
3047 # `kBy/{email}` or `MiBy/10ms` (although you should almost never
3048 # have `/s` in a metric `unit`; rates should always be computed at
3049 # query time from the underlying cumulative or delta value).
3050 # * `.` multiplication or composition (as an infix operator). For
3051 # examples, `GBy.d` or `k{watt}.h`.
3052 #
3053 # The grammar for a unit is as follows:
3054 #
3055 # Expression = Component { &quot;.&quot; Component } { &quot;/&quot; Component } ;
3056 #
3057 # Component = ( [ PREFIX ] UNIT | &quot;%&quot; ) [ Annotation ]
3058 # | Annotation
3059 # | &quot;1&quot;
3060 # ;
3061 #
3062 # Annotation = &quot;{&quot; NAME &quot;}&quot; ;
3063 #
3064 # Notes:
3065 #
3066 # * `Annotation` is just a comment if it follows a `UNIT`. If the annotation
3067 # is used alone, then the unit is equivalent to `1`. For examples,
3068 # `{request}/s == 1/s`, `By{transmitted}/s == By/s`.
3069 # * `NAME` is a sequence of non-blank printable ASCII characters not
3070 # containing `{` or `}`.
3071 # * `1` represents a unitary [dimensionless
3072 # unit](https://en.wikipedia.org/wiki/Dimensionless_quantity) of 1, such
3073 # as in `1/s`. It is typically used when none of the basic units are
3074 # appropriate. For example, &quot;new users per day&quot; can be represented as
3075 # `1/d` or `{new-users}/d` (and a metric value `5` would mean &quot;5 new
3076 # users). Alternatively, &quot;thousands of page views per day&quot; would be
3077 # represented as `1000/d` or `k1/d` or `k{page_views}/d` (and a metric
3078 # value of `5.3` would mean &quot;5300 page views per day&quot;).
3079 # * `%` represents dimensionless value of 1/100, and annotates values giving
3080 # a percentage (so the metric values are typically in the range of 0..100,
3081 # and a metric value `3` means &quot;3 percent&quot;).
3082 # * `10^2.%` indicates a metric contains a ratio, typically in the range
3083 # 0..1, that will be multiplied by 100 and displayed as a percentage
3084 # (so a metric value `0.03` means &quot;3 percent&quot;).
3085 &quot;displayName&quot;: &quot;A String&quot;, # A concise name for the metric, which can be displayed in user interfaces.
3086 # Use sentence case without an ending period, for example &quot;Request count&quot;.
3087 # This field is optional but it is recommended to be set for any metrics
3088 # associated with user-visible concepts, such as Quota.
3089 &quot;monitoredResourceTypes&quot;: [ # Read-only. If present, then a time
3090 # series, which is identified partially by
3091 # a metric type and a MonitoredResourceDescriptor, that is associated
3092 # with this metric type can only be associated with one of the monitored
3093 # resource types listed here.
3094 &quot;A String&quot;,
3095 ],
3096 &quot;metadata&quot;: { # Additional annotations that can be used to guide the usage of a metric. # Optional. Metadata which can be used to guide usage of the metric.
3097 &quot;samplePeriod&quot;: &quot;A String&quot;, # The sampling period of metric data points. For metrics which are written
3098 # periodically, consecutive data points are stored at this time interval,
3099 # excluding data loss due to errors. Metrics with a higher granularity have
3100 # a smaller sampling period.
3101 &quot;ingestDelay&quot;: &quot;A String&quot;, # The delay of data points caused by ingestion. Data points older than this
3102 # age are guaranteed to be ingested and available to be read, excluding
3103 # data loss due to errors.
3104 &quot;launchStage&quot;: &quot;A String&quot;, # Deprecated. Must use the MetricDescriptor.launch_stage instead.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07003105 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003106 &quot;name&quot;: &quot;A String&quot;, # The resource name of the metric descriptor.
3107 &quot;valueType&quot;: &quot;A String&quot;, # Whether the measurement is an integer, a floating-point number, etc.
3108 # Some combinations of `metric_kind` and `value_type` might not be supported.
3109 &quot;launchStage&quot;: &quot;A String&quot;, # Optional. The launch stage of the metric definition.
3110 &quot;type&quot;: &quot;A String&quot;, # The metric type, including its DNS name prefix. The type is not
3111 # URL-encoded.
3112 #
3113 # All service defined metrics must be prefixed with the service name, in the
3114 # format of `{service name}/{relative metric name}`, such as
3115 # `cloudsql.googleapis.com/database/cpu/utilization`. The relative metric
3116 # name must follow:
3117 #
3118 # * Only upper and lower-case letters, digits, &#x27;/&#x27; and underscores &#x27;_&#x27; are
3119 # allowed.
3120 # * The maximum number of characters allowed for the relative_metric_name is
3121 # 100.
3122 #
3123 # All user-defined metric types have the DNS name
3124 # `custom.googleapis.com`, `external.googleapis.com`, or
3125 # `logging.googleapis.com/user/`.
3126 #
3127 # Metric types should use a natural hierarchical grouping. For example:
3128 #
3129 # &quot;custom.googleapis.com/invoice/paid/amount&quot;
3130 # &quot;external.googleapis.com/prometheus/up&quot;
3131 # &quot;appengine.googleapis.com/http/server/response_latencies&quot;
3132 &quot;description&quot;: &quot;A String&quot;, # A detailed description of the metric, which can be used in documentation.
3133 &quot;labels&quot;: [ # The set of labels that can be used to describe a specific
3134 # instance of this metric type.
3135 #
3136 # The label key name must follow:
3137 #
3138 # * Only upper and lower-case letters, digits and underscores (_) are
3139 # allowed.
3140 # * Label name must start with a letter or digit.
3141 # * The maximum length of a label name is 100 characters.
3142 #
3143 # For example, the
3144 # `appengine.googleapis.com/http/server/response_latencies` metric
3145 # type has a label for the HTTP response code, `response_code`, so
3146 # you can look at latencies for successful responses or just
3147 # for responses that failed.
3148 { # A description of a label.
3149 &quot;valueType&quot;: &quot;A String&quot;, # The type of data that can be assigned to the label.
3150 &quot;description&quot;: &quot;A String&quot;, # A human-readable description for the label.
3151 &quot;key&quot;: &quot;A String&quot;, # The label key.
3152 },
3153 ],
3154 &quot;metricKind&quot;: &quot;A String&quot;, # Whether the metric records instantaneous values, changes to a value, etc.
3155 # Some combinations of `metric_kind` and `value_type` might not be supported.
3156 },
3157 ],
3158 &quot;documentation&quot;: { # `Documentation` provides the information for describing a service. # Additional API documentation.
Bu Sun Kim65020912020-05-20 12:08:20 -07003159 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003160 # Example:
3161 # &lt;pre&gt;&lt;code&gt;documentation:
3162 # summary: &gt;
3163 # The Google Calendar API gives access
3164 # to most calendar features.
3165 # pages:
3166 # - name: Overview
3167 # content: &amp;#40;== include google/foo/overview.md ==&amp;#41;
3168 # - name: Tutorial
3169 # content: &amp;#40;== include google/foo/tutorial.md ==&amp;#41;
3170 # subpages;
3171 # - name: Java
3172 # content: &amp;#40;== include google/foo/tutorial_java.md ==&amp;#41;
3173 # rules:
3174 # - selector: google.calendar.Calendar.Get
3175 # description: &gt;
3176 # ...
3177 # - selector: google.calendar.Calendar.Put
3178 # description: &gt;
3179 # ...
3180 # &lt;/code&gt;&lt;/pre&gt;
3181 # Documentation is provided in markdown syntax. In addition to
3182 # standard markdown features, definition lists, tables and fenced
3183 # code blocks are supported. Section headers can be provided and are
3184 # interpreted relative to the section nesting of the context where
3185 # a documentation fragment is embedded.
3186 #
3187 # Documentation from the IDL is merged with documentation defined
3188 # via the config at normalization time, where documentation provided
3189 # by config rules overrides IDL provided.
3190 #
3191 # A number of constructs specific to the API platform are supported
3192 # in documentation text.
3193 #
3194 # In order to reference a proto element, the following
3195 # notation can be used:
3196 # &lt;pre&gt;&lt;code&gt;&amp;#91;fully.qualified.proto.name]&amp;#91;]&lt;/code&gt;&lt;/pre&gt;
3197 # To override the display text used for the link, this can be used:
3198 # &lt;pre&gt;&lt;code&gt;&amp;#91;display text]&amp;#91;fully.qualified.proto.name]&lt;/code&gt;&lt;/pre&gt;
3199 # Text can be excluded from doc using the following notation:
3200 # &lt;pre&gt;&lt;code&gt;&amp;#40;-- internal comment --&amp;#41;&lt;/code&gt;&lt;/pre&gt;
3201 #
3202 # A few directives are available in documentation. Note that
3203 # directives must appear on a single line to be properly
3204 # identified. The `include` directive includes a markdown file from
3205 # an external source:
3206 # &lt;pre&gt;&lt;code&gt;&amp;#40;== include path/to/file ==&amp;#41;&lt;/code&gt;&lt;/pre&gt;
3207 # The `resource_for` directive marks a message to be the resource of
3208 # a collection in REST view. If it is not specified, tools attempt
3209 # to infer the resource from the operations in a collection:
3210 # &lt;pre&gt;&lt;code&gt;&amp;#40;== resource_for v1.shelves.books ==&amp;#41;&lt;/code&gt;&lt;/pre&gt;
3211 # The directive `suppress_warning` does not directly affect documentation
3212 # and is documented together with service config validation.
3213 &quot;serviceRootUrl&quot;: &quot;A String&quot;, # Specifies the service root url if the default one (the service name
3214 # from the yaml file) is not suitable. This can be seen in any fully
3215 # specified service urls as well as sections that show a base that other
3216 # urls are relative to.
3217 &quot;overview&quot;: &quot;A String&quot;, # Declares a single overview page. For example:
3218 # &lt;pre&gt;&lt;code&gt;documentation:
3219 # summary: ...
3220 # overview: &amp;#40;== include overview.md ==&amp;#41;
3221 # &lt;/code&gt;&lt;/pre&gt;
3222 # This is a shortcut for the following declaration (using pages style):
3223 # &lt;pre&gt;&lt;code&gt;documentation:
3224 # summary: ...
3225 # pages:
3226 # - name: Overview
3227 # content: &amp;#40;== include overview.md ==&amp;#41;
3228 # &lt;/code&gt;&lt;/pre&gt;
3229 # Note: you cannot specify both `overview` field and `pages` field.
3230 &quot;documentationRootUrl&quot;: &quot;A String&quot;, # The URL to the root of documentation.
3231 &quot;rules&quot;: [ # A list of documentation rules that apply to individual API elements.
Bu Sun Kim65020912020-05-20 12:08:20 -07003232 #
3233 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003234 { # A documentation rule provides information about individual API elements.
3235 &quot;deprecationDescription&quot;: &quot;A String&quot;, # Deprecation description of the selected element(s). It can be provided if
3236 # an element is marked as `deprecated`.
3237 &quot;description&quot;: &quot;A String&quot;, # Description of the selected API(s).
3238 &quot;selector&quot;: &quot;A String&quot;, # The selector is a comma-separated list of patterns. Each pattern is a
3239 # qualified name of the element which may end in &quot;*&quot;, indicating a wildcard.
3240 # Wildcards are only allowed at the end and for a whole component of the
3241 # qualified name, i.e. &quot;foo.*&quot; is ok, but not &quot;foo.b*&quot; or &quot;foo.*.bar&quot;. A
3242 # wildcard will match one or more components. To specify a default for all
3243 # applicable elements, the whole pattern &quot;*&quot; is used.
Bu Sun Kim65020912020-05-20 12:08:20 -07003244 },
3245 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003246 &quot;pages&quot;: [ # The top level pages for the documentation set.
3247 { # Represents a documentation page. A page can contain subpages to represent
3248 # nested documentation set structure.
3249 &quot;content&quot;: &quot;A String&quot;, # The Markdown content of the page. You can use &lt;code&gt;&amp;#40;== include {path}
3250 # ==&amp;#41;&lt;/code&gt; to include content from a Markdown file.
3251 &quot;name&quot;: &quot;A String&quot;, # The name of the page. It will be used as an identity of the page to
3252 # generate URI of the page, text of the link to this page in navigation,
3253 # etc. The full page name (start from the root page name to this page
3254 # concatenated with `.`) can be used as reference to the page in your
3255 # documentation. For example:
3256 # &lt;pre&gt;&lt;code&gt;pages:
3257 # - name: Tutorial
3258 # content: &amp;#40;== include tutorial.md ==&amp;#41;
3259 # subpages:
3260 # - name: Java
3261 # content: &amp;#40;== include tutorial_java.md ==&amp;#41;
3262 # &lt;/code&gt;&lt;/pre&gt;
3263 # You can reference `Java` page using Markdown reference link syntax:
3264 # `Java`.
3265 &quot;subpages&quot;: [ # Subpages of this page. The order of subpages specified here will be
3266 # honored in the generated docset.
3267 # Object with schema name: Page
3268 ],
3269 },
3270 ],
3271 &quot;summary&quot;: &quot;A String&quot;, # A short summary of what the service does. Can only be provided by
3272 # plain text.
Bu Sun Kim65020912020-05-20 12:08:20 -07003273 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003274 &quot;configVersion&quot;: 42, # The semantic version of the service configuration. The config version
3275 # affects the interpretation of the service configuration. For example,
3276 # certain features are enabled by default for certain config versions.
3277 #
3278 # The latest config version is `3`.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07003279 &quot;quota&quot;: { # Quota configuration helps to achieve fairness and budgeting in service # Quota configuration.
3280 # usage.
3281 #
3282 # The metric based quota configuration works this way:
3283 # - The service configuration defines a set of metrics.
3284 # - For API calls, the quota.metric_rules maps methods to metrics with
3285 # corresponding costs.
3286 # - The quota.limits defines limits on the metrics, which will be used for
3287 # quota checks at runtime.
3288 #
3289 # An example quota configuration in yaml format:
3290 #
3291 # quota:
3292 # limits:
3293 #
3294 # - name: apiWriteQpsPerProject
3295 # metric: library.googleapis.com/write_calls
3296 # unit: &quot;1/min/{project}&quot; # rate limit for consumer projects
3297 # values:
3298 # STANDARD: 10000
3299 #
3300 #
3301 # # The metric rules bind all methods to the read_calls metric,
3302 # # except for the UpdateBook and DeleteBook methods. These two methods
3303 # # are mapped to the write_calls metric, with the UpdateBook method
3304 # # consuming at twice rate as the DeleteBook method.
3305 # metric_rules:
3306 # - selector: &quot;*&quot;
3307 # metric_costs:
3308 # library.googleapis.com/read_calls: 1
3309 # - selector: google.example.library.v1.LibraryService.UpdateBook
3310 # metric_costs:
3311 # library.googleapis.com/write_calls: 2
3312 # - selector: google.example.library.v1.LibraryService.DeleteBook
3313 # metric_costs:
3314 # library.googleapis.com/write_calls: 1
3315 #
3316 # Corresponding Metric definition:
3317 #
3318 # metrics:
3319 # - name: library.googleapis.com/read_calls
3320 # display_name: Read requests
3321 # metric_kind: DELTA
3322 # value_type: INT64
3323 #
3324 # - name: library.googleapis.com/write_calls
3325 # display_name: Write requests
3326 # metric_kind: DELTA
3327 # value_type: INT64
3328 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003329 &quot;metricRules&quot;: [ # List of `MetricRule` definitions, each one mapping a selected method to one
3330 # or more metrics.
3331 { # Bind API methods to metrics. Binding a method to a metric causes that
3332 # metric&#x27;s configured quota behaviors to apply to the method call.
3333 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
3334 #
3335 # Refer to selector for syntax details.
3336 &quot;metricCosts&quot;: { # Metrics to update when the selected methods are called, and the associated
3337 # cost applied to each metric.
3338 #
3339 # The key of the map is the metric name, and the values are the amount
3340 # increased for the metric against which the quota limits are defined.
3341 # The value must not be negative.
3342 &quot;a_key&quot;: &quot;A String&quot;,
3343 },
3344 },
3345 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07003346 &quot;limits&quot;: [ # List of `QuotaLimit` definitions for the service.
3347 { # `QuotaLimit` defines a specific limit that applies over a specified duration
3348 # for a limit type. There can be at most one limit for a duration and limit
3349 # type combination defined within a `QuotaGroup`.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003350 &quot;values&quot;: { # Tiered limit values. You must specify this as a key:value pair, with an
3351 # integer value that is the maximum number of requests allowed for the
3352 # specified unit. Currently only STANDARD is supported.
3353 &quot;a_key&quot;: &quot;A String&quot;,
3354 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07003355 &quot;duration&quot;: &quot;A String&quot;, # Duration of this limit in textual notation. Must be &quot;100s&quot; or &quot;1d&quot;.
Bu Sun Kim65020912020-05-20 12:08:20 -07003356 #
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07003357 # Used by group-based quotas only.
3358 &quot;freeTier&quot;: &quot;A String&quot;, # Free tier value displayed in the Developers Console for this limit.
3359 # The free tier is the number of tokens that will be subtracted from the
3360 # billed amount when billing is enabled.
3361 # This field can only be set on a limit with duration &quot;1d&quot;, in a billable
3362 # group; it is invalid on any other limit. If this field is not set, it
3363 # defaults to 0, indicating that there is no free tier for this service.
Bu Sun Kim65020912020-05-20 12:08:20 -07003364 #
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07003365 # Used by group-based quotas only.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003366 &quot;displayName&quot;: &quot;A String&quot;, # User-visible display name for this limit.
3367 # Optional. If not set, the UI will provide a default display name based on
3368 # the quota configuration. This field can be used to override the default
3369 # display name generated from the configuration.
3370 &quot;description&quot;: &quot;A String&quot;, # Optional. User-visible, extended description for this quota limit.
3371 # Should be used only when more context is needed to understand this limit
3372 # than provided by the limit&#x27;s display name (see: `display_name`).
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07003373 &quot;defaultLimit&quot;: &quot;A String&quot;, # Default number of tokens that can be consumed during the specified
3374 # duration. This is the number of tokens assigned when a client
3375 # application developer activates the service for his/her project.
3376 #
3377 # Specifying a value of 0 will block all requests. This can be used if you
3378 # are provisioning quota to selected consumers and blocking others.
3379 # Similarly, a value of -1 will indicate an unlimited quota. No other
3380 # negative values are allowed.
3381 #
3382 # Used by group-based quotas only.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07003383 &quot;name&quot;: &quot;A String&quot;, # Name of the quota limit.
3384 #
3385 # The name must be provided, and it must be unique within the service. The
3386 # name can only include alphanumeric characters as well as &#x27;-&#x27;.
3387 #
3388 # The maximum length of the limit name is 64 characters.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003389 &quot;maxLimit&quot;: &quot;A String&quot;, # Maximum number of tokens that can be consumed during the specified
3390 # duration. Client application developers can override the default limit up
3391 # to this maximum. If specified, this value cannot be set to a value less
3392 # than the default limit. If not specified, it is set to the default limit.
3393 #
3394 # To allow clients to apply overrides with no upper bound, set this to -1,
3395 # indicating unlimited maximum quota.
3396 #
3397 # Used by group-based quotas only.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07003398 &quot;metric&quot;: &quot;A String&quot;, # The name of the metric this quota limit applies to. The quota limits with
3399 # the same metric will be checked together during runtime. The metric must be
3400 # defined within the service config.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003401 &quot;unit&quot;: &quot;A String&quot;, # Specify the unit of the quota limit. It uses the same syntax as
3402 # Metric.unit. The supported unit kinds are determined by the quota
3403 # backend system.
3404 #
3405 # Here are some examples:
3406 # * &quot;1/min/{project}&quot; for quota per minute per project.
3407 #
3408 # Note: the order of unit components is insignificant.
3409 # The &quot;1&quot; at the beginning is required to follow the metric unit syntax.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07003410 },
3411 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003412 },
3413 &quot;customError&quot;: { # Customize service error responses. For example, list any service # Custom error configuration.
3414 # specific protobuf types that can appear in error detail lists of
3415 # error responses.
3416 #
3417 # Example:
3418 #
3419 # custom_error:
3420 # types:
3421 # - google.foo.v1.CustomError
3422 # - google.foo.v1.AnotherError
3423 &quot;types&quot;: [ # The list of custom error detail types, e.g. &#x27;google.foo.v1.CustomError&#x27;.
3424 &quot;A String&quot;,
3425 ],
3426 &quot;rules&quot;: [ # The list of custom error rules that apply to individual API messages.
3427 #
3428 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
3429 { # A custom error rule.
3430 &quot;selector&quot;: &quot;A String&quot;, # Selects messages to which this rule applies.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07003431 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003432 # Refer to selector for syntax details.
3433 &quot;isErrorType&quot;: True or False, # Mark this message as possible payload in error response. Otherwise,
3434 # objects of this type will be filtered when they appear in error payload.
3435 },
3436 ],
3437 },
3438 &quot;authentication&quot;: { # `Authentication` defines the authentication configuration for an API. # Auth configuration.
3439 #
3440 # Example for an API targeted for external use:
3441 #
3442 # name: calendar.googleapis.com
3443 # authentication:
3444 # providers:
3445 # - id: google_calendar_auth
3446 # jwks_uri: https://www.googleapis.com/oauth2/v1/certs
3447 # issuer: https://securetoken.google.com
3448 # rules:
3449 # - selector: &quot;*&quot;
3450 # requirements:
3451 # provider_id: google_calendar_auth
3452 &quot;rules&quot;: [ # A list of authentication rules that apply to individual API methods.
3453 #
3454 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
3455 { # Authentication rules for the service.
3456 #
3457 # By default, if a method has any authentication requirements, every request
3458 # must include a valid credential matching one of the requirements.
3459 # It&#x27;s an error to include more than one kind of credential in a single
3460 # request.
3461 #
3462 # If a method doesn&#x27;t have any auth requirements, request credentials will be
3463 # ignored.
3464 &quot;oauth&quot;: { # OAuth scopes are a way to define data and permissions on data. For example, # The requirements for OAuth credentials.
3465 # there are scopes defined for &quot;Read-only access to Google Calendar&quot; and
3466 # &quot;Access to Cloud Platform&quot;. Users can consent to a scope for an application,
3467 # giving it permission to access that data on their behalf.
3468 #
3469 # OAuth scope specifications should be fairly coarse grained; a user will need
3470 # to see and understand the text description of what your scope means.
3471 #
3472 # In most cases: use one or at most two OAuth scopes for an entire family of
3473 # products. If your product has multiple APIs, you should probably be sharing
3474 # the OAuth scope across all of those APIs.
3475 #
3476 # When you need finer grained OAuth consent screens: talk with your product
3477 # management about how developers will use them in practice.
3478 #
3479 # Please note that even though each of the canonical scopes is enough for a
3480 # request to be accepted and passed to the backend, a request can still fail
3481 # due to the backend requiring additional scopes or permissions.
3482 &quot;canonicalScopes&quot;: &quot;A String&quot;, # The list of publicly documented OAuth scopes that are allowed access. An
3483 # OAuth token containing any of these scopes will be accepted.
3484 #
3485 # Example:
3486 #
3487 # canonical_scopes: https://www.googleapis.com/auth/calendar,
3488 # https://www.googleapis.com/auth/calendar.read
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07003489 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003490 &quot;requirements&quot;: [ # Requirements for additional authentication providers.
3491 { # User-defined authentication requirements, including support for
3492 # [JSON Web Token
3493 # (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32).
3494 &quot;providerId&quot;: &quot;A String&quot;, # id from authentication provider.
3495 #
3496 # Example:
3497 #
3498 # provider_id: bookstore_auth
3499 &quot;audiences&quot;: &quot;A String&quot;, # NOTE: This will be deprecated soon, once AuthProvider.audiences is
3500 # implemented and accepted in all the runtime components.
3501 #
3502 # The list of JWT
3503 # [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3).
3504 # that are allowed to access. A JWT containing any of these audiences will
3505 # be accepted. When this setting is absent, only JWTs with audience
3506 # &quot;https://Service_name/API_name&quot;
3507 # will be accepted. For example, if no audiences are in the setting,
3508 # LibraryService API will only accept JWTs with the following audience
3509 # &quot;https://library-example.googleapis.com/google.example.library.v1.LibraryService&quot;.
3510 #
3511 # Example:
3512 #
3513 # audiences: bookstore_android.apps.googleusercontent.com,
3514 # bookstore_web.apps.googleusercontent.com
3515 },
3516 ],
3517 &quot;allowWithoutCredential&quot;: True or False, # If true, the service accepts API keys without any other credential.
Bu Sun Kim65020912020-05-20 12:08:20 -07003518 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
3519 #
3520 # Refer to selector for syntax details.
Bu Sun Kim65020912020-05-20 12:08:20 -07003521 },
3522 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003523 &quot;providers&quot;: [ # Defines a set of authentication providers that a service supports.
3524 { # Configuration for an authentication provider, including support for
3525 # [JSON Web Token
3526 # (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32).
3527 &quot;id&quot;: &quot;A String&quot;, # The unique identifier of the auth provider. It will be referred to by
3528 # `AuthRequirement.provider_id`.
3529 #
3530 # Example: &quot;bookstore_auth&quot;.
3531 &quot;issuer&quot;: &quot;A String&quot;, # Identifies the principal that issued the JWT. See
3532 # https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.1
3533 # Usually a URL or an email address.
3534 #
3535 # Example: https://securetoken.google.com
3536 # Example: 1234567-compute@developer.gserviceaccount.com
3537 &quot;jwksUri&quot;: &quot;A String&quot;, # URL of the provider&#x27;s public key set to validate signature of the JWT. See
3538 # [OpenID
3539 # Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata).
3540 # Optional if the key set document:
3541 # - can be retrieved from
3542 # [OpenID
3543 # Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html of
3544 # the issuer.
3545 # - can be inferred from the email domain of the issuer (e.g. a Google
3546 # service account).
3547 #
3548 # Example: https://www.googleapis.com/oauth2/v1/certs
3549 &quot;audiences&quot;: &quot;A String&quot;, # The list of JWT
3550 # [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3).
3551 # that are allowed to access. A JWT containing any of these audiences will
3552 # be accepted. When this setting is absent, JWTs with audiences:
3553 # - &quot;https://[service.name]/[google.protobuf.Api.name]&quot;
3554 # - &quot;https://[service.name]/&quot;
3555 # will be accepted.
3556 # For example, if no audiences are in the setting, LibraryService API will
3557 # accept JWTs with the following audiences:
3558 # -
3559 # https://library-example.googleapis.com/google.example.library.v1.LibraryService
3560 # - https://library-example.googleapis.com/
3561 #
3562 # Example:
3563 #
3564 # audiences: bookstore_android.apps.googleusercontent.com,
3565 # bookstore_web.apps.googleusercontent.com
3566 &quot;authorizationUrl&quot;: &quot;A String&quot;, # Redirect URL if JWT token is required but not present or is expired.
3567 # Implement authorizationUrl of securityDefinitions in OpenAPI spec.
3568 &quot;jwtLocations&quot;: [ # Defines the locations to extract the JWT.
3569 #
3570 # JWT locations can be either from HTTP headers or URL query parameters.
3571 # The rule is that the first match wins. The checking order is: checking
3572 # all headers first, then URL query parameters.
3573 #
3574 # If not specified, default to use following 3 locations:
3575 # 1) Authorization: Bearer
3576 # 2) x-goog-iap-jwt-assertion
3577 # 3) access_token query parameter
3578 #
3579 # Default locations can be specified as followings:
3580 # jwt_locations:
3581 # - header: Authorization
3582 # value_prefix: &quot;Bearer &quot;
3583 # - header: x-goog-iap-jwt-assertion
3584 # - query: access_token
3585 { # Specifies a location to extract JWT from an API request.
3586 &quot;query&quot;: &quot;A String&quot;, # Specifies URL query parameter name to extract JWT token.
3587 &quot;valuePrefix&quot;: &quot;A String&quot;, # The value prefix. The value format is &quot;value_prefix{token}&quot;
3588 # Only applies to &quot;in&quot; header type. Must be empty for &quot;in&quot; query type.
3589 # If not empty, the header value has to match (case sensitive) this prefix.
3590 # If not matched, JWT will not be extracted. If matched, JWT will be
3591 # extracted after the prefix is removed.
3592 #
3593 # For example, for &quot;Authorization: Bearer {JWT}&quot;,
3594 # value_prefix=&quot;Bearer &quot; with a space at the end.
3595 &quot;header&quot;: &quot;A String&quot;, # Specifies HTTP header name to extract JWT token.
3596 },
3597 ],
3598 },
3599 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07003600 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003601 &quot;title&quot;: &quot;A String&quot;, # The product title for this service.
3602 &quot;producerProjectId&quot;: &quot;A String&quot;, # The Google project that owns this service.
3603 &quot;apis&quot;: [ # A list of API interfaces exported by this service. Only the `name` field
3604 # of the google.protobuf.Api needs to be provided by the configuration
3605 # author, as the remaining fields will be derived from the IDL during the
3606 # normalization process. It is an error to specify an API interface here
3607 # which cannot be resolved against the associated IDL files.
3608 { # Api is a light-weight descriptor for an API Interface.
3609 #
3610 # Interfaces are also described as &quot;protocol buffer services&quot; in some contexts,
3611 # such as by the &quot;service&quot; keyword in a .proto file, but they are different
3612 # from API Services, which represent a concrete implementation of an interface
3613 # as opposed to simply a description of methods and bindings. They are also
3614 # sometimes simply referred to as &quot;APIs&quot; in other contexts, such as the name of
3615 # this message itself. See https://cloud.google.com/apis/design/glossary for
3616 # detailed terminology.
3617 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # Source context for the protocol buffer service represented by this
3618 # message.
3619 # protobuf element, like the file in which it is defined.
3620 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
3621 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
3622 },
3623 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax of the service.
3624 &quot;methods&quot;: [ # The methods of this interface, in unspecified order.
3625 { # Method represents a method of an API interface.
3626 &quot;options&quot;: [ # Any metadata attached to the method.
3627 { # A protocol buffer option, which can be attached to a message, field,
3628 # enumeration, etc.
3629 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
3630 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
3631 # should be used. If the value is an enum, it should be stored as an int32
3632 # value using the google.protobuf.Int32Value type.
3633 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
3634 },
3635 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
3636 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
3637 # For custom options, it should be the fully-qualified name. For example,
3638 # `&quot;google.api.http&quot;`.
3639 },
3640 ],
3641 &quot;responseStreaming&quot;: True or False, # If true, the response is streamed.
3642 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax of this method.
3643 &quot;requestTypeUrl&quot;: &quot;A String&quot;, # A URL of the input message type.
3644 &quot;name&quot;: &quot;A String&quot;, # The simple name of this method.
3645 &quot;responseTypeUrl&quot;: &quot;A String&quot;, # The URL of the output message type.
3646 &quot;requestStreaming&quot;: True or False, # If true, the request is streamed.
3647 },
3648 ],
3649 &quot;name&quot;: &quot;A String&quot;, # The fully qualified name of this interface, including package name
3650 # followed by the interface&#x27;s simple name.
3651 &quot;version&quot;: &quot;A String&quot;, # A version string for this interface. If specified, must have the form
3652 # `major-version.minor-version`, as in `1.10`. If the minor version is
3653 # omitted, it defaults to zero. If the entire version field is empty, the
3654 # major version is derived from the package name, as outlined below. If the
3655 # field is not empty, the version in the package name will be verified to be
3656 # consistent with what is provided here.
3657 #
3658 # The versioning schema uses [semantic
3659 # versioning](http://semver.org) where the major version number
3660 # indicates a breaking change and the minor version an additive,
3661 # non-breaking change. Both version numbers are signals to users
3662 # what to expect from different versions, and should be carefully
3663 # chosen based on the product plan.
3664 #
3665 # The major version is also reflected in the package name of the
3666 # interface, which must end in `v&lt;major-version&gt;`, as in
3667 # `google.feature.v1`. For major versions 0 and 1, the suffix can
3668 # be omitted. Zero major versions must only be used for
3669 # experimental, non-GA interfaces.
3670 &quot;options&quot;: [ # Any metadata attached to the interface.
3671 { # A protocol buffer option, which can be attached to a message, field,
3672 # enumeration, etc.
3673 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
3674 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
3675 # should be used. If the value is an enum, it should be stored as an int32
3676 # value using the google.protobuf.Int32Value type.
3677 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
3678 },
3679 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
3680 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
3681 # For custom options, it should be the fully-qualified name. For example,
3682 # `&quot;google.api.http&quot;`.
3683 },
3684 ],
3685 &quot;mixins&quot;: [ # Included interfaces. See Mixin.
3686 { # Declares an API Interface to be included in this interface. The including
3687 # interface must redeclare all the methods from the included interface, but
3688 # documentation and options are inherited as follows:
3689 #
3690 # - If after comment and whitespace stripping, the documentation
3691 # string of the redeclared method is empty, it will be inherited
3692 # from the original method.
3693 #
3694 # - Each annotation belonging to the service config (http,
3695 # visibility) which is not set in the redeclared method will be
3696 # inherited.
3697 #
3698 # - If an http annotation is inherited, the path pattern will be
3699 # modified as follows. Any version prefix will be replaced by the
3700 # version of the including interface plus the root path if
3701 # specified.
3702 #
3703 # Example of a simple mixin:
3704 #
3705 # package google.acl.v1;
3706 # service AccessControl {
3707 # // Get the underlying ACL object.
3708 # rpc GetAcl(GetAclRequest) returns (Acl) {
3709 # option (google.api.http).get = &quot;/v1/{resource=**}:getAcl&quot;;
3710 # }
3711 # }
3712 #
3713 # package google.storage.v2;
3714 # service Storage {
3715 # // rpc GetAcl(GetAclRequest) returns (Acl);
3716 #
3717 # // Get a data record.
3718 # rpc GetData(GetDataRequest) returns (Data) {
3719 # option (google.api.http).get = &quot;/v2/{resource=**}&quot;;
3720 # }
3721 # }
3722 #
3723 # Example of a mixin configuration:
3724 #
3725 # apis:
3726 # - name: google.storage.v2.Storage
3727 # mixins:
3728 # - name: google.acl.v1.AccessControl
3729 #
3730 # The mixin construct implies that all methods in `AccessControl` are
3731 # also declared with same name and request/response types in
3732 # `Storage`. A documentation generator or annotation processor will
3733 # see the effective `Storage.GetAcl` method after inherting
3734 # documentation and annotations as follows:
3735 #
3736 # service Storage {
3737 # // Get the underlying ACL object.
3738 # rpc GetAcl(GetAclRequest) returns (Acl) {
3739 # option (google.api.http).get = &quot;/v2/{resource=**}:getAcl&quot;;
3740 # }
3741 # ...
3742 # }
3743 #
3744 # Note how the version in the path pattern changed from `v1` to `v2`.
3745 #
3746 # If the `root` field in the mixin is specified, it should be a
3747 # relative path under which inherited HTTP paths are placed. Example:
3748 #
3749 # apis:
3750 # - name: google.storage.v2.Storage
3751 # mixins:
3752 # - name: google.acl.v1.AccessControl
3753 # root: acls
3754 #
3755 # This implies the following inherited HTTP annotation:
3756 #
3757 # service Storage {
3758 # // Get the underlying ACL object.
3759 # rpc GetAcl(GetAclRequest) returns (Acl) {
3760 # option (google.api.http).get = &quot;/v2/acls/{resource=**}:getAcl&quot;;
3761 # }
3762 # ...
3763 # }
3764 &quot;root&quot;: &quot;A String&quot;, # If non-empty specifies a path under which inherited HTTP paths
3765 # are rooted.
3766 &quot;name&quot;: &quot;A String&quot;, # The fully qualified name of the interface which is included.
3767 },
3768 ],
3769 },
3770 ],
3771 &quot;id&quot;: &quot;A String&quot;, # A unique ID for a specific instance of this message, typically assigned
3772 # by the client for tracking purpose. Must be no longer than 63 characters
3773 # and only lower case letters, digits, &#x27;.&#x27;, &#x27;_&#x27; and &#x27;-&#x27; are allowed. If
3774 # empty, the server may choose to generate one instead.
3775 &quot;endpoints&quot;: [ # Configuration for network endpoints. If this is empty, then an endpoint
3776 # with the same name as the service is automatically generated to service all
3777 # defined APIs.
3778 { # `Endpoint` describes a network endpoint that serves a set of APIs.
3779 # A service may expose any number of endpoints, and all endpoints share the
3780 # same service configuration, such as quota configuration and monitoring
3781 # configuration.
3782 #
3783 # Example service configuration:
3784 #
3785 # name: library-example.googleapis.com
3786 # endpoints:
3787 # # Below entry makes &#x27;google.example.library.v1.Library&#x27;
3788 # # API be served from endpoint address library-example.googleapis.com.
3789 # # It also allows HTTP OPTIONS calls to be passed to the backend, for
3790 # # it to decide whether the subsequent cross-origin request is
3791 # # allowed to proceed.
3792 # - name: library-example.googleapis.com
3793 # allow_cors: true
3794 &quot;name&quot;: &quot;A String&quot;, # The canonical name of this endpoint.
3795 &quot;allowCors&quot;: True or False, # Allowing
3796 # [CORS](https://en.wikipedia.org/wiki/Cross-origin_resource_sharing), aka
3797 # cross-domain traffic, would allow the backends served from this endpoint to
3798 # receive and respond to HTTP OPTIONS requests. The response will be used by
3799 # the browser to determine whether the subsequent cross-origin request is
3800 # allowed to proceed.
3801 &quot;target&quot;: &quot;A String&quot;, # The specification of an Internet routable address of API frontend that will
3802 # handle requests to this [API
3803 # Endpoint](https://cloud.google.com/apis/design/glossary). It should be
3804 # either a valid IPv4 address or a fully-qualified domain name. For example,
3805 # &quot;8.8.8.8&quot; or &quot;myservice.appspot.com&quot;.
3806 &quot;aliases&quot;: [ # DEPRECATED: This field is no longer supported. Instead of using aliases,
3807 # please specify multiple google.api.Endpoint for each of the intended
3808 # aliases.
3809 #
3810 # Additional names that this endpoint will be hosted on.
3811 &quot;A String&quot;,
3812 ],
3813 },
3814 ],
3815 &quot;systemParameters&quot;: { # ### System parameter configuration # System parameter configuration.
3816 #
3817 # A system parameter is a special kind of parameter defined by the API
3818 # system, not by an individual API. It is typically mapped to an HTTP header
3819 # and/or a URL query parameter. This configuration specifies which methods
3820 # change the names of the system parameters.
3821 &quot;rules&quot;: [ # Define system parameters.
3822 #
3823 # The parameters defined here will override the default parameters
3824 # implemented by the system. If this field is missing from the service
3825 # config, default system parameters will be used. Default system parameters
3826 # and names is implementation-dependent.
3827 #
3828 # Example: define api key for all methods
3829 #
3830 # system_parameters
3831 # rules:
3832 # - selector: &quot;*&quot;
3833 # parameters:
3834 # - name: api_key
3835 # url_query_parameter: api_key
3836 #
3837 #
3838 # Example: define 2 api key names for a specific method.
3839 #
3840 # system_parameters
3841 # rules:
3842 # - selector: &quot;/ListShelves&quot;
3843 # parameters:
3844 # - name: api_key
3845 # http_header: Api-Key1
3846 # - name: api_key
3847 # http_header: Api-Key2
3848 #
3849 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
3850 { # Define a system parameter rule mapping system parameter definitions to
3851 # methods.
3852 &quot;parameters&quot;: [ # Define parameters. Multiple names may be defined for a parameter.
3853 # For a given method call, only one of them should be used. If multiple
3854 # names are used the behavior is implementation-dependent.
3855 # If none of the specified names are present the behavior is
3856 # parameter-dependent.
3857 { # Define a parameter&#x27;s name and location. The parameter may be passed as either
3858 # an HTTP header or a URL query parameter, and if both are passed the behavior
3859 # is implementation-dependent.
3860 &quot;name&quot;: &quot;A String&quot;, # Define the name of the parameter, such as &quot;api_key&quot; . It is case sensitive.
3861 &quot;httpHeader&quot;: &quot;A String&quot;, # Define the HTTP header name to use for the parameter. It is case
3862 # insensitive.
3863 &quot;urlQueryParameter&quot;: &quot;A String&quot;, # Define the URL query parameter name to use for the parameter. It is case
3864 # sensitive.
3865 },
3866 ],
3867 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies. Use &#x27;*&#x27; to indicate all
3868 # methods in all APIs.
3869 #
3870 # Refer to selector for syntax details.
3871 },
3872 ],
3873 },
3874 &quot;monitoredResources&quot;: [ # Defines the monitored resources used by this service. This is required
3875 # by the Service.monitoring and Service.logging configurations.
3876 { # An object that describes the schema of a MonitoredResource object using a
3877 # type name and a set of labels. For example, the monitored resource
3878 # descriptor for Google Compute Engine VM instances has a type of
3879 # `&quot;gce_instance&quot;` and specifies the use of the labels `&quot;instance_id&quot;` and
3880 # `&quot;zone&quot;` to identify particular VM instances.
3881 #
3882 # Different services can support different monitored resource types.
3883 #
3884 # The following are specific rules to service defined monitored resources for
3885 # Monitoring and Logging:
3886 #
3887 # * The `type`, `display_name`, `description`, `labels` and `launch_stage`
3888 # fields are all required.
3889 # * The first label of the monitored resource descriptor must be
3890 # `resource_container`. There are legacy monitored resource descritptors
3891 # start with `project_id`.
3892 # * It must include a `location` label.
3893 # * Maximum of default 5 service defined monitored resource descriptors
3894 # is allowed per service.
3895 # * Maximum of default 10 labels per monitored resource is allowed.
3896 #
3897 # The default maximum limit can be overridden. Please follow
3898 # https://cloud.google.com/monitoring/quotas
3899 &quot;name&quot;: &quot;A String&quot;, # Optional. The resource name of the monitored resource descriptor:
3900 # `&quot;projects/{project_id}/monitoredResourceDescriptors/{type}&quot;` where
3901 # {type} is the value of the `type` field in this object and
3902 # {project_id} is a project ID that provides API-specific context for
3903 # accessing the type. APIs that do not use project information can use the
3904 # resource name format `&quot;monitoredResourceDescriptors/{type}&quot;`.
3905 &quot;launchStage&quot;: &quot;A String&quot;, # Optional. The launch stage of the monitored resource definition.
3906 &quot;displayName&quot;: &quot;A String&quot;, # Optional. A concise name for the monitored resource type that might be
3907 # displayed in user interfaces. It should be a Title Cased Noun Phrase,
3908 # without any article or other determiners. For example,
3909 # `&quot;Google Cloud SQL Database&quot;`.
3910 &quot;labels&quot;: [ # Required. A set of labels used to describe instances of this monitored
3911 # resource type.
3912 # The label key name must follow:
3913 #
3914 # * Only upper and lower-case letters, digits and underscores (_) are
3915 # allowed.
3916 # * Label name must start with a letter or digit.
3917 # * The maximum length of a label name is 100 characters.
3918 #
3919 # For example, an individual Google Cloud SQL database is
3920 # identified by values for the labels `database_id` and `location`.
3921 { # A description of a label.
3922 &quot;valueType&quot;: &quot;A String&quot;, # The type of data that can be assigned to the label.
3923 &quot;description&quot;: &quot;A String&quot;, # A human-readable description for the label.
3924 &quot;key&quot;: &quot;A String&quot;, # The label key.
3925 },
3926 ],
3927 &quot;description&quot;: &quot;A String&quot;, # Optional. A detailed description of the monitored resource type that might
3928 # be used in documentation.
3929 &quot;type&quot;: &quot;A String&quot;, # Required. The monitored resource type. For example, the type
3930 # `cloudsql_database` represents databases in Google Cloud SQL.
3931 #
3932 # All service defined monitored resource types must be prefixed with the
3933 # service name, in the format of `{service name}/{relative resource name}`.
3934 # The relative resource name must follow:
3935 #
3936 # * Only upper and lower-case letters and digits are allowed.
3937 # * It must start with upper case character and is recommended to use Upper
3938 # Camel Case style.
3939 # * The maximum number of characters allowed for the relative_resource_name
3940 # is 100.
3941 #
3942 # Note there are legacy service monitored resources not following this rule.
3943 },
3944 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07003945 &quot;context&quot;: { # `Context` defines which contexts an API requests. # Context configuration.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07003946 #
3947 # Example:
3948 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003949 # context:
3950 # rules:
3951 # - selector: &quot;*&quot;
3952 # requested:
3953 # - google.rpc.context.ProjectContext
3954 # - google.rpc.context.OriginContext
3955 #
3956 # The above specifies that all methods in the API request
3957 # `google.rpc.context.ProjectContext` and
3958 # `google.rpc.context.OriginContext`.
3959 #
3960 # Available context types are defined in package
3961 # `google.rpc.context`.
3962 #
3963 # This also provides mechanism to whitelist any protobuf message extension that
3964 # can be sent in grpc metadata using “x-goog-ext-&lt;extension_id&gt;-bin” and
3965 # “x-goog-ext-&lt;extension_id&gt;-jspb” format. For example, list any service
3966 # specific protobuf types that can appear in grpc metadata as follows in your
3967 # yaml file:
3968 #
3969 # Example:
3970 #
3971 # context:
3972 # rules:
3973 # - selector: &quot;google.example.library.v1.LibraryService.CreateBook&quot;
3974 # allowed_request_extensions:
3975 # - google.foo.v1.NewExtension
3976 # allowed_response_extensions:
3977 # - google.foo.v1.NewExtension
3978 #
3979 # You can also specify extension ID instead of fully qualified extension name
3980 # here.
3981 &quot;rules&quot;: [ # A list of RPC context rules that apply to individual API methods.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07003982 #
Bu Sun Kim65020912020-05-20 12:08:20 -07003983 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
3984 { # A context rule provides information about the context for an individual API
3985 # element.
Bu Sun Kim65020912020-05-20 12:08:20 -07003986 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07003987 #
3988 # Refer to selector for syntax details.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07003989 &quot;requested&quot;: [ # A list of full type names of requested contexts.
3990 &quot;A String&quot;,
3991 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07003992 &quot;provided&quot;: [ # A list of full type names of provided contexts.
3993 &quot;A String&quot;,
3994 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07003995 &quot;allowedRequestExtensions&quot;: [ # A list of full type names or extension IDs of extensions allowed in grpc
3996 # side channel from client to backend.
3997 &quot;A String&quot;,
3998 ],
3999 &quot;allowedResponseExtensions&quot;: [ # A list of full type names or extension IDs of extensions allowed in grpc
4000 # side channel from backend to client.
4001 &quot;A String&quot;,
4002 ],
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004003 },
4004 ],
4005 },
4006 }</pre>
4007</div>
4008
4009<div class="method">
Bu Sun Kim65020912020-05-20 12:08:20 -07004010 <code class="details" id="get">get(serviceName, configId, view=None, x__xgafv=None)</code>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004011 <pre>Gets a service configuration (version) for a managed service.
4012
4013Args:
Dan O'Mearadd494642020-05-01 07:42:23 -07004014 serviceName: string, Required. The name of the service. See the [overview](/service-management/overview)
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004015for naming requirements. For example: `example.googleapis.com`. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07004016 configId: string, Required. The id of the service configuration resource.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004017
4018This field must be specified for the server to return all fields, including
4019`SourceInfo`. (required)
Bu Sun Kim65020912020-05-20 12:08:20 -07004020 view: string, Specifies which parts of the Service Config should be returned in the
4021response.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004022 x__xgafv: string, V1 error format.
4023 Allowed values
4024 1 - v1 error format
4025 2 - v2 error format
4026
4027Returns:
4028 An object of the form:
4029
Sai Cheemalapatiea3a5e12016-10-12 14:05:53 -07004030 { # `Service` is the root object of Google service configuration schema. It
4031 # describes basic information about a service, such as the name and the
4032 # title, and delegates other aspects to sub-sections. Each sub-section is
4033 # either a proto message or a repeated proto message that configures a
4034 # specific aspect, such as auth. See each proto message definition for details.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004035 #
4036 # Example:
4037 #
4038 # type: google.api.Service
Sai Cheemalapatiea3a5e12016-10-12 14:05:53 -07004039 # config_version: 3
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004040 # name: calendar.googleapis.com
4041 # title: Google Calendar API
4042 # apis:
Sai Cheemalapatiea3a5e12016-10-12 14:05:53 -07004043 # - name: google.calendar.v3.Calendar
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004044 # authentication:
4045 # providers:
4046 # - id: google_calendar_auth
4047 # jwks_uri: https://www.googleapis.com/oauth2/v1/certs
4048 # issuer: https://securetoken.google.com
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004049 # rules:
Bu Sun Kim65020912020-05-20 12:08:20 -07004050 # - selector: &quot;*&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004051 # requirements:
4052 # provider_id: google_calendar_auth
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004053 &quot;enums&quot;: [ # A list of all enum types included in this API service. Enums
4054 # referenced directly or indirectly by the `apis` are automatically
4055 # included. Enums which are not referenced but shall be included
4056 # should be listed here by name. Example:
4057 #
4058 # enums:
4059 # - name: google.someapi.v1.SomeEnum
4060 { # Enum type definition.
4061 &quot;options&quot;: [ # Protocol buffer options.
4062 { # A protocol buffer option, which can be attached to a message, field,
4063 # enumeration, etc.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004064 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
4065 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
4066 # should be used. If the value is an enum, it should be stored as an int32
4067 # value using the google.protobuf.Int32Value type.
4068 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
4069 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004070 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
4071 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
4072 # For custom options, it should be the fully-qualified name. For example,
4073 # `&quot;google.api.http&quot;`.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004074 },
4075 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004076 &quot;enumvalue&quot;: [ # Enum value definitions.
4077 { # Enum value definition.
4078 &quot;name&quot;: &quot;A String&quot;, # Enum value name.
4079 &quot;options&quot;: [ # Protocol buffer options.
4080 { # A protocol buffer option, which can be attached to a message, field,
4081 # enumeration, etc.
4082 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
4083 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
4084 # should be used. If the value is an enum, it should be stored as an int32
4085 # value using the google.protobuf.Int32Value type.
4086 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
4087 },
4088 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
4089 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
4090 # For custom options, it should be the fully-qualified name. For example,
4091 # `&quot;google.api.http&quot;`.
4092 },
4093 ],
4094 &quot;number&quot;: 42, # Enum value number.
4095 },
4096 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004097 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # The source context.
4098 # protobuf element, like the file in which it is defined.
4099 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
4100 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
4101 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004102 &quot;name&quot;: &quot;A String&quot;, # Enum type name.
4103 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax.
4104 },
4105 ],
4106 &quot;backend&quot;: { # `Backend` defines the backend configuration for a service. # API backend configuration.
4107 &quot;rules&quot;: [ # A list of API backend rules that apply to individual API methods.
4108 #
4109 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
4110 { # A backend rule provides configuration for an individual API element.
4111 &quot;disableAuth&quot;: True or False, # When disable_auth is true, a JWT ID token won&#x27;t be generated and the
4112 # original &quot;Authorization&quot; HTTP header will be preserved. If the header is
4113 # used to carry the original token and is expected by the backend, this
4114 # field must be set to true to preserve the header.
4115 &quot;address&quot;: &quot;A String&quot;, # The address of the API backend.
4116 #
4117 # The scheme is used to determine the backend protocol and security.
4118 # The following schemes are accepted:
4119 #
4120 # SCHEME PROTOCOL SECURITY
4121 # http:// HTTP None
4122 # https:// HTTP TLS
4123 # grpc:// gRPC None
4124 # grpcs:// gRPC TLS
4125 #
4126 # It is recommended to explicitly include a scheme. Leaving out the scheme
4127 # may cause constrasting behaviors across platforms.
4128 #
4129 # If the port is unspecified, the default is:
4130 # - 80 for schemes without TLS
4131 # - 443 for schemes with TLS
4132 #
4133 # For HTTP backends, use protocol
4134 # to specify the protocol version.
4135 &quot;minDeadline&quot;: 3.14, # Minimum deadline in seconds needed for this method. Calls having deadline
4136 # value lower than this will be rejected.
4137 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
4138 #
4139 # Refer to selector for syntax details.
4140 &quot;protocol&quot;: &quot;A String&quot;, # The protocol used for sending a request to the backend.
4141 # The supported values are &quot;http/1.1&quot; and &quot;h2&quot;.
4142 #
4143 # The default value is inferred from the scheme in the
4144 # address field:
4145 #
4146 # SCHEME PROTOCOL
4147 # http:// http/1.1
4148 # https:// http/1.1
4149 # grpc:// h2
4150 # grpcs:// h2
4151 #
4152 # For secure HTTP backends (https://) that support HTTP/2, set this field
4153 # to &quot;h2&quot; for improved performance.
4154 #
4155 # Configuring this field to non-default values is only supported for secure
4156 # HTTP backends. This field will be ignored for all other backends.
4157 #
4158 # See
4159 # https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#alpn-protocol-ids
4160 # for more details on the supported values.
4161 &quot;operationDeadline&quot;: 3.14, # The number of seconds to wait for the completion of a long running
4162 # operation. The default is no deadline.
4163 &quot;pathTranslation&quot;: &quot;A String&quot;,
4164 &quot;jwtAudience&quot;: &quot;A String&quot;, # The JWT audience is used when generating a JWT ID token for the backend.
4165 # This ID token will be added in the HTTP &quot;authorization&quot; header, and sent
4166 # to the backend.
4167 &quot;deadline&quot;: 3.14, # The number of seconds to wait for a response from a request. The default
4168 # varies based on the request protocol and deployment environment.
4169 },
4170 ],
4171 },
4172 &quot;systemTypes&quot;: [ # A list of all proto message types included in this API service.
4173 # It serves similar purpose as [google.api.Service.types], except that
4174 # these types are not needed by user-defined APIs. Therefore, they will not
4175 # show up in the generated discovery doc. This field should only be used
4176 # to define system APIs in ESF.
4177 { # A protocol buffer message type.
4178 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # The source context.
4179 # protobuf element, like the file in which it is defined.
4180 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
4181 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
4182 },
4183 &quot;oneofs&quot;: [ # The list of types appearing in `oneof` definitions in this type.
4184 &quot;A String&quot;,
4185 ],
4186 &quot;fields&quot;: [ # The list of fields.
4187 { # A single field of a message type.
4188 &quot;oneofIndex&quot;: 42, # The index of the field type in `Type.oneofs`, for message or enumeration
4189 # types. The first type has index 1; zero means the type is not in the list.
4190 &quot;name&quot;: &quot;A String&quot;, # The field name.
4191 &quot;defaultValue&quot;: &quot;A String&quot;, # The string value of the default value of this field. Proto2 syntax only.
4192 &quot;packed&quot;: True or False, # Whether to use alternative packed wire representation.
4193 &quot;typeUrl&quot;: &quot;A String&quot;, # The field type URL, without the scheme, for message or enumeration
4194 # types. Example: `&quot;type.googleapis.com/google.protobuf.Timestamp&quot;`.
4195 &quot;cardinality&quot;: &quot;A String&quot;, # The field cardinality.
4196 &quot;jsonName&quot;: &quot;A String&quot;, # The field JSON name.
4197 &quot;kind&quot;: &quot;A String&quot;, # The field type.
4198 &quot;options&quot;: [ # The protocol buffer options.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004199 { # A protocol buffer option, which can be attached to a message, field,
4200 # enumeration, etc.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004201 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
4202 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
4203 # should be used. If the value is an enum, it should be stored as an int32
4204 # value using the google.protobuf.Int32Value type.
4205 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
4206 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004207 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
4208 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
4209 # For custom options, it should be the fully-qualified name. For example,
4210 # `&quot;google.api.http&quot;`.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004211 },
4212 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004213 &quot;number&quot;: 42, # The field number.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004214 },
4215 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004216 &quot;options&quot;: [ # The protocol buffer options.
Bu Sun Kim65020912020-05-20 12:08:20 -07004217 { # A protocol buffer option, which can be attached to a message, field,
4218 # enumeration, etc.
4219 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
4220 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
4221 # should be used. If the value is an enum, it should be stored as an int32
4222 # value using the google.protobuf.Int32Value type.
4223 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
4224 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004225 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
4226 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
4227 # For custom options, it should be the fully-qualified name. For example,
4228 # `&quot;google.api.http&quot;`.
Bu Sun Kim65020912020-05-20 12:08:20 -07004229 },
4230 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004231 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax.
4232 &quot;name&quot;: &quot;A String&quot;, # The fully qualified message name.
Bu Sun Kim65020912020-05-20 12:08:20 -07004233 },
4234 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004235 &quot;name&quot;: &quot;A String&quot;, # The service name, which is a DNS-like logical identifier for the
4236 # service, such as `calendar.googleapis.com`. The service name
4237 # typically goes through DNS verification to make sure the owner
4238 # of the service also owns the DNS name.
4239 &quot;sourceInfo&quot;: { # Source information used to create a Service Config # Output only. The source information for this configuration if available.
4240 &quot;sourceFiles&quot;: [ # All files used during config generation.
4241 {
4242 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim65020912020-05-20 12:08:20 -07004243 },
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004244 ],
4245 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004246 &quot;billing&quot;: { # Billing related configuration of the service. # Billing configuration.
4247 #
4248 # The following example shows how to configure monitored resources and metrics
4249 # for billing, `consumer_destinations` is the only supported destination and
4250 # the monitored resources need at least one label key
4251 # `cloud.googleapis.com/location` to indicate the location of the billing
4252 # usage, using different monitored resources between monitoring and billing is
4253 # recommended so they can be evolved independently:
4254 #
4255 #
4256 # monitored_resources:
4257 # - type: library.googleapis.com/billing_branch
4258 # labels:
4259 # - key: cloud.googleapis.com/location
4260 # description: |
4261 # Predefined label to support billing location restriction.
4262 # - key: city
4263 # description: |
4264 # Custom label to define the city where the library branch is located
4265 # in.
4266 # - key: name
4267 # description: Custom label to define the name of the library branch.
4268 # metrics:
4269 # - name: library.googleapis.com/book/borrowed_count
4270 # metric_kind: DELTA
4271 # value_type: INT64
4272 # unit: &quot;1&quot;
4273 # billing:
4274 # consumer_destinations:
4275 # - monitored_resource: library.googleapis.com/billing_branch
4276 # metrics:
4277 # - library.googleapis.com/book/borrowed_count
4278 &quot;consumerDestinations&quot;: [ # Billing configurations for sending metrics to the consumer project.
4279 # There can be multiple consumer destinations per service, each one must have
4280 # a different monitored resource type. A metric can be used in at most
4281 # one consumer destination.
4282 { # Configuration of a specific billing destination (Currently only support
4283 # bill against consumer project).
4284 &quot;metrics&quot;: [ # Names of the metrics to report to this billing destination.
4285 # Each name must be defined in Service.metrics section.
4286 &quot;A String&quot;,
4287 ],
4288 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in
4289 # Service.monitored_resources section.
4290 },
4291 ],
4292 },
4293 &quot;monitoring&quot;: { # Monitoring configuration of the service. # Monitoring configuration.
4294 #
4295 # The example below shows how to configure monitored resources and metrics
4296 # for monitoring. In the example, a monitored resource and two metrics are
4297 # defined. The `library.googleapis.com/book/returned_count` metric is sent
4298 # to both producer and consumer projects, whereas the
4299 # `library.googleapis.com/book/num_overdue` metric is only sent to the
4300 # consumer project.
4301 #
4302 # monitored_resources:
4303 # - type: library.googleapis.com/Branch
4304 # display_name: &quot;Library Branch&quot;
4305 # description: &quot;A branch of a library.&quot;
4306 # launch_stage: GA
4307 # labels:
4308 # - key: resource_container
4309 # description: &quot;The Cloud container (ie. project id) for the Branch.&quot;
4310 # - key: location
4311 # description: &quot;The location of the library branch.&quot;
4312 # - key: branch_id
4313 # description: &quot;The id of the branch.&quot;
4314 # metrics:
4315 # - name: library.googleapis.com/book/returned_count
4316 # display_name: &quot;Books Returned&quot;
4317 # description: &quot;The count of books that have been returned.&quot;
4318 # launch_stage: GA
4319 # metric_kind: DELTA
4320 # value_type: INT64
4321 # unit: &quot;1&quot;
4322 # labels:
4323 # - key: customer_id
4324 # description: &quot;The id of the customer.&quot;
4325 # - name: library.googleapis.com/book/num_overdue
4326 # display_name: &quot;Books Overdue&quot;
4327 # description: &quot;The current number of overdue books.&quot;
4328 # launch_stage: GA
4329 # metric_kind: GAUGE
4330 # value_type: INT64
4331 # unit: &quot;1&quot;
4332 # labels:
4333 # - key: customer_id
4334 # description: &quot;The id of the customer.&quot;
4335 # monitoring:
4336 # producer_destinations:
4337 # - monitored_resource: library.googleapis.com/Branch
4338 # metrics:
4339 # - library.googleapis.com/book/returned_count
4340 # consumer_destinations:
4341 # - monitored_resource: library.googleapis.com/Branch
4342 # metrics:
4343 # - library.googleapis.com/book/returned_count
4344 # - library.googleapis.com/book/num_overdue
4345 &quot;producerDestinations&quot;: [ # Monitoring configurations for sending metrics to the producer project.
4346 # There can be multiple producer destinations. A monitored resource type may
4347 # appear in multiple monitoring destinations if different aggregations are
4348 # needed for different sets of metrics associated with that monitored
4349 # resource type. A monitored resource and metric pair may only be used once
4350 # in the Monitoring configuration.
4351 { # Configuration of a specific monitoring destination (the producer project
4352 # or the consumer project).
4353 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in
4354 # Service.monitored_resources section.
4355 &quot;metrics&quot;: [ # Types of the metrics to report to this monitoring destination.
4356 # Each type must be defined in Service.metrics section.
4357 &quot;A String&quot;,
4358 ],
4359 },
4360 ],
4361 &quot;consumerDestinations&quot;: [ # Monitoring configurations for sending metrics to the consumer project.
4362 # There can be multiple consumer destinations. A monitored resource type may
4363 # appear in multiple monitoring destinations if different aggregations are
4364 # needed for different sets of metrics associated with that monitored
4365 # resource type. A monitored resource and metric pair may only be used once
4366 # in the Monitoring configuration.
4367 { # Configuration of a specific monitoring destination (the producer project
4368 # or the consumer project).
4369 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in
4370 # Service.monitored_resources section.
4371 &quot;metrics&quot;: [ # Types of the metrics to report to this monitoring destination.
4372 # Each type must be defined in Service.metrics section.
4373 &quot;A String&quot;,
4374 ],
4375 },
4376 ],
4377 },
4378 &quot;logging&quot;: { # Logging configuration of the service. # Logging configuration.
4379 #
4380 # The following example shows how to configure logs to be sent to the
4381 # producer and consumer projects. In the example, the `activity_history`
4382 # log is sent to both the producer and consumer projects, whereas the
4383 # `purchase_history` log is only sent to the producer project.
4384 #
4385 # monitored_resources:
4386 # - type: library.googleapis.com/branch
4387 # labels:
4388 # - key: /city
4389 # description: The city where the library branch is located in.
4390 # - key: /name
4391 # description: The name of the branch.
4392 # logs:
4393 # - name: activity_history
4394 # labels:
4395 # - key: /customer_id
4396 # - name: purchase_history
4397 # logging:
4398 # producer_destinations:
4399 # - monitored_resource: library.googleapis.com/branch
4400 # logs:
4401 # - activity_history
4402 # - purchase_history
4403 # consumer_destinations:
4404 # - monitored_resource: library.googleapis.com/branch
4405 # logs:
4406 # - activity_history
4407 &quot;producerDestinations&quot;: [ # Logging configurations for sending logs to the producer project.
4408 # There can be multiple producer destinations, each one must have a
4409 # different monitored resource type. A log can be used in at most
4410 # one producer destination.
4411 { # Configuration of a specific logging destination (the producer project
4412 # or the consumer project).
4413 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in the
4414 # Service.monitored_resources section.
4415 &quot;logs&quot;: [ # Names of the logs to be sent to this destination. Each name must
4416 # be defined in the Service.logs section. If the log name is
4417 # not a domain scoped name, it will be automatically prefixed with
4418 # the service name followed by &quot;/&quot;.
4419 &quot;A String&quot;,
4420 ],
4421 },
4422 ],
4423 &quot;consumerDestinations&quot;: [ # Logging configurations for sending logs to the consumer project.
4424 # There can be multiple consumer destinations, each one must have a
4425 # different monitored resource type. A log can be used in at most
4426 # one consumer destination.
4427 { # Configuration of a specific logging destination (the producer project
4428 # or the consumer project).
4429 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in the
4430 # Service.monitored_resources section.
4431 &quot;logs&quot;: [ # Names of the logs to be sent to this destination. Each name must
4432 # be defined in the Service.logs section. If the log name is
4433 # not a domain scoped name, it will be automatically prefixed with
4434 # the service name followed by &quot;/&quot;.
4435 &quot;A String&quot;,
4436 ],
4437 },
4438 ],
4439 },
4440 &quot;control&quot;: { # Selects and configures the service controller used by the service. The # Configuration for the service control plane.
4441 # service controller handles features like abuse, quota, billing, logging,
4442 # monitoring, etc.
4443 &quot;environment&quot;: &quot;A String&quot;, # The service control environment to use. If empty, no control plane
4444 # feature (like quota and billing) will be enabled.
4445 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004446 &quot;usage&quot;: { # Configuration controlling usage of a service. # Configuration controlling usage of this service.
4447 &quot;requirements&quot;: [ # Requirements that must be satisfied before a consumer project can use the
4448 # service. Each requirement is of the form &lt;service.name&gt;/&lt;requirement-id&gt;;
4449 # for example &#x27;serviceusage.googleapis.com/billing-enabled&#x27;.
4450 &quot;A String&quot;,
4451 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004452 &quot;serviceIdentity&quot;: { # The per-product per-project service identity for a service. # The configuration of a per-product per-project service identity.
4453 #
4454 #
4455 # Use this field to configure per-product per-project service identity.
4456 # Example of a service identity configuration.
4457 #
4458 # usage:
4459 # service_identity:
4460 # - service_account_parent: &quot;projects/123456789&quot;
4461 # display_name: &quot;Cloud XXX Service Agent&quot;
4462 # description: &quot;Used as the identity of Cloud XXX to access resources&quot;
4463 &quot;serviceAccountParent&quot;: &quot;A String&quot;, # A service account project that hosts the service accounts.
4464 #
4465 # An example name would be:
4466 # `projects/123456789`
4467 &quot;description&quot;: &quot;A String&quot;, # Optional. A user-specified opaque description of the service account.
4468 # Must be less than or equal to 256 UTF-8 bytes.
4469 &quot;displayName&quot;: &quot;A String&quot;, # Optional. A user-specified name for the service account.
4470 # Must be less than or equal to 100 UTF-8 bytes.
4471 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004472 &quot;rules&quot;: [ # A list of usage rules that apply to individual API methods.
4473 #
4474 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
4475 { # Usage configuration rules for the service.
4476 #
4477 # NOTE: Under development.
4478 #
4479 #
4480 # Use this rule to configure unregistered calls for the service. Unregistered
4481 # calls are calls that do not contain consumer project identity.
4482 # (Example: calls that do not contain an API key).
4483 # By default, API methods do not allow unregistered calls, and each method call
4484 # must be identified by a consumer project identity. Use this rule to
4485 # allow/disallow unregistered calls.
4486 #
4487 # Example of an API that wants to allow unregistered calls for entire service.
4488 #
4489 # usage:
4490 # rules:
4491 # - selector: &quot;*&quot;
4492 # allow_unregistered_calls: true
4493 #
4494 # Example of a method that wants to allow unregistered calls.
4495 #
4496 # usage:
4497 # rules:
4498 # - selector: &quot;google.example.library.v1.LibraryService.CreateBook&quot;
4499 # allow_unregistered_calls: true
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004500 &quot;skipServiceControl&quot;: True or False, # If true, the selected method should skip service control and the control
4501 # plane features, such as quota and billing, will not be available.
4502 # This flag is used by Google Cloud Endpoints to bypass checks for internal
4503 # methods, such as service health check methods.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004504 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies. Use &#x27;*&#x27; to indicate all
4505 # methods in all APIs.
4506 #
4507 # Refer to selector for syntax details.
4508 &quot;allowUnregisteredCalls&quot;: True or False, # If true, the selected method allows unregistered calls, e.g. calls
4509 # that don&#x27;t identify any user or application.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004510 },
4511 ],
4512 &quot;producerNotificationChannel&quot;: &quot;A String&quot;, # The full resource name of a channel used for sending notifications to the
4513 # service producer.
4514 #
4515 # Google Service Management currently only supports
4516 # [Google Cloud Pub/Sub](https://cloud.google.com/pubsub) as a notification
4517 # channel. To use Google Cloud Pub/Sub as the channel, this must be the name
4518 # of a Cloud Pub/Sub topic that uses the Cloud Pub/Sub topic name format
4519 # documented in https://cloud.google.com/pubsub/docs/overview.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004520 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004521 &quot;types&quot;: [ # A list of all proto message types included in this API service.
4522 # Types referenced directly or indirectly by the `apis` are
4523 # automatically included. Messages which are not referenced but
4524 # shall be included, such as types used by the `google.protobuf.Any` type,
4525 # should be listed here by name. Example:
4526 #
4527 # types:
4528 # - name: google.protobuf.Int32
4529 { # A protocol buffer message type.
4530 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # The source context.
4531 # protobuf element, like the file in which it is defined.
4532 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
4533 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
4534 },
4535 &quot;oneofs&quot;: [ # The list of types appearing in `oneof` definitions in this type.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004536 &quot;A String&quot;,
4537 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004538 &quot;fields&quot;: [ # The list of fields.
4539 { # A single field of a message type.
4540 &quot;oneofIndex&quot;: 42, # The index of the field type in `Type.oneofs`, for message or enumeration
4541 # types. The first type has index 1; zero means the type is not in the list.
4542 &quot;name&quot;: &quot;A String&quot;, # The field name.
4543 &quot;defaultValue&quot;: &quot;A String&quot;, # The string value of the default value of this field. Proto2 syntax only.
4544 &quot;packed&quot;: True or False, # Whether to use alternative packed wire representation.
4545 &quot;typeUrl&quot;: &quot;A String&quot;, # The field type URL, without the scheme, for message or enumeration
4546 # types. Example: `&quot;type.googleapis.com/google.protobuf.Timestamp&quot;`.
4547 &quot;cardinality&quot;: &quot;A String&quot;, # The field cardinality.
4548 &quot;jsonName&quot;: &quot;A String&quot;, # The field JSON name.
4549 &quot;kind&quot;: &quot;A String&quot;, # The field type.
4550 &quot;options&quot;: [ # The protocol buffer options.
4551 { # A protocol buffer option, which can be attached to a message, field,
4552 # enumeration, etc.
4553 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
4554 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
4555 # should be used. If the value is an enum, it should be stored as an int32
4556 # value using the google.protobuf.Int32Value type.
4557 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
4558 },
4559 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
4560 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
4561 # For custom options, it should be the fully-qualified name. For example,
4562 # `&quot;google.api.http&quot;`.
4563 },
4564 ],
4565 &quot;number&quot;: 42, # The field number.
4566 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004567 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004568 &quot;options&quot;: [ # The protocol buffer options.
4569 { # A protocol buffer option, which can be attached to a message, field,
4570 # enumeration, etc.
4571 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
4572 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
4573 # should be used. If the value is an enum, it should be stored as an int32
4574 # value using the google.protobuf.Int32Value type.
4575 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
4576 },
4577 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
4578 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
4579 # For custom options, it should be the fully-qualified name. For example,
4580 # `&quot;google.api.http&quot;`.
4581 },
4582 ],
4583 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax.
4584 &quot;name&quot;: &quot;A String&quot;, # The fully qualified message name.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004585 },
4586 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07004587 &quot;http&quot;: { # Defines the HTTP configuration for an API service. It contains a list of # HTTP configuration.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004588 # HttpRule, each specifying the mapping of an RPC method
4589 # to one or more HTTP REST API methods.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004590 &quot;fullyDecodeReservedExpansion&quot;: True or False, # When set to true, URL path parameters will be fully URI-decoded except in
4591 # cases of single segment matches in reserved expansion, where &quot;%2F&quot; will be
4592 # left encoded.
4593 #
4594 # The default behavior is to not decode RFC 6570 reserved characters in multi
4595 # segment matches.
Bu Sun Kim65020912020-05-20 12:08:20 -07004596 &quot;rules&quot;: [ # A list of HTTP configuration rules that apply to individual API methods.
4597 #
4598 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004599 { # # gRPC Transcoding
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004600 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004601 # gRPC Transcoding is a feature for mapping between a gRPC method and one or
4602 # more HTTP REST endpoints. It allows developers to build a single API service
4603 # that supports both gRPC APIs and REST APIs. Many systems, including [Google
4604 # APIs](https://github.com/googleapis/googleapis),
4605 # [Cloud Endpoints](https://cloud.google.com/endpoints), [gRPC
4606 # Gateway](https://github.com/grpc-ecosystem/grpc-gateway),
4607 # and [Envoy](https://github.com/envoyproxy/envoy) proxy support this feature
4608 # and use it for large scale production services.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004609 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004610 # `HttpRule` defines the schema of the gRPC/REST mapping. The mapping specifies
4611 # how different portions of the gRPC request message are mapped to the URL
4612 # path, URL query parameters, and HTTP request body. It also controls how the
4613 # gRPC response message is mapped to the HTTP response body. `HttpRule` is
4614 # typically specified as an `google.api.http` annotation on the gRPC method.
4615 #
4616 # Each mapping specifies a URL path template and an HTTP method. The path
4617 # template may refer to one or more fields in the gRPC request message, as long
4618 # as each field is a non-repeated field with a primitive (non-message) type.
4619 # The path template controls how fields of the request message are mapped to
4620 # the URL path.
4621 #
4622 # Example:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004623 #
4624 # service Messaging {
4625 # rpc GetMessage(GetMessageRequest) returns (Message) {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004626 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07004627 # get: &quot;/v1/{name=messages/*}&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004628 # };
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004629 # }
4630 # }
4631 # message GetMessageRequest {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004632 # string name = 1; // Mapped to URL path.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004633 # }
4634 # message Message {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004635 # string text = 1; // The resource content.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004636 # }
4637 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004638 # This enables an HTTP REST to gRPC mapping as below:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004639 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004640 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004641 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -07004642 # `GET /v1/messages/123456` | `GetMessage(name: &quot;messages/123456&quot;)`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004643 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004644 # Any fields in the request message which are not bound by the path template
4645 # automatically become HTTP query parameters if there is no HTTP request body.
4646 # For example:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004647 #
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -04004648 # service Messaging {
4649 # rpc GetMessage(GetMessageRequest) returns (Message) {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004650 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07004651 # get:&quot;/v1/messages/{message_id}&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004652 # };
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -04004653 # }
4654 # }
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004655 # message GetMessageRequest {
4656 # message SubMessage {
4657 # string subfield = 1;
4658 # }
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004659 # string message_id = 1; // Mapped to URL path.
4660 # int64 revision = 2; // Mapped to URL query parameter `revision`.
4661 # SubMessage sub = 3; // Mapped to URL query parameter `sub.subfield`.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004662 # }
4663 #
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004664 # This enables a HTTP JSON to RPC mapping as below:
4665 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004666 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004667 # -----|-----
Dan O'Mearadd494642020-05-01 07:42:23 -07004668 # `GET /v1/messages/123456?revision=2&amp;sub.subfield=foo` |
Bu Sun Kim65020912020-05-20 12:08:20 -07004669 # `GetMessage(message_id: &quot;123456&quot; revision: 2 sub: SubMessage(subfield:
4670 # &quot;foo&quot;))`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004671 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004672 # Note that fields which are mapped to URL query parameters must have a
4673 # primitive type or a repeated primitive type or a non-repeated message type.
4674 # In the case of a repeated type, the parameter can be repeated in the URL
Dan O'Mearadd494642020-05-01 07:42:23 -07004675 # as `...?param=A&amp;param=B`. In the case of a message type, each field of the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004676 # message is mapped to a separate parameter, such as
Dan O'Mearadd494642020-05-01 07:42:23 -07004677 # `...?foo.a=A&amp;foo.b=B&amp;foo.c=C`.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004678 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004679 # For HTTP methods that allow a request body, the `body` field
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004680 # specifies the mapping. Consider a REST update method on the
4681 # message resource collection:
4682 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004683 # service Messaging {
4684 # rpc UpdateMessage(UpdateMessageRequest) returns (Message) {
4685 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07004686 # patch: &quot;/v1/messages/{message_id}&quot;
4687 # body: &quot;message&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004688 # };
4689 # }
4690 # }
4691 # message UpdateMessageRequest {
4692 # string message_id = 1; // mapped to the URL
4693 # Message message = 2; // mapped to the body
4694 # }
4695 #
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004696 # The following HTTP JSON to RPC mapping is enabled, where the
4697 # representation of the JSON in the request body is determined by
4698 # protos JSON encoding:
4699 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004700 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004701 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -07004702 # `PATCH /v1/messages/123456 { &quot;text&quot;: &quot;Hi!&quot; }` | `UpdateMessage(message_id:
4703 # &quot;123456&quot; message { text: &quot;Hi!&quot; })`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004704 #
4705 # The special name `*` can be used in the body mapping to define that
4706 # every field not bound by the path template should be mapped to the
4707 # request body. This enables the following alternative definition of
4708 # the update method:
4709 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004710 # service Messaging {
4711 # rpc UpdateMessage(Message) returns (Message) {
4712 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07004713 # patch: &quot;/v1/messages/{message_id}&quot;
4714 # body: &quot;*&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004715 # };
4716 # }
4717 # }
4718 # message Message {
4719 # string message_id = 1;
4720 # string text = 2;
4721 # }
4722 #
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004723 #
4724 # The following HTTP JSON to RPC mapping is enabled:
4725 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004726 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004727 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -07004728 # `PATCH /v1/messages/123456 { &quot;text&quot;: &quot;Hi!&quot; }` | `UpdateMessage(message_id:
4729 # &quot;123456&quot; text: &quot;Hi!&quot;)`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004730 #
4731 # Note that when using `*` in the body mapping, it is not possible to
4732 # have HTTP parameters, as all fields not bound by the path end in
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004733 # the body. This makes this option more rarely used in practice when
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004734 # defining REST APIs. The common usage of `*` is in custom methods
Bu Sun Kim65020912020-05-20 12:08:20 -07004735 # which don&#x27;t use the URL at all for transferring data.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004736 #
4737 # It is possible to define multiple HTTP methods for one RPC by using
4738 # the `additional_bindings` option. Example:
4739 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004740 # service Messaging {
4741 # rpc GetMessage(GetMessageRequest) returns (Message) {
4742 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07004743 # get: &quot;/v1/messages/{message_id}&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004744 # additional_bindings {
Bu Sun Kim65020912020-05-20 12:08:20 -07004745 # get: &quot;/v1/users/{user_id}/messages/{message_id}&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004746 # }
4747 # };
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004748 # }
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08004749 # }
4750 # message GetMessageRequest {
4751 # string message_id = 1;
4752 # string user_id = 2;
4753 # }
4754 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004755 # This enables the following two alternative HTTP JSON to RPC mappings:
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004756 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004757 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004758 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -07004759 # `GET /v1/messages/123456` | `GetMessage(message_id: &quot;123456&quot;)`
4760 # `GET /v1/users/me/messages/123456` | `GetMessage(user_id: &quot;me&quot; message_id:
4761 # &quot;123456&quot;)`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004762 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004763 # ## Rules for HTTP mapping
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004764 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004765 # 1. Leaf request fields (recursive expansion nested messages in the request
4766 # message) are classified into three categories:
4767 # - Fields referred by the path template. They are passed via the URL path.
4768 # - Fields referred by the HttpRule.body. They are passed via the HTTP
4769 # request body.
4770 # - All other fields are passed via the URL query parameters, and the
4771 # parameter name is the field path in the request message. A repeated
4772 # field can be represented as multiple query parameters under the same
4773 # name.
Bu Sun Kim65020912020-05-20 12:08:20 -07004774 # 2. If HttpRule.body is &quot;*&quot;, there is no URL query parameter, all fields
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004775 # are passed via URL path and HTTP request body.
4776 # 3. If HttpRule.body is omitted, there is no HTTP request body, all
4777 # fields are passed via URL path and URL query parameters.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004778 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004779 # ### Path template syntax
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004780 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004781 # Template = &quot;/&quot; Segments [ Verb ] ;
4782 # Segments = Segment { &quot;/&quot; Segment } ;
4783 # Segment = &quot;*&quot; | &quot;**&quot; | LITERAL | Variable ;
4784 # Variable = &quot;{&quot; FieldPath [ &quot;=&quot; Segments ] &quot;}&quot; ;
4785 # FieldPath = IDENT { &quot;.&quot; IDENT } ;
4786 # Verb = &quot;:&quot; LITERAL ;
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004787 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004788 # The syntax `*` matches a single URL path segment. The syntax `**` matches
4789 # zero or more URL path segments, which must be the last part of the URL path
4790 # except the `Verb`.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004791 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004792 # The syntax `Variable` matches part of the URL path as specified by its
4793 # template. A variable template must not contain other variables. If a variable
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004794 # matches a single path segment, its template may be omitted, e.g. `{var}`
4795 # is equivalent to `{var=*}`.
4796 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004797 # The syntax `LITERAL` matches literal text in the URL path. If the `LITERAL`
4798 # contains any reserved character, such characters should be percent-encoded
4799 # before the matching.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07004800 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004801 # If a variable contains exactly one path segment, such as `&quot;{var}&quot;` or
4802 # `&quot;{var=*}&quot;`, when such a variable is expanded into a URL path on the client
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004803 # side, all characters except `[-_.~0-9a-zA-Z]` are percent-encoded. The
4804 # server side does the reverse decoding. Such variables show up in the
4805 # [Discovery
4806 # Document](https://developers.google.com/discovery/v1/reference/apis) as
4807 # `{var}`.
4808 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004809 # If a variable contains multiple path segments, such as `&quot;{var=foo/*}&quot;`
4810 # or `&quot;{var=**}&quot;`, when such a variable is expanded into a URL path on the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004811 # client side, all characters except `[-_.~/0-9a-zA-Z]` are percent-encoded.
Bu Sun Kim65020912020-05-20 12:08:20 -07004812 # The server side does the reverse decoding, except &quot;%2F&quot; and &quot;%2f&quot; are left
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004813 # unchanged. Such variables show up in the
4814 # [Discovery
4815 # Document](https://developers.google.com/discovery/v1/reference/apis) as
4816 # `{+var}`.
4817 #
4818 # ## Using gRPC API Service Configuration
4819 #
4820 # gRPC API Service Configuration (service config) is a configuration language
4821 # for configuring a gRPC service to become a user-facing product. The
4822 # service config is simply the YAML representation of the `google.api.Service`
4823 # proto message.
4824 #
4825 # As an alternative to annotating your proto file, you can configure gRPC
4826 # transcoding in your service config YAML files. You do this by specifying a
4827 # `HttpRule` that maps the gRPC method to a REST endpoint, achieving the same
4828 # effect as the proto annotation. This can be particularly useful if you
4829 # have a proto that is reused in multiple services. Note that any transcoding
4830 # specified in the service config will override any matching transcoding
4831 # configuration in the proto.
4832 #
4833 # Example:
4834 #
4835 # http:
4836 # rules:
4837 # # Selects a gRPC method and applies HttpRule to it.
4838 # - selector: example.v1.Messaging.GetMessage
4839 # get: /v1/messages/{message_id}/{sub.subfield}
4840 #
4841 # ## Special notes
4842 #
4843 # When gRPC Transcoding is used to map a gRPC to JSON REST endpoints, the
4844 # proto to JSON conversion must follow the [proto3
4845 # specification](https://developers.google.com/protocol-buffers/docs/proto3#json).
4846 #
4847 # While the single segment variable follows the semantics of
4848 # [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.2 Simple String
4849 # Expansion, the multi segment variable **does not** follow RFC 6570 Section
4850 # 3.2.3 Reserved Expansion. The reason is that the Reserved Expansion
4851 # does not expand special characters like `?` and `#`, which would lead
4852 # to invalid URLs. As the result, gRPC Transcoding uses a custom encoding
4853 # for multi segment variables.
4854 #
4855 # The path variables **must not** refer to any repeated or mapped field,
4856 # because client libraries are not capable of handling such variable expansion.
4857 #
Bu Sun Kim65020912020-05-20 12:08:20 -07004858 # The path variables **must not** capture the leading &quot;/&quot; character. The reason
4859 # is that the most common use case &quot;{var}&quot; does not capture the leading &quot;/&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07004860 # character. For consistency, all path variables must share the same behavior.
4861 #
4862 # Repeated message fields must not be mapped to URL query parameters, because
4863 # no client library can support such complicated mapping.
4864 #
4865 # If an API needs to use a JSON array for request or response body, it can map
4866 # the request or response body to a repeated field. However, some gRPC
4867 # Transcoding implementations may not support this feature.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004868 &quot;put&quot;: &quot;A String&quot;, # Maps to HTTP PUT. Used for replacing a resource.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004869 &quot;selector&quot;: &quot;A String&quot;, # Selects a method to which this rule applies.
4870 #
4871 # Refer to selector for syntax details.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004872 &quot;post&quot;: &quot;A String&quot;, # Maps to HTTP POST. Used for creating a resource or performing an action.
4873 &quot;responseBody&quot;: &quot;A String&quot;, # Optional. The name of the response field whose value is mapped to the HTTP
4874 # response body. When omitted, the entire response message will be used
4875 # as the HTTP response body.
4876 #
4877 # NOTE: The referred field must be present at the top-level of the response
4878 # message type.
4879 &quot;body&quot;: &quot;A String&quot;, # The name of the request field whose value is mapped to the HTTP request
4880 # body, or `*` for mapping all request fields not captured by the path
4881 # pattern to the HTTP body, or omitted for not having any HTTP request body.
4882 #
4883 # NOTE: the referred field must be present at the top-level of the request
4884 # message type.
4885 &quot;patch&quot;: &quot;A String&quot;, # Maps to HTTP PATCH. Used for updating a resource.
4886 &quot;additionalBindings&quot;: [ # Additional HTTP bindings for the selector. Nested bindings must
4887 # not contain an `additional_bindings` field themselves (that is,
4888 # the nesting may only be one level deep).
4889 # Object with schema name: HttpRule
4890 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004891 &quot;custom&quot;: { # A custom pattern is used for defining custom HTTP verb. # The custom pattern is used for specifying an HTTP method that is not
4892 # included in the `pattern` field, such as HEAD, or &quot;*&quot; to leave the
4893 # HTTP method unspecified for this rule. The wild-card rule is useful
4894 # for services that provide content to Web (HTML) clients.
4895 &quot;path&quot;: &quot;A String&quot;, # The path matched by this custom verb.
4896 &quot;kind&quot;: &quot;A String&quot;, # The name of this custom HTTP verb.
4897 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004898 &quot;allowHalfDuplex&quot;: True or False, # When this flag is set to true, HTTP requests will be allowed to invoke a
4899 # half-duplex streaming method.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004900 &quot;delete&quot;: &quot;A String&quot;, # Maps to HTTP DELETE. Used for deleting a resource.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004901 &quot;get&quot;: &quot;A String&quot;, # Maps to HTTP GET. Used for listing and getting information about
4902 # resources.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004903 },
4904 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004905 },
4906 &quot;logs&quot;: [ # Defines the logs used by this service.
4907 { # A description of a log type. Example in YAML format:
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004908 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004909 # - name: library.googleapis.com/activity_history
4910 # description: The history of borrowing and returning library items.
4911 # display_name: Activity
4912 # labels:
4913 # - key: /customer_id
4914 # description: Identifier of a library customer
4915 &quot;description&quot;: &quot;A String&quot;, # A human-readable description of this log. This information appears in
4916 # the documentation and can contain details.
4917 &quot;labels&quot;: [ # The set of labels that are available to describe a specific log entry.
4918 # Runtime requests that contain labels not specified here are
4919 # considered invalid.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004920 { # A description of a label.
4921 &quot;valueType&quot;: &quot;A String&quot;, # The type of data that can be assigned to the label.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004922 &quot;description&quot;: &quot;A String&quot;, # A human-readable description for the label.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004923 &quot;key&quot;: &quot;A String&quot;, # The label key.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004924 },
4925 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004926 &quot;displayName&quot;: &quot;A String&quot;, # The human-readable name for this log. This information appears on
4927 # the user interface and should be concise.
4928 &quot;name&quot;: &quot;A String&quot;, # The name of the log. It must be less than 512 characters long and can
4929 # include the following characters: upper- and lower-case alphanumeric
4930 # characters [A-Za-z0-9], and punctuation characters including
4931 # slash, underscore, hyphen, period [/_-.].
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07004932 },
4933 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07004934 &quot;metrics&quot;: [ # Defines the metrics used by this service.
4935 { # Defines a metric type and its schema. Once a metric descriptor is created,
4936 # deleting or altering it stops data collection and makes the metric type&#x27;s
4937 # existing data unusable.
4938 #
4939 # The following are specific rules for service defined Monitoring metric
4940 # descriptors:
4941 #
4942 # * `type`, `metric_kind`, `value_type`, `description`, and `display_name`
4943 # fields are all required. The `unit` field must be specified
4944 # if the `value_type` is any of DOUBLE, INT64, DISTRIBUTION.
4945 # * Maximum of default 500 metric descriptors per service is allowed.
4946 # * Maximum of default 10 labels per metric descriptor is allowed.
4947 #
4948 # The default maximum limit can be overridden. Please follow
4949 # https://cloud.google.com/monitoring/quotas
4950 &quot;unit&quot;: &quot;A String&quot;, # The units in which the metric value is reported. It is only applicable
4951 # if the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The `unit`
4952 # defines the representation of the stored metric values.
4953 #
4954 # Different systems may scale the values to be more easily displayed (so a
4955 # value of `0.02KBy` _might_ be displayed as `20By`, and a value of
4956 # `3523KBy` _might_ be displayed as `3.5MBy`). However, if the `unit` is
4957 # `KBy`, then the value of the metric is always in thousands of bytes, no
4958 # matter how it may be displayed..
4959 #
4960 # If you want a custom metric to record the exact number of CPU-seconds used
4961 # by a job, you can create an `INT64 CUMULATIVE` metric whose `unit` is
4962 # `s{CPU}` (or equivalently `1s{CPU}` or just `s`). If the job uses 12,005
4963 # CPU-seconds, then the value is written as `12005`.
4964 #
4965 # Alternatively, if you want a custom metric to record data in a more
4966 # granular way, you can create a `DOUBLE CUMULATIVE` metric whose `unit` is
4967 # `ks{CPU}`, and then write the value `12.005` (which is `12005/1000`),
4968 # or use `Kis{CPU}` and write `11.723` (which is `12005/1024`).
4969 #
4970 # The supported units are a subset of [The Unified Code for Units of
4971 # Measure](http://unitsofmeasure.org/ucum.html) standard:
4972 #
4973 # **Basic units (UNIT)**
4974 #
4975 # * `bit` bit
4976 # * `By` byte
4977 # * `s` second
4978 # * `min` minute
4979 # * `h` hour
4980 # * `d` day
4981 # * `1` dimensionless
4982 #
4983 # **Prefixes (PREFIX)**
4984 #
4985 # * `k` kilo (10^3)
4986 # * `M` mega (10^6)
4987 # * `G` giga (10^9)
4988 # * `T` tera (10^12)
4989 # * `P` peta (10^15)
4990 # * `E` exa (10^18)
4991 # * `Z` zetta (10^21)
4992 # * `Y` yotta (10^24)
4993 #
4994 # * `m` milli (10^-3)
4995 # * `u` micro (10^-6)
4996 # * `n` nano (10^-9)
4997 # * `p` pico (10^-12)
4998 # * `f` femto (10^-15)
4999 # * `a` atto (10^-18)
5000 # * `z` zepto (10^-21)
5001 # * `y` yocto (10^-24)
5002 #
5003 # * `Ki` kibi (2^10)
5004 # * `Mi` mebi (2^20)
5005 # * `Gi` gibi (2^30)
5006 # * `Ti` tebi (2^40)
5007 # * `Pi` pebi (2^50)
5008 #
5009 # **Grammar**
5010 #
5011 # The grammar also includes these connectors:
5012 #
5013 # * `/` division or ratio (as an infix operator). For examples,
5014 # `kBy/{email}` or `MiBy/10ms` (although you should almost never
5015 # have `/s` in a metric `unit`; rates should always be computed at
5016 # query time from the underlying cumulative or delta value).
5017 # * `.` multiplication or composition (as an infix operator). For
5018 # examples, `GBy.d` or `k{watt}.h`.
5019 #
5020 # The grammar for a unit is as follows:
5021 #
5022 # Expression = Component { &quot;.&quot; Component } { &quot;/&quot; Component } ;
5023 #
5024 # Component = ( [ PREFIX ] UNIT | &quot;%&quot; ) [ Annotation ]
5025 # | Annotation
5026 # | &quot;1&quot;
5027 # ;
5028 #
5029 # Annotation = &quot;{&quot; NAME &quot;}&quot; ;
5030 #
5031 # Notes:
5032 #
5033 # * `Annotation` is just a comment if it follows a `UNIT`. If the annotation
5034 # is used alone, then the unit is equivalent to `1`. For examples,
5035 # `{request}/s == 1/s`, `By{transmitted}/s == By/s`.
5036 # * `NAME` is a sequence of non-blank printable ASCII characters not
5037 # containing `{` or `}`.
5038 # * `1` represents a unitary [dimensionless
5039 # unit](https://en.wikipedia.org/wiki/Dimensionless_quantity) of 1, such
5040 # as in `1/s`. It is typically used when none of the basic units are
5041 # appropriate. For example, &quot;new users per day&quot; can be represented as
5042 # `1/d` or `{new-users}/d` (and a metric value `5` would mean &quot;5 new
5043 # users). Alternatively, &quot;thousands of page views per day&quot; would be
5044 # represented as `1000/d` or `k1/d` or `k{page_views}/d` (and a metric
5045 # value of `5.3` would mean &quot;5300 page views per day&quot;).
5046 # * `%` represents dimensionless value of 1/100, and annotates values giving
5047 # a percentage (so the metric values are typically in the range of 0..100,
5048 # and a metric value `3` means &quot;3 percent&quot;).
5049 # * `10^2.%` indicates a metric contains a ratio, typically in the range
5050 # 0..1, that will be multiplied by 100 and displayed as a percentage
5051 # (so a metric value `0.03` means &quot;3 percent&quot;).
5052 &quot;displayName&quot;: &quot;A String&quot;, # A concise name for the metric, which can be displayed in user interfaces.
5053 # Use sentence case without an ending period, for example &quot;Request count&quot;.
5054 # This field is optional but it is recommended to be set for any metrics
5055 # associated with user-visible concepts, such as Quota.
5056 &quot;monitoredResourceTypes&quot;: [ # Read-only. If present, then a time
5057 # series, which is identified partially by
5058 # a metric type and a MonitoredResourceDescriptor, that is associated
5059 # with this metric type can only be associated with one of the monitored
5060 # resource types listed here.
5061 &quot;A String&quot;,
5062 ],
5063 &quot;metadata&quot;: { # Additional annotations that can be used to guide the usage of a metric. # Optional. Metadata which can be used to guide usage of the metric.
5064 &quot;samplePeriod&quot;: &quot;A String&quot;, # The sampling period of metric data points. For metrics which are written
5065 # periodically, consecutive data points are stored at this time interval,
5066 # excluding data loss due to errors. Metrics with a higher granularity have
5067 # a smaller sampling period.
5068 &quot;ingestDelay&quot;: &quot;A String&quot;, # The delay of data points caused by ingestion. Data points older than this
5069 # age are guaranteed to be ingested and available to be read, excluding
5070 # data loss due to errors.
5071 &quot;launchStage&quot;: &quot;A String&quot;, # Deprecated. Must use the MetricDescriptor.launch_stage instead.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07005072 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005073 &quot;name&quot;: &quot;A String&quot;, # The resource name of the metric descriptor.
5074 &quot;valueType&quot;: &quot;A String&quot;, # Whether the measurement is an integer, a floating-point number, etc.
5075 # Some combinations of `metric_kind` and `value_type` might not be supported.
5076 &quot;launchStage&quot;: &quot;A String&quot;, # Optional. The launch stage of the metric definition.
5077 &quot;type&quot;: &quot;A String&quot;, # The metric type, including its DNS name prefix. The type is not
5078 # URL-encoded.
5079 #
5080 # All service defined metrics must be prefixed with the service name, in the
5081 # format of `{service name}/{relative metric name}`, such as
5082 # `cloudsql.googleapis.com/database/cpu/utilization`. The relative metric
5083 # name must follow:
5084 #
5085 # * Only upper and lower-case letters, digits, &#x27;/&#x27; and underscores &#x27;_&#x27; are
5086 # allowed.
5087 # * The maximum number of characters allowed for the relative_metric_name is
5088 # 100.
5089 #
5090 # All user-defined metric types have the DNS name
5091 # `custom.googleapis.com`, `external.googleapis.com`, or
5092 # `logging.googleapis.com/user/`.
5093 #
5094 # Metric types should use a natural hierarchical grouping. For example:
5095 #
5096 # &quot;custom.googleapis.com/invoice/paid/amount&quot;
5097 # &quot;external.googleapis.com/prometheus/up&quot;
5098 # &quot;appengine.googleapis.com/http/server/response_latencies&quot;
5099 &quot;description&quot;: &quot;A String&quot;, # A detailed description of the metric, which can be used in documentation.
5100 &quot;labels&quot;: [ # The set of labels that can be used to describe a specific
5101 # instance of this metric type.
5102 #
5103 # The label key name must follow:
5104 #
5105 # * Only upper and lower-case letters, digits and underscores (_) are
5106 # allowed.
5107 # * Label name must start with a letter or digit.
5108 # * The maximum length of a label name is 100 characters.
5109 #
5110 # For example, the
5111 # `appengine.googleapis.com/http/server/response_latencies` metric
5112 # type has a label for the HTTP response code, `response_code`, so
5113 # you can look at latencies for successful responses or just
5114 # for responses that failed.
5115 { # A description of a label.
5116 &quot;valueType&quot;: &quot;A String&quot;, # The type of data that can be assigned to the label.
5117 &quot;description&quot;: &quot;A String&quot;, # A human-readable description for the label.
5118 &quot;key&quot;: &quot;A String&quot;, # The label key.
5119 },
5120 ],
5121 &quot;metricKind&quot;: &quot;A String&quot;, # Whether the metric records instantaneous values, changes to a value, etc.
5122 # Some combinations of `metric_kind` and `value_type` might not be supported.
5123 },
5124 ],
5125 &quot;documentation&quot;: { # `Documentation` provides the information for describing a service. # Additional API documentation.
Bu Sun Kim65020912020-05-20 12:08:20 -07005126 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005127 # Example:
5128 # &lt;pre&gt;&lt;code&gt;documentation:
5129 # summary: &gt;
5130 # The Google Calendar API gives access
5131 # to most calendar features.
5132 # pages:
5133 # - name: Overview
5134 # content: &amp;#40;== include google/foo/overview.md ==&amp;#41;
5135 # - name: Tutorial
5136 # content: &amp;#40;== include google/foo/tutorial.md ==&amp;#41;
5137 # subpages;
5138 # - name: Java
5139 # content: &amp;#40;== include google/foo/tutorial_java.md ==&amp;#41;
5140 # rules:
5141 # - selector: google.calendar.Calendar.Get
5142 # description: &gt;
5143 # ...
5144 # - selector: google.calendar.Calendar.Put
5145 # description: &gt;
5146 # ...
5147 # &lt;/code&gt;&lt;/pre&gt;
5148 # Documentation is provided in markdown syntax. In addition to
5149 # standard markdown features, definition lists, tables and fenced
5150 # code blocks are supported. Section headers can be provided and are
5151 # interpreted relative to the section nesting of the context where
5152 # a documentation fragment is embedded.
5153 #
5154 # Documentation from the IDL is merged with documentation defined
5155 # via the config at normalization time, where documentation provided
5156 # by config rules overrides IDL provided.
5157 #
5158 # A number of constructs specific to the API platform are supported
5159 # in documentation text.
5160 #
5161 # In order to reference a proto element, the following
5162 # notation can be used:
5163 # &lt;pre&gt;&lt;code&gt;&amp;#91;fully.qualified.proto.name]&amp;#91;]&lt;/code&gt;&lt;/pre&gt;
5164 # To override the display text used for the link, this can be used:
5165 # &lt;pre&gt;&lt;code&gt;&amp;#91;display text]&amp;#91;fully.qualified.proto.name]&lt;/code&gt;&lt;/pre&gt;
5166 # Text can be excluded from doc using the following notation:
5167 # &lt;pre&gt;&lt;code&gt;&amp;#40;-- internal comment --&amp;#41;&lt;/code&gt;&lt;/pre&gt;
5168 #
5169 # A few directives are available in documentation. Note that
5170 # directives must appear on a single line to be properly
5171 # identified. The `include` directive includes a markdown file from
5172 # an external source:
5173 # &lt;pre&gt;&lt;code&gt;&amp;#40;== include path/to/file ==&amp;#41;&lt;/code&gt;&lt;/pre&gt;
5174 # The `resource_for` directive marks a message to be the resource of
5175 # a collection in REST view. If it is not specified, tools attempt
5176 # to infer the resource from the operations in a collection:
5177 # &lt;pre&gt;&lt;code&gt;&amp;#40;== resource_for v1.shelves.books ==&amp;#41;&lt;/code&gt;&lt;/pre&gt;
5178 # The directive `suppress_warning` does not directly affect documentation
5179 # and is documented together with service config validation.
5180 &quot;serviceRootUrl&quot;: &quot;A String&quot;, # Specifies the service root url if the default one (the service name
5181 # from the yaml file) is not suitable. This can be seen in any fully
5182 # specified service urls as well as sections that show a base that other
5183 # urls are relative to.
5184 &quot;overview&quot;: &quot;A String&quot;, # Declares a single overview page. For example:
5185 # &lt;pre&gt;&lt;code&gt;documentation:
5186 # summary: ...
5187 # overview: &amp;#40;== include overview.md ==&amp;#41;
5188 # &lt;/code&gt;&lt;/pre&gt;
5189 # This is a shortcut for the following declaration (using pages style):
5190 # &lt;pre&gt;&lt;code&gt;documentation:
5191 # summary: ...
5192 # pages:
5193 # - name: Overview
5194 # content: &amp;#40;== include overview.md ==&amp;#41;
5195 # &lt;/code&gt;&lt;/pre&gt;
5196 # Note: you cannot specify both `overview` field and `pages` field.
5197 &quot;documentationRootUrl&quot;: &quot;A String&quot;, # The URL to the root of documentation.
5198 &quot;rules&quot;: [ # A list of documentation rules that apply to individual API elements.
Bu Sun Kim65020912020-05-20 12:08:20 -07005199 #
5200 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005201 { # A documentation rule provides information about individual API elements.
5202 &quot;deprecationDescription&quot;: &quot;A String&quot;, # Deprecation description of the selected element(s). It can be provided if
5203 # an element is marked as `deprecated`.
5204 &quot;description&quot;: &quot;A String&quot;, # Description of the selected API(s).
5205 &quot;selector&quot;: &quot;A String&quot;, # The selector is a comma-separated list of patterns. Each pattern is a
5206 # qualified name of the element which may end in &quot;*&quot;, indicating a wildcard.
5207 # Wildcards are only allowed at the end and for a whole component of the
5208 # qualified name, i.e. &quot;foo.*&quot; is ok, but not &quot;foo.b*&quot; or &quot;foo.*.bar&quot;. A
5209 # wildcard will match one or more components. To specify a default for all
5210 # applicable elements, the whole pattern &quot;*&quot; is used.
Bu Sun Kim65020912020-05-20 12:08:20 -07005211 },
5212 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005213 &quot;pages&quot;: [ # The top level pages for the documentation set.
5214 { # Represents a documentation page. A page can contain subpages to represent
5215 # nested documentation set structure.
5216 &quot;content&quot;: &quot;A String&quot;, # The Markdown content of the page. You can use &lt;code&gt;&amp;#40;== include {path}
5217 # ==&amp;#41;&lt;/code&gt; to include content from a Markdown file.
5218 &quot;name&quot;: &quot;A String&quot;, # The name of the page. It will be used as an identity of the page to
5219 # generate URI of the page, text of the link to this page in navigation,
5220 # etc. The full page name (start from the root page name to this page
5221 # concatenated with `.`) can be used as reference to the page in your
5222 # documentation. For example:
5223 # &lt;pre&gt;&lt;code&gt;pages:
5224 # - name: Tutorial
5225 # content: &amp;#40;== include tutorial.md ==&amp;#41;
5226 # subpages:
5227 # - name: Java
5228 # content: &amp;#40;== include tutorial_java.md ==&amp;#41;
5229 # &lt;/code&gt;&lt;/pre&gt;
5230 # You can reference `Java` page using Markdown reference link syntax:
5231 # `Java`.
5232 &quot;subpages&quot;: [ # Subpages of this page. The order of subpages specified here will be
5233 # honored in the generated docset.
5234 # Object with schema name: Page
5235 ],
5236 },
5237 ],
5238 &quot;summary&quot;: &quot;A String&quot;, # A short summary of what the service does. Can only be provided by
5239 # plain text.
Bu Sun Kim65020912020-05-20 12:08:20 -07005240 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005241 &quot;configVersion&quot;: 42, # The semantic version of the service configuration. The config version
5242 # affects the interpretation of the service configuration. For example,
5243 # certain features are enabled by default for certain config versions.
5244 #
5245 # The latest config version is `3`.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07005246 &quot;quota&quot;: { # Quota configuration helps to achieve fairness and budgeting in service # Quota configuration.
5247 # usage.
5248 #
5249 # The metric based quota configuration works this way:
5250 # - The service configuration defines a set of metrics.
5251 # - For API calls, the quota.metric_rules maps methods to metrics with
5252 # corresponding costs.
5253 # - The quota.limits defines limits on the metrics, which will be used for
5254 # quota checks at runtime.
5255 #
5256 # An example quota configuration in yaml format:
5257 #
5258 # quota:
5259 # limits:
5260 #
5261 # - name: apiWriteQpsPerProject
5262 # metric: library.googleapis.com/write_calls
5263 # unit: &quot;1/min/{project}&quot; # rate limit for consumer projects
5264 # values:
5265 # STANDARD: 10000
5266 #
5267 #
5268 # # The metric rules bind all methods to the read_calls metric,
5269 # # except for the UpdateBook and DeleteBook methods. These two methods
5270 # # are mapped to the write_calls metric, with the UpdateBook method
5271 # # consuming at twice rate as the DeleteBook method.
5272 # metric_rules:
5273 # - selector: &quot;*&quot;
5274 # metric_costs:
5275 # library.googleapis.com/read_calls: 1
5276 # - selector: google.example.library.v1.LibraryService.UpdateBook
5277 # metric_costs:
5278 # library.googleapis.com/write_calls: 2
5279 # - selector: google.example.library.v1.LibraryService.DeleteBook
5280 # metric_costs:
5281 # library.googleapis.com/write_calls: 1
5282 #
5283 # Corresponding Metric definition:
5284 #
5285 # metrics:
5286 # - name: library.googleapis.com/read_calls
5287 # display_name: Read requests
5288 # metric_kind: DELTA
5289 # value_type: INT64
5290 #
5291 # - name: library.googleapis.com/write_calls
5292 # display_name: Write requests
5293 # metric_kind: DELTA
5294 # value_type: INT64
5295 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005296 &quot;metricRules&quot;: [ # List of `MetricRule` definitions, each one mapping a selected method to one
5297 # or more metrics.
5298 { # Bind API methods to metrics. Binding a method to a metric causes that
5299 # metric&#x27;s configured quota behaviors to apply to the method call.
5300 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
5301 #
5302 # Refer to selector for syntax details.
5303 &quot;metricCosts&quot;: { # Metrics to update when the selected methods are called, and the associated
5304 # cost applied to each metric.
5305 #
5306 # The key of the map is the metric name, and the values are the amount
5307 # increased for the metric against which the quota limits are defined.
5308 # The value must not be negative.
5309 &quot;a_key&quot;: &quot;A String&quot;,
5310 },
5311 },
5312 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07005313 &quot;limits&quot;: [ # List of `QuotaLimit` definitions for the service.
5314 { # `QuotaLimit` defines a specific limit that applies over a specified duration
5315 # for a limit type. There can be at most one limit for a duration and limit
5316 # type combination defined within a `QuotaGroup`.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005317 &quot;values&quot;: { # Tiered limit values. You must specify this as a key:value pair, with an
5318 # integer value that is the maximum number of requests allowed for the
5319 # specified unit. Currently only STANDARD is supported.
5320 &quot;a_key&quot;: &quot;A String&quot;,
5321 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07005322 &quot;duration&quot;: &quot;A String&quot;, # Duration of this limit in textual notation. Must be &quot;100s&quot; or &quot;1d&quot;.
Bu Sun Kim65020912020-05-20 12:08:20 -07005323 #
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07005324 # Used by group-based quotas only.
5325 &quot;freeTier&quot;: &quot;A String&quot;, # Free tier value displayed in the Developers Console for this limit.
5326 # The free tier is the number of tokens that will be subtracted from the
5327 # billed amount when billing is enabled.
5328 # This field can only be set on a limit with duration &quot;1d&quot;, in a billable
5329 # group; it is invalid on any other limit. If this field is not set, it
5330 # defaults to 0, indicating that there is no free tier for this service.
Bu Sun Kim65020912020-05-20 12:08:20 -07005331 #
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07005332 # Used by group-based quotas only.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005333 &quot;displayName&quot;: &quot;A String&quot;, # User-visible display name for this limit.
5334 # Optional. If not set, the UI will provide a default display name based on
5335 # the quota configuration. This field can be used to override the default
5336 # display name generated from the configuration.
5337 &quot;description&quot;: &quot;A String&quot;, # Optional. User-visible, extended description for this quota limit.
5338 # Should be used only when more context is needed to understand this limit
5339 # than provided by the limit&#x27;s display name (see: `display_name`).
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07005340 &quot;defaultLimit&quot;: &quot;A String&quot;, # Default number of tokens that can be consumed during the specified
5341 # duration. This is the number of tokens assigned when a client
5342 # application developer activates the service for his/her project.
5343 #
5344 # Specifying a value of 0 will block all requests. This can be used if you
5345 # are provisioning quota to selected consumers and blocking others.
5346 # Similarly, a value of -1 will indicate an unlimited quota. No other
5347 # negative values are allowed.
5348 #
5349 # Used by group-based quotas only.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07005350 &quot;name&quot;: &quot;A String&quot;, # Name of the quota limit.
5351 #
5352 # The name must be provided, and it must be unique within the service. The
5353 # name can only include alphanumeric characters as well as &#x27;-&#x27;.
5354 #
5355 # The maximum length of the limit name is 64 characters.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005356 &quot;maxLimit&quot;: &quot;A String&quot;, # Maximum number of tokens that can be consumed during the specified
5357 # duration. Client application developers can override the default limit up
5358 # to this maximum. If specified, this value cannot be set to a value less
5359 # than the default limit. If not specified, it is set to the default limit.
5360 #
5361 # To allow clients to apply overrides with no upper bound, set this to -1,
5362 # indicating unlimited maximum quota.
5363 #
5364 # Used by group-based quotas only.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07005365 &quot;metric&quot;: &quot;A String&quot;, # The name of the metric this quota limit applies to. The quota limits with
5366 # the same metric will be checked together during runtime. The metric must be
5367 # defined within the service config.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005368 &quot;unit&quot;: &quot;A String&quot;, # Specify the unit of the quota limit. It uses the same syntax as
5369 # Metric.unit. The supported unit kinds are determined by the quota
5370 # backend system.
5371 #
5372 # Here are some examples:
5373 # * &quot;1/min/{project}&quot; for quota per minute per project.
5374 #
5375 # Note: the order of unit components is insignificant.
5376 # The &quot;1&quot; at the beginning is required to follow the metric unit syntax.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07005377 },
5378 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005379 },
5380 &quot;customError&quot;: { # Customize service error responses. For example, list any service # Custom error configuration.
5381 # specific protobuf types that can appear in error detail lists of
5382 # error responses.
5383 #
5384 # Example:
5385 #
5386 # custom_error:
5387 # types:
5388 # - google.foo.v1.CustomError
5389 # - google.foo.v1.AnotherError
5390 &quot;types&quot;: [ # The list of custom error detail types, e.g. &#x27;google.foo.v1.CustomError&#x27;.
5391 &quot;A String&quot;,
5392 ],
5393 &quot;rules&quot;: [ # The list of custom error rules that apply to individual API messages.
5394 #
5395 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
5396 { # A custom error rule.
5397 &quot;selector&quot;: &quot;A String&quot;, # Selects messages to which this rule applies.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07005398 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005399 # Refer to selector for syntax details.
5400 &quot;isErrorType&quot;: True or False, # Mark this message as possible payload in error response. Otherwise,
5401 # objects of this type will be filtered when they appear in error payload.
5402 },
5403 ],
5404 },
5405 &quot;authentication&quot;: { # `Authentication` defines the authentication configuration for an API. # Auth configuration.
5406 #
5407 # Example for an API targeted for external use:
5408 #
5409 # name: calendar.googleapis.com
5410 # authentication:
5411 # providers:
5412 # - id: google_calendar_auth
5413 # jwks_uri: https://www.googleapis.com/oauth2/v1/certs
5414 # issuer: https://securetoken.google.com
5415 # rules:
5416 # - selector: &quot;*&quot;
5417 # requirements:
5418 # provider_id: google_calendar_auth
5419 &quot;rules&quot;: [ # A list of authentication rules that apply to individual API methods.
5420 #
5421 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
5422 { # Authentication rules for the service.
5423 #
5424 # By default, if a method has any authentication requirements, every request
5425 # must include a valid credential matching one of the requirements.
5426 # It&#x27;s an error to include more than one kind of credential in a single
5427 # request.
5428 #
5429 # If a method doesn&#x27;t have any auth requirements, request credentials will be
5430 # ignored.
5431 &quot;oauth&quot;: { # OAuth scopes are a way to define data and permissions on data. For example, # The requirements for OAuth credentials.
5432 # there are scopes defined for &quot;Read-only access to Google Calendar&quot; and
5433 # &quot;Access to Cloud Platform&quot;. Users can consent to a scope for an application,
5434 # giving it permission to access that data on their behalf.
5435 #
5436 # OAuth scope specifications should be fairly coarse grained; a user will need
5437 # to see and understand the text description of what your scope means.
5438 #
5439 # In most cases: use one or at most two OAuth scopes for an entire family of
5440 # products. If your product has multiple APIs, you should probably be sharing
5441 # the OAuth scope across all of those APIs.
5442 #
5443 # When you need finer grained OAuth consent screens: talk with your product
5444 # management about how developers will use them in practice.
5445 #
5446 # Please note that even though each of the canonical scopes is enough for a
5447 # request to be accepted and passed to the backend, a request can still fail
5448 # due to the backend requiring additional scopes or permissions.
5449 &quot;canonicalScopes&quot;: &quot;A String&quot;, # The list of publicly documented OAuth scopes that are allowed access. An
5450 # OAuth token containing any of these scopes will be accepted.
5451 #
5452 # Example:
5453 #
5454 # canonical_scopes: https://www.googleapis.com/auth/calendar,
5455 # https://www.googleapis.com/auth/calendar.read
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07005456 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005457 &quot;requirements&quot;: [ # Requirements for additional authentication providers.
5458 { # User-defined authentication requirements, including support for
5459 # [JSON Web Token
5460 # (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32).
5461 &quot;providerId&quot;: &quot;A String&quot;, # id from authentication provider.
5462 #
5463 # Example:
5464 #
5465 # provider_id: bookstore_auth
5466 &quot;audiences&quot;: &quot;A String&quot;, # NOTE: This will be deprecated soon, once AuthProvider.audiences is
5467 # implemented and accepted in all the runtime components.
5468 #
5469 # The list of JWT
5470 # [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3).
5471 # that are allowed to access. A JWT containing any of these audiences will
5472 # be accepted. When this setting is absent, only JWTs with audience
5473 # &quot;https://Service_name/API_name&quot;
5474 # will be accepted. For example, if no audiences are in the setting,
5475 # LibraryService API will only accept JWTs with the following audience
5476 # &quot;https://library-example.googleapis.com/google.example.library.v1.LibraryService&quot;.
5477 #
5478 # Example:
5479 #
5480 # audiences: bookstore_android.apps.googleusercontent.com,
5481 # bookstore_web.apps.googleusercontent.com
5482 },
5483 ],
5484 &quot;allowWithoutCredential&quot;: True or False, # If true, the service accepts API keys without any other credential.
Bu Sun Kim65020912020-05-20 12:08:20 -07005485 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
5486 #
5487 # Refer to selector for syntax details.
Bu Sun Kim65020912020-05-20 12:08:20 -07005488 },
5489 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005490 &quot;providers&quot;: [ # Defines a set of authentication providers that a service supports.
5491 { # Configuration for an authentication provider, including support for
5492 # [JSON Web Token
5493 # (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32).
5494 &quot;id&quot;: &quot;A String&quot;, # The unique identifier of the auth provider. It will be referred to by
5495 # `AuthRequirement.provider_id`.
5496 #
5497 # Example: &quot;bookstore_auth&quot;.
5498 &quot;issuer&quot;: &quot;A String&quot;, # Identifies the principal that issued the JWT. See
5499 # https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.1
5500 # Usually a URL or an email address.
5501 #
5502 # Example: https://securetoken.google.com
5503 # Example: 1234567-compute@developer.gserviceaccount.com
5504 &quot;jwksUri&quot;: &quot;A String&quot;, # URL of the provider&#x27;s public key set to validate signature of the JWT. See
5505 # [OpenID
5506 # Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata).
5507 # Optional if the key set document:
5508 # - can be retrieved from
5509 # [OpenID
5510 # Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html of
5511 # the issuer.
5512 # - can be inferred from the email domain of the issuer (e.g. a Google
5513 # service account).
5514 #
5515 # Example: https://www.googleapis.com/oauth2/v1/certs
5516 &quot;audiences&quot;: &quot;A String&quot;, # The list of JWT
5517 # [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3).
5518 # that are allowed to access. A JWT containing any of these audiences will
5519 # be accepted. When this setting is absent, JWTs with audiences:
5520 # - &quot;https://[service.name]/[google.protobuf.Api.name]&quot;
5521 # - &quot;https://[service.name]/&quot;
5522 # will be accepted.
5523 # For example, if no audiences are in the setting, LibraryService API will
5524 # accept JWTs with the following audiences:
5525 # -
5526 # https://library-example.googleapis.com/google.example.library.v1.LibraryService
5527 # - https://library-example.googleapis.com/
5528 #
5529 # Example:
5530 #
5531 # audiences: bookstore_android.apps.googleusercontent.com,
5532 # bookstore_web.apps.googleusercontent.com
5533 &quot;authorizationUrl&quot;: &quot;A String&quot;, # Redirect URL if JWT token is required but not present or is expired.
5534 # Implement authorizationUrl of securityDefinitions in OpenAPI spec.
5535 &quot;jwtLocations&quot;: [ # Defines the locations to extract the JWT.
5536 #
5537 # JWT locations can be either from HTTP headers or URL query parameters.
5538 # The rule is that the first match wins. The checking order is: checking
5539 # all headers first, then URL query parameters.
5540 #
5541 # If not specified, default to use following 3 locations:
5542 # 1) Authorization: Bearer
5543 # 2) x-goog-iap-jwt-assertion
5544 # 3) access_token query parameter
5545 #
5546 # Default locations can be specified as followings:
5547 # jwt_locations:
5548 # - header: Authorization
5549 # value_prefix: &quot;Bearer &quot;
5550 # - header: x-goog-iap-jwt-assertion
5551 # - query: access_token
5552 { # Specifies a location to extract JWT from an API request.
5553 &quot;query&quot;: &quot;A String&quot;, # Specifies URL query parameter name to extract JWT token.
5554 &quot;valuePrefix&quot;: &quot;A String&quot;, # The value prefix. The value format is &quot;value_prefix{token}&quot;
5555 # Only applies to &quot;in&quot; header type. Must be empty for &quot;in&quot; query type.
5556 # If not empty, the header value has to match (case sensitive) this prefix.
5557 # If not matched, JWT will not be extracted. If matched, JWT will be
5558 # extracted after the prefix is removed.
5559 #
5560 # For example, for &quot;Authorization: Bearer {JWT}&quot;,
5561 # value_prefix=&quot;Bearer &quot; with a space at the end.
5562 &quot;header&quot;: &quot;A String&quot;, # Specifies HTTP header name to extract JWT token.
5563 },
5564 ],
5565 },
5566 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07005567 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005568 &quot;title&quot;: &quot;A String&quot;, # The product title for this service.
5569 &quot;producerProjectId&quot;: &quot;A String&quot;, # The Google project that owns this service.
5570 &quot;apis&quot;: [ # A list of API interfaces exported by this service. Only the `name` field
5571 # of the google.protobuf.Api needs to be provided by the configuration
5572 # author, as the remaining fields will be derived from the IDL during the
5573 # normalization process. It is an error to specify an API interface here
5574 # which cannot be resolved against the associated IDL files.
5575 { # Api is a light-weight descriptor for an API Interface.
5576 #
5577 # Interfaces are also described as &quot;protocol buffer services&quot; in some contexts,
5578 # such as by the &quot;service&quot; keyword in a .proto file, but they are different
5579 # from API Services, which represent a concrete implementation of an interface
5580 # as opposed to simply a description of methods and bindings. They are also
5581 # sometimes simply referred to as &quot;APIs&quot; in other contexts, such as the name of
5582 # this message itself. See https://cloud.google.com/apis/design/glossary for
5583 # detailed terminology.
5584 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # Source context for the protocol buffer service represented by this
5585 # message.
5586 # protobuf element, like the file in which it is defined.
5587 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
5588 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
5589 },
5590 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax of the service.
5591 &quot;methods&quot;: [ # The methods of this interface, in unspecified order.
5592 { # Method represents a method of an API interface.
5593 &quot;options&quot;: [ # Any metadata attached to the method.
5594 { # A protocol buffer option, which can be attached to a message, field,
5595 # enumeration, etc.
5596 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
5597 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
5598 # should be used. If the value is an enum, it should be stored as an int32
5599 # value using the google.protobuf.Int32Value type.
5600 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
5601 },
5602 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
5603 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
5604 # For custom options, it should be the fully-qualified name. For example,
5605 # `&quot;google.api.http&quot;`.
5606 },
5607 ],
5608 &quot;responseStreaming&quot;: True or False, # If true, the response is streamed.
5609 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax of this method.
5610 &quot;requestTypeUrl&quot;: &quot;A String&quot;, # A URL of the input message type.
5611 &quot;name&quot;: &quot;A String&quot;, # The simple name of this method.
5612 &quot;responseTypeUrl&quot;: &quot;A String&quot;, # The URL of the output message type.
5613 &quot;requestStreaming&quot;: True or False, # If true, the request is streamed.
5614 },
5615 ],
5616 &quot;name&quot;: &quot;A String&quot;, # The fully qualified name of this interface, including package name
5617 # followed by the interface&#x27;s simple name.
5618 &quot;version&quot;: &quot;A String&quot;, # A version string for this interface. If specified, must have the form
5619 # `major-version.minor-version`, as in `1.10`. If the minor version is
5620 # omitted, it defaults to zero. If the entire version field is empty, the
5621 # major version is derived from the package name, as outlined below. If the
5622 # field is not empty, the version in the package name will be verified to be
5623 # consistent with what is provided here.
5624 #
5625 # The versioning schema uses [semantic
5626 # versioning](http://semver.org) where the major version number
5627 # indicates a breaking change and the minor version an additive,
5628 # non-breaking change. Both version numbers are signals to users
5629 # what to expect from different versions, and should be carefully
5630 # chosen based on the product plan.
5631 #
5632 # The major version is also reflected in the package name of the
5633 # interface, which must end in `v&lt;major-version&gt;`, as in
5634 # `google.feature.v1`. For major versions 0 and 1, the suffix can
5635 # be omitted. Zero major versions must only be used for
5636 # experimental, non-GA interfaces.
5637 &quot;options&quot;: [ # Any metadata attached to the interface.
5638 { # A protocol buffer option, which can be attached to a message, field,
5639 # enumeration, etc.
5640 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
5641 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
5642 # should be used. If the value is an enum, it should be stored as an int32
5643 # value using the google.protobuf.Int32Value type.
5644 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
5645 },
5646 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
5647 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
5648 # For custom options, it should be the fully-qualified name. For example,
5649 # `&quot;google.api.http&quot;`.
5650 },
5651 ],
5652 &quot;mixins&quot;: [ # Included interfaces. See Mixin.
5653 { # Declares an API Interface to be included in this interface. The including
5654 # interface must redeclare all the methods from the included interface, but
5655 # documentation and options are inherited as follows:
5656 #
5657 # - If after comment and whitespace stripping, the documentation
5658 # string of the redeclared method is empty, it will be inherited
5659 # from the original method.
5660 #
5661 # - Each annotation belonging to the service config (http,
5662 # visibility) which is not set in the redeclared method will be
5663 # inherited.
5664 #
5665 # - If an http annotation is inherited, the path pattern will be
5666 # modified as follows. Any version prefix will be replaced by the
5667 # version of the including interface plus the root path if
5668 # specified.
5669 #
5670 # Example of a simple mixin:
5671 #
5672 # package google.acl.v1;
5673 # service AccessControl {
5674 # // Get the underlying ACL object.
5675 # rpc GetAcl(GetAclRequest) returns (Acl) {
5676 # option (google.api.http).get = &quot;/v1/{resource=**}:getAcl&quot;;
5677 # }
5678 # }
5679 #
5680 # package google.storage.v2;
5681 # service Storage {
5682 # // rpc GetAcl(GetAclRequest) returns (Acl);
5683 #
5684 # // Get a data record.
5685 # rpc GetData(GetDataRequest) returns (Data) {
5686 # option (google.api.http).get = &quot;/v2/{resource=**}&quot;;
5687 # }
5688 # }
5689 #
5690 # Example of a mixin configuration:
5691 #
5692 # apis:
5693 # - name: google.storage.v2.Storage
5694 # mixins:
5695 # - name: google.acl.v1.AccessControl
5696 #
5697 # The mixin construct implies that all methods in `AccessControl` are
5698 # also declared with same name and request/response types in
5699 # `Storage`. A documentation generator or annotation processor will
5700 # see the effective `Storage.GetAcl` method after inherting
5701 # documentation and annotations as follows:
5702 #
5703 # service Storage {
5704 # // Get the underlying ACL object.
5705 # rpc GetAcl(GetAclRequest) returns (Acl) {
5706 # option (google.api.http).get = &quot;/v2/{resource=**}:getAcl&quot;;
5707 # }
5708 # ...
5709 # }
5710 #
5711 # Note how the version in the path pattern changed from `v1` to `v2`.
5712 #
5713 # If the `root` field in the mixin is specified, it should be a
5714 # relative path under which inherited HTTP paths are placed. Example:
5715 #
5716 # apis:
5717 # - name: google.storage.v2.Storage
5718 # mixins:
5719 # - name: google.acl.v1.AccessControl
5720 # root: acls
5721 #
5722 # This implies the following inherited HTTP annotation:
5723 #
5724 # service Storage {
5725 # // Get the underlying ACL object.
5726 # rpc GetAcl(GetAclRequest) returns (Acl) {
5727 # option (google.api.http).get = &quot;/v2/acls/{resource=**}:getAcl&quot;;
5728 # }
5729 # ...
5730 # }
5731 &quot;root&quot;: &quot;A String&quot;, # If non-empty specifies a path under which inherited HTTP paths
5732 # are rooted.
5733 &quot;name&quot;: &quot;A String&quot;, # The fully qualified name of the interface which is included.
5734 },
5735 ],
5736 },
5737 ],
5738 &quot;id&quot;: &quot;A String&quot;, # A unique ID for a specific instance of this message, typically assigned
5739 # by the client for tracking purpose. Must be no longer than 63 characters
5740 # and only lower case letters, digits, &#x27;.&#x27;, &#x27;_&#x27; and &#x27;-&#x27; are allowed. If
5741 # empty, the server may choose to generate one instead.
5742 &quot;endpoints&quot;: [ # Configuration for network endpoints. If this is empty, then an endpoint
5743 # with the same name as the service is automatically generated to service all
5744 # defined APIs.
5745 { # `Endpoint` describes a network endpoint that serves a set of APIs.
5746 # A service may expose any number of endpoints, and all endpoints share the
5747 # same service configuration, such as quota configuration and monitoring
5748 # configuration.
5749 #
5750 # Example service configuration:
5751 #
5752 # name: library-example.googleapis.com
5753 # endpoints:
5754 # # Below entry makes &#x27;google.example.library.v1.Library&#x27;
5755 # # API be served from endpoint address library-example.googleapis.com.
5756 # # It also allows HTTP OPTIONS calls to be passed to the backend, for
5757 # # it to decide whether the subsequent cross-origin request is
5758 # # allowed to proceed.
5759 # - name: library-example.googleapis.com
5760 # allow_cors: true
5761 &quot;name&quot;: &quot;A String&quot;, # The canonical name of this endpoint.
5762 &quot;allowCors&quot;: True or False, # Allowing
5763 # [CORS](https://en.wikipedia.org/wiki/Cross-origin_resource_sharing), aka
5764 # cross-domain traffic, would allow the backends served from this endpoint to
5765 # receive and respond to HTTP OPTIONS requests. The response will be used by
5766 # the browser to determine whether the subsequent cross-origin request is
5767 # allowed to proceed.
5768 &quot;target&quot;: &quot;A String&quot;, # The specification of an Internet routable address of API frontend that will
5769 # handle requests to this [API
5770 # Endpoint](https://cloud.google.com/apis/design/glossary). It should be
5771 # either a valid IPv4 address or a fully-qualified domain name. For example,
5772 # &quot;8.8.8.8&quot; or &quot;myservice.appspot.com&quot;.
5773 &quot;aliases&quot;: [ # DEPRECATED: This field is no longer supported. Instead of using aliases,
5774 # please specify multiple google.api.Endpoint for each of the intended
5775 # aliases.
5776 #
5777 # Additional names that this endpoint will be hosted on.
5778 &quot;A String&quot;,
5779 ],
5780 },
5781 ],
5782 &quot;systemParameters&quot;: { # ### System parameter configuration # System parameter configuration.
5783 #
5784 # A system parameter is a special kind of parameter defined by the API
5785 # system, not by an individual API. It is typically mapped to an HTTP header
5786 # and/or a URL query parameter. This configuration specifies which methods
5787 # change the names of the system parameters.
5788 &quot;rules&quot;: [ # Define system parameters.
5789 #
5790 # The parameters defined here will override the default parameters
5791 # implemented by the system. If this field is missing from the service
5792 # config, default system parameters will be used. Default system parameters
5793 # and names is implementation-dependent.
5794 #
5795 # Example: define api key for all methods
5796 #
5797 # system_parameters
5798 # rules:
5799 # - selector: &quot;*&quot;
5800 # parameters:
5801 # - name: api_key
5802 # url_query_parameter: api_key
5803 #
5804 #
5805 # Example: define 2 api key names for a specific method.
5806 #
5807 # system_parameters
5808 # rules:
5809 # - selector: &quot;/ListShelves&quot;
5810 # parameters:
5811 # - name: api_key
5812 # http_header: Api-Key1
5813 # - name: api_key
5814 # http_header: Api-Key2
5815 #
5816 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
5817 { # Define a system parameter rule mapping system parameter definitions to
5818 # methods.
5819 &quot;parameters&quot;: [ # Define parameters. Multiple names may be defined for a parameter.
5820 # For a given method call, only one of them should be used. If multiple
5821 # names are used the behavior is implementation-dependent.
5822 # If none of the specified names are present the behavior is
5823 # parameter-dependent.
5824 { # Define a parameter&#x27;s name and location. The parameter may be passed as either
5825 # an HTTP header or a URL query parameter, and if both are passed the behavior
5826 # is implementation-dependent.
5827 &quot;name&quot;: &quot;A String&quot;, # Define the name of the parameter, such as &quot;api_key&quot; . It is case sensitive.
5828 &quot;httpHeader&quot;: &quot;A String&quot;, # Define the HTTP header name to use for the parameter. It is case
5829 # insensitive.
5830 &quot;urlQueryParameter&quot;: &quot;A String&quot;, # Define the URL query parameter name to use for the parameter. It is case
5831 # sensitive.
5832 },
5833 ],
5834 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies. Use &#x27;*&#x27; to indicate all
5835 # methods in all APIs.
5836 #
5837 # Refer to selector for syntax details.
5838 },
5839 ],
5840 },
5841 &quot;monitoredResources&quot;: [ # Defines the monitored resources used by this service. This is required
5842 # by the Service.monitoring and Service.logging configurations.
5843 { # An object that describes the schema of a MonitoredResource object using a
5844 # type name and a set of labels. For example, the monitored resource
5845 # descriptor for Google Compute Engine VM instances has a type of
5846 # `&quot;gce_instance&quot;` and specifies the use of the labels `&quot;instance_id&quot;` and
5847 # `&quot;zone&quot;` to identify particular VM instances.
5848 #
5849 # Different services can support different monitored resource types.
5850 #
5851 # The following are specific rules to service defined monitored resources for
5852 # Monitoring and Logging:
5853 #
5854 # * The `type`, `display_name`, `description`, `labels` and `launch_stage`
5855 # fields are all required.
5856 # * The first label of the monitored resource descriptor must be
5857 # `resource_container`. There are legacy monitored resource descritptors
5858 # start with `project_id`.
5859 # * It must include a `location` label.
5860 # * Maximum of default 5 service defined monitored resource descriptors
5861 # is allowed per service.
5862 # * Maximum of default 10 labels per monitored resource is allowed.
5863 #
5864 # The default maximum limit can be overridden. Please follow
5865 # https://cloud.google.com/monitoring/quotas
5866 &quot;name&quot;: &quot;A String&quot;, # Optional. The resource name of the monitored resource descriptor:
5867 # `&quot;projects/{project_id}/monitoredResourceDescriptors/{type}&quot;` where
5868 # {type} is the value of the `type` field in this object and
5869 # {project_id} is a project ID that provides API-specific context for
5870 # accessing the type. APIs that do not use project information can use the
5871 # resource name format `&quot;monitoredResourceDescriptors/{type}&quot;`.
5872 &quot;launchStage&quot;: &quot;A String&quot;, # Optional. The launch stage of the monitored resource definition.
5873 &quot;displayName&quot;: &quot;A String&quot;, # Optional. A concise name for the monitored resource type that might be
5874 # displayed in user interfaces. It should be a Title Cased Noun Phrase,
5875 # without any article or other determiners. For example,
5876 # `&quot;Google Cloud SQL Database&quot;`.
5877 &quot;labels&quot;: [ # Required. A set of labels used to describe instances of this monitored
5878 # resource type.
5879 # The label key name must follow:
5880 #
5881 # * Only upper and lower-case letters, digits and underscores (_) are
5882 # allowed.
5883 # * Label name must start with a letter or digit.
5884 # * The maximum length of a label name is 100 characters.
5885 #
5886 # For example, an individual Google Cloud SQL database is
5887 # identified by values for the labels `database_id` and `location`.
5888 { # A description of a label.
5889 &quot;valueType&quot;: &quot;A String&quot;, # The type of data that can be assigned to the label.
5890 &quot;description&quot;: &quot;A String&quot;, # A human-readable description for the label.
5891 &quot;key&quot;: &quot;A String&quot;, # The label key.
5892 },
5893 ],
5894 &quot;description&quot;: &quot;A String&quot;, # Optional. A detailed description of the monitored resource type that might
5895 # be used in documentation.
5896 &quot;type&quot;: &quot;A String&quot;, # Required. The monitored resource type. For example, the type
5897 # `cloudsql_database` represents databases in Google Cloud SQL.
5898 #
5899 # All service defined monitored resource types must be prefixed with the
5900 # service name, in the format of `{service name}/{relative resource name}`.
5901 # The relative resource name must follow:
5902 #
5903 # * Only upper and lower-case letters and digits are allowed.
5904 # * It must start with upper case character and is recommended to use Upper
5905 # Camel Case style.
5906 # * The maximum number of characters allowed for the relative_resource_name
5907 # is 100.
5908 #
5909 # Note there are legacy service monitored resources not following this rule.
5910 },
5911 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07005912 &quot;context&quot;: { # `Context` defines which contexts an API requests. # Context configuration.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07005913 #
5914 # Example:
5915 #
Bu Sun Kim65020912020-05-20 12:08:20 -07005916 # context:
5917 # rules:
5918 # - selector: &quot;*&quot;
5919 # requested:
5920 # - google.rpc.context.ProjectContext
5921 # - google.rpc.context.OriginContext
5922 #
5923 # The above specifies that all methods in the API request
5924 # `google.rpc.context.ProjectContext` and
5925 # `google.rpc.context.OriginContext`.
5926 #
5927 # Available context types are defined in package
5928 # `google.rpc.context`.
5929 #
5930 # This also provides mechanism to whitelist any protobuf message extension that
5931 # can be sent in grpc metadata using “x-goog-ext-&lt;extension_id&gt;-bin” and
5932 # “x-goog-ext-&lt;extension_id&gt;-jspb” format. For example, list any service
5933 # specific protobuf types that can appear in grpc metadata as follows in your
5934 # yaml file:
5935 #
5936 # Example:
5937 #
5938 # context:
5939 # rules:
5940 # - selector: &quot;google.example.library.v1.LibraryService.CreateBook&quot;
5941 # allowed_request_extensions:
5942 # - google.foo.v1.NewExtension
5943 # allowed_response_extensions:
5944 # - google.foo.v1.NewExtension
5945 #
5946 # You can also specify extension ID instead of fully qualified extension name
5947 # here.
5948 &quot;rules&quot;: [ # A list of RPC context rules that apply to individual API methods.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07005949 #
Bu Sun Kim65020912020-05-20 12:08:20 -07005950 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
5951 { # A context rule provides information about the context for an individual API
5952 # element.
Bu Sun Kim65020912020-05-20 12:08:20 -07005953 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07005954 #
5955 # Refer to selector for syntax details.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07005956 &quot;requested&quot;: [ # A list of full type names of requested contexts.
5957 &quot;A String&quot;,
5958 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07005959 &quot;provided&quot;: [ # A list of full type names of provided contexts.
5960 &quot;A String&quot;,
5961 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005962 &quot;allowedRequestExtensions&quot;: [ # A list of full type names or extension IDs of extensions allowed in grpc
5963 # side channel from client to backend.
5964 &quot;A String&quot;,
5965 ],
5966 &quot;allowedResponseExtensions&quot;: [ # A list of full type names or extension IDs of extensions allowed in grpc
5967 # side channel from backend to client.
5968 &quot;A String&quot;,
5969 ],
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07005970 },
5971 ],
5972 },
5973 }</pre>
5974</div>
5975
5976<div class="method">
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005977 <code class="details" id="list">list(serviceName, pageSize=None, pageToken=None, x__xgafv=None)</code>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07005978 <pre>Lists the history of the service configuration for a managed service,
5979from the newest to the oldest.
5980
5981Args:
Dan O'Mearadd494642020-05-01 07:42:23 -07005982 serviceName: string, Required. The name of the service. See the [overview](/service-management/overview)
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07005983for naming requirements. For example: `example.googleapis.com`. (required)
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07005984 pageSize: integer, The max number of items to include in the response list. Page size is 50
5985if not specified. Maximum value is 100.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07005986 pageToken: string, The token of the page to retrieve.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07005987 x__xgafv: string, V1 error format.
5988 Allowed values
5989 1 - v1 error format
5990 2 - v2 error format
5991
5992Returns:
5993 An object of the form:
5994
5995 { # Response message for ListServiceConfigs method.
Bu Sun Kim65020912020-05-20 12:08:20 -07005996 &quot;serviceConfigs&quot;: [ # The list of service configuration resources.
Sai Cheemalapatiea3a5e12016-10-12 14:05:53 -07005997 { # `Service` is the root object of Google service configuration schema. It
5998 # describes basic information about a service, such as the name and the
5999 # title, and delegates other aspects to sub-sections. Each sub-section is
6000 # either a proto message or a repeated proto message that configures a
6001 # specific aspect, such as auth. See each proto message definition for details.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006002 #
6003 # Example:
6004 #
6005 # type: google.api.Service
Sai Cheemalapatiea3a5e12016-10-12 14:05:53 -07006006 # config_version: 3
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006007 # name: calendar.googleapis.com
6008 # title: Google Calendar API
6009 # apis:
Sai Cheemalapatiea3a5e12016-10-12 14:05:53 -07006010 # - name: google.calendar.v3.Calendar
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006011 # authentication:
6012 # providers:
6013 # - id: google_calendar_auth
6014 # jwks_uri: https://www.googleapis.com/oauth2/v1/certs
6015 # issuer: https://securetoken.google.com
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006016 # rules:
Bu Sun Kim65020912020-05-20 12:08:20 -07006017 # - selector: &quot;*&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006018 # requirements:
6019 # provider_id: google_calendar_auth
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006020 &quot;enums&quot;: [ # A list of all enum types included in this API service. Enums
6021 # referenced directly or indirectly by the `apis` are automatically
6022 # included. Enums which are not referenced but shall be included
6023 # should be listed here by name. Example:
6024 #
6025 # enums:
6026 # - name: google.someapi.v1.SomeEnum
6027 { # Enum type definition.
6028 &quot;options&quot;: [ # Protocol buffer options.
6029 { # A protocol buffer option, which can be attached to a message, field,
6030 # enumeration, etc.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006031 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
6032 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
6033 # should be used. If the value is an enum, it should be stored as an int32
6034 # value using the google.protobuf.Int32Value type.
6035 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
6036 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006037 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
6038 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
6039 # For custom options, it should be the fully-qualified name. For example,
6040 # `&quot;google.api.http&quot;`.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006041 },
6042 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006043 &quot;enumvalue&quot;: [ # Enum value definitions.
6044 { # Enum value definition.
6045 &quot;name&quot;: &quot;A String&quot;, # Enum value name.
6046 &quot;options&quot;: [ # Protocol buffer options.
6047 { # A protocol buffer option, which can be attached to a message, field,
6048 # enumeration, etc.
6049 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
6050 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
6051 # should be used. If the value is an enum, it should be stored as an int32
6052 # value using the google.protobuf.Int32Value type.
6053 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
6054 },
6055 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
6056 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
6057 # For custom options, it should be the fully-qualified name. For example,
6058 # `&quot;google.api.http&quot;`.
6059 },
6060 ],
6061 &quot;number&quot;: 42, # Enum value number.
6062 },
6063 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006064 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # The source context.
6065 # protobuf element, like the file in which it is defined.
6066 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
6067 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
6068 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006069 &quot;name&quot;: &quot;A String&quot;, # Enum type name.
6070 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax.
6071 },
6072 ],
6073 &quot;backend&quot;: { # `Backend` defines the backend configuration for a service. # API backend configuration.
6074 &quot;rules&quot;: [ # A list of API backend rules that apply to individual API methods.
6075 #
6076 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
6077 { # A backend rule provides configuration for an individual API element.
6078 &quot;disableAuth&quot;: True or False, # When disable_auth is true, a JWT ID token won&#x27;t be generated and the
6079 # original &quot;Authorization&quot; HTTP header will be preserved. If the header is
6080 # used to carry the original token and is expected by the backend, this
6081 # field must be set to true to preserve the header.
6082 &quot;address&quot;: &quot;A String&quot;, # The address of the API backend.
6083 #
6084 # The scheme is used to determine the backend protocol and security.
6085 # The following schemes are accepted:
6086 #
6087 # SCHEME PROTOCOL SECURITY
6088 # http:// HTTP None
6089 # https:// HTTP TLS
6090 # grpc:// gRPC None
6091 # grpcs:// gRPC TLS
6092 #
6093 # It is recommended to explicitly include a scheme. Leaving out the scheme
6094 # may cause constrasting behaviors across platforms.
6095 #
6096 # If the port is unspecified, the default is:
6097 # - 80 for schemes without TLS
6098 # - 443 for schemes with TLS
6099 #
6100 # For HTTP backends, use protocol
6101 # to specify the protocol version.
6102 &quot;minDeadline&quot;: 3.14, # Minimum deadline in seconds needed for this method. Calls having deadline
6103 # value lower than this will be rejected.
6104 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
6105 #
6106 # Refer to selector for syntax details.
6107 &quot;protocol&quot;: &quot;A String&quot;, # The protocol used for sending a request to the backend.
6108 # The supported values are &quot;http/1.1&quot; and &quot;h2&quot;.
6109 #
6110 # The default value is inferred from the scheme in the
6111 # address field:
6112 #
6113 # SCHEME PROTOCOL
6114 # http:// http/1.1
6115 # https:// http/1.1
6116 # grpc:// h2
6117 # grpcs:// h2
6118 #
6119 # For secure HTTP backends (https://) that support HTTP/2, set this field
6120 # to &quot;h2&quot; for improved performance.
6121 #
6122 # Configuring this field to non-default values is only supported for secure
6123 # HTTP backends. This field will be ignored for all other backends.
6124 #
6125 # See
6126 # https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#alpn-protocol-ids
6127 # for more details on the supported values.
6128 &quot;operationDeadline&quot;: 3.14, # The number of seconds to wait for the completion of a long running
6129 # operation. The default is no deadline.
6130 &quot;pathTranslation&quot;: &quot;A String&quot;,
6131 &quot;jwtAudience&quot;: &quot;A String&quot;, # The JWT audience is used when generating a JWT ID token for the backend.
6132 # This ID token will be added in the HTTP &quot;authorization&quot; header, and sent
6133 # to the backend.
6134 &quot;deadline&quot;: 3.14, # The number of seconds to wait for a response from a request. The default
6135 # varies based on the request protocol and deployment environment.
6136 },
6137 ],
6138 },
6139 &quot;systemTypes&quot;: [ # A list of all proto message types included in this API service.
6140 # It serves similar purpose as [google.api.Service.types], except that
6141 # these types are not needed by user-defined APIs. Therefore, they will not
6142 # show up in the generated discovery doc. This field should only be used
6143 # to define system APIs in ESF.
6144 { # A protocol buffer message type.
6145 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # The source context.
6146 # protobuf element, like the file in which it is defined.
6147 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
6148 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
6149 },
6150 &quot;oneofs&quot;: [ # The list of types appearing in `oneof` definitions in this type.
6151 &quot;A String&quot;,
6152 ],
6153 &quot;fields&quot;: [ # The list of fields.
6154 { # A single field of a message type.
6155 &quot;oneofIndex&quot;: 42, # The index of the field type in `Type.oneofs`, for message or enumeration
6156 # types. The first type has index 1; zero means the type is not in the list.
6157 &quot;name&quot;: &quot;A String&quot;, # The field name.
6158 &quot;defaultValue&quot;: &quot;A String&quot;, # The string value of the default value of this field. Proto2 syntax only.
6159 &quot;packed&quot;: True or False, # Whether to use alternative packed wire representation.
6160 &quot;typeUrl&quot;: &quot;A String&quot;, # The field type URL, without the scheme, for message or enumeration
6161 # types. Example: `&quot;type.googleapis.com/google.protobuf.Timestamp&quot;`.
6162 &quot;cardinality&quot;: &quot;A String&quot;, # The field cardinality.
6163 &quot;jsonName&quot;: &quot;A String&quot;, # The field JSON name.
6164 &quot;kind&quot;: &quot;A String&quot;, # The field type.
6165 &quot;options&quot;: [ # The protocol buffer options.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006166 { # A protocol buffer option, which can be attached to a message, field,
6167 # enumeration, etc.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006168 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
6169 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
6170 # should be used. If the value is an enum, it should be stored as an int32
6171 # value using the google.protobuf.Int32Value type.
6172 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
6173 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006174 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
6175 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
6176 # For custom options, it should be the fully-qualified name. For example,
6177 # `&quot;google.api.http&quot;`.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006178 },
6179 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006180 &quot;number&quot;: 42, # The field number.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006181 },
6182 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006183 &quot;options&quot;: [ # The protocol buffer options.
Bu Sun Kim65020912020-05-20 12:08:20 -07006184 { # A protocol buffer option, which can be attached to a message, field,
6185 # enumeration, etc.
6186 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
6187 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
6188 # should be used. If the value is an enum, it should be stored as an int32
6189 # value using the google.protobuf.Int32Value type.
6190 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
6191 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006192 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
6193 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
6194 # For custom options, it should be the fully-qualified name. For example,
6195 # `&quot;google.api.http&quot;`.
Bu Sun Kim65020912020-05-20 12:08:20 -07006196 },
6197 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006198 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax.
6199 &quot;name&quot;: &quot;A String&quot;, # The fully qualified message name.
Bu Sun Kim65020912020-05-20 12:08:20 -07006200 },
6201 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006202 &quot;name&quot;: &quot;A String&quot;, # The service name, which is a DNS-like logical identifier for the
6203 # service, such as `calendar.googleapis.com`. The service name
6204 # typically goes through DNS verification to make sure the owner
6205 # of the service also owns the DNS name.
6206 &quot;sourceInfo&quot;: { # Source information used to create a Service Config # Output only. The source information for this configuration if available.
6207 &quot;sourceFiles&quot;: [ # All files used during config generation.
6208 {
6209 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Bu Sun Kim65020912020-05-20 12:08:20 -07006210 },
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006211 ],
6212 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006213 &quot;billing&quot;: { # Billing related configuration of the service. # Billing configuration.
6214 #
6215 # The following example shows how to configure monitored resources and metrics
6216 # for billing, `consumer_destinations` is the only supported destination and
6217 # the monitored resources need at least one label key
6218 # `cloud.googleapis.com/location` to indicate the location of the billing
6219 # usage, using different monitored resources between monitoring and billing is
6220 # recommended so they can be evolved independently:
6221 #
6222 #
6223 # monitored_resources:
6224 # - type: library.googleapis.com/billing_branch
6225 # labels:
6226 # - key: cloud.googleapis.com/location
6227 # description: |
6228 # Predefined label to support billing location restriction.
6229 # - key: city
6230 # description: |
6231 # Custom label to define the city where the library branch is located
6232 # in.
6233 # - key: name
6234 # description: Custom label to define the name of the library branch.
6235 # metrics:
6236 # - name: library.googleapis.com/book/borrowed_count
6237 # metric_kind: DELTA
6238 # value_type: INT64
6239 # unit: &quot;1&quot;
6240 # billing:
6241 # consumer_destinations:
6242 # - monitored_resource: library.googleapis.com/billing_branch
6243 # metrics:
6244 # - library.googleapis.com/book/borrowed_count
6245 &quot;consumerDestinations&quot;: [ # Billing configurations for sending metrics to the consumer project.
6246 # There can be multiple consumer destinations per service, each one must have
6247 # a different monitored resource type. A metric can be used in at most
6248 # one consumer destination.
6249 { # Configuration of a specific billing destination (Currently only support
6250 # bill against consumer project).
6251 &quot;metrics&quot;: [ # Names of the metrics to report to this billing destination.
6252 # Each name must be defined in Service.metrics section.
6253 &quot;A String&quot;,
6254 ],
6255 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in
6256 # Service.monitored_resources section.
6257 },
6258 ],
6259 },
6260 &quot;monitoring&quot;: { # Monitoring configuration of the service. # Monitoring configuration.
6261 #
6262 # The example below shows how to configure monitored resources and metrics
6263 # for monitoring. In the example, a monitored resource and two metrics are
6264 # defined. The `library.googleapis.com/book/returned_count` metric is sent
6265 # to both producer and consumer projects, whereas the
6266 # `library.googleapis.com/book/num_overdue` metric is only sent to the
6267 # consumer project.
6268 #
6269 # monitored_resources:
6270 # - type: library.googleapis.com/Branch
6271 # display_name: &quot;Library Branch&quot;
6272 # description: &quot;A branch of a library.&quot;
6273 # launch_stage: GA
6274 # labels:
6275 # - key: resource_container
6276 # description: &quot;The Cloud container (ie. project id) for the Branch.&quot;
6277 # - key: location
6278 # description: &quot;The location of the library branch.&quot;
6279 # - key: branch_id
6280 # description: &quot;The id of the branch.&quot;
6281 # metrics:
6282 # - name: library.googleapis.com/book/returned_count
6283 # display_name: &quot;Books Returned&quot;
6284 # description: &quot;The count of books that have been returned.&quot;
6285 # launch_stage: GA
6286 # metric_kind: DELTA
6287 # value_type: INT64
6288 # unit: &quot;1&quot;
6289 # labels:
6290 # - key: customer_id
6291 # description: &quot;The id of the customer.&quot;
6292 # - name: library.googleapis.com/book/num_overdue
6293 # display_name: &quot;Books Overdue&quot;
6294 # description: &quot;The current number of overdue books.&quot;
6295 # launch_stage: GA
6296 # metric_kind: GAUGE
6297 # value_type: INT64
6298 # unit: &quot;1&quot;
6299 # labels:
6300 # - key: customer_id
6301 # description: &quot;The id of the customer.&quot;
6302 # monitoring:
6303 # producer_destinations:
6304 # - monitored_resource: library.googleapis.com/Branch
6305 # metrics:
6306 # - library.googleapis.com/book/returned_count
6307 # consumer_destinations:
6308 # - monitored_resource: library.googleapis.com/Branch
6309 # metrics:
6310 # - library.googleapis.com/book/returned_count
6311 # - library.googleapis.com/book/num_overdue
6312 &quot;producerDestinations&quot;: [ # Monitoring configurations for sending metrics to the producer project.
6313 # There can be multiple producer destinations. A monitored resource type may
6314 # appear in multiple monitoring destinations if different aggregations are
6315 # needed for different sets of metrics associated with that monitored
6316 # resource type. A monitored resource and metric pair may only be used once
6317 # in the Monitoring configuration.
6318 { # Configuration of a specific monitoring destination (the producer project
6319 # or the consumer project).
6320 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in
6321 # Service.monitored_resources section.
6322 &quot;metrics&quot;: [ # Types of the metrics to report to this monitoring destination.
6323 # Each type must be defined in Service.metrics section.
6324 &quot;A String&quot;,
6325 ],
6326 },
6327 ],
6328 &quot;consumerDestinations&quot;: [ # Monitoring configurations for sending metrics to the consumer project.
6329 # There can be multiple consumer destinations. A monitored resource type may
6330 # appear in multiple monitoring destinations if different aggregations are
6331 # needed for different sets of metrics associated with that monitored
6332 # resource type. A monitored resource and metric pair may only be used once
6333 # in the Monitoring configuration.
6334 { # Configuration of a specific monitoring destination (the producer project
6335 # or the consumer project).
6336 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in
6337 # Service.monitored_resources section.
6338 &quot;metrics&quot;: [ # Types of the metrics to report to this monitoring destination.
6339 # Each type must be defined in Service.metrics section.
6340 &quot;A String&quot;,
6341 ],
6342 },
6343 ],
6344 },
6345 &quot;logging&quot;: { # Logging configuration of the service. # Logging configuration.
6346 #
6347 # The following example shows how to configure logs to be sent to the
6348 # producer and consumer projects. In the example, the `activity_history`
6349 # log is sent to both the producer and consumer projects, whereas the
6350 # `purchase_history` log is only sent to the producer project.
6351 #
6352 # monitored_resources:
6353 # - type: library.googleapis.com/branch
6354 # labels:
6355 # - key: /city
6356 # description: The city where the library branch is located in.
6357 # - key: /name
6358 # description: The name of the branch.
6359 # logs:
6360 # - name: activity_history
6361 # labels:
6362 # - key: /customer_id
6363 # - name: purchase_history
6364 # logging:
6365 # producer_destinations:
6366 # - monitored_resource: library.googleapis.com/branch
6367 # logs:
6368 # - activity_history
6369 # - purchase_history
6370 # consumer_destinations:
6371 # - monitored_resource: library.googleapis.com/branch
6372 # logs:
6373 # - activity_history
6374 &quot;producerDestinations&quot;: [ # Logging configurations for sending logs to the producer project.
6375 # There can be multiple producer destinations, each one must have a
6376 # different monitored resource type. A log can be used in at most
6377 # one producer destination.
6378 { # Configuration of a specific logging destination (the producer project
6379 # or the consumer project).
6380 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in the
6381 # Service.monitored_resources section.
6382 &quot;logs&quot;: [ # Names of the logs to be sent to this destination. Each name must
6383 # be defined in the Service.logs section. If the log name is
6384 # not a domain scoped name, it will be automatically prefixed with
6385 # the service name followed by &quot;/&quot;.
6386 &quot;A String&quot;,
6387 ],
6388 },
6389 ],
6390 &quot;consumerDestinations&quot;: [ # Logging configurations for sending logs to the consumer project.
6391 # There can be multiple consumer destinations, each one must have a
6392 # different monitored resource type. A log can be used in at most
6393 # one consumer destination.
6394 { # Configuration of a specific logging destination (the producer project
6395 # or the consumer project).
6396 &quot;monitoredResource&quot;: &quot;A String&quot;, # The monitored resource type. The type must be defined in the
6397 # Service.monitored_resources section.
6398 &quot;logs&quot;: [ # Names of the logs to be sent to this destination. Each name must
6399 # be defined in the Service.logs section. If the log name is
6400 # not a domain scoped name, it will be automatically prefixed with
6401 # the service name followed by &quot;/&quot;.
6402 &quot;A String&quot;,
6403 ],
6404 },
6405 ],
6406 },
6407 &quot;control&quot;: { # Selects and configures the service controller used by the service. The # Configuration for the service control plane.
6408 # service controller handles features like abuse, quota, billing, logging,
6409 # monitoring, etc.
6410 &quot;environment&quot;: &quot;A String&quot;, # The service control environment to use. If empty, no control plane
6411 # feature (like quota and billing) will be enabled.
6412 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006413 &quot;usage&quot;: { # Configuration controlling usage of a service. # Configuration controlling usage of this service.
6414 &quot;requirements&quot;: [ # Requirements that must be satisfied before a consumer project can use the
6415 # service. Each requirement is of the form &lt;service.name&gt;/&lt;requirement-id&gt;;
6416 # for example &#x27;serviceusage.googleapis.com/billing-enabled&#x27;.
6417 &quot;A String&quot;,
6418 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006419 &quot;serviceIdentity&quot;: { # The per-product per-project service identity for a service. # The configuration of a per-product per-project service identity.
6420 #
6421 #
6422 # Use this field to configure per-product per-project service identity.
6423 # Example of a service identity configuration.
6424 #
6425 # usage:
6426 # service_identity:
6427 # - service_account_parent: &quot;projects/123456789&quot;
6428 # display_name: &quot;Cloud XXX Service Agent&quot;
6429 # description: &quot;Used as the identity of Cloud XXX to access resources&quot;
6430 &quot;serviceAccountParent&quot;: &quot;A String&quot;, # A service account project that hosts the service accounts.
6431 #
6432 # An example name would be:
6433 # `projects/123456789`
6434 &quot;description&quot;: &quot;A String&quot;, # Optional. A user-specified opaque description of the service account.
6435 # Must be less than or equal to 256 UTF-8 bytes.
6436 &quot;displayName&quot;: &quot;A String&quot;, # Optional. A user-specified name for the service account.
6437 # Must be less than or equal to 100 UTF-8 bytes.
6438 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006439 &quot;rules&quot;: [ # A list of usage rules that apply to individual API methods.
6440 #
6441 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
6442 { # Usage configuration rules for the service.
6443 #
6444 # NOTE: Under development.
6445 #
6446 #
6447 # Use this rule to configure unregistered calls for the service. Unregistered
6448 # calls are calls that do not contain consumer project identity.
6449 # (Example: calls that do not contain an API key).
6450 # By default, API methods do not allow unregistered calls, and each method call
6451 # must be identified by a consumer project identity. Use this rule to
6452 # allow/disallow unregistered calls.
6453 #
6454 # Example of an API that wants to allow unregistered calls for entire service.
6455 #
6456 # usage:
6457 # rules:
6458 # - selector: &quot;*&quot;
6459 # allow_unregistered_calls: true
6460 #
6461 # Example of a method that wants to allow unregistered calls.
6462 #
6463 # usage:
6464 # rules:
6465 # - selector: &quot;google.example.library.v1.LibraryService.CreateBook&quot;
6466 # allow_unregistered_calls: true
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006467 &quot;skipServiceControl&quot;: True or False, # If true, the selected method should skip service control and the control
6468 # plane features, such as quota and billing, will not be available.
6469 # This flag is used by Google Cloud Endpoints to bypass checks for internal
6470 # methods, such as service health check methods.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006471 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies. Use &#x27;*&#x27; to indicate all
6472 # methods in all APIs.
6473 #
6474 # Refer to selector for syntax details.
6475 &quot;allowUnregisteredCalls&quot;: True or False, # If true, the selected method allows unregistered calls, e.g. calls
6476 # that don&#x27;t identify any user or application.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006477 },
6478 ],
6479 &quot;producerNotificationChannel&quot;: &quot;A String&quot;, # The full resource name of a channel used for sending notifications to the
6480 # service producer.
6481 #
6482 # Google Service Management currently only supports
6483 # [Google Cloud Pub/Sub](https://cloud.google.com/pubsub) as a notification
6484 # channel. To use Google Cloud Pub/Sub as the channel, this must be the name
6485 # of a Cloud Pub/Sub topic that uses the Cloud Pub/Sub topic name format
6486 # documented in https://cloud.google.com/pubsub/docs/overview.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006487 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006488 &quot;types&quot;: [ # A list of all proto message types included in this API service.
6489 # Types referenced directly or indirectly by the `apis` are
6490 # automatically included. Messages which are not referenced but
6491 # shall be included, such as types used by the `google.protobuf.Any` type,
6492 # should be listed here by name. Example:
6493 #
6494 # types:
6495 # - name: google.protobuf.Int32
6496 { # A protocol buffer message type.
6497 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # The source context.
6498 # protobuf element, like the file in which it is defined.
6499 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
6500 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
6501 },
6502 &quot;oneofs&quot;: [ # The list of types appearing in `oneof` definitions in this type.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006503 &quot;A String&quot;,
6504 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006505 &quot;fields&quot;: [ # The list of fields.
6506 { # A single field of a message type.
6507 &quot;oneofIndex&quot;: 42, # The index of the field type in `Type.oneofs`, for message or enumeration
6508 # types. The first type has index 1; zero means the type is not in the list.
6509 &quot;name&quot;: &quot;A String&quot;, # The field name.
6510 &quot;defaultValue&quot;: &quot;A String&quot;, # The string value of the default value of this field. Proto2 syntax only.
6511 &quot;packed&quot;: True or False, # Whether to use alternative packed wire representation.
6512 &quot;typeUrl&quot;: &quot;A String&quot;, # The field type URL, without the scheme, for message or enumeration
6513 # types. Example: `&quot;type.googleapis.com/google.protobuf.Timestamp&quot;`.
6514 &quot;cardinality&quot;: &quot;A String&quot;, # The field cardinality.
6515 &quot;jsonName&quot;: &quot;A String&quot;, # The field JSON name.
6516 &quot;kind&quot;: &quot;A String&quot;, # The field type.
6517 &quot;options&quot;: [ # The protocol buffer options.
6518 { # A protocol buffer option, which can be attached to a message, field,
6519 # enumeration, etc.
6520 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
6521 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
6522 # should be used. If the value is an enum, it should be stored as an int32
6523 # value using the google.protobuf.Int32Value type.
6524 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
6525 },
6526 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
6527 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
6528 # For custom options, it should be the fully-qualified name. For example,
6529 # `&quot;google.api.http&quot;`.
6530 },
6531 ],
6532 &quot;number&quot;: 42, # The field number.
6533 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006534 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006535 &quot;options&quot;: [ # The protocol buffer options.
6536 { # A protocol buffer option, which can be attached to a message, field,
6537 # enumeration, etc.
6538 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
6539 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
6540 # should be used. If the value is an enum, it should be stored as an int32
6541 # value using the google.protobuf.Int32Value type.
6542 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
6543 },
6544 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
6545 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
6546 # For custom options, it should be the fully-qualified name. For example,
6547 # `&quot;google.api.http&quot;`.
6548 },
6549 ],
6550 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax.
6551 &quot;name&quot;: &quot;A String&quot;, # The fully qualified message name.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006552 },
6553 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07006554 &quot;http&quot;: { # Defines the HTTP configuration for an API service. It contains a list of # HTTP configuration.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006555 # HttpRule, each specifying the mapping of an RPC method
6556 # to one or more HTTP REST API methods.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006557 &quot;fullyDecodeReservedExpansion&quot;: True or False, # When set to true, URL path parameters will be fully URI-decoded except in
6558 # cases of single segment matches in reserved expansion, where &quot;%2F&quot; will be
6559 # left encoded.
6560 #
6561 # The default behavior is to not decode RFC 6570 reserved characters in multi
6562 # segment matches.
Bu Sun Kim65020912020-05-20 12:08:20 -07006563 &quot;rules&quot;: [ # A list of HTTP configuration rules that apply to individual API methods.
6564 #
6565 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006566 { # # gRPC Transcoding
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006567 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006568 # gRPC Transcoding is a feature for mapping between a gRPC method and one or
6569 # more HTTP REST endpoints. It allows developers to build a single API service
6570 # that supports both gRPC APIs and REST APIs. Many systems, including [Google
6571 # APIs](https://github.com/googleapis/googleapis),
6572 # [Cloud Endpoints](https://cloud.google.com/endpoints), [gRPC
6573 # Gateway](https://github.com/grpc-ecosystem/grpc-gateway),
6574 # and [Envoy](https://github.com/envoyproxy/envoy) proxy support this feature
6575 # and use it for large scale production services.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006576 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006577 # `HttpRule` defines the schema of the gRPC/REST mapping. The mapping specifies
6578 # how different portions of the gRPC request message are mapped to the URL
6579 # path, URL query parameters, and HTTP request body. It also controls how the
6580 # gRPC response message is mapped to the HTTP response body. `HttpRule` is
6581 # typically specified as an `google.api.http` annotation on the gRPC method.
6582 #
6583 # Each mapping specifies a URL path template and an HTTP method. The path
6584 # template may refer to one or more fields in the gRPC request message, as long
6585 # as each field is a non-repeated field with a primitive (non-message) type.
6586 # The path template controls how fields of the request message are mapped to
6587 # the URL path.
6588 #
6589 # Example:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006590 #
6591 # service Messaging {
6592 # rpc GetMessage(GetMessageRequest) returns (Message) {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006593 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07006594 # get: &quot;/v1/{name=messages/*}&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006595 # };
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006596 # }
6597 # }
6598 # message GetMessageRequest {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006599 # string name = 1; // Mapped to URL path.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006600 # }
6601 # message Message {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006602 # string text = 1; // The resource content.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006603 # }
6604 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006605 # This enables an HTTP REST to gRPC mapping as below:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006606 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006607 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006608 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -07006609 # `GET /v1/messages/123456` | `GetMessage(name: &quot;messages/123456&quot;)`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006610 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006611 # Any fields in the request message which are not bound by the path template
6612 # automatically become HTTP query parameters if there is no HTTP request body.
6613 # For example:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006614 #
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -04006615 # service Messaging {
6616 # rpc GetMessage(GetMessageRequest) returns (Message) {
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006617 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07006618 # get:&quot;/v1/messages/{message_id}&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006619 # };
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -04006620 # }
6621 # }
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006622 # message GetMessageRequest {
6623 # message SubMessage {
6624 # string subfield = 1;
6625 # }
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006626 # string message_id = 1; // Mapped to URL path.
6627 # int64 revision = 2; // Mapped to URL query parameter `revision`.
6628 # SubMessage sub = 3; // Mapped to URL query parameter `sub.subfield`.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006629 # }
6630 #
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006631 # This enables a HTTP JSON to RPC mapping as below:
6632 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006633 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006634 # -----|-----
Dan O'Mearadd494642020-05-01 07:42:23 -07006635 # `GET /v1/messages/123456?revision=2&amp;sub.subfield=foo` |
Bu Sun Kim65020912020-05-20 12:08:20 -07006636 # `GetMessage(message_id: &quot;123456&quot; revision: 2 sub: SubMessage(subfield:
6637 # &quot;foo&quot;))`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006638 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006639 # Note that fields which are mapped to URL query parameters must have a
6640 # primitive type or a repeated primitive type or a non-repeated message type.
6641 # In the case of a repeated type, the parameter can be repeated in the URL
Dan O'Mearadd494642020-05-01 07:42:23 -07006642 # as `...?param=A&amp;param=B`. In the case of a message type, each field of the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006643 # message is mapped to a separate parameter, such as
Dan O'Mearadd494642020-05-01 07:42:23 -07006644 # `...?foo.a=A&amp;foo.b=B&amp;foo.c=C`.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006645 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006646 # For HTTP methods that allow a request body, the `body` field
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006647 # specifies the mapping. Consider a REST update method on the
6648 # message resource collection:
6649 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006650 # service Messaging {
6651 # rpc UpdateMessage(UpdateMessageRequest) returns (Message) {
6652 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07006653 # patch: &quot;/v1/messages/{message_id}&quot;
6654 # body: &quot;message&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006655 # };
6656 # }
6657 # }
6658 # message UpdateMessageRequest {
6659 # string message_id = 1; // mapped to the URL
6660 # Message message = 2; // mapped to the body
6661 # }
6662 #
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006663 # The following HTTP JSON to RPC mapping is enabled, where the
6664 # representation of the JSON in the request body is determined by
6665 # protos JSON encoding:
6666 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006667 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006668 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -07006669 # `PATCH /v1/messages/123456 { &quot;text&quot;: &quot;Hi!&quot; }` | `UpdateMessage(message_id:
6670 # &quot;123456&quot; message { text: &quot;Hi!&quot; })`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006671 #
6672 # The special name `*` can be used in the body mapping to define that
6673 # every field not bound by the path template should be mapped to the
6674 # request body. This enables the following alternative definition of
6675 # the update method:
6676 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006677 # service Messaging {
6678 # rpc UpdateMessage(Message) returns (Message) {
6679 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07006680 # patch: &quot;/v1/messages/{message_id}&quot;
6681 # body: &quot;*&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006682 # };
6683 # }
6684 # }
6685 # message Message {
6686 # string message_id = 1;
6687 # string text = 2;
6688 # }
6689 #
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006690 #
6691 # The following HTTP JSON to RPC mapping is enabled:
6692 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006693 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006694 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -07006695 # `PATCH /v1/messages/123456 { &quot;text&quot;: &quot;Hi!&quot; }` | `UpdateMessage(message_id:
6696 # &quot;123456&quot; text: &quot;Hi!&quot;)`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006697 #
6698 # Note that when using `*` in the body mapping, it is not possible to
6699 # have HTTP parameters, as all fields not bound by the path end in
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006700 # the body. This makes this option more rarely used in practice when
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006701 # defining REST APIs. The common usage of `*` is in custom methods
Bu Sun Kim65020912020-05-20 12:08:20 -07006702 # which don&#x27;t use the URL at all for transferring data.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006703 #
6704 # It is possible to define multiple HTTP methods for one RPC by using
6705 # the `additional_bindings` option. Example:
6706 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006707 # service Messaging {
6708 # rpc GetMessage(GetMessageRequest) returns (Message) {
6709 # option (google.api.http) = {
Bu Sun Kim65020912020-05-20 12:08:20 -07006710 # get: &quot;/v1/messages/{message_id}&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006711 # additional_bindings {
Bu Sun Kim65020912020-05-20 12:08:20 -07006712 # get: &quot;/v1/users/{user_id}/messages/{message_id}&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006713 # }
6714 # };
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006715 # }
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08006716 # }
6717 # message GetMessageRequest {
6718 # string message_id = 1;
6719 # string user_id = 2;
6720 # }
6721 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006722 # This enables the following two alternative HTTP JSON to RPC mappings:
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006723 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006724 # HTTP | gRPC
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006725 # -----|-----
Bu Sun Kim65020912020-05-20 12:08:20 -07006726 # `GET /v1/messages/123456` | `GetMessage(message_id: &quot;123456&quot;)`
6727 # `GET /v1/users/me/messages/123456` | `GetMessage(user_id: &quot;me&quot; message_id:
6728 # &quot;123456&quot;)`
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006729 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006730 # ## Rules for HTTP mapping
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006731 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006732 # 1. Leaf request fields (recursive expansion nested messages in the request
6733 # message) are classified into three categories:
6734 # - Fields referred by the path template. They are passed via the URL path.
6735 # - Fields referred by the HttpRule.body. They are passed via the HTTP
6736 # request body.
6737 # - All other fields are passed via the URL query parameters, and the
6738 # parameter name is the field path in the request message. A repeated
6739 # field can be represented as multiple query parameters under the same
6740 # name.
Bu Sun Kim65020912020-05-20 12:08:20 -07006741 # 2. If HttpRule.body is &quot;*&quot;, there is no URL query parameter, all fields
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006742 # are passed via URL path and HTTP request body.
6743 # 3. If HttpRule.body is omitted, there is no HTTP request body, all
6744 # fields are passed via URL path and URL query parameters.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006745 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006746 # ### Path template syntax
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006747 #
Bu Sun Kim65020912020-05-20 12:08:20 -07006748 # Template = &quot;/&quot; Segments [ Verb ] ;
6749 # Segments = Segment { &quot;/&quot; Segment } ;
6750 # Segment = &quot;*&quot; | &quot;**&quot; | LITERAL | Variable ;
6751 # Variable = &quot;{&quot; FieldPath [ &quot;=&quot; Segments ] &quot;}&quot; ;
6752 # FieldPath = IDENT { &quot;.&quot; IDENT } ;
6753 # Verb = &quot;:&quot; LITERAL ;
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006754 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006755 # The syntax `*` matches a single URL path segment. The syntax `**` matches
6756 # zero or more URL path segments, which must be the last part of the URL path
6757 # except the `Verb`.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006758 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006759 # The syntax `Variable` matches part of the URL path as specified by its
6760 # template. A variable template must not contain other variables. If a variable
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006761 # matches a single path segment, its template may be omitted, e.g. `{var}`
6762 # is equivalent to `{var=*}`.
6763 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006764 # The syntax `LITERAL` matches literal text in the URL path. If the `LITERAL`
6765 # contains any reserved character, such characters should be percent-encoded
6766 # before the matching.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07006767 #
Bu Sun Kim65020912020-05-20 12:08:20 -07006768 # If a variable contains exactly one path segment, such as `&quot;{var}&quot;` or
6769 # `&quot;{var=*}&quot;`, when such a variable is expanded into a URL path on the client
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006770 # side, all characters except `[-_.~0-9a-zA-Z]` are percent-encoded. The
6771 # server side does the reverse decoding. Such variables show up in the
6772 # [Discovery
6773 # Document](https://developers.google.com/discovery/v1/reference/apis) as
6774 # `{var}`.
6775 #
Bu Sun Kim65020912020-05-20 12:08:20 -07006776 # If a variable contains multiple path segments, such as `&quot;{var=foo/*}&quot;`
6777 # or `&quot;{var=**}&quot;`, when such a variable is expanded into a URL path on the
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006778 # client side, all characters except `[-_.~/0-9a-zA-Z]` are percent-encoded.
Bu Sun Kim65020912020-05-20 12:08:20 -07006779 # The server side does the reverse decoding, except &quot;%2F&quot; and &quot;%2f&quot; are left
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006780 # unchanged. Such variables show up in the
6781 # [Discovery
6782 # Document](https://developers.google.com/discovery/v1/reference/apis) as
6783 # `{+var}`.
6784 #
6785 # ## Using gRPC API Service Configuration
6786 #
6787 # gRPC API Service Configuration (service config) is a configuration language
6788 # for configuring a gRPC service to become a user-facing product. The
6789 # service config is simply the YAML representation of the `google.api.Service`
6790 # proto message.
6791 #
6792 # As an alternative to annotating your proto file, you can configure gRPC
6793 # transcoding in your service config YAML files. You do this by specifying a
6794 # `HttpRule` that maps the gRPC method to a REST endpoint, achieving the same
6795 # effect as the proto annotation. This can be particularly useful if you
6796 # have a proto that is reused in multiple services. Note that any transcoding
6797 # specified in the service config will override any matching transcoding
6798 # configuration in the proto.
6799 #
6800 # Example:
6801 #
6802 # http:
6803 # rules:
6804 # # Selects a gRPC method and applies HttpRule to it.
6805 # - selector: example.v1.Messaging.GetMessage
6806 # get: /v1/messages/{message_id}/{sub.subfield}
6807 #
6808 # ## Special notes
6809 #
6810 # When gRPC Transcoding is used to map a gRPC to JSON REST endpoints, the
6811 # proto to JSON conversion must follow the [proto3
6812 # specification](https://developers.google.com/protocol-buffers/docs/proto3#json).
6813 #
6814 # While the single segment variable follows the semantics of
6815 # [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.2 Simple String
6816 # Expansion, the multi segment variable **does not** follow RFC 6570 Section
6817 # 3.2.3 Reserved Expansion. The reason is that the Reserved Expansion
6818 # does not expand special characters like `?` and `#`, which would lead
6819 # to invalid URLs. As the result, gRPC Transcoding uses a custom encoding
6820 # for multi segment variables.
6821 #
6822 # The path variables **must not** refer to any repeated or mapped field,
6823 # because client libraries are not capable of handling such variable expansion.
6824 #
Bu Sun Kim65020912020-05-20 12:08:20 -07006825 # The path variables **must not** capture the leading &quot;/&quot; character. The reason
6826 # is that the most common use case &quot;{var}&quot; does not capture the leading &quot;/&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07006827 # character. For consistency, all path variables must share the same behavior.
6828 #
6829 # Repeated message fields must not be mapped to URL query parameters, because
6830 # no client library can support such complicated mapping.
6831 #
6832 # If an API needs to use a JSON array for request or response body, it can map
6833 # the request or response body to a repeated field. However, some gRPC
6834 # Transcoding implementations may not support this feature.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006835 &quot;put&quot;: &quot;A String&quot;, # Maps to HTTP PUT. Used for replacing a resource.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006836 &quot;selector&quot;: &quot;A String&quot;, # Selects a method to which this rule applies.
6837 #
6838 # Refer to selector for syntax details.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006839 &quot;post&quot;: &quot;A String&quot;, # Maps to HTTP POST. Used for creating a resource or performing an action.
6840 &quot;responseBody&quot;: &quot;A String&quot;, # Optional. The name of the response field whose value is mapped to the HTTP
6841 # response body. When omitted, the entire response message will be used
6842 # as the HTTP response body.
6843 #
6844 # NOTE: The referred field must be present at the top-level of the response
6845 # message type.
6846 &quot;body&quot;: &quot;A String&quot;, # The name of the request field whose value is mapped to the HTTP request
6847 # body, or `*` for mapping all request fields not captured by the path
6848 # pattern to the HTTP body, or omitted for not having any HTTP request body.
6849 #
6850 # NOTE: the referred field must be present at the top-level of the request
6851 # message type.
6852 &quot;patch&quot;: &quot;A String&quot;, # Maps to HTTP PATCH. Used for updating a resource.
6853 &quot;additionalBindings&quot;: [ # Additional HTTP bindings for the selector. Nested bindings must
6854 # not contain an `additional_bindings` field themselves (that is,
6855 # the nesting may only be one level deep).
6856 # Object with schema name: HttpRule
6857 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006858 &quot;custom&quot;: { # A custom pattern is used for defining custom HTTP verb. # The custom pattern is used for specifying an HTTP method that is not
6859 # included in the `pattern` field, such as HEAD, or &quot;*&quot; to leave the
6860 # HTTP method unspecified for this rule. The wild-card rule is useful
6861 # for services that provide content to Web (HTML) clients.
6862 &quot;path&quot;: &quot;A String&quot;, # The path matched by this custom verb.
6863 &quot;kind&quot;: &quot;A String&quot;, # The name of this custom HTTP verb.
6864 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006865 &quot;allowHalfDuplex&quot;: True or False, # When this flag is set to true, HTTP requests will be allowed to invoke a
6866 # half-duplex streaming method.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006867 &quot;delete&quot;: &quot;A String&quot;, # Maps to HTTP DELETE. Used for deleting a resource.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006868 &quot;get&quot;: &quot;A String&quot;, # Maps to HTTP GET. Used for listing and getting information about
6869 # resources.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006870 },
6871 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006872 },
6873 &quot;logs&quot;: [ # Defines the logs used by this service.
6874 { # A description of a log type. Example in YAML format:
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006875 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006876 # - name: library.googleapis.com/activity_history
6877 # description: The history of borrowing and returning library items.
6878 # display_name: Activity
6879 # labels:
6880 # - key: /customer_id
6881 # description: Identifier of a library customer
6882 &quot;description&quot;: &quot;A String&quot;, # A human-readable description of this log. This information appears in
6883 # the documentation and can contain details.
6884 &quot;labels&quot;: [ # The set of labels that are available to describe a specific log entry.
6885 # Runtime requests that contain labels not specified here are
6886 # considered invalid.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006887 { # A description of a label.
6888 &quot;valueType&quot;: &quot;A String&quot;, # The type of data that can be assigned to the label.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006889 &quot;description&quot;: &quot;A String&quot;, # A human-readable description for the label.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006890 &quot;key&quot;: &quot;A String&quot;, # The label key.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006891 },
6892 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006893 &quot;displayName&quot;: &quot;A String&quot;, # The human-readable name for this log. This information appears on
6894 # the user interface and should be concise.
6895 &quot;name&quot;: &quot;A String&quot;, # The name of the log. It must be less than 512 characters long and can
6896 # include the following characters: upper- and lower-case alphanumeric
6897 # characters [A-Za-z0-9], and punctuation characters including
6898 # slash, underscore, hyphen, period [/_-.].
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07006899 },
6900 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07006901 &quot;metrics&quot;: [ # Defines the metrics used by this service.
6902 { # Defines a metric type and its schema. Once a metric descriptor is created,
6903 # deleting or altering it stops data collection and makes the metric type&#x27;s
6904 # existing data unusable.
6905 #
6906 # The following are specific rules for service defined Monitoring metric
6907 # descriptors:
6908 #
6909 # * `type`, `metric_kind`, `value_type`, `description`, and `display_name`
6910 # fields are all required. The `unit` field must be specified
6911 # if the `value_type` is any of DOUBLE, INT64, DISTRIBUTION.
6912 # * Maximum of default 500 metric descriptors per service is allowed.
6913 # * Maximum of default 10 labels per metric descriptor is allowed.
6914 #
6915 # The default maximum limit can be overridden. Please follow
6916 # https://cloud.google.com/monitoring/quotas
6917 &quot;unit&quot;: &quot;A String&quot;, # The units in which the metric value is reported. It is only applicable
6918 # if the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The `unit`
6919 # defines the representation of the stored metric values.
6920 #
6921 # Different systems may scale the values to be more easily displayed (so a
6922 # value of `0.02KBy` _might_ be displayed as `20By`, and a value of
6923 # `3523KBy` _might_ be displayed as `3.5MBy`). However, if the `unit` is
6924 # `KBy`, then the value of the metric is always in thousands of bytes, no
6925 # matter how it may be displayed..
6926 #
6927 # If you want a custom metric to record the exact number of CPU-seconds used
6928 # by a job, you can create an `INT64 CUMULATIVE` metric whose `unit` is
6929 # `s{CPU}` (or equivalently `1s{CPU}` or just `s`). If the job uses 12,005
6930 # CPU-seconds, then the value is written as `12005`.
6931 #
6932 # Alternatively, if you want a custom metric to record data in a more
6933 # granular way, you can create a `DOUBLE CUMULATIVE` metric whose `unit` is
6934 # `ks{CPU}`, and then write the value `12.005` (which is `12005/1000`),
6935 # or use `Kis{CPU}` and write `11.723` (which is `12005/1024`).
6936 #
6937 # The supported units are a subset of [The Unified Code for Units of
6938 # Measure](http://unitsofmeasure.org/ucum.html) standard:
6939 #
6940 # **Basic units (UNIT)**
6941 #
6942 # * `bit` bit
6943 # * `By` byte
6944 # * `s` second
6945 # * `min` minute
6946 # * `h` hour
6947 # * `d` day
6948 # * `1` dimensionless
6949 #
6950 # **Prefixes (PREFIX)**
6951 #
6952 # * `k` kilo (10^3)
6953 # * `M` mega (10^6)
6954 # * `G` giga (10^9)
6955 # * `T` tera (10^12)
6956 # * `P` peta (10^15)
6957 # * `E` exa (10^18)
6958 # * `Z` zetta (10^21)
6959 # * `Y` yotta (10^24)
6960 #
6961 # * `m` milli (10^-3)
6962 # * `u` micro (10^-6)
6963 # * `n` nano (10^-9)
6964 # * `p` pico (10^-12)
6965 # * `f` femto (10^-15)
6966 # * `a` atto (10^-18)
6967 # * `z` zepto (10^-21)
6968 # * `y` yocto (10^-24)
6969 #
6970 # * `Ki` kibi (2^10)
6971 # * `Mi` mebi (2^20)
6972 # * `Gi` gibi (2^30)
6973 # * `Ti` tebi (2^40)
6974 # * `Pi` pebi (2^50)
6975 #
6976 # **Grammar**
6977 #
6978 # The grammar also includes these connectors:
6979 #
6980 # * `/` division or ratio (as an infix operator). For examples,
6981 # `kBy/{email}` or `MiBy/10ms` (although you should almost never
6982 # have `/s` in a metric `unit`; rates should always be computed at
6983 # query time from the underlying cumulative or delta value).
6984 # * `.` multiplication or composition (as an infix operator). For
6985 # examples, `GBy.d` or `k{watt}.h`.
6986 #
6987 # The grammar for a unit is as follows:
6988 #
6989 # Expression = Component { &quot;.&quot; Component } { &quot;/&quot; Component } ;
6990 #
6991 # Component = ( [ PREFIX ] UNIT | &quot;%&quot; ) [ Annotation ]
6992 # | Annotation
6993 # | &quot;1&quot;
6994 # ;
6995 #
6996 # Annotation = &quot;{&quot; NAME &quot;}&quot; ;
6997 #
6998 # Notes:
6999 #
7000 # * `Annotation` is just a comment if it follows a `UNIT`. If the annotation
7001 # is used alone, then the unit is equivalent to `1`. For examples,
7002 # `{request}/s == 1/s`, `By{transmitted}/s == By/s`.
7003 # * `NAME` is a sequence of non-blank printable ASCII characters not
7004 # containing `{` or `}`.
7005 # * `1` represents a unitary [dimensionless
7006 # unit](https://en.wikipedia.org/wiki/Dimensionless_quantity) of 1, such
7007 # as in `1/s`. It is typically used when none of the basic units are
7008 # appropriate. For example, &quot;new users per day&quot; can be represented as
7009 # `1/d` or `{new-users}/d` (and a metric value `5` would mean &quot;5 new
7010 # users). Alternatively, &quot;thousands of page views per day&quot; would be
7011 # represented as `1000/d` or `k1/d` or `k{page_views}/d` (and a metric
7012 # value of `5.3` would mean &quot;5300 page views per day&quot;).
7013 # * `%` represents dimensionless value of 1/100, and annotates values giving
7014 # a percentage (so the metric values are typically in the range of 0..100,
7015 # and a metric value `3` means &quot;3 percent&quot;).
7016 # * `10^2.%` indicates a metric contains a ratio, typically in the range
7017 # 0..1, that will be multiplied by 100 and displayed as a percentage
7018 # (so a metric value `0.03` means &quot;3 percent&quot;).
7019 &quot;displayName&quot;: &quot;A String&quot;, # A concise name for the metric, which can be displayed in user interfaces.
7020 # Use sentence case without an ending period, for example &quot;Request count&quot;.
7021 # This field is optional but it is recommended to be set for any metrics
7022 # associated with user-visible concepts, such as Quota.
7023 &quot;monitoredResourceTypes&quot;: [ # Read-only. If present, then a time
7024 # series, which is identified partially by
7025 # a metric type and a MonitoredResourceDescriptor, that is associated
7026 # with this metric type can only be associated with one of the monitored
7027 # resource types listed here.
7028 &quot;A String&quot;,
7029 ],
7030 &quot;metadata&quot;: { # Additional annotations that can be used to guide the usage of a metric. # Optional. Metadata which can be used to guide usage of the metric.
7031 &quot;samplePeriod&quot;: &quot;A String&quot;, # The sampling period of metric data points. For metrics which are written
7032 # periodically, consecutive data points are stored at this time interval,
7033 # excluding data loss due to errors. Metrics with a higher granularity have
7034 # a smaller sampling period.
7035 &quot;ingestDelay&quot;: &quot;A String&quot;, # The delay of data points caused by ingestion. Data points older than this
7036 # age are guaranteed to be ingested and available to be read, excluding
7037 # data loss due to errors.
7038 &quot;launchStage&quot;: &quot;A String&quot;, # Deprecated. Must use the MetricDescriptor.launch_stage instead.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07007039 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007040 &quot;name&quot;: &quot;A String&quot;, # The resource name of the metric descriptor.
7041 &quot;valueType&quot;: &quot;A String&quot;, # Whether the measurement is an integer, a floating-point number, etc.
7042 # Some combinations of `metric_kind` and `value_type` might not be supported.
7043 &quot;launchStage&quot;: &quot;A String&quot;, # Optional. The launch stage of the metric definition.
7044 &quot;type&quot;: &quot;A String&quot;, # The metric type, including its DNS name prefix. The type is not
7045 # URL-encoded.
7046 #
7047 # All service defined metrics must be prefixed with the service name, in the
7048 # format of `{service name}/{relative metric name}`, such as
7049 # `cloudsql.googleapis.com/database/cpu/utilization`. The relative metric
7050 # name must follow:
7051 #
7052 # * Only upper and lower-case letters, digits, &#x27;/&#x27; and underscores &#x27;_&#x27; are
7053 # allowed.
7054 # * The maximum number of characters allowed for the relative_metric_name is
7055 # 100.
7056 #
7057 # All user-defined metric types have the DNS name
7058 # `custom.googleapis.com`, `external.googleapis.com`, or
7059 # `logging.googleapis.com/user/`.
7060 #
7061 # Metric types should use a natural hierarchical grouping. For example:
7062 #
7063 # &quot;custom.googleapis.com/invoice/paid/amount&quot;
7064 # &quot;external.googleapis.com/prometheus/up&quot;
7065 # &quot;appengine.googleapis.com/http/server/response_latencies&quot;
7066 &quot;description&quot;: &quot;A String&quot;, # A detailed description of the metric, which can be used in documentation.
7067 &quot;labels&quot;: [ # The set of labels that can be used to describe a specific
7068 # instance of this metric type.
7069 #
7070 # The label key name must follow:
7071 #
7072 # * Only upper and lower-case letters, digits and underscores (_) are
7073 # allowed.
7074 # * Label name must start with a letter or digit.
7075 # * The maximum length of a label name is 100 characters.
7076 #
7077 # For example, the
7078 # `appengine.googleapis.com/http/server/response_latencies` metric
7079 # type has a label for the HTTP response code, `response_code`, so
7080 # you can look at latencies for successful responses or just
7081 # for responses that failed.
7082 { # A description of a label.
7083 &quot;valueType&quot;: &quot;A String&quot;, # The type of data that can be assigned to the label.
7084 &quot;description&quot;: &quot;A String&quot;, # A human-readable description for the label.
7085 &quot;key&quot;: &quot;A String&quot;, # The label key.
7086 },
7087 ],
7088 &quot;metricKind&quot;: &quot;A String&quot;, # Whether the metric records instantaneous values, changes to a value, etc.
7089 # Some combinations of `metric_kind` and `value_type` might not be supported.
7090 },
7091 ],
7092 &quot;documentation&quot;: { # `Documentation` provides the information for describing a service. # Additional API documentation.
Bu Sun Kim65020912020-05-20 12:08:20 -07007093 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007094 # Example:
7095 # &lt;pre&gt;&lt;code&gt;documentation:
7096 # summary: &gt;
7097 # The Google Calendar API gives access
7098 # to most calendar features.
7099 # pages:
7100 # - name: Overview
7101 # content: &amp;#40;== include google/foo/overview.md ==&amp;#41;
7102 # - name: Tutorial
7103 # content: &amp;#40;== include google/foo/tutorial.md ==&amp;#41;
7104 # subpages;
7105 # - name: Java
7106 # content: &amp;#40;== include google/foo/tutorial_java.md ==&amp;#41;
7107 # rules:
7108 # - selector: google.calendar.Calendar.Get
7109 # description: &gt;
7110 # ...
7111 # - selector: google.calendar.Calendar.Put
7112 # description: &gt;
7113 # ...
7114 # &lt;/code&gt;&lt;/pre&gt;
7115 # Documentation is provided in markdown syntax. In addition to
7116 # standard markdown features, definition lists, tables and fenced
7117 # code blocks are supported. Section headers can be provided and are
7118 # interpreted relative to the section nesting of the context where
7119 # a documentation fragment is embedded.
7120 #
7121 # Documentation from the IDL is merged with documentation defined
7122 # via the config at normalization time, where documentation provided
7123 # by config rules overrides IDL provided.
7124 #
7125 # A number of constructs specific to the API platform are supported
7126 # in documentation text.
7127 #
7128 # In order to reference a proto element, the following
7129 # notation can be used:
7130 # &lt;pre&gt;&lt;code&gt;&amp;#91;fully.qualified.proto.name]&amp;#91;]&lt;/code&gt;&lt;/pre&gt;
7131 # To override the display text used for the link, this can be used:
7132 # &lt;pre&gt;&lt;code&gt;&amp;#91;display text]&amp;#91;fully.qualified.proto.name]&lt;/code&gt;&lt;/pre&gt;
7133 # Text can be excluded from doc using the following notation:
7134 # &lt;pre&gt;&lt;code&gt;&amp;#40;-- internal comment --&amp;#41;&lt;/code&gt;&lt;/pre&gt;
7135 #
7136 # A few directives are available in documentation. Note that
7137 # directives must appear on a single line to be properly
7138 # identified. The `include` directive includes a markdown file from
7139 # an external source:
7140 # &lt;pre&gt;&lt;code&gt;&amp;#40;== include path/to/file ==&amp;#41;&lt;/code&gt;&lt;/pre&gt;
7141 # The `resource_for` directive marks a message to be the resource of
7142 # a collection in REST view. If it is not specified, tools attempt
7143 # to infer the resource from the operations in a collection:
7144 # &lt;pre&gt;&lt;code&gt;&amp;#40;== resource_for v1.shelves.books ==&amp;#41;&lt;/code&gt;&lt;/pre&gt;
7145 # The directive `suppress_warning` does not directly affect documentation
7146 # and is documented together with service config validation.
7147 &quot;serviceRootUrl&quot;: &quot;A String&quot;, # Specifies the service root url if the default one (the service name
7148 # from the yaml file) is not suitable. This can be seen in any fully
7149 # specified service urls as well as sections that show a base that other
7150 # urls are relative to.
7151 &quot;overview&quot;: &quot;A String&quot;, # Declares a single overview page. For example:
7152 # &lt;pre&gt;&lt;code&gt;documentation:
7153 # summary: ...
7154 # overview: &amp;#40;== include overview.md ==&amp;#41;
7155 # &lt;/code&gt;&lt;/pre&gt;
7156 # This is a shortcut for the following declaration (using pages style):
7157 # &lt;pre&gt;&lt;code&gt;documentation:
7158 # summary: ...
7159 # pages:
7160 # - name: Overview
7161 # content: &amp;#40;== include overview.md ==&amp;#41;
7162 # &lt;/code&gt;&lt;/pre&gt;
7163 # Note: you cannot specify both `overview` field and `pages` field.
7164 &quot;documentationRootUrl&quot;: &quot;A String&quot;, # The URL to the root of documentation.
7165 &quot;rules&quot;: [ # A list of documentation rules that apply to individual API elements.
Bu Sun Kim65020912020-05-20 12:08:20 -07007166 #
7167 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007168 { # A documentation rule provides information about individual API elements.
7169 &quot;deprecationDescription&quot;: &quot;A String&quot;, # Deprecation description of the selected element(s). It can be provided if
7170 # an element is marked as `deprecated`.
7171 &quot;description&quot;: &quot;A String&quot;, # Description of the selected API(s).
7172 &quot;selector&quot;: &quot;A String&quot;, # The selector is a comma-separated list of patterns. Each pattern is a
7173 # qualified name of the element which may end in &quot;*&quot;, indicating a wildcard.
7174 # Wildcards are only allowed at the end and for a whole component of the
7175 # qualified name, i.e. &quot;foo.*&quot; is ok, but not &quot;foo.b*&quot; or &quot;foo.*.bar&quot;. A
7176 # wildcard will match one or more components. To specify a default for all
7177 # applicable elements, the whole pattern &quot;*&quot; is used.
Bu Sun Kim65020912020-05-20 12:08:20 -07007178 },
7179 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007180 &quot;pages&quot;: [ # The top level pages for the documentation set.
7181 { # Represents a documentation page. A page can contain subpages to represent
7182 # nested documentation set structure.
7183 &quot;content&quot;: &quot;A String&quot;, # The Markdown content of the page. You can use &lt;code&gt;&amp;#40;== include {path}
7184 # ==&amp;#41;&lt;/code&gt; to include content from a Markdown file.
7185 &quot;name&quot;: &quot;A String&quot;, # The name of the page. It will be used as an identity of the page to
7186 # generate URI of the page, text of the link to this page in navigation,
7187 # etc. The full page name (start from the root page name to this page
7188 # concatenated with `.`) can be used as reference to the page in your
7189 # documentation. For example:
7190 # &lt;pre&gt;&lt;code&gt;pages:
7191 # - name: Tutorial
7192 # content: &amp;#40;== include tutorial.md ==&amp;#41;
7193 # subpages:
7194 # - name: Java
7195 # content: &amp;#40;== include tutorial_java.md ==&amp;#41;
7196 # &lt;/code&gt;&lt;/pre&gt;
7197 # You can reference `Java` page using Markdown reference link syntax:
7198 # `Java`.
7199 &quot;subpages&quot;: [ # Subpages of this page. The order of subpages specified here will be
7200 # honored in the generated docset.
7201 # Object with schema name: Page
7202 ],
7203 },
7204 ],
7205 &quot;summary&quot;: &quot;A String&quot;, # A short summary of what the service does. Can only be provided by
7206 # plain text.
Bu Sun Kim65020912020-05-20 12:08:20 -07007207 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007208 &quot;configVersion&quot;: 42, # The semantic version of the service configuration. The config version
7209 # affects the interpretation of the service configuration. For example,
7210 # certain features are enabled by default for certain config versions.
7211 #
7212 # The latest config version is `3`.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07007213 &quot;quota&quot;: { # Quota configuration helps to achieve fairness and budgeting in service # Quota configuration.
7214 # usage.
7215 #
7216 # The metric based quota configuration works this way:
7217 # - The service configuration defines a set of metrics.
7218 # - For API calls, the quota.metric_rules maps methods to metrics with
7219 # corresponding costs.
7220 # - The quota.limits defines limits on the metrics, which will be used for
7221 # quota checks at runtime.
7222 #
7223 # An example quota configuration in yaml format:
7224 #
7225 # quota:
7226 # limits:
7227 #
7228 # - name: apiWriteQpsPerProject
7229 # metric: library.googleapis.com/write_calls
7230 # unit: &quot;1/min/{project}&quot; # rate limit for consumer projects
7231 # values:
7232 # STANDARD: 10000
7233 #
7234 #
7235 # # The metric rules bind all methods to the read_calls metric,
7236 # # except for the UpdateBook and DeleteBook methods. These two methods
7237 # # are mapped to the write_calls metric, with the UpdateBook method
7238 # # consuming at twice rate as the DeleteBook method.
7239 # metric_rules:
7240 # - selector: &quot;*&quot;
7241 # metric_costs:
7242 # library.googleapis.com/read_calls: 1
7243 # - selector: google.example.library.v1.LibraryService.UpdateBook
7244 # metric_costs:
7245 # library.googleapis.com/write_calls: 2
7246 # - selector: google.example.library.v1.LibraryService.DeleteBook
7247 # metric_costs:
7248 # library.googleapis.com/write_calls: 1
7249 #
7250 # Corresponding Metric definition:
7251 #
7252 # metrics:
7253 # - name: library.googleapis.com/read_calls
7254 # display_name: Read requests
7255 # metric_kind: DELTA
7256 # value_type: INT64
7257 #
7258 # - name: library.googleapis.com/write_calls
7259 # display_name: Write requests
7260 # metric_kind: DELTA
7261 # value_type: INT64
7262 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007263 &quot;metricRules&quot;: [ # List of `MetricRule` definitions, each one mapping a selected method to one
7264 # or more metrics.
7265 { # Bind API methods to metrics. Binding a method to a metric causes that
7266 # metric&#x27;s configured quota behaviors to apply to the method call.
7267 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
7268 #
7269 # Refer to selector for syntax details.
7270 &quot;metricCosts&quot;: { # Metrics to update when the selected methods are called, and the associated
7271 # cost applied to each metric.
7272 #
7273 # The key of the map is the metric name, and the values are the amount
7274 # increased for the metric against which the quota limits are defined.
7275 # The value must not be negative.
7276 &quot;a_key&quot;: &quot;A String&quot;,
7277 },
7278 },
7279 ],
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07007280 &quot;limits&quot;: [ # List of `QuotaLimit` definitions for the service.
7281 { # `QuotaLimit` defines a specific limit that applies over a specified duration
7282 # for a limit type. There can be at most one limit for a duration and limit
7283 # type combination defined within a `QuotaGroup`.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007284 &quot;values&quot;: { # Tiered limit values. You must specify this as a key:value pair, with an
7285 # integer value that is the maximum number of requests allowed for the
7286 # specified unit. Currently only STANDARD is supported.
7287 &quot;a_key&quot;: &quot;A String&quot;,
7288 },
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07007289 &quot;duration&quot;: &quot;A String&quot;, # Duration of this limit in textual notation. Must be &quot;100s&quot; or &quot;1d&quot;.
Bu Sun Kim65020912020-05-20 12:08:20 -07007290 #
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07007291 # Used by group-based quotas only.
7292 &quot;freeTier&quot;: &quot;A String&quot;, # Free tier value displayed in the Developers Console for this limit.
7293 # The free tier is the number of tokens that will be subtracted from the
7294 # billed amount when billing is enabled.
7295 # This field can only be set on a limit with duration &quot;1d&quot;, in a billable
7296 # group; it is invalid on any other limit. If this field is not set, it
7297 # defaults to 0, indicating that there is no free tier for this service.
Bu Sun Kim65020912020-05-20 12:08:20 -07007298 #
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07007299 # Used by group-based quotas only.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007300 &quot;displayName&quot;: &quot;A String&quot;, # User-visible display name for this limit.
7301 # Optional. If not set, the UI will provide a default display name based on
7302 # the quota configuration. This field can be used to override the default
7303 # display name generated from the configuration.
7304 &quot;description&quot;: &quot;A String&quot;, # Optional. User-visible, extended description for this quota limit.
7305 # Should be used only when more context is needed to understand this limit
7306 # than provided by the limit&#x27;s display name (see: `display_name`).
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07007307 &quot;defaultLimit&quot;: &quot;A String&quot;, # Default number of tokens that can be consumed during the specified
7308 # duration. This is the number of tokens assigned when a client
7309 # application developer activates the service for his/her project.
7310 #
7311 # Specifying a value of 0 will block all requests. This can be used if you
7312 # are provisioning quota to selected consumers and blocking others.
7313 # Similarly, a value of -1 will indicate an unlimited quota. No other
7314 # negative values are allowed.
7315 #
7316 # Used by group-based quotas only.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07007317 &quot;name&quot;: &quot;A String&quot;, # Name of the quota limit.
7318 #
7319 # The name must be provided, and it must be unique within the service. The
7320 # name can only include alphanumeric characters as well as &#x27;-&#x27;.
7321 #
7322 # The maximum length of the limit name is 64 characters.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007323 &quot;maxLimit&quot;: &quot;A String&quot;, # Maximum number of tokens that can be consumed during the specified
7324 # duration. Client application developers can override the default limit up
7325 # to this maximum. If specified, this value cannot be set to a value less
7326 # than the default limit. If not specified, it is set to the default limit.
7327 #
7328 # To allow clients to apply overrides with no upper bound, set this to -1,
7329 # indicating unlimited maximum quota.
7330 #
7331 # Used by group-based quotas only.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07007332 &quot;metric&quot;: &quot;A String&quot;, # The name of the metric this quota limit applies to. The quota limits with
7333 # the same metric will be checked together during runtime. The metric must be
7334 # defined within the service config.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007335 &quot;unit&quot;: &quot;A String&quot;, # Specify the unit of the quota limit. It uses the same syntax as
7336 # Metric.unit. The supported unit kinds are determined by the quota
7337 # backend system.
7338 #
7339 # Here are some examples:
7340 # * &quot;1/min/{project}&quot; for quota per minute per project.
7341 #
7342 # Note: the order of unit components is insignificant.
7343 # The &quot;1&quot; at the beginning is required to follow the metric unit syntax.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07007344 },
7345 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007346 },
7347 &quot;customError&quot;: { # Customize service error responses. For example, list any service # Custom error configuration.
7348 # specific protobuf types that can appear in error detail lists of
7349 # error responses.
7350 #
7351 # Example:
7352 #
7353 # custom_error:
7354 # types:
7355 # - google.foo.v1.CustomError
7356 # - google.foo.v1.AnotherError
7357 &quot;types&quot;: [ # The list of custom error detail types, e.g. &#x27;google.foo.v1.CustomError&#x27;.
7358 &quot;A String&quot;,
7359 ],
7360 &quot;rules&quot;: [ # The list of custom error rules that apply to individual API messages.
7361 #
7362 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
7363 { # A custom error rule.
7364 &quot;selector&quot;: &quot;A String&quot;, # Selects messages to which this rule applies.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07007365 #
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007366 # Refer to selector for syntax details.
7367 &quot;isErrorType&quot;: True or False, # Mark this message as possible payload in error response. Otherwise,
7368 # objects of this type will be filtered when they appear in error payload.
7369 },
7370 ],
7371 },
7372 &quot;authentication&quot;: { # `Authentication` defines the authentication configuration for an API. # Auth configuration.
7373 #
7374 # Example for an API targeted for external use:
7375 #
7376 # name: calendar.googleapis.com
7377 # authentication:
7378 # providers:
7379 # - id: google_calendar_auth
7380 # jwks_uri: https://www.googleapis.com/oauth2/v1/certs
7381 # issuer: https://securetoken.google.com
7382 # rules:
7383 # - selector: &quot;*&quot;
7384 # requirements:
7385 # provider_id: google_calendar_auth
7386 &quot;rules&quot;: [ # A list of authentication rules that apply to individual API methods.
7387 #
7388 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
7389 { # Authentication rules for the service.
7390 #
7391 # By default, if a method has any authentication requirements, every request
7392 # must include a valid credential matching one of the requirements.
7393 # It&#x27;s an error to include more than one kind of credential in a single
7394 # request.
7395 #
7396 # If a method doesn&#x27;t have any auth requirements, request credentials will be
7397 # ignored.
7398 &quot;oauth&quot;: { # OAuth scopes are a way to define data and permissions on data. For example, # The requirements for OAuth credentials.
7399 # there are scopes defined for &quot;Read-only access to Google Calendar&quot; and
7400 # &quot;Access to Cloud Platform&quot;. Users can consent to a scope for an application,
7401 # giving it permission to access that data on their behalf.
7402 #
7403 # OAuth scope specifications should be fairly coarse grained; a user will need
7404 # to see and understand the text description of what your scope means.
7405 #
7406 # In most cases: use one or at most two OAuth scopes for an entire family of
7407 # products. If your product has multiple APIs, you should probably be sharing
7408 # the OAuth scope across all of those APIs.
7409 #
7410 # When you need finer grained OAuth consent screens: talk with your product
7411 # management about how developers will use them in practice.
7412 #
7413 # Please note that even though each of the canonical scopes is enough for a
7414 # request to be accepted and passed to the backend, a request can still fail
7415 # due to the backend requiring additional scopes or permissions.
7416 &quot;canonicalScopes&quot;: &quot;A String&quot;, # The list of publicly documented OAuth scopes that are allowed access. An
7417 # OAuth token containing any of these scopes will be accepted.
7418 #
7419 # Example:
7420 #
7421 # canonical_scopes: https://www.googleapis.com/auth/calendar,
7422 # https://www.googleapis.com/auth/calendar.read
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07007423 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007424 &quot;requirements&quot;: [ # Requirements for additional authentication providers.
7425 { # User-defined authentication requirements, including support for
7426 # [JSON Web Token
7427 # (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32).
7428 &quot;providerId&quot;: &quot;A String&quot;, # id from authentication provider.
7429 #
7430 # Example:
7431 #
7432 # provider_id: bookstore_auth
7433 &quot;audiences&quot;: &quot;A String&quot;, # NOTE: This will be deprecated soon, once AuthProvider.audiences is
7434 # implemented and accepted in all the runtime components.
7435 #
7436 # The list of JWT
7437 # [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3).
7438 # that are allowed to access. A JWT containing any of these audiences will
7439 # be accepted. When this setting is absent, only JWTs with audience
7440 # &quot;https://Service_name/API_name&quot;
7441 # will be accepted. For example, if no audiences are in the setting,
7442 # LibraryService API will only accept JWTs with the following audience
7443 # &quot;https://library-example.googleapis.com/google.example.library.v1.LibraryService&quot;.
7444 #
7445 # Example:
7446 #
7447 # audiences: bookstore_android.apps.googleusercontent.com,
7448 # bookstore_web.apps.googleusercontent.com
7449 },
7450 ],
7451 &quot;allowWithoutCredential&quot;: True or False, # If true, the service accepts API keys without any other credential.
Bu Sun Kim65020912020-05-20 12:08:20 -07007452 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
7453 #
7454 # Refer to selector for syntax details.
Bu Sun Kim65020912020-05-20 12:08:20 -07007455 },
7456 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007457 &quot;providers&quot;: [ # Defines a set of authentication providers that a service supports.
7458 { # Configuration for an authentication provider, including support for
7459 # [JSON Web Token
7460 # (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32).
7461 &quot;id&quot;: &quot;A String&quot;, # The unique identifier of the auth provider. It will be referred to by
7462 # `AuthRequirement.provider_id`.
7463 #
7464 # Example: &quot;bookstore_auth&quot;.
7465 &quot;issuer&quot;: &quot;A String&quot;, # Identifies the principal that issued the JWT. See
7466 # https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.1
7467 # Usually a URL or an email address.
7468 #
7469 # Example: https://securetoken.google.com
7470 # Example: 1234567-compute@developer.gserviceaccount.com
7471 &quot;jwksUri&quot;: &quot;A String&quot;, # URL of the provider&#x27;s public key set to validate signature of the JWT. See
7472 # [OpenID
7473 # Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata).
7474 # Optional if the key set document:
7475 # - can be retrieved from
7476 # [OpenID
7477 # Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html of
7478 # the issuer.
7479 # - can be inferred from the email domain of the issuer (e.g. a Google
7480 # service account).
7481 #
7482 # Example: https://www.googleapis.com/oauth2/v1/certs
7483 &quot;audiences&quot;: &quot;A String&quot;, # The list of JWT
7484 # [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3).
7485 # that are allowed to access. A JWT containing any of these audiences will
7486 # be accepted. When this setting is absent, JWTs with audiences:
7487 # - &quot;https://[service.name]/[google.protobuf.Api.name]&quot;
7488 # - &quot;https://[service.name]/&quot;
7489 # will be accepted.
7490 # For example, if no audiences are in the setting, LibraryService API will
7491 # accept JWTs with the following audiences:
7492 # -
7493 # https://library-example.googleapis.com/google.example.library.v1.LibraryService
7494 # - https://library-example.googleapis.com/
7495 #
7496 # Example:
7497 #
7498 # audiences: bookstore_android.apps.googleusercontent.com,
7499 # bookstore_web.apps.googleusercontent.com
7500 &quot;authorizationUrl&quot;: &quot;A String&quot;, # Redirect URL if JWT token is required but not present or is expired.
7501 # Implement authorizationUrl of securityDefinitions in OpenAPI spec.
7502 &quot;jwtLocations&quot;: [ # Defines the locations to extract the JWT.
7503 #
7504 # JWT locations can be either from HTTP headers or URL query parameters.
7505 # The rule is that the first match wins. The checking order is: checking
7506 # all headers first, then URL query parameters.
7507 #
7508 # If not specified, default to use following 3 locations:
7509 # 1) Authorization: Bearer
7510 # 2) x-goog-iap-jwt-assertion
7511 # 3) access_token query parameter
7512 #
7513 # Default locations can be specified as followings:
7514 # jwt_locations:
7515 # - header: Authorization
7516 # value_prefix: &quot;Bearer &quot;
7517 # - header: x-goog-iap-jwt-assertion
7518 # - query: access_token
7519 { # Specifies a location to extract JWT from an API request.
7520 &quot;query&quot;: &quot;A String&quot;, # Specifies URL query parameter name to extract JWT token.
7521 &quot;valuePrefix&quot;: &quot;A String&quot;, # The value prefix. The value format is &quot;value_prefix{token}&quot;
7522 # Only applies to &quot;in&quot; header type. Must be empty for &quot;in&quot; query type.
7523 # If not empty, the header value has to match (case sensitive) this prefix.
7524 # If not matched, JWT will not be extracted. If matched, JWT will be
7525 # extracted after the prefix is removed.
7526 #
7527 # For example, for &quot;Authorization: Bearer {JWT}&quot;,
7528 # value_prefix=&quot;Bearer &quot; with a space at the end.
7529 &quot;header&quot;: &quot;A String&quot;, # Specifies HTTP header name to extract JWT token.
7530 },
7531 ],
7532 },
7533 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07007534 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007535 &quot;title&quot;: &quot;A String&quot;, # The product title for this service.
7536 &quot;producerProjectId&quot;: &quot;A String&quot;, # The Google project that owns this service.
7537 &quot;apis&quot;: [ # A list of API interfaces exported by this service. Only the `name` field
7538 # of the google.protobuf.Api needs to be provided by the configuration
7539 # author, as the remaining fields will be derived from the IDL during the
7540 # normalization process. It is an error to specify an API interface here
7541 # which cannot be resolved against the associated IDL files.
7542 { # Api is a light-weight descriptor for an API Interface.
7543 #
7544 # Interfaces are also described as &quot;protocol buffer services&quot; in some contexts,
7545 # such as by the &quot;service&quot; keyword in a .proto file, but they are different
7546 # from API Services, which represent a concrete implementation of an interface
7547 # as opposed to simply a description of methods and bindings. They are also
7548 # sometimes simply referred to as &quot;APIs&quot; in other contexts, such as the name of
7549 # this message itself. See https://cloud.google.com/apis/design/glossary for
7550 # detailed terminology.
7551 &quot;sourceContext&quot;: { # `SourceContext` represents information about the source of a # Source context for the protocol buffer service represented by this
7552 # message.
7553 # protobuf element, like the file in which it is defined.
7554 &quot;fileName&quot;: &quot;A String&quot;, # The path-qualified name of the .proto file that contained the associated
7555 # protobuf element. For example: `&quot;google/protobuf/source_context.proto&quot;`.
7556 },
7557 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax of the service.
7558 &quot;methods&quot;: [ # The methods of this interface, in unspecified order.
7559 { # Method represents a method of an API interface.
7560 &quot;options&quot;: [ # Any metadata attached to the method.
7561 { # A protocol buffer option, which can be attached to a message, field,
7562 # enumeration, etc.
7563 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
7564 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
7565 # should be used. If the value is an enum, it should be stored as an int32
7566 # value using the google.protobuf.Int32Value type.
7567 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
7568 },
7569 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
7570 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
7571 # For custom options, it should be the fully-qualified name. For example,
7572 # `&quot;google.api.http&quot;`.
7573 },
7574 ],
7575 &quot;responseStreaming&quot;: True or False, # If true, the response is streamed.
7576 &quot;syntax&quot;: &quot;A String&quot;, # The source syntax of this method.
7577 &quot;requestTypeUrl&quot;: &quot;A String&quot;, # A URL of the input message type.
7578 &quot;name&quot;: &quot;A String&quot;, # The simple name of this method.
7579 &quot;responseTypeUrl&quot;: &quot;A String&quot;, # The URL of the output message type.
7580 &quot;requestStreaming&quot;: True or False, # If true, the request is streamed.
7581 },
7582 ],
7583 &quot;name&quot;: &quot;A String&quot;, # The fully qualified name of this interface, including package name
7584 # followed by the interface&#x27;s simple name.
7585 &quot;version&quot;: &quot;A String&quot;, # A version string for this interface. If specified, must have the form
7586 # `major-version.minor-version`, as in `1.10`. If the minor version is
7587 # omitted, it defaults to zero. If the entire version field is empty, the
7588 # major version is derived from the package name, as outlined below. If the
7589 # field is not empty, the version in the package name will be verified to be
7590 # consistent with what is provided here.
7591 #
7592 # The versioning schema uses [semantic
7593 # versioning](http://semver.org) where the major version number
7594 # indicates a breaking change and the minor version an additive,
7595 # non-breaking change. Both version numbers are signals to users
7596 # what to expect from different versions, and should be carefully
7597 # chosen based on the product plan.
7598 #
7599 # The major version is also reflected in the package name of the
7600 # interface, which must end in `v&lt;major-version&gt;`, as in
7601 # `google.feature.v1`. For major versions 0 and 1, the suffix can
7602 # be omitted. Zero major versions must only be used for
7603 # experimental, non-GA interfaces.
7604 &quot;options&quot;: [ # Any metadata attached to the interface.
7605 { # A protocol buffer option, which can be attached to a message, field,
7606 # enumeration, etc.
7607 &quot;value&quot;: { # The option&#x27;s value packed in an Any message. If the value is a primitive,
7608 # the corresponding wrapper type defined in google/protobuf/wrappers.proto
7609 # should be used. If the value is an enum, it should be stored as an int32
7610 # value using the google.protobuf.Int32Value type.
7611 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
7612 },
7613 &quot;name&quot;: &quot;A String&quot;, # The option&#x27;s name. For protobuf built-in options (options defined in
7614 # descriptor.proto), this is the short name. For example, `&quot;map_entry&quot;`.
7615 # For custom options, it should be the fully-qualified name. For example,
7616 # `&quot;google.api.http&quot;`.
7617 },
7618 ],
7619 &quot;mixins&quot;: [ # Included interfaces. See Mixin.
7620 { # Declares an API Interface to be included in this interface. The including
7621 # interface must redeclare all the methods from the included interface, but
7622 # documentation and options are inherited as follows:
7623 #
7624 # - If after comment and whitespace stripping, the documentation
7625 # string of the redeclared method is empty, it will be inherited
7626 # from the original method.
7627 #
7628 # - Each annotation belonging to the service config (http,
7629 # visibility) which is not set in the redeclared method will be
7630 # inherited.
7631 #
7632 # - If an http annotation is inherited, the path pattern will be
7633 # modified as follows. Any version prefix will be replaced by the
7634 # version of the including interface plus the root path if
7635 # specified.
7636 #
7637 # Example of a simple mixin:
7638 #
7639 # package google.acl.v1;
7640 # service AccessControl {
7641 # // Get the underlying ACL object.
7642 # rpc GetAcl(GetAclRequest) returns (Acl) {
7643 # option (google.api.http).get = &quot;/v1/{resource=**}:getAcl&quot;;
7644 # }
7645 # }
7646 #
7647 # package google.storage.v2;
7648 # service Storage {
7649 # // rpc GetAcl(GetAclRequest) returns (Acl);
7650 #
7651 # // Get a data record.
7652 # rpc GetData(GetDataRequest) returns (Data) {
7653 # option (google.api.http).get = &quot;/v2/{resource=**}&quot;;
7654 # }
7655 # }
7656 #
7657 # Example of a mixin configuration:
7658 #
7659 # apis:
7660 # - name: google.storage.v2.Storage
7661 # mixins:
7662 # - name: google.acl.v1.AccessControl
7663 #
7664 # The mixin construct implies that all methods in `AccessControl` are
7665 # also declared with same name and request/response types in
7666 # `Storage`. A documentation generator or annotation processor will
7667 # see the effective `Storage.GetAcl` method after inherting
7668 # documentation and annotations as follows:
7669 #
7670 # service Storage {
7671 # // Get the underlying ACL object.
7672 # rpc GetAcl(GetAclRequest) returns (Acl) {
7673 # option (google.api.http).get = &quot;/v2/{resource=**}:getAcl&quot;;
7674 # }
7675 # ...
7676 # }
7677 #
7678 # Note how the version in the path pattern changed from `v1` to `v2`.
7679 #
7680 # If the `root` field in the mixin is specified, it should be a
7681 # relative path under which inherited HTTP paths are placed. Example:
7682 #
7683 # apis:
7684 # - name: google.storage.v2.Storage
7685 # mixins:
7686 # - name: google.acl.v1.AccessControl
7687 # root: acls
7688 #
7689 # This implies the following inherited HTTP annotation:
7690 #
7691 # service Storage {
7692 # // Get the underlying ACL object.
7693 # rpc GetAcl(GetAclRequest) returns (Acl) {
7694 # option (google.api.http).get = &quot;/v2/acls/{resource=**}:getAcl&quot;;
7695 # }
7696 # ...
7697 # }
7698 &quot;root&quot;: &quot;A String&quot;, # If non-empty specifies a path under which inherited HTTP paths
7699 # are rooted.
7700 &quot;name&quot;: &quot;A String&quot;, # The fully qualified name of the interface which is included.
7701 },
7702 ],
7703 },
7704 ],
7705 &quot;id&quot;: &quot;A String&quot;, # A unique ID for a specific instance of this message, typically assigned
7706 # by the client for tracking purpose. Must be no longer than 63 characters
7707 # and only lower case letters, digits, &#x27;.&#x27;, &#x27;_&#x27; and &#x27;-&#x27; are allowed. If
7708 # empty, the server may choose to generate one instead.
7709 &quot;endpoints&quot;: [ # Configuration for network endpoints. If this is empty, then an endpoint
7710 # with the same name as the service is automatically generated to service all
7711 # defined APIs.
7712 { # `Endpoint` describes a network endpoint that serves a set of APIs.
7713 # A service may expose any number of endpoints, and all endpoints share the
7714 # same service configuration, such as quota configuration and monitoring
7715 # configuration.
7716 #
7717 # Example service configuration:
7718 #
7719 # name: library-example.googleapis.com
7720 # endpoints:
7721 # # Below entry makes &#x27;google.example.library.v1.Library&#x27;
7722 # # API be served from endpoint address library-example.googleapis.com.
7723 # # It also allows HTTP OPTIONS calls to be passed to the backend, for
7724 # # it to decide whether the subsequent cross-origin request is
7725 # # allowed to proceed.
7726 # - name: library-example.googleapis.com
7727 # allow_cors: true
7728 &quot;name&quot;: &quot;A String&quot;, # The canonical name of this endpoint.
7729 &quot;allowCors&quot;: True or False, # Allowing
7730 # [CORS](https://en.wikipedia.org/wiki/Cross-origin_resource_sharing), aka
7731 # cross-domain traffic, would allow the backends served from this endpoint to
7732 # receive and respond to HTTP OPTIONS requests. The response will be used by
7733 # the browser to determine whether the subsequent cross-origin request is
7734 # allowed to proceed.
7735 &quot;target&quot;: &quot;A String&quot;, # The specification of an Internet routable address of API frontend that will
7736 # handle requests to this [API
7737 # Endpoint](https://cloud.google.com/apis/design/glossary). It should be
7738 # either a valid IPv4 address or a fully-qualified domain name. For example,
7739 # &quot;8.8.8.8&quot; or &quot;myservice.appspot.com&quot;.
7740 &quot;aliases&quot;: [ # DEPRECATED: This field is no longer supported. Instead of using aliases,
7741 # please specify multiple google.api.Endpoint for each of the intended
7742 # aliases.
7743 #
7744 # Additional names that this endpoint will be hosted on.
7745 &quot;A String&quot;,
7746 ],
7747 },
7748 ],
7749 &quot;systemParameters&quot;: { # ### System parameter configuration # System parameter configuration.
7750 #
7751 # A system parameter is a special kind of parameter defined by the API
7752 # system, not by an individual API. It is typically mapped to an HTTP header
7753 # and/or a URL query parameter. This configuration specifies which methods
7754 # change the names of the system parameters.
7755 &quot;rules&quot;: [ # Define system parameters.
7756 #
7757 # The parameters defined here will override the default parameters
7758 # implemented by the system. If this field is missing from the service
7759 # config, default system parameters will be used. Default system parameters
7760 # and names is implementation-dependent.
7761 #
7762 # Example: define api key for all methods
7763 #
7764 # system_parameters
7765 # rules:
7766 # - selector: &quot;*&quot;
7767 # parameters:
7768 # - name: api_key
7769 # url_query_parameter: api_key
7770 #
7771 #
7772 # Example: define 2 api key names for a specific method.
7773 #
7774 # system_parameters
7775 # rules:
7776 # - selector: &quot;/ListShelves&quot;
7777 # parameters:
7778 # - name: api_key
7779 # http_header: Api-Key1
7780 # - name: api_key
7781 # http_header: Api-Key2
7782 #
7783 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
7784 { # Define a system parameter rule mapping system parameter definitions to
7785 # methods.
7786 &quot;parameters&quot;: [ # Define parameters. Multiple names may be defined for a parameter.
7787 # For a given method call, only one of them should be used. If multiple
7788 # names are used the behavior is implementation-dependent.
7789 # If none of the specified names are present the behavior is
7790 # parameter-dependent.
7791 { # Define a parameter&#x27;s name and location. The parameter may be passed as either
7792 # an HTTP header or a URL query parameter, and if both are passed the behavior
7793 # is implementation-dependent.
7794 &quot;name&quot;: &quot;A String&quot;, # Define the name of the parameter, such as &quot;api_key&quot; . It is case sensitive.
7795 &quot;httpHeader&quot;: &quot;A String&quot;, # Define the HTTP header name to use for the parameter. It is case
7796 # insensitive.
7797 &quot;urlQueryParameter&quot;: &quot;A String&quot;, # Define the URL query parameter name to use for the parameter. It is case
7798 # sensitive.
7799 },
7800 ],
7801 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies. Use &#x27;*&#x27; to indicate all
7802 # methods in all APIs.
7803 #
7804 # Refer to selector for syntax details.
7805 },
7806 ],
7807 },
7808 &quot;monitoredResources&quot;: [ # Defines the monitored resources used by this service. This is required
7809 # by the Service.monitoring and Service.logging configurations.
7810 { # An object that describes the schema of a MonitoredResource object using a
7811 # type name and a set of labels. For example, the monitored resource
7812 # descriptor for Google Compute Engine VM instances has a type of
7813 # `&quot;gce_instance&quot;` and specifies the use of the labels `&quot;instance_id&quot;` and
7814 # `&quot;zone&quot;` to identify particular VM instances.
7815 #
7816 # Different services can support different monitored resource types.
7817 #
7818 # The following are specific rules to service defined monitored resources for
7819 # Monitoring and Logging:
7820 #
7821 # * The `type`, `display_name`, `description`, `labels` and `launch_stage`
7822 # fields are all required.
7823 # * The first label of the monitored resource descriptor must be
7824 # `resource_container`. There are legacy monitored resource descritptors
7825 # start with `project_id`.
7826 # * It must include a `location` label.
7827 # * Maximum of default 5 service defined monitored resource descriptors
7828 # is allowed per service.
7829 # * Maximum of default 10 labels per monitored resource is allowed.
7830 #
7831 # The default maximum limit can be overridden. Please follow
7832 # https://cloud.google.com/monitoring/quotas
7833 &quot;name&quot;: &quot;A String&quot;, # Optional. The resource name of the monitored resource descriptor:
7834 # `&quot;projects/{project_id}/monitoredResourceDescriptors/{type}&quot;` where
7835 # {type} is the value of the `type` field in this object and
7836 # {project_id} is a project ID that provides API-specific context for
7837 # accessing the type. APIs that do not use project information can use the
7838 # resource name format `&quot;monitoredResourceDescriptors/{type}&quot;`.
7839 &quot;launchStage&quot;: &quot;A String&quot;, # Optional. The launch stage of the monitored resource definition.
7840 &quot;displayName&quot;: &quot;A String&quot;, # Optional. A concise name for the monitored resource type that might be
7841 # displayed in user interfaces. It should be a Title Cased Noun Phrase,
7842 # without any article or other determiners. For example,
7843 # `&quot;Google Cloud SQL Database&quot;`.
7844 &quot;labels&quot;: [ # Required. A set of labels used to describe instances of this monitored
7845 # resource type.
7846 # The label key name must follow:
7847 #
7848 # * Only upper and lower-case letters, digits and underscores (_) are
7849 # allowed.
7850 # * Label name must start with a letter or digit.
7851 # * The maximum length of a label name is 100 characters.
7852 #
7853 # For example, an individual Google Cloud SQL database is
7854 # identified by values for the labels `database_id` and `location`.
7855 { # A description of a label.
7856 &quot;valueType&quot;: &quot;A String&quot;, # The type of data that can be assigned to the label.
7857 &quot;description&quot;: &quot;A String&quot;, # A human-readable description for the label.
7858 &quot;key&quot;: &quot;A String&quot;, # The label key.
7859 },
7860 ],
7861 &quot;description&quot;: &quot;A String&quot;, # Optional. A detailed description of the monitored resource type that might
7862 # be used in documentation.
7863 &quot;type&quot;: &quot;A String&quot;, # Required. The monitored resource type. For example, the type
7864 # `cloudsql_database` represents databases in Google Cloud SQL.
7865 #
7866 # All service defined monitored resource types must be prefixed with the
7867 # service name, in the format of `{service name}/{relative resource name}`.
7868 # The relative resource name must follow:
7869 #
7870 # * Only upper and lower-case letters and digits are allowed.
7871 # * It must start with upper case character and is recommended to use Upper
7872 # Camel Case style.
7873 # * The maximum number of characters allowed for the relative_resource_name
7874 # is 100.
7875 #
7876 # Note there are legacy service monitored resources not following this rule.
7877 },
7878 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07007879 &quot;context&quot;: { # `Context` defines which contexts an API requests. # Context configuration.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07007880 #
7881 # Example:
7882 #
Bu Sun Kim65020912020-05-20 12:08:20 -07007883 # context:
7884 # rules:
7885 # - selector: &quot;*&quot;
7886 # requested:
7887 # - google.rpc.context.ProjectContext
7888 # - google.rpc.context.OriginContext
7889 #
7890 # The above specifies that all methods in the API request
7891 # `google.rpc.context.ProjectContext` and
7892 # `google.rpc.context.OriginContext`.
7893 #
7894 # Available context types are defined in package
7895 # `google.rpc.context`.
7896 #
7897 # This also provides mechanism to whitelist any protobuf message extension that
7898 # can be sent in grpc metadata using “x-goog-ext-&lt;extension_id&gt;-bin” and
7899 # “x-goog-ext-&lt;extension_id&gt;-jspb” format. For example, list any service
7900 # specific protobuf types that can appear in grpc metadata as follows in your
7901 # yaml file:
7902 #
7903 # Example:
7904 #
7905 # context:
7906 # rules:
7907 # - selector: &quot;google.example.library.v1.LibraryService.CreateBook&quot;
7908 # allowed_request_extensions:
7909 # - google.foo.v1.NewExtension
7910 # allowed_response_extensions:
7911 # - google.foo.v1.NewExtension
7912 #
7913 # You can also specify extension ID instead of fully qualified extension name
7914 # here.
7915 &quot;rules&quot;: [ # A list of RPC context rules that apply to individual API methods.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07007916 #
Bu Sun Kim65020912020-05-20 12:08:20 -07007917 # **NOTE:** All service configuration rules follow &quot;last one wins&quot; order.
7918 { # A context rule provides information about the context for an individual API
7919 # element.
Bu Sun Kim65020912020-05-20 12:08:20 -07007920 &quot;selector&quot;: &quot;A String&quot;, # Selects the methods to which this rule applies.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07007921 #
7922 # Refer to selector for syntax details.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07007923 &quot;requested&quot;: [ # A list of full type names of requested contexts.
7924 &quot;A String&quot;,
7925 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07007926 &quot;provided&quot;: [ # A list of full type names of provided contexts.
7927 &quot;A String&quot;,
7928 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007929 &quot;allowedRequestExtensions&quot;: [ # A list of full type names or extension IDs of extensions allowed in grpc
7930 # side channel from client to backend.
7931 &quot;A String&quot;,
7932 ],
7933 &quot;allowedResponseExtensions&quot;: [ # A list of full type names or extension IDs of extensions allowed in grpc
7934 # side channel from backend to client.
7935 &quot;A String&quot;,
7936 ],
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07007937 },
7938 ],
7939 },
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07007940 },
7941 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07007942 &quot;nextPageToken&quot;: &quot;A String&quot;, # The token of the next page of results.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07007943 }</pre>
7944</div>
7945
7946<div class="method">
7947 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
7948 <pre>Retrieves the next page of results.
7949
7950Args:
7951 previous_request: The request for the previous page. (required)
7952 previous_response: The response from the request for the previous page. (required)
7953
7954Returns:
Bu Sun Kim65020912020-05-20 12:08:20 -07007955 A request object that you can call &#x27;execute()&#x27; on to request the next
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07007956 page. Returns None if there are no more items in the collection.
7957 </pre>
7958</div>
7959
7960<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07007961 <code class="details" id="submit">submit(serviceName, body=None, x__xgafv=None)</code>
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07007962 <pre>Creates a new service configuration (version) for a managed service based
7963on
7964user-supplied configuration source files (for example: OpenAPI
7965Specification). This method stores the source configurations as well as the
7966generated service configuration. To rollout the service configuration to
7967other services,
7968please call CreateServiceRollout.
7969
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07007970Only the 100 most recent configuration sources and ones referenced by
7971existing service configurtions are kept for each service. The rest will be
7972deleted eventually.
7973
Dan O'Mearadd494642020-05-01 07:42:23 -07007974Operation&lt;response: SubmitConfigSourceResponse&gt;
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07007975
7976Args:
Dan O'Mearadd494642020-05-01 07:42:23 -07007977 serviceName: string, Required. The name of the service. See the [overview](/service-management/overview)
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07007978for naming requirements. For example: `example.googleapis.com`. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07007979 body: object, The request body.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07007980 The object takes the form of:
7981
7982{ # Request message for SubmitConfigSource method.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07007983 &quot;validateOnly&quot;: True or False, # Optional. If set, this will result in the generation of a
7984 # `google.api.Service` configuration based on the `ConfigSource` provided,
7985 # but the generated config and the sources will NOT be persisted.
Bu Sun Kim65020912020-05-20 12:08:20 -07007986 &quot;configSource&quot;: { # Represents a source file which is used to generate the service configuration # Required. The source configuration for the service.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07007987 # defined by `google.api.Service`.
Bu Sun Kim65020912020-05-20 12:08:20 -07007988 &quot;files&quot;: [ # Set of source configuration files that are used to generate a service
7989 # configuration (`google.api.Service`).
7990 { # Generic specification of a source configuration file
Bu Sun Kim65020912020-05-20 12:08:20 -07007991 &quot;fileType&quot;: &quot;A String&quot;, # The type of configuration file this represents.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007992 &quot;filePath&quot;: &quot;A String&quot;, # The file name of the configuration file (full or relative path).
Bu Sun Kim65020912020-05-20 12:08:20 -07007993 &quot;fileContents&quot;: &quot;A String&quot;, # The bytes that constitute the file.
7994 },
7995 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07007996 &quot;id&quot;: &quot;A String&quot;, # A unique ID for a specific instance of this message, typically assigned
7997 # by the client for tracking purpose. If empty, the server may choose to
7998 # generate one instead.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07007999 },
8000 }
8001
8002 x__xgafv: string, V1 error format.
8003 Allowed values
8004 1 - v1 error format
8005 2 - v2 error format
8006
8007Returns:
8008 An object of the form:
8009
8010 { # This resource represents a long-running operation that is the result of a
8011 # network API call.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07008012 &quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation.
8013 # different programming environments, including REST APIs and RPC APIs. It is
8014 # used by [gRPC](https://github.com/grpc). Each `Status` message contains
8015 # three pieces of data: error code, error message, and error details.
8016 #
8017 # You can find out more about this error model and how to work with it in the
8018 # [API Design Guide](https://cloud.google.com/apis/design/errors).
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07008019 &quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of
8020 # message types for APIs to use.
8021 {
8022 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
8023 },
8024 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07008025 &quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
8026 &quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any
8027 # user-facing error message should be localized and sent in the
8028 # google.rpc.Status.details field, or localized by the client.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -07008029 },
Bu Sun Kim65020912020-05-20 12:08:20 -07008030 &quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -04008031 # contains progress information and common metadata such as create time.
8032 # Some services might not provide such metadata. Any method that returns a
8033 # long-running operation should document the metadata type, if any.
Bu Sun Kim65020912020-05-20 12:08:20 -07008034 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -04008035 },
Bu Sun Kim65020912020-05-20 12:08:20 -07008036 &quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress.
Dan O'Mearadd494642020-05-01 07:42:23 -07008037 # If `true`, the operation is completed, and either `error` or `response` is
8038 # available.
Bu Sun Kim65020912020-05-20 12:08:20 -07008039 &quot;response&quot;: { # The normal response of the operation in case of success. If the original
Dan O'Mearadd494642020-05-01 07:42:23 -07008040 # method returns no data on success, such as `Delete`, the response is
8041 # `google.protobuf.Empty`. If the original method is standard
8042 # `Get`/`Create`/`Update`, the response should be the resource. For other
8043 # methods, the response should have the type `XxxResponse`, where `Xxx`
8044 # is the original method name. For example, if the original method name
8045 # is `TakeSnapshot()`, the inferred response type is
8046 # `TakeSnapshotResponse`.
Bu Sun Kim65020912020-05-20 12:08:20 -07008047 &quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
Dan O'Mearadd494642020-05-01 07:42:23 -07008048 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07008049 &quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that
8050 # originally returns it. If you use the default HTTP mapping, the
8051 # `name` should be a resource name ending with `operations/{unique_id}`.
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -07008052 }</pre>
8053</div>
8054
8055</body></html>