Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1 | <html><body> |
| 2 | <style> |
| 3 | |
| 4 | body, 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 | |
| 15 | body { |
| 16 | font-size: 13px; |
| 17 | padding: 1em; |
| 18 | } |
| 19 | |
| 20 | h1 { |
| 21 | font-size: 26px; |
| 22 | margin-bottom: 1em; |
| 23 | } |
| 24 | |
| 25 | h2 { |
| 26 | font-size: 24px; |
| 27 | margin-bottom: 1em; |
| 28 | } |
| 29 | |
| 30 | h3 { |
| 31 | font-size: 20px; |
| 32 | margin-bottom: 1em; |
| 33 | margin-top: 1em; |
| 34 | } |
| 35 | |
| 36 | pre, code { |
| 37 | line-height: 1.5; |
| 38 | font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace; |
| 39 | } |
| 40 | |
| 41 | pre { |
| 42 | margin-top: 0.5em; |
| 43 | } |
| 44 | |
| 45 | h1, h2, h3, p { |
| 46 | font-family: Arial, sans serif; |
| 47 | } |
| 48 | |
| 49 | h1, 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 | |
| 75 | <h1><a href="serviceusage_v1.html">Service Usage API</a> . <a href="serviceusage_v1.services.html">services</a></h1> |
| 76 | <h2>Instance Methods</h2> |
| 77 | <p class="toc_element"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 78 | <code><a href="#batchEnable">batchEnable(parent, body=None, x__xgafv=None)</a></code></p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 79 | <p class="firstline">Enable multiple services on a project. The operation is atomic: if enabling</p> |
| 80 | <p class="toc_element"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 81 | <code><a href="#batchGet">batchGet(parent, names=None, x__xgafv=None)</a></code></p> |
| 82 | <p class="firstline">Returns the service configurations and enabled states for a given list of</p> |
| 83 | <p class="toc_element"> |
| 84 | <code><a href="#disable">disable(name, body=None, x__xgafv=None)</a></code></p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 85 | <p class="firstline">Disable a service so that it can no longer be used with a project.</p> |
| 86 | <p class="toc_element"> |
| 87 | <code><a href="#enable">enable(name, body=None, x__xgafv=None)</a></code></p> |
| 88 | <p class="firstline">Enable a service so that it can be used with a project.</p> |
| 89 | <p class="toc_element"> |
| 90 | <code><a href="#get">get(name, x__xgafv=None)</a></code></p> |
| 91 | <p class="firstline">Returns the service configuration and enabled state for a given service.</p> |
| 92 | <p class="toc_element"> |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 93 | <code><a href="#list">list(parent, pageSize=None, pageToken=None, filter=None, x__xgafv=None)</a></code></p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 94 | <p class="firstline">List all services available to the specified project, and the current</p> |
| 95 | <p class="toc_element"> |
| 96 | <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p> |
| 97 | <p class="firstline">Retrieves the next page of results.</p> |
| 98 | <h3>Method Details</h3> |
| 99 | <div class="method"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 100 | <code class="details" id="batchEnable">batchEnable(parent, body=None, x__xgafv=None)</code> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 101 | <pre>Enable multiple services on a project. The operation is atomic: if enabling |
| 102 | any service fails, then the entire batch fails, and no state changes occur. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 103 | To enable a single service, use the `EnableService` method instead. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 104 | |
| 105 | Args: |
| 106 | parent: string, Parent to enable services on. |
| 107 | |
| 108 | An example name would be: |
| 109 | `projects/123` where `123` is the project number. |
| 110 | |
| 111 | The `BatchEnableServices` method currently only supports projects. (required) |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 112 | body: object, The request body. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 113 | The object takes the form of: |
| 114 | |
| 115 | { # Request message for the `BatchEnableServices` method. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 116 | "serviceIds": [ # The identifiers of the services to enable on the project. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 117 | # |
| 118 | # A valid identifier would be: |
| 119 | # serviceusage.googleapis.com |
| 120 | # |
| 121 | # Enabling services requires that each service is public or is shared with |
| 122 | # the user enabling the service. |
| 123 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 124 | # A single request can enable a maximum of 20 services at a time. If more |
| 125 | # than 20 services are specified, the request will fail, and no state changes |
| 126 | # will occur. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 127 | "A String", |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 128 | ], |
| 129 | } |
| 130 | |
| 131 | x__xgafv: string, V1 error format. |
| 132 | Allowed values |
| 133 | 1 - v1 error format |
| 134 | 2 - v2 error format |
| 135 | |
| 136 | Returns: |
| 137 | An object of the form: |
| 138 | |
| 139 | { # This resource represents a long-running operation that is the result of a |
| 140 | # network API call. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 141 | "done": True or False, # If the value is `false`, it means the operation is still in progress. |
| 142 | # If `true`, the operation is completed, and either `error` or `response` is |
| 143 | # available. |
| 144 | "metadata": { # Service-specific metadata associated with the operation. It typically |
| 145 | # contains progress information and common metadata such as create time. |
| 146 | # Some services might not provide such metadata. Any method that returns a |
| 147 | # long-running operation should document the metadata type, if any. |
| 148 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 149 | }, |
| 150 | "error": { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation. |
| 151 | # different programming environments, including REST APIs and RPC APIs. It is |
| 152 | # used by [gRPC](https://github.com/grpc). Each `Status` message contains |
| 153 | # three pieces of data: error code, error message, and error details. |
| 154 | # |
| 155 | # You can find out more about this error model and how to work with it in the |
| 156 | # [API Design Guide](https://cloud.google.com/apis/design/errors). |
| 157 | "details": [ # A list of messages that carry the error details. There is a common set of |
| 158 | # message types for APIs to use. |
| 159 | { |
| 160 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 161 | }, |
| 162 | ], |
| 163 | "message": "A String", # A developer-facing error message, which should be in English. Any |
| 164 | # user-facing error message should be localized and sent in the |
| 165 | # google.rpc.Status.details field, or localized by the client. |
| 166 | "code": 42, # The status code, which should be an enum value of google.rpc.Code. |
| 167 | }, |
| 168 | "name": "A String", # The server-assigned name, which is only unique within the same service that |
| 169 | # originally returns it. If you use the default HTTP mapping, the |
| 170 | # `name` should be a resource name ending with `operations/{unique_id}`. |
| 171 | "response": { # The normal response of the operation in case of success. If the original |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 172 | # method returns no data on success, such as `Delete`, the response is |
| 173 | # `google.protobuf.Empty`. If the original method is standard |
| 174 | # `Get`/`Create`/`Update`, the response should be the resource. For other |
| 175 | # methods, the response should have the type `XxxResponse`, where `Xxx` |
| 176 | # is the original method name. For example, if the original method name |
| 177 | # is `TakeSnapshot()`, the inferred response type is |
| 178 | # `TakeSnapshotResponse`. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 179 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 180 | }, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 181 | }</pre> |
| 182 | </div> |
| 183 | |
| 184 | <div class="method"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 185 | <code class="details" id="batchGet">batchGet(parent, names=None, x__xgafv=None)</code> |
| 186 | <pre>Returns the service configurations and enabled states for a given list of |
| 187 | services. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 188 | |
| 189 | Args: |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 190 | parent: string, Parent to retrieve services from. |
| 191 | If this is set, the parent of all of the services specified in `names` must |
| 192 | match this field. An example name would be: `projects/123` where `123` is |
| 193 | the project number. The `BatchGetServices` method currently only supports |
| 194 | projects. (required) |
| 195 | names: string, Names of the services to retrieve. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 196 | |
| 197 | An example name would be: |
| 198 | `projects/123/services/serviceusage.googleapis.com` where `123` is the |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 199 | project number. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 200 | A single request can get a maximum of 30 services at a time. (repeated) |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 201 | x__xgafv: string, V1 error format. |
| 202 | Allowed values |
| 203 | 1 - v1 error format |
| 204 | 2 - v2 error format |
| 205 | |
| 206 | Returns: |
| 207 | An object of the form: |
| 208 | |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 209 | { # Response message for the `BatchGetServices` method. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 210 | "services": [ # The requested Service states. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 211 | { # A service that is available for use by the consumer. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 212 | "name": "A String", # The resource name of the consumer and service. |
| 213 | # |
| 214 | # A valid name would be: |
| 215 | # - projects/123/services/serviceusage.googleapis.com |
| 216 | "config": { # The configuration of the service. # The service configuration of the available service. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 217 | # Some fields may be filtered out of the configuration in responses to |
| 218 | # the `ListServices` method. These fields are present only in responses to |
| 219 | # the `GetService` method. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 220 | "quota": { # Quota configuration helps to achieve fairness and budgeting in service # Quota configuration. |
| 221 | # usage. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 222 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 223 | # The metric based quota configuration works this way: |
| 224 | # - The service configuration defines a set of metrics. |
| 225 | # - For API calls, the quota.metric_rules maps methods to metrics with |
| 226 | # corresponding costs. |
| 227 | # - The quota.limits defines limits on the metrics, which will be used for |
| 228 | # quota checks at runtime. |
| 229 | # |
| 230 | # An example quota configuration in yaml format: |
| 231 | # |
| 232 | # quota: |
| 233 | # limits: |
| 234 | # |
| 235 | # - name: apiWriteQpsPerProject |
| 236 | # metric: library.googleapis.com/write_calls |
| 237 | # unit: "1/min/{project}" # rate limit for consumer projects |
| 238 | # values: |
| 239 | # STANDARD: 10000 |
| 240 | # |
| 241 | # |
| 242 | # # The metric rules bind all methods to the read_calls metric, |
| 243 | # # except for the UpdateBook and DeleteBook methods. These two methods |
| 244 | # # are mapped to the write_calls metric, with the UpdateBook method |
| 245 | # # consuming at twice rate as the DeleteBook method. |
| 246 | # metric_rules: |
| 247 | # - selector: "*" |
| 248 | # metric_costs: |
| 249 | # library.googleapis.com/read_calls: 1 |
| 250 | # - selector: google.example.library.v1.LibraryService.UpdateBook |
| 251 | # metric_costs: |
| 252 | # library.googleapis.com/write_calls: 2 |
| 253 | # - selector: google.example.library.v1.LibraryService.DeleteBook |
| 254 | # metric_costs: |
| 255 | # library.googleapis.com/write_calls: 1 |
| 256 | # |
| 257 | # Corresponding Metric definition: |
| 258 | # |
| 259 | # metrics: |
| 260 | # - name: library.googleapis.com/read_calls |
| 261 | # display_name: Read requests |
| 262 | # metric_kind: DELTA |
| 263 | # value_type: INT64 |
| 264 | # |
| 265 | # - name: library.googleapis.com/write_calls |
| 266 | # display_name: Write requests |
| 267 | # metric_kind: DELTA |
| 268 | # value_type: INT64 |
| 269 | # |
| 270 | "limits": [ # List of `QuotaLimit` definitions for the service. |
| 271 | { # `QuotaLimit` defines a specific limit that applies over a specified duration |
| 272 | # for a limit type. There can be at most one limit for a duration and limit |
| 273 | # type combination defined within a `QuotaGroup`. |
| 274 | "displayName": "A String", # User-visible display name for this limit. |
| 275 | # Optional. If not set, the UI will provide a default display name based on |
| 276 | # the quota configuration. This field can be used to override the default |
| 277 | # display name generated from the configuration. |
| 278 | "freeTier": "A String", # Free tier value displayed in the Developers Console for this limit. |
| 279 | # The free tier is the number of tokens that will be subtracted from the |
| 280 | # billed amount when billing is enabled. |
| 281 | # This field can only be set on a limit with duration "1d", in a billable |
| 282 | # group; it is invalid on any other limit. If this field is not set, it |
| 283 | # defaults to 0, indicating that there is no free tier for this service. |
| 284 | # |
| 285 | # Used by group-based quotas only. |
| 286 | "values": { # Tiered limit values. You must specify this as a key:value pair, with an |
| 287 | # integer value that is the maximum number of requests allowed for the |
| 288 | # specified unit. Currently only STANDARD is supported. |
| 289 | "a_key": "A String", |
| 290 | }, |
| 291 | "name": "A String", # Name of the quota limit. |
| 292 | # |
| 293 | # The name must be provided, and it must be unique within the service. The |
| 294 | # name can only include alphanumeric characters as well as '-'. |
| 295 | # |
| 296 | # The maximum length of the limit name is 64 characters. |
| 297 | "description": "A String", # Optional. User-visible, extended description for this quota limit. |
| 298 | # Should be used only when more context is needed to understand this limit |
| 299 | # than provided by the limit's display name (see: `display_name`). |
| 300 | "maxLimit": "A String", # Maximum number of tokens that can be consumed during the specified |
| 301 | # duration. Client application developers can override the default limit up |
| 302 | # to this maximum. If specified, this value cannot be set to a value less |
| 303 | # than the default limit. If not specified, it is set to the default limit. |
| 304 | # |
| 305 | # To allow clients to apply overrides with no upper bound, set this to -1, |
| 306 | # indicating unlimited maximum quota. |
| 307 | # |
| 308 | # Used by group-based quotas only. |
| 309 | "metric": "A String", # The name of the metric this quota limit applies to. The quota limits with |
| 310 | # the same metric will be checked together during runtime. The metric must be |
| 311 | # defined within the service config. |
| 312 | "unit": "A String", # Specify the unit of the quota limit. It uses the same syntax as |
| 313 | # Metric.unit. The supported unit kinds are determined by the quota |
| 314 | # backend system. |
| 315 | # |
| 316 | # Here are some examples: |
| 317 | # * "1/min/{project}" for quota per minute per project. |
| 318 | # |
| 319 | # Note: the order of unit components is insignificant. |
| 320 | # The "1" at the beginning is required to follow the metric unit syntax. |
| 321 | "duration": "A String", # Duration of this limit in textual notation. Must be "100s" or "1d". |
| 322 | # |
| 323 | # Used by group-based quotas only. |
| 324 | "defaultLimit": "A String", # Default number of tokens that can be consumed during the specified |
| 325 | # duration. This is the number of tokens assigned when a client |
| 326 | # application developer activates the service for his/her project. |
| 327 | # |
| 328 | # Specifying a value of 0 will block all requests. This can be used if you |
| 329 | # are provisioning quota to selected consumers and blocking others. |
| 330 | # Similarly, a value of -1 will indicate an unlimited quota. No other |
| 331 | # negative values are allowed. |
| 332 | # |
| 333 | # Used by group-based quotas only. |
| 334 | }, |
| 335 | ], |
| 336 | "metricRules": [ # List of `MetricRule` definitions, each one mapping a selected method to one |
| 337 | # or more metrics. |
| 338 | { # Bind API methods to metrics. Binding a method to a metric causes that |
| 339 | # metric's configured quota behaviors to apply to the method call. |
| 340 | "selector": "A String", # Selects the methods to which this rule applies. |
| 341 | # |
| 342 | # Refer to selector for syntax details. |
| 343 | "metricCosts": { # Metrics to update when the selected methods are called, and the associated |
| 344 | # cost applied to each metric. |
| 345 | # |
| 346 | # The key of the map is the metric name, and the values are the amount |
| 347 | # increased for the metric against which the quota limits are defined. |
| 348 | # The value must not be negative. |
| 349 | "a_key": "A String", |
| 350 | }, |
| 351 | }, |
| 352 | ], |
| 353 | }, |
| 354 | "apis": [ # A list of API interfaces exported by this service. Contains only the names, |
| 355 | # versions, and method names of the interfaces. |
| 356 | { # Api is a light-weight descriptor for an API Interface. |
| 357 | # |
| 358 | # Interfaces are also described as "protocol buffer services" in some contexts, |
| 359 | # such as by the "service" keyword in a .proto file, but they are different |
| 360 | # from API Services, which represent a concrete implementation of an interface |
| 361 | # as opposed to simply a description of methods and bindings. They are also |
| 362 | # sometimes simply referred to as "APIs" in other contexts, such as the name of |
| 363 | # this message itself. See https://cloud.google.com/apis/design/glossary for |
| 364 | # detailed terminology. |
| 365 | "name": "A String", # The fully qualified name of this interface, including package name |
| 366 | # followed by the interface's simple name. |
| 367 | "options": [ # Any metadata attached to the interface. |
| 368 | { # A protocol buffer option, which can be attached to a message, field, |
| 369 | # enumeration, etc. |
| 370 | "name": "A String", # The option's name. For protobuf built-in options (options defined in |
| 371 | # descriptor.proto), this is the short name. For example, `"map_entry"`. |
| 372 | # For custom options, it should be the fully-qualified name. For example, |
| 373 | # `"google.api.http"`. |
| 374 | "value": { # The option's value packed in an Any message. If the value is a primitive, |
| 375 | # the corresponding wrapper type defined in google/protobuf/wrappers.proto |
| 376 | # should be used. If the value is an enum, it should be stored as an int32 |
| 377 | # value using the google.protobuf.Int32Value type. |
| 378 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 379 | }, |
| 380 | }, |
| 381 | ], |
| 382 | "syntax": "A String", # The source syntax of the service. |
| 383 | "methods": [ # The methods of this interface, in unspecified order. |
| 384 | { # Method represents a method of an API interface. |
| 385 | "responseStreaming": True or False, # If true, the response is streamed. |
| 386 | "name": "A String", # The simple name of this method. |
| 387 | "syntax": "A String", # The source syntax of this method. |
| 388 | "options": [ # Any metadata attached to the method. |
| 389 | { # A protocol buffer option, which can be attached to a message, field, |
| 390 | # enumeration, etc. |
| 391 | "name": "A String", # The option's name. For protobuf built-in options (options defined in |
| 392 | # descriptor.proto), this is the short name. For example, `"map_entry"`. |
| 393 | # For custom options, it should be the fully-qualified name. For example, |
| 394 | # `"google.api.http"`. |
| 395 | "value": { # The option's value packed in an Any message. If the value is a primitive, |
| 396 | # the corresponding wrapper type defined in google/protobuf/wrappers.proto |
| 397 | # should be used. If the value is an enum, it should be stored as an int32 |
| 398 | # value using the google.protobuf.Int32Value type. |
| 399 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 400 | }, |
| 401 | }, |
| 402 | ], |
| 403 | "requestStreaming": True or False, # If true, the request is streamed. |
| 404 | "requestTypeUrl": "A String", # A URL of the input message type. |
| 405 | "responseTypeUrl": "A String", # The URL of the output message type. |
| 406 | }, |
| 407 | ], |
| 408 | "sourceContext": { # `SourceContext` represents information about the source of a # Source context for the protocol buffer service represented by this |
| 409 | # message. |
| 410 | # protobuf element, like the file in which it is defined. |
| 411 | "fileName": "A String", # The path-qualified name of the .proto file that contained the associated |
| 412 | # protobuf element. For example: `"google/protobuf/source_context.proto"`. |
| 413 | }, |
| 414 | "version": "A String", # A version string for this interface. If specified, must have the form |
| 415 | # `major-version.minor-version`, as in `1.10`. If the minor version is |
| 416 | # omitted, it defaults to zero. If the entire version field is empty, the |
| 417 | # major version is derived from the package name, as outlined below. If the |
| 418 | # field is not empty, the version in the package name will be verified to be |
| 419 | # consistent with what is provided here. |
| 420 | # |
| 421 | # The versioning schema uses [semantic |
| 422 | # versioning](http://semver.org) where the major version number |
| 423 | # indicates a breaking change and the minor version an additive, |
| 424 | # non-breaking change. Both version numbers are signals to users |
| 425 | # what to expect from different versions, and should be carefully |
| 426 | # chosen based on the product plan. |
| 427 | # |
| 428 | # The major version is also reflected in the package name of the |
| 429 | # interface, which must end in `v<major-version>`, as in |
| 430 | # `google.feature.v1`. For major versions 0 and 1, the suffix can |
| 431 | # be omitted. Zero major versions must only be used for |
| 432 | # experimental, non-GA interfaces. |
| 433 | "mixins": [ # Included interfaces. See Mixin. |
| 434 | { # Declares an API Interface to be included in this interface. The including |
| 435 | # interface must redeclare all the methods from the included interface, but |
| 436 | # documentation and options are inherited as follows: |
| 437 | # |
| 438 | # - If after comment and whitespace stripping, the documentation |
| 439 | # string of the redeclared method is empty, it will be inherited |
| 440 | # from the original method. |
| 441 | # |
| 442 | # - Each annotation belonging to the service config (http, |
| 443 | # visibility) which is not set in the redeclared method will be |
| 444 | # inherited. |
| 445 | # |
| 446 | # - If an http annotation is inherited, the path pattern will be |
| 447 | # modified as follows. Any version prefix will be replaced by the |
| 448 | # version of the including interface plus the root path if |
| 449 | # specified. |
| 450 | # |
| 451 | # Example of a simple mixin: |
| 452 | # |
| 453 | # package google.acl.v1; |
| 454 | # service AccessControl { |
| 455 | # // Get the underlying ACL object. |
| 456 | # rpc GetAcl(GetAclRequest) returns (Acl) { |
| 457 | # option (google.api.http).get = "/v1/{resource=**}:getAcl"; |
| 458 | # } |
| 459 | # } |
| 460 | # |
| 461 | # package google.storage.v2; |
| 462 | # service Storage { |
| 463 | # // rpc GetAcl(GetAclRequest) returns (Acl); |
| 464 | # |
| 465 | # // Get a data record. |
| 466 | # rpc GetData(GetDataRequest) returns (Data) { |
| 467 | # option (google.api.http).get = "/v2/{resource=**}"; |
| 468 | # } |
| 469 | # } |
| 470 | # |
| 471 | # Example of a mixin configuration: |
| 472 | # |
| 473 | # apis: |
| 474 | # - name: google.storage.v2.Storage |
| 475 | # mixins: |
| 476 | # - name: google.acl.v1.AccessControl |
| 477 | # |
| 478 | # The mixin construct implies that all methods in `AccessControl` are |
| 479 | # also declared with same name and request/response types in |
| 480 | # `Storage`. A documentation generator or annotation processor will |
| 481 | # see the effective `Storage.GetAcl` method after inherting |
| 482 | # documentation and annotations as follows: |
| 483 | # |
| 484 | # service Storage { |
| 485 | # // Get the underlying ACL object. |
| 486 | # rpc GetAcl(GetAclRequest) returns (Acl) { |
| 487 | # option (google.api.http).get = "/v2/{resource=**}:getAcl"; |
| 488 | # } |
| 489 | # ... |
| 490 | # } |
| 491 | # |
| 492 | # Note how the version in the path pattern changed from `v1` to `v2`. |
| 493 | # |
| 494 | # If the `root` field in the mixin is specified, it should be a |
| 495 | # relative path under which inherited HTTP paths are placed. Example: |
| 496 | # |
| 497 | # apis: |
| 498 | # - name: google.storage.v2.Storage |
| 499 | # mixins: |
| 500 | # - name: google.acl.v1.AccessControl |
| 501 | # root: acls |
| 502 | # |
| 503 | # This implies the following inherited HTTP annotation: |
| 504 | # |
| 505 | # service Storage { |
| 506 | # // Get the underlying ACL object. |
| 507 | # rpc GetAcl(GetAclRequest) returns (Acl) { |
| 508 | # option (google.api.http).get = "/v2/acls/{resource=**}:getAcl"; |
| 509 | # } |
| 510 | # ... |
| 511 | # } |
| 512 | "name": "A String", # The fully qualified name of the interface which is included. |
| 513 | "root": "A String", # If non-empty specifies a path under which inherited HTTP paths |
| 514 | # are rooted. |
| 515 | }, |
| 516 | ], |
| 517 | }, |
| 518 | ], |
| 519 | "title": "A String", # The product title for this service. |
| 520 | "documentation": { # `Documentation` provides the information for describing a service. # Additional API documentation. Contains only the summary and the |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 521 | # documentation URL. |
| 522 | # |
| 523 | # Example: |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 524 | # <pre><code>documentation: |
| 525 | # summary: > |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 526 | # The Google Calendar API gives access |
| 527 | # to most calendar features. |
| 528 | # pages: |
| 529 | # - name: Overview |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 530 | # content: &#40;== include google/foo/overview.md ==&#41; |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 531 | # - name: Tutorial |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 532 | # content: &#40;== include google/foo/tutorial.md ==&#41; |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 533 | # subpages; |
| 534 | # - name: Java |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 535 | # content: &#40;== include google/foo/tutorial_java.md ==&#41; |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 536 | # rules: |
| 537 | # - selector: google.calendar.Calendar.Get |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 538 | # description: > |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 539 | # ... |
| 540 | # - selector: google.calendar.Calendar.Put |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 541 | # description: > |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 542 | # ... |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 543 | # </code></pre> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 544 | # Documentation is provided in markdown syntax. In addition to |
| 545 | # standard markdown features, definition lists, tables and fenced |
| 546 | # code blocks are supported. Section headers can be provided and are |
| 547 | # interpreted relative to the section nesting of the context where |
| 548 | # a documentation fragment is embedded. |
| 549 | # |
| 550 | # Documentation from the IDL is merged with documentation defined |
| 551 | # via the config at normalization time, where documentation provided |
| 552 | # by config rules overrides IDL provided. |
| 553 | # |
| 554 | # A number of constructs specific to the API platform are supported |
| 555 | # in documentation text. |
| 556 | # |
| 557 | # In order to reference a proto element, the following |
| 558 | # notation can be used: |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 559 | # <pre><code>&#91;fully.qualified.proto.name]&#91;]</code></pre> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 560 | # To override the display text used for the link, this can be used: |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 561 | # <pre><code>&#91;display text]&#91;fully.qualified.proto.name]</code></pre> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 562 | # Text can be excluded from doc using the following notation: |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 563 | # <pre><code>&#40;-- internal comment --&#41;</code></pre> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 564 | # |
| 565 | # A few directives are available in documentation. Note that |
| 566 | # directives must appear on a single line to be properly |
| 567 | # identified. The `include` directive includes a markdown file from |
| 568 | # an external source: |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 569 | # <pre><code>&#40;== include path/to/file ==&#41;</code></pre> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 570 | # The `resource_for` directive marks a message to be the resource of |
| 571 | # a collection in REST view. If it is not specified, tools attempt |
| 572 | # to infer the resource from the operations in a collection: |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 573 | # <pre><code>&#40;== resource_for v1.shelves.books ==&#41;</code></pre> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 574 | # The directive `suppress_warning` does not directly affect documentation |
| 575 | # and is documented together with service config validation. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 576 | "serviceRootUrl": "A String", # Specifies the service root url if the default one (the service name |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 577 | # from the yaml file) is not suitable. This can be seen in any fully |
| 578 | # specified service urls as well as sections that show a base that other |
| 579 | # urls are relative to. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 580 | "documentationRootUrl": "A String", # The URL to the root of documentation. |
| 581 | "summary": "A String", # A short summary of what the service does. Can only be provided by |
| 582 | # plain text. |
| 583 | "pages": [ # The top level pages for the documentation set. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 584 | { # Represents a documentation page. A page can contain subpages to represent |
| 585 | # nested documentation set structure. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 586 | "subpages": [ # Subpages of this page. The order of subpages specified here will be |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 587 | # honored in the generated docset. |
| 588 | # Object with schema name: Page |
| 589 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 590 | "name": "A String", # The name of the page. It will be used as an identity of the page to |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 591 | # generate URI of the page, text of the link to this page in navigation, |
| 592 | # etc. The full page name (start from the root page name to this page |
| 593 | # concatenated with `.`) can be used as reference to the page in your |
| 594 | # documentation. For example: |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 595 | # <pre><code>pages: |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 596 | # - name: Tutorial |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 597 | # content: &#40;== include tutorial.md ==&#41; |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 598 | # subpages: |
| 599 | # - name: Java |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 600 | # content: &#40;== include tutorial_java.md ==&#41; |
| 601 | # </code></pre> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 602 | # You can reference `Java` page using Markdown reference link syntax: |
| 603 | # `Java`. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 604 | "content": "A String", # The Markdown content of the page. You can use <code>&#40;== include {path} |
| 605 | # ==&#41;</code> to include content from a Markdown file. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 606 | }, |
| 607 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 608 | "overview": "A String", # Declares a single overview page. For example: |
| 609 | # <pre><code>documentation: |
| 610 | # summary: ... |
| 611 | # overview: &#40;== include overview.md ==&#41; |
| 612 | # </code></pre> |
| 613 | # This is a shortcut for the following declaration (using pages style): |
| 614 | # <pre><code>documentation: |
| 615 | # summary: ... |
| 616 | # pages: |
| 617 | # - name: Overview |
| 618 | # content: &#40;== include overview.md ==&#41; |
| 619 | # </code></pre> |
| 620 | # Note: you cannot specify both `overview` field and `pages` field. |
| 621 | "rules": [ # A list of documentation rules that apply to individual API elements. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 622 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 623 | # **NOTE:** All service configuration rules follow "last one wins" order. |
| 624 | { # A documentation rule provides information about individual API elements. |
| 625 | "deprecationDescription": "A String", # Deprecation description of the selected element(s). It can be provided if |
| 626 | # an element is marked as `deprecated`. |
| 627 | "description": "A String", # Description of the selected API(s). |
| 628 | "selector": "A String", # The selector is a comma-separated list of patterns. Each pattern is a |
| 629 | # qualified name of the element which may end in "*", indicating a wildcard. |
| 630 | # Wildcards are only allowed at the end and for a whole component of the |
| 631 | # qualified name, i.e. "foo.*" is ok, but not "foo.b*" or "foo.*.bar". A |
| 632 | # wildcard will match one or more components. To specify a default for all |
| 633 | # applicable elements, the whole pattern "*" is used. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 634 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 635 | ], |
| 636 | }, |
| 637 | "name": "A String", # The DNS address at which this service is available. |
| 638 | # |
| 639 | # An example DNS address would be: |
| 640 | # `calendar.googleapis.com`. |
| 641 | "authentication": { # `Authentication` defines the authentication configuration for an API. # Auth configuration. Contains only the OAuth rules. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 642 | # |
| 643 | # Example for an API targeted for external use: |
| 644 | # |
| 645 | # name: calendar.googleapis.com |
| 646 | # authentication: |
| 647 | # providers: |
| 648 | # - id: google_calendar_auth |
| 649 | # jwks_uri: https://www.googleapis.com/oauth2/v1/certs |
| 650 | # issuer: https://securetoken.google.com |
| 651 | # rules: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 652 | # - selector: "*" |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 653 | # requirements: |
| 654 | # provider_id: google_calendar_auth |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 655 | "providers": [ # Defines a set of authentication providers that a service supports. |
| 656 | { # Configuration for an authentication provider, including support for |
| 657 | # [JSON Web Token |
| 658 | # (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32). |
| 659 | "jwksUri": "A String", # URL of the provider's public key set to validate signature of the JWT. See |
| 660 | # [OpenID |
| 661 | # Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata). |
| 662 | # Optional if the key set document: |
| 663 | # - can be retrieved from |
| 664 | # [OpenID |
| 665 | # Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html of |
| 666 | # the issuer. |
| 667 | # - can be inferred from the email domain of the issuer (e.g. a Google |
| 668 | # service account). |
| 669 | # |
| 670 | # Example: https://www.googleapis.com/oauth2/v1/certs |
| 671 | "issuer": "A String", # Identifies the principal that issued the JWT. See |
| 672 | # https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.1 |
| 673 | # Usually a URL or an email address. |
| 674 | # |
| 675 | # Example: https://securetoken.google.com |
| 676 | # Example: 1234567-compute@developer.gserviceaccount.com |
| 677 | "id": "A String", # The unique identifier of the auth provider. It will be referred to by |
| 678 | # `AuthRequirement.provider_id`. |
| 679 | # |
| 680 | # Example: "bookstore_auth". |
| 681 | "jwtLocations": [ # Defines the locations to extract the JWT. |
| 682 | # |
| 683 | # JWT locations can be either from HTTP headers or URL query parameters. |
| 684 | # The rule is that the first match wins. The checking order is: checking |
| 685 | # all headers first, then URL query parameters. |
| 686 | # |
| 687 | # If not specified, default to use following 3 locations: |
| 688 | # 1) Authorization: Bearer |
| 689 | # 2) x-goog-iap-jwt-assertion |
| 690 | # 3) access_token query parameter |
| 691 | # |
| 692 | # Default locations can be specified as followings: |
| 693 | # jwt_locations: |
| 694 | # - header: Authorization |
| 695 | # value_prefix: "Bearer " |
| 696 | # - header: x-goog-iap-jwt-assertion |
| 697 | # - query: access_token |
| 698 | { # Specifies a location to extract JWT from an API request. |
| 699 | "query": "A String", # Specifies URL query parameter name to extract JWT token. |
| 700 | "header": "A String", # Specifies HTTP header name to extract JWT token. |
| 701 | "valuePrefix": "A String", # The value prefix. The value format is "value_prefix{token}" |
| 702 | # Only applies to "in" header type. Must be empty for "in" query type. |
| 703 | # If not empty, the header value has to match (case sensitive) this prefix. |
| 704 | # If not matched, JWT will not be extracted. If matched, JWT will be |
| 705 | # extracted after the prefix is removed. |
| 706 | # |
| 707 | # For example, for "Authorization: Bearer {JWT}", |
| 708 | # value_prefix="Bearer " with a space at the end. |
| 709 | }, |
| 710 | ], |
| 711 | "audiences": "A String", # The list of JWT |
| 712 | # [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3). |
| 713 | # that are allowed to access. A JWT containing any of these audiences will |
| 714 | # be accepted. When this setting is absent, JWTs with audiences: |
| 715 | # - "https://[service.name]/[google.protobuf.Api.name]" |
| 716 | # - "https://[service.name]/" |
| 717 | # will be accepted. |
| 718 | # For example, if no audiences are in the setting, LibraryService API will |
| 719 | # accept JWTs with the following audiences: |
| 720 | # - |
| 721 | # https://library-example.googleapis.com/google.example.library.v1.LibraryService |
| 722 | # - https://library-example.googleapis.com/ |
| 723 | # |
| 724 | # Example: |
| 725 | # |
| 726 | # audiences: bookstore_android.apps.googleusercontent.com, |
| 727 | # bookstore_web.apps.googleusercontent.com |
| 728 | "authorizationUrl": "A String", # Redirect URL if JWT token is required but not present or is expired. |
| 729 | # Implement authorizationUrl of securityDefinitions in OpenAPI spec. |
| 730 | }, |
| 731 | ], |
| 732 | "rules": [ # A list of authentication rules that apply to individual API methods. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 733 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 734 | # **NOTE:** All service configuration rules follow "last one wins" order. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 735 | { # Authentication rules for the service. |
| 736 | # |
| 737 | # By default, if a method has any authentication requirements, every request |
| 738 | # must include a valid credential matching one of the requirements. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 739 | # It's an error to include more than one kind of credential in a single |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 740 | # request. |
| 741 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 742 | # If a method doesn't have any auth requirements, request credentials will be |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 743 | # ignored. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 744 | "selector": "A String", # Selects the methods to which this rule applies. |
| 745 | # |
| 746 | # Refer to selector for syntax details. |
| 747 | "requirements": [ # Requirements for additional authentication providers. |
| 748 | { # User-defined authentication requirements, including support for |
| 749 | # [JSON Web Token |
| 750 | # (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32). |
| 751 | "providerId": "A String", # id from authentication provider. |
| 752 | # |
| 753 | # Example: |
| 754 | # |
| 755 | # provider_id: bookstore_auth |
| 756 | "audiences": "A String", # NOTE: This will be deprecated soon, once AuthProvider.audiences is |
| 757 | # implemented and accepted in all the runtime components. |
| 758 | # |
| 759 | # The list of JWT |
| 760 | # [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3). |
| 761 | # that are allowed to access. A JWT containing any of these audiences will |
| 762 | # be accepted. When this setting is absent, only JWTs with audience |
| 763 | # "https://Service_name/API_name" |
| 764 | # will be accepted. For example, if no audiences are in the setting, |
| 765 | # LibraryService API will only accept JWTs with the following audience |
| 766 | # "https://library-example.googleapis.com/google.example.library.v1.LibraryService". |
| 767 | # |
| 768 | # Example: |
| 769 | # |
| 770 | # audiences: bookstore_android.apps.googleusercontent.com, |
| 771 | # bookstore_web.apps.googleusercontent.com |
| 772 | }, |
| 773 | ], |
| 774 | "oauth": { # OAuth scopes are a way to define data and permissions on data. For example, # The requirements for OAuth credentials. |
| 775 | # there are scopes defined for "Read-only access to Google Calendar" and |
| 776 | # "Access to Cloud Platform". Users can consent to a scope for an application, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 777 | # giving it permission to access that data on their behalf. |
| 778 | # |
| 779 | # OAuth scope specifications should be fairly coarse grained; a user will need |
| 780 | # to see and understand the text description of what your scope means. |
| 781 | # |
| 782 | # In most cases: use one or at most two OAuth scopes for an entire family of |
| 783 | # products. If your product has multiple APIs, you should probably be sharing |
| 784 | # the OAuth scope across all of those APIs. |
| 785 | # |
| 786 | # When you need finer grained OAuth consent screens: talk with your product |
| 787 | # management about how developers will use them in practice. |
| 788 | # |
| 789 | # Please note that even though each of the canonical scopes is enough for a |
| 790 | # request to be accepted and passed to the backend, a request can still fail |
| 791 | # due to the backend requiring additional scopes or permissions. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 792 | "canonicalScopes": "A String", # The list of publicly documented OAuth scopes that are allowed access. An |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 793 | # OAuth token containing any of these scopes will be accepted. |
| 794 | # |
| 795 | # Example: |
| 796 | # |
| 797 | # canonical_scopes: https://www.googleapis.com/auth/calendar, |
| 798 | # https://www.googleapis.com/auth/calendar.read |
| 799 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 800 | "allowWithoutCredential": True or False, # If true, the service accepts API keys without any other credential. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 801 | }, |
| 802 | ], |
| 803 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 804 | "usage": { # Configuration controlling usage of a service. # Configuration controlling usage of this service. |
| 805 | "rules": [ # A list of usage rules that apply to individual API methods. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 806 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 807 | # **NOTE:** All service configuration rules follow "last one wins" order. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 808 | { # Usage configuration rules for the service. |
| 809 | # |
| 810 | # NOTE: Under development. |
| 811 | # |
| 812 | # |
| 813 | # Use this rule to configure unregistered calls for the service. Unregistered |
| 814 | # calls are calls that do not contain consumer project identity. |
| 815 | # (Example: calls that do not contain an API key). |
| 816 | # By default, API methods do not allow unregistered calls, and each method call |
| 817 | # must be identified by a consumer project identity. Use this rule to |
| 818 | # allow/disallow unregistered calls. |
| 819 | # |
| 820 | # Example of an API that wants to allow unregistered calls for entire service. |
| 821 | # |
| 822 | # usage: |
| 823 | # rules: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 824 | # - selector: "*" |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 825 | # allow_unregistered_calls: true |
| 826 | # |
| 827 | # Example of a method that wants to allow unregistered calls. |
| 828 | # |
| 829 | # usage: |
| 830 | # rules: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 831 | # - selector: "google.example.library.v1.LibraryService.CreateBook" |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 832 | # allow_unregistered_calls: true |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 833 | "skipServiceControl": True or False, # If true, the selected method should skip service control and the control |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 834 | # plane features, such as quota and billing, will not be available. |
| 835 | # This flag is used by Google Cloud Endpoints to bypass checks for internal |
| 836 | # methods, such as service health check methods. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 837 | "selector": "A String", # Selects the methods to which this rule applies. Use '*' to indicate all |
| 838 | # methods in all APIs. |
| 839 | # |
| 840 | # Refer to selector for syntax details. |
| 841 | "allowUnregisteredCalls": True or False, # If true, the selected method allows unregistered calls, e.g. calls |
| 842 | # that don't identify any user or application. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 843 | }, |
| 844 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 845 | "requirements": [ # Requirements that must be satisfied before a consumer project can use the |
| 846 | # service. Each requirement is of the form <service.name>/<requirement-id>; |
| 847 | # for example 'serviceusage.googleapis.com/billing-enabled'. |
| 848 | "A String", |
| 849 | ], |
| 850 | "producerNotificationChannel": "A String", # The full resource name of a channel used for sending notifications to the |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 851 | # service producer. |
| 852 | # |
| 853 | # Google Service Management currently only supports |
| 854 | # [Google Cloud Pub/Sub](https://cloud.google.com/pubsub) as a notification |
| 855 | # channel. To use Google Cloud Pub/Sub as the channel, this must be the name |
| 856 | # of a Cloud Pub/Sub topic that uses the Cloud Pub/Sub topic name format |
| 857 | # documented in https://cloud.google.com/pubsub/docs/overview. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 858 | "serviceIdentity": { # The per-product per-project service identity for a service. # The configuration of a per-product per-project service identity. |
| 859 | # |
| 860 | # |
| 861 | # Use this field to configure per-product per-project service identity. |
| 862 | # Example of a service identity configuration. |
| 863 | # |
| 864 | # usage: |
| 865 | # service_identity: |
| 866 | # - service_account_parent: "projects/123456789" |
| 867 | # display_name: "Cloud XXX Service Agent" |
| 868 | # description: "Used as the identity of Cloud XXX to access resources" |
| 869 | "description": "A String", # Optional. A user-specified opaque description of the service account. |
| 870 | # Must be less than or equal to 256 UTF-8 bytes. |
| 871 | "serviceAccountParent": "A String", # A service account project that hosts the service accounts. |
| 872 | # |
| 873 | # An example name would be: |
| 874 | # `projects/123456789` |
| 875 | "displayName": "A String", # Optional. A user-specified name for the service account. |
| 876 | # Must be less than or equal to 100 UTF-8 bytes. |
| 877 | }, |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 878 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 879 | "endpoints": [ # Configuration for network endpoints. Contains only the names and aliases |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 880 | # of the endpoints. |
| 881 | { # `Endpoint` describes a network endpoint that serves a set of APIs. |
| 882 | # A service may expose any number of endpoints, and all endpoints share the |
| 883 | # same service configuration, such as quota configuration and monitoring |
| 884 | # configuration. |
| 885 | # |
| 886 | # Example service configuration: |
| 887 | # |
| 888 | # name: library-example.googleapis.com |
| 889 | # endpoints: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 890 | # # Below entry makes 'google.example.library.v1.Library' |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 891 | # # API be served from endpoint address library-example.googleapis.com. |
| 892 | # # It also allows HTTP OPTIONS calls to be passed to the backend, for |
| 893 | # # it to decide whether the subsequent cross-origin request is |
| 894 | # # allowed to proceed. |
| 895 | # - name: library-example.googleapis.com |
| 896 | # allow_cors: true |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 897 | "features": [ # The list of features enabled on this endpoint. |
| 898 | "A String", |
| 899 | ], |
| 900 | "allowCors": True or False, # Allowing |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 901 | # [CORS](https://en.wikipedia.org/wiki/Cross-origin_resource_sharing), aka |
| 902 | # cross-domain traffic, would allow the backends served from this endpoint to |
| 903 | # receive and respond to HTTP OPTIONS requests. The response will be used by |
| 904 | # the browser to determine whether the subsequent cross-origin request is |
| 905 | # allowed to proceed. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 906 | "name": "A String", # The canonical name of this endpoint. |
| 907 | "aliases": [ # DEPRECATED: This field is no longer supported. Instead of using aliases, |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 908 | # please specify multiple google.api.Endpoint for each of the intended |
| 909 | # aliases. |
| 910 | # |
| 911 | # Additional names that this endpoint will be hosted on. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 912 | "A String", |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 913 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 914 | "target": "A String", # The specification of an Internet routable address of API frontend that will |
| 915 | # handle requests to this [API |
| 916 | # Endpoint](https://cloud.google.com/apis/design/glossary). It should be |
| 917 | # either a valid IPv4 address or a fully-qualified domain name. For example, |
| 918 | # "8.8.8.8" or "myservice.appspot.com". |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 919 | }, |
| 920 | ], |
| 921 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 922 | "state": "A String", # Whether or not the service has been enabled for use by the consumer. |
| 923 | "parent": "A String", # The resource name of the consumer. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 924 | # |
| 925 | # A valid name would be: |
| 926 | # - projects/123 |
| 927 | }, |
| 928 | ], |
| 929 | }</pre> |
| 930 | </div> |
| 931 | |
| 932 | <div class="method"> |
| 933 | <code class="details" id="disable">disable(name, body=None, x__xgafv=None)</code> |
| 934 | <pre>Disable a service so that it can no longer be used with a project. |
| 935 | This prevents unintended usage that may cause unexpected billing |
| 936 | charges or security leaks. |
| 937 | |
| 938 | It is not valid to call the disable method on a service that is not |
| 939 | currently enabled. Callers will receive a `FAILED_PRECONDITION` status if |
| 940 | the target service is not currently enabled. |
| 941 | |
| 942 | Args: |
| 943 | name: string, Name of the consumer and service to disable the service on. |
| 944 | |
| 945 | The enable and disable methods currently only support projects. |
| 946 | |
| 947 | An example name would be: |
| 948 | `projects/123/services/serviceusage.googleapis.com` where `123` is the |
| 949 | project number. (required) |
| 950 | body: object, The request body. |
| 951 | The object takes the form of: |
| 952 | |
| 953 | { # Request message for the `DisableService` method. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 954 | "disableDependentServices": True or False, # Indicates if services that are enabled and which depend on this service |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 955 | # should also be disabled. If not set, an error will be generated if any |
| 956 | # enabled services depend on the service to be disabled. When set, the |
| 957 | # service, and any enabled services that depend on it, will be disabled |
| 958 | # together. |
| 959 | } |
| 960 | |
| 961 | x__xgafv: string, V1 error format. |
| 962 | Allowed values |
| 963 | 1 - v1 error format |
| 964 | 2 - v2 error format |
| 965 | |
| 966 | Returns: |
| 967 | An object of the form: |
| 968 | |
| 969 | { # This resource represents a long-running operation that is the result of a |
| 970 | # network API call. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 971 | "done": True or False, # If the value is `false`, it means the operation is still in progress. |
| 972 | # If `true`, the operation is completed, and either `error` or `response` is |
| 973 | # available. |
| 974 | "metadata": { # Service-specific metadata associated with the operation. It typically |
| 975 | # contains progress information and common metadata such as create time. |
| 976 | # Some services might not provide such metadata. Any method that returns a |
| 977 | # long-running operation should document the metadata type, if any. |
| 978 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 979 | }, |
| 980 | "error": { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation. |
| 981 | # different programming environments, including REST APIs and RPC APIs. It is |
| 982 | # used by [gRPC](https://github.com/grpc). Each `Status` message contains |
| 983 | # three pieces of data: error code, error message, and error details. |
| 984 | # |
| 985 | # You can find out more about this error model and how to work with it in the |
| 986 | # [API Design Guide](https://cloud.google.com/apis/design/errors). |
| 987 | "details": [ # A list of messages that carry the error details. There is a common set of |
| 988 | # message types for APIs to use. |
| 989 | { |
| 990 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 991 | }, |
| 992 | ], |
| 993 | "message": "A String", # A developer-facing error message, which should be in English. Any |
| 994 | # user-facing error message should be localized and sent in the |
| 995 | # google.rpc.Status.details field, or localized by the client. |
| 996 | "code": 42, # The status code, which should be an enum value of google.rpc.Code. |
| 997 | }, |
| 998 | "name": "A String", # The server-assigned name, which is only unique within the same service that |
| 999 | # originally returns it. If you use the default HTTP mapping, the |
| 1000 | # `name` should be a resource name ending with `operations/{unique_id}`. |
| 1001 | "response": { # The normal response of the operation in case of success. If the original |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1002 | # method returns no data on success, such as `Delete`, the response is |
| 1003 | # `google.protobuf.Empty`. If the original method is standard |
| 1004 | # `Get`/`Create`/`Update`, the response should be the resource. For other |
| 1005 | # methods, the response should have the type `XxxResponse`, where `Xxx` |
| 1006 | # is the original method name. For example, if the original method name |
| 1007 | # is `TakeSnapshot()`, the inferred response type is |
| 1008 | # `TakeSnapshotResponse`. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1009 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1010 | }, |
| 1011 | }</pre> |
| 1012 | </div> |
| 1013 | |
| 1014 | <div class="method"> |
| 1015 | <code class="details" id="enable">enable(name, body=None, x__xgafv=None)</code> |
| 1016 | <pre>Enable a service so that it can be used with a project. |
| 1017 | |
| 1018 | Args: |
| 1019 | name: string, Name of the consumer and service to enable the service on. |
| 1020 | |
| 1021 | The `EnableService` and `DisableService` methods currently only support |
| 1022 | projects. |
| 1023 | |
| 1024 | Enabling a service requires that the service is public or is shared with |
| 1025 | the user enabling the service. |
| 1026 | |
| 1027 | An example name would be: |
| 1028 | `projects/123/services/serviceusage.googleapis.com` where `123` is the |
| 1029 | project number. (required) |
| 1030 | body: object, The request body. |
| 1031 | The object takes the form of: |
| 1032 | |
| 1033 | { # Request message for the `EnableService` method. |
| 1034 | } |
| 1035 | |
| 1036 | x__xgafv: string, V1 error format. |
| 1037 | Allowed values |
| 1038 | 1 - v1 error format |
| 1039 | 2 - v2 error format |
| 1040 | |
| 1041 | Returns: |
| 1042 | An object of the form: |
| 1043 | |
| 1044 | { # This resource represents a long-running operation that is the result of a |
| 1045 | # network API call. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1046 | "done": True or False, # If the value is `false`, it means the operation is still in progress. |
| 1047 | # If `true`, the operation is completed, and either `error` or `response` is |
| 1048 | # available. |
| 1049 | "metadata": { # Service-specific metadata associated with the operation. It typically |
| 1050 | # contains progress information and common metadata such as create time. |
| 1051 | # Some services might not provide such metadata. Any method that returns a |
| 1052 | # long-running operation should document the metadata type, if any. |
| 1053 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 1054 | }, |
| 1055 | "error": { # The `Status` type defines a logical error model that is suitable for # The error result of the operation in case of failure or cancellation. |
| 1056 | # different programming environments, including REST APIs and RPC APIs. It is |
| 1057 | # used by [gRPC](https://github.com/grpc). Each `Status` message contains |
| 1058 | # three pieces of data: error code, error message, and error details. |
| 1059 | # |
| 1060 | # You can find out more about this error model and how to work with it in the |
| 1061 | # [API Design Guide](https://cloud.google.com/apis/design/errors). |
| 1062 | "details": [ # A list of messages that carry the error details. There is a common set of |
| 1063 | # message types for APIs to use. |
| 1064 | { |
| 1065 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 1066 | }, |
| 1067 | ], |
| 1068 | "message": "A String", # A developer-facing error message, which should be in English. Any |
| 1069 | # user-facing error message should be localized and sent in the |
| 1070 | # google.rpc.Status.details field, or localized by the client. |
| 1071 | "code": 42, # The status code, which should be an enum value of google.rpc.Code. |
| 1072 | }, |
| 1073 | "name": "A String", # The server-assigned name, which is only unique within the same service that |
| 1074 | # originally returns it. If you use the default HTTP mapping, the |
| 1075 | # `name` should be a resource name ending with `operations/{unique_id}`. |
| 1076 | "response": { # The normal response of the operation in case of success. If the original |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1077 | # method returns no data on success, such as `Delete`, the response is |
| 1078 | # `google.protobuf.Empty`. If the original method is standard |
| 1079 | # `Get`/`Create`/`Update`, the response should be the resource. For other |
| 1080 | # methods, the response should have the type `XxxResponse`, where `Xxx` |
| 1081 | # is the original method name. For example, if the original method name |
| 1082 | # is `TakeSnapshot()`, the inferred response type is |
| 1083 | # `TakeSnapshotResponse`. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1084 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1085 | }, |
| 1086 | }</pre> |
| 1087 | </div> |
| 1088 | |
| 1089 | <div class="method"> |
| 1090 | <code class="details" id="get">get(name, x__xgafv=None)</code> |
| 1091 | <pre>Returns the service configuration and enabled state for a given service. |
| 1092 | |
| 1093 | Args: |
| 1094 | name: string, Name of the consumer and service to get the `ConsumerState` for. |
| 1095 | |
| 1096 | An example name would be: |
| 1097 | `projects/123/services/serviceusage.googleapis.com` where `123` is the |
| 1098 | project number. (required) |
| 1099 | x__xgafv: string, V1 error format. |
| 1100 | Allowed values |
| 1101 | 1 - v1 error format |
| 1102 | 2 - v2 error format |
| 1103 | |
| 1104 | Returns: |
| 1105 | An object of the form: |
| 1106 | |
| 1107 | { # A service that is available for use by the consumer. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1108 | "name": "A String", # The resource name of the consumer and service. |
| 1109 | # |
| 1110 | # A valid name would be: |
| 1111 | # - projects/123/services/serviceusage.googleapis.com |
| 1112 | "config": { # The configuration of the service. # The service configuration of the available service. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1113 | # Some fields may be filtered out of the configuration in responses to |
| 1114 | # the `ListServices` method. These fields are present only in responses to |
| 1115 | # the `GetService` method. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1116 | "quota": { # Quota configuration helps to achieve fairness and budgeting in service # Quota configuration. |
| 1117 | # usage. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1118 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1119 | # The metric based quota configuration works this way: |
| 1120 | # - The service configuration defines a set of metrics. |
| 1121 | # - For API calls, the quota.metric_rules maps methods to metrics with |
| 1122 | # corresponding costs. |
| 1123 | # - The quota.limits defines limits on the metrics, which will be used for |
| 1124 | # quota checks at runtime. |
| 1125 | # |
| 1126 | # An example quota configuration in yaml format: |
| 1127 | # |
| 1128 | # quota: |
| 1129 | # limits: |
| 1130 | # |
| 1131 | # - name: apiWriteQpsPerProject |
| 1132 | # metric: library.googleapis.com/write_calls |
| 1133 | # unit: "1/min/{project}" # rate limit for consumer projects |
| 1134 | # values: |
| 1135 | # STANDARD: 10000 |
| 1136 | # |
| 1137 | # |
| 1138 | # # The metric rules bind all methods to the read_calls metric, |
| 1139 | # # except for the UpdateBook and DeleteBook methods. These two methods |
| 1140 | # # are mapped to the write_calls metric, with the UpdateBook method |
| 1141 | # # consuming at twice rate as the DeleteBook method. |
| 1142 | # metric_rules: |
| 1143 | # - selector: "*" |
| 1144 | # metric_costs: |
| 1145 | # library.googleapis.com/read_calls: 1 |
| 1146 | # - selector: google.example.library.v1.LibraryService.UpdateBook |
| 1147 | # metric_costs: |
| 1148 | # library.googleapis.com/write_calls: 2 |
| 1149 | # - selector: google.example.library.v1.LibraryService.DeleteBook |
| 1150 | # metric_costs: |
| 1151 | # library.googleapis.com/write_calls: 1 |
| 1152 | # |
| 1153 | # Corresponding Metric definition: |
| 1154 | # |
| 1155 | # metrics: |
| 1156 | # - name: library.googleapis.com/read_calls |
| 1157 | # display_name: Read requests |
| 1158 | # metric_kind: DELTA |
| 1159 | # value_type: INT64 |
| 1160 | # |
| 1161 | # - name: library.googleapis.com/write_calls |
| 1162 | # display_name: Write requests |
| 1163 | # metric_kind: DELTA |
| 1164 | # value_type: INT64 |
| 1165 | # |
| 1166 | "limits": [ # List of `QuotaLimit` definitions for the service. |
| 1167 | { # `QuotaLimit` defines a specific limit that applies over a specified duration |
| 1168 | # for a limit type. There can be at most one limit for a duration and limit |
| 1169 | # type combination defined within a `QuotaGroup`. |
| 1170 | "displayName": "A String", # User-visible display name for this limit. |
| 1171 | # Optional. If not set, the UI will provide a default display name based on |
| 1172 | # the quota configuration. This field can be used to override the default |
| 1173 | # display name generated from the configuration. |
| 1174 | "freeTier": "A String", # Free tier value displayed in the Developers Console for this limit. |
| 1175 | # The free tier is the number of tokens that will be subtracted from the |
| 1176 | # billed amount when billing is enabled. |
| 1177 | # This field can only be set on a limit with duration "1d", in a billable |
| 1178 | # group; it is invalid on any other limit. If this field is not set, it |
| 1179 | # defaults to 0, indicating that there is no free tier for this service. |
| 1180 | # |
| 1181 | # Used by group-based quotas only. |
| 1182 | "values": { # Tiered limit values. You must specify this as a key:value pair, with an |
| 1183 | # integer value that is the maximum number of requests allowed for the |
| 1184 | # specified unit. Currently only STANDARD is supported. |
| 1185 | "a_key": "A String", |
| 1186 | }, |
| 1187 | "name": "A String", # Name of the quota limit. |
| 1188 | # |
| 1189 | # The name must be provided, and it must be unique within the service. The |
| 1190 | # name can only include alphanumeric characters as well as '-'. |
| 1191 | # |
| 1192 | # The maximum length of the limit name is 64 characters. |
| 1193 | "description": "A String", # Optional. User-visible, extended description for this quota limit. |
| 1194 | # Should be used only when more context is needed to understand this limit |
| 1195 | # than provided by the limit's display name (see: `display_name`). |
| 1196 | "maxLimit": "A String", # Maximum number of tokens that can be consumed during the specified |
| 1197 | # duration. Client application developers can override the default limit up |
| 1198 | # to this maximum. If specified, this value cannot be set to a value less |
| 1199 | # than the default limit. If not specified, it is set to the default limit. |
| 1200 | # |
| 1201 | # To allow clients to apply overrides with no upper bound, set this to -1, |
| 1202 | # indicating unlimited maximum quota. |
| 1203 | # |
| 1204 | # Used by group-based quotas only. |
| 1205 | "metric": "A String", # The name of the metric this quota limit applies to. The quota limits with |
| 1206 | # the same metric will be checked together during runtime. The metric must be |
| 1207 | # defined within the service config. |
| 1208 | "unit": "A String", # Specify the unit of the quota limit. It uses the same syntax as |
| 1209 | # Metric.unit. The supported unit kinds are determined by the quota |
| 1210 | # backend system. |
| 1211 | # |
| 1212 | # Here are some examples: |
| 1213 | # * "1/min/{project}" for quota per minute per project. |
| 1214 | # |
| 1215 | # Note: the order of unit components is insignificant. |
| 1216 | # The "1" at the beginning is required to follow the metric unit syntax. |
| 1217 | "duration": "A String", # Duration of this limit in textual notation. Must be "100s" or "1d". |
| 1218 | # |
| 1219 | # Used by group-based quotas only. |
| 1220 | "defaultLimit": "A String", # Default number of tokens that can be consumed during the specified |
| 1221 | # duration. This is the number of tokens assigned when a client |
| 1222 | # application developer activates the service for his/her project. |
| 1223 | # |
| 1224 | # Specifying a value of 0 will block all requests. This can be used if you |
| 1225 | # are provisioning quota to selected consumers and blocking others. |
| 1226 | # Similarly, a value of -1 will indicate an unlimited quota. No other |
| 1227 | # negative values are allowed. |
| 1228 | # |
| 1229 | # Used by group-based quotas only. |
| 1230 | }, |
| 1231 | ], |
| 1232 | "metricRules": [ # List of `MetricRule` definitions, each one mapping a selected method to one |
| 1233 | # or more metrics. |
| 1234 | { # Bind API methods to metrics. Binding a method to a metric causes that |
| 1235 | # metric's configured quota behaviors to apply to the method call. |
| 1236 | "selector": "A String", # Selects the methods to which this rule applies. |
| 1237 | # |
| 1238 | # Refer to selector for syntax details. |
| 1239 | "metricCosts": { # Metrics to update when the selected methods are called, and the associated |
| 1240 | # cost applied to each metric. |
| 1241 | # |
| 1242 | # The key of the map is the metric name, and the values are the amount |
| 1243 | # increased for the metric against which the quota limits are defined. |
| 1244 | # The value must not be negative. |
| 1245 | "a_key": "A String", |
| 1246 | }, |
| 1247 | }, |
| 1248 | ], |
| 1249 | }, |
| 1250 | "apis": [ # A list of API interfaces exported by this service. Contains only the names, |
| 1251 | # versions, and method names of the interfaces. |
| 1252 | { # Api is a light-weight descriptor for an API Interface. |
| 1253 | # |
| 1254 | # Interfaces are also described as "protocol buffer services" in some contexts, |
| 1255 | # such as by the "service" keyword in a .proto file, but they are different |
| 1256 | # from API Services, which represent a concrete implementation of an interface |
| 1257 | # as opposed to simply a description of methods and bindings. They are also |
| 1258 | # sometimes simply referred to as "APIs" in other contexts, such as the name of |
| 1259 | # this message itself. See https://cloud.google.com/apis/design/glossary for |
| 1260 | # detailed terminology. |
| 1261 | "name": "A String", # The fully qualified name of this interface, including package name |
| 1262 | # followed by the interface's simple name. |
| 1263 | "options": [ # Any metadata attached to the interface. |
| 1264 | { # A protocol buffer option, which can be attached to a message, field, |
| 1265 | # enumeration, etc. |
| 1266 | "name": "A String", # The option's name. For protobuf built-in options (options defined in |
| 1267 | # descriptor.proto), this is the short name. For example, `"map_entry"`. |
| 1268 | # For custom options, it should be the fully-qualified name. For example, |
| 1269 | # `"google.api.http"`. |
| 1270 | "value": { # The option's value packed in an Any message. If the value is a primitive, |
| 1271 | # the corresponding wrapper type defined in google/protobuf/wrappers.proto |
| 1272 | # should be used. If the value is an enum, it should be stored as an int32 |
| 1273 | # value using the google.protobuf.Int32Value type. |
| 1274 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 1275 | }, |
| 1276 | }, |
| 1277 | ], |
| 1278 | "syntax": "A String", # The source syntax of the service. |
| 1279 | "methods": [ # The methods of this interface, in unspecified order. |
| 1280 | { # Method represents a method of an API interface. |
| 1281 | "responseStreaming": True or False, # If true, the response is streamed. |
| 1282 | "name": "A String", # The simple name of this method. |
| 1283 | "syntax": "A String", # The source syntax of this method. |
| 1284 | "options": [ # Any metadata attached to the method. |
| 1285 | { # A protocol buffer option, which can be attached to a message, field, |
| 1286 | # enumeration, etc. |
| 1287 | "name": "A String", # The option's name. For protobuf built-in options (options defined in |
| 1288 | # descriptor.proto), this is the short name. For example, `"map_entry"`. |
| 1289 | # For custom options, it should be the fully-qualified name. For example, |
| 1290 | # `"google.api.http"`. |
| 1291 | "value": { # The option's value packed in an Any message. If the value is a primitive, |
| 1292 | # the corresponding wrapper type defined in google/protobuf/wrappers.proto |
| 1293 | # should be used. If the value is an enum, it should be stored as an int32 |
| 1294 | # value using the google.protobuf.Int32Value type. |
| 1295 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 1296 | }, |
| 1297 | }, |
| 1298 | ], |
| 1299 | "requestStreaming": True or False, # If true, the request is streamed. |
| 1300 | "requestTypeUrl": "A String", # A URL of the input message type. |
| 1301 | "responseTypeUrl": "A String", # The URL of the output message type. |
| 1302 | }, |
| 1303 | ], |
| 1304 | "sourceContext": { # `SourceContext` represents information about the source of a # Source context for the protocol buffer service represented by this |
| 1305 | # message. |
| 1306 | # protobuf element, like the file in which it is defined. |
| 1307 | "fileName": "A String", # The path-qualified name of the .proto file that contained the associated |
| 1308 | # protobuf element. For example: `"google/protobuf/source_context.proto"`. |
| 1309 | }, |
| 1310 | "version": "A String", # A version string for this interface. If specified, must have the form |
| 1311 | # `major-version.minor-version`, as in `1.10`. If the minor version is |
| 1312 | # omitted, it defaults to zero. If the entire version field is empty, the |
| 1313 | # major version is derived from the package name, as outlined below. If the |
| 1314 | # field is not empty, the version in the package name will be verified to be |
| 1315 | # consistent with what is provided here. |
| 1316 | # |
| 1317 | # The versioning schema uses [semantic |
| 1318 | # versioning](http://semver.org) where the major version number |
| 1319 | # indicates a breaking change and the minor version an additive, |
| 1320 | # non-breaking change. Both version numbers are signals to users |
| 1321 | # what to expect from different versions, and should be carefully |
| 1322 | # chosen based on the product plan. |
| 1323 | # |
| 1324 | # The major version is also reflected in the package name of the |
| 1325 | # interface, which must end in `v<major-version>`, as in |
| 1326 | # `google.feature.v1`. For major versions 0 and 1, the suffix can |
| 1327 | # be omitted. Zero major versions must only be used for |
| 1328 | # experimental, non-GA interfaces. |
| 1329 | "mixins": [ # Included interfaces. See Mixin. |
| 1330 | { # Declares an API Interface to be included in this interface. The including |
| 1331 | # interface must redeclare all the methods from the included interface, but |
| 1332 | # documentation and options are inherited as follows: |
| 1333 | # |
| 1334 | # - If after comment and whitespace stripping, the documentation |
| 1335 | # string of the redeclared method is empty, it will be inherited |
| 1336 | # from the original method. |
| 1337 | # |
| 1338 | # - Each annotation belonging to the service config (http, |
| 1339 | # visibility) which is not set in the redeclared method will be |
| 1340 | # inherited. |
| 1341 | # |
| 1342 | # - If an http annotation is inherited, the path pattern will be |
| 1343 | # modified as follows. Any version prefix will be replaced by the |
| 1344 | # version of the including interface plus the root path if |
| 1345 | # specified. |
| 1346 | # |
| 1347 | # Example of a simple mixin: |
| 1348 | # |
| 1349 | # package google.acl.v1; |
| 1350 | # service AccessControl { |
| 1351 | # // Get the underlying ACL object. |
| 1352 | # rpc GetAcl(GetAclRequest) returns (Acl) { |
| 1353 | # option (google.api.http).get = "/v1/{resource=**}:getAcl"; |
| 1354 | # } |
| 1355 | # } |
| 1356 | # |
| 1357 | # package google.storage.v2; |
| 1358 | # service Storage { |
| 1359 | # // rpc GetAcl(GetAclRequest) returns (Acl); |
| 1360 | # |
| 1361 | # // Get a data record. |
| 1362 | # rpc GetData(GetDataRequest) returns (Data) { |
| 1363 | # option (google.api.http).get = "/v2/{resource=**}"; |
| 1364 | # } |
| 1365 | # } |
| 1366 | # |
| 1367 | # Example of a mixin configuration: |
| 1368 | # |
| 1369 | # apis: |
| 1370 | # - name: google.storage.v2.Storage |
| 1371 | # mixins: |
| 1372 | # - name: google.acl.v1.AccessControl |
| 1373 | # |
| 1374 | # The mixin construct implies that all methods in `AccessControl` are |
| 1375 | # also declared with same name and request/response types in |
| 1376 | # `Storage`. A documentation generator or annotation processor will |
| 1377 | # see the effective `Storage.GetAcl` method after inherting |
| 1378 | # documentation and annotations as follows: |
| 1379 | # |
| 1380 | # service Storage { |
| 1381 | # // Get the underlying ACL object. |
| 1382 | # rpc GetAcl(GetAclRequest) returns (Acl) { |
| 1383 | # option (google.api.http).get = "/v2/{resource=**}:getAcl"; |
| 1384 | # } |
| 1385 | # ... |
| 1386 | # } |
| 1387 | # |
| 1388 | # Note how the version in the path pattern changed from `v1` to `v2`. |
| 1389 | # |
| 1390 | # If the `root` field in the mixin is specified, it should be a |
| 1391 | # relative path under which inherited HTTP paths are placed. Example: |
| 1392 | # |
| 1393 | # apis: |
| 1394 | # - name: google.storage.v2.Storage |
| 1395 | # mixins: |
| 1396 | # - name: google.acl.v1.AccessControl |
| 1397 | # root: acls |
| 1398 | # |
| 1399 | # This implies the following inherited HTTP annotation: |
| 1400 | # |
| 1401 | # service Storage { |
| 1402 | # // Get the underlying ACL object. |
| 1403 | # rpc GetAcl(GetAclRequest) returns (Acl) { |
| 1404 | # option (google.api.http).get = "/v2/acls/{resource=**}:getAcl"; |
| 1405 | # } |
| 1406 | # ... |
| 1407 | # } |
| 1408 | "name": "A String", # The fully qualified name of the interface which is included. |
| 1409 | "root": "A String", # If non-empty specifies a path under which inherited HTTP paths |
| 1410 | # are rooted. |
| 1411 | }, |
| 1412 | ], |
| 1413 | }, |
| 1414 | ], |
| 1415 | "title": "A String", # The product title for this service. |
| 1416 | "documentation": { # `Documentation` provides the information for describing a service. # Additional API documentation. Contains only the summary and the |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1417 | # documentation URL. |
| 1418 | # |
| 1419 | # Example: |
| 1420 | # <pre><code>documentation: |
| 1421 | # summary: > |
| 1422 | # The Google Calendar API gives access |
| 1423 | # to most calendar features. |
| 1424 | # pages: |
| 1425 | # - name: Overview |
| 1426 | # content: &#40;== include google/foo/overview.md ==&#41; |
| 1427 | # - name: Tutorial |
| 1428 | # content: &#40;== include google/foo/tutorial.md ==&#41; |
| 1429 | # subpages; |
| 1430 | # - name: Java |
| 1431 | # content: &#40;== include google/foo/tutorial_java.md ==&#41; |
| 1432 | # rules: |
| 1433 | # - selector: google.calendar.Calendar.Get |
| 1434 | # description: > |
| 1435 | # ... |
| 1436 | # - selector: google.calendar.Calendar.Put |
| 1437 | # description: > |
| 1438 | # ... |
| 1439 | # </code></pre> |
| 1440 | # Documentation is provided in markdown syntax. In addition to |
| 1441 | # standard markdown features, definition lists, tables and fenced |
| 1442 | # code blocks are supported. Section headers can be provided and are |
| 1443 | # interpreted relative to the section nesting of the context where |
| 1444 | # a documentation fragment is embedded. |
| 1445 | # |
| 1446 | # Documentation from the IDL is merged with documentation defined |
| 1447 | # via the config at normalization time, where documentation provided |
| 1448 | # by config rules overrides IDL provided. |
| 1449 | # |
| 1450 | # A number of constructs specific to the API platform are supported |
| 1451 | # in documentation text. |
| 1452 | # |
| 1453 | # In order to reference a proto element, the following |
| 1454 | # notation can be used: |
| 1455 | # <pre><code>&#91;fully.qualified.proto.name]&#91;]</code></pre> |
| 1456 | # To override the display text used for the link, this can be used: |
| 1457 | # <pre><code>&#91;display text]&#91;fully.qualified.proto.name]</code></pre> |
| 1458 | # Text can be excluded from doc using the following notation: |
| 1459 | # <pre><code>&#40;-- internal comment --&#41;</code></pre> |
| 1460 | # |
| 1461 | # A few directives are available in documentation. Note that |
| 1462 | # directives must appear on a single line to be properly |
| 1463 | # identified. The `include` directive includes a markdown file from |
| 1464 | # an external source: |
| 1465 | # <pre><code>&#40;== include path/to/file ==&#41;</code></pre> |
| 1466 | # The `resource_for` directive marks a message to be the resource of |
| 1467 | # a collection in REST view. If it is not specified, tools attempt |
| 1468 | # to infer the resource from the operations in a collection: |
| 1469 | # <pre><code>&#40;== resource_for v1.shelves.books ==&#41;</code></pre> |
| 1470 | # The directive `suppress_warning` does not directly affect documentation |
| 1471 | # and is documented together with service config validation. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1472 | "serviceRootUrl": "A String", # Specifies the service root url if the default one (the service name |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1473 | # from the yaml file) is not suitable. This can be seen in any fully |
| 1474 | # specified service urls as well as sections that show a base that other |
| 1475 | # urls are relative to. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1476 | "documentationRootUrl": "A String", # The URL to the root of documentation. |
| 1477 | "summary": "A String", # A short summary of what the service does. Can only be provided by |
| 1478 | # plain text. |
| 1479 | "pages": [ # The top level pages for the documentation set. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1480 | { # Represents a documentation page. A page can contain subpages to represent |
| 1481 | # nested documentation set structure. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1482 | "subpages": [ # Subpages of this page. The order of subpages specified here will be |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1483 | # honored in the generated docset. |
| 1484 | # Object with schema name: Page |
| 1485 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1486 | "name": "A String", # The name of the page. It will be used as an identity of the page to |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1487 | # generate URI of the page, text of the link to this page in navigation, |
| 1488 | # etc. The full page name (start from the root page name to this page |
| 1489 | # concatenated with `.`) can be used as reference to the page in your |
| 1490 | # documentation. For example: |
| 1491 | # <pre><code>pages: |
| 1492 | # - name: Tutorial |
| 1493 | # content: &#40;== include tutorial.md ==&#41; |
| 1494 | # subpages: |
| 1495 | # - name: Java |
| 1496 | # content: &#40;== include tutorial_java.md ==&#41; |
| 1497 | # </code></pre> |
| 1498 | # You can reference `Java` page using Markdown reference link syntax: |
| 1499 | # `Java`. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1500 | "content": "A String", # The Markdown content of the page. You can use <code>&#40;== include {path} |
| 1501 | # ==&#41;</code> to include content from a Markdown file. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1502 | }, |
| 1503 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1504 | "overview": "A String", # Declares a single overview page. For example: |
| 1505 | # <pre><code>documentation: |
| 1506 | # summary: ... |
| 1507 | # overview: &#40;== include overview.md ==&#41; |
| 1508 | # </code></pre> |
| 1509 | # This is a shortcut for the following declaration (using pages style): |
| 1510 | # <pre><code>documentation: |
| 1511 | # summary: ... |
| 1512 | # pages: |
| 1513 | # - name: Overview |
| 1514 | # content: &#40;== include overview.md ==&#41; |
| 1515 | # </code></pre> |
| 1516 | # Note: you cannot specify both `overview` field and `pages` field. |
| 1517 | "rules": [ # A list of documentation rules that apply to individual API elements. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1518 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1519 | # **NOTE:** All service configuration rules follow "last one wins" order. |
| 1520 | { # A documentation rule provides information about individual API elements. |
| 1521 | "deprecationDescription": "A String", # Deprecation description of the selected element(s). It can be provided if |
| 1522 | # an element is marked as `deprecated`. |
| 1523 | "description": "A String", # Description of the selected API(s). |
| 1524 | "selector": "A String", # The selector is a comma-separated list of patterns. Each pattern is a |
| 1525 | # qualified name of the element which may end in "*", indicating a wildcard. |
| 1526 | # Wildcards are only allowed at the end and for a whole component of the |
| 1527 | # qualified name, i.e. "foo.*" is ok, but not "foo.b*" or "foo.*.bar". A |
| 1528 | # wildcard will match one or more components. To specify a default for all |
| 1529 | # applicable elements, the whole pattern "*" is used. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1530 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1531 | ], |
| 1532 | }, |
| 1533 | "name": "A String", # The DNS address at which this service is available. |
| 1534 | # |
| 1535 | # An example DNS address would be: |
| 1536 | # `calendar.googleapis.com`. |
| 1537 | "authentication": { # `Authentication` defines the authentication configuration for an API. # Auth configuration. Contains only the OAuth rules. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1538 | # |
| 1539 | # Example for an API targeted for external use: |
| 1540 | # |
| 1541 | # name: calendar.googleapis.com |
| 1542 | # authentication: |
| 1543 | # providers: |
| 1544 | # - id: google_calendar_auth |
| 1545 | # jwks_uri: https://www.googleapis.com/oauth2/v1/certs |
| 1546 | # issuer: https://securetoken.google.com |
| 1547 | # rules: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1548 | # - selector: "*" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1549 | # requirements: |
| 1550 | # provider_id: google_calendar_auth |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1551 | "providers": [ # Defines a set of authentication providers that a service supports. |
| 1552 | { # Configuration for an authentication provider, including support for |
| 1553 | # [JSON Web Token |
| 1554 | # (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32). |
| 1555 | "jwksUri": "A String", # URL of the provider's public key set to validate signature of the JWT. See |
| 1556 | # [OpenID |
| 1557 | # Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata). |
| 1558 | # Optional if the key set document: |
| 1559 | # - can be retrieved from |
| 1560 | # [OpenID |
| 1561 | # Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html of |
| 1562 | # the issuer. |
| 1563 | # - can be inferred from the email domain of the issuer (e.g. a Google |
| 1564 | # service account). |
| 1565 | # |
| 1566 | # Example: https://www.googleapis.com/oauth2/v1/certs |
| 1567 | "issuer": "A String", # Identifies the principal that issued the JWT. See |
| 1568 | # https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.1 |
| 1569 | # Usually a URL or an email address. |
| 1570 | # |
| 1571 | # Example: https://securetoken.google.com |
| 1572 | # Example: 1234567-compute@developer.gserviceaccount.com |
| 1573 | "id": "A String", # The unique identifier of the auth provider. It will be referred to by |
| 1574 | # `AuthRequirement.provider_id`. |
| 1575 | # |
| 1576 | # Example: "bookstore_auth". |
| 1577 | "jwtLocations": [ # Defines the locations to extract the JWT. |
| 1578 | # |
| 1579 | # JWT locations can be either from HTTP headers or URL query parameters. |
| 1580 | # The rule is that the first match wins. The checking order is: checking |
| 1581 | # all headers first, then URL query parameters. |
| 1582 | # |
| 1583 | # If not specified, default to use following 3 locations: |
| 1584 | # 1) Authorization: Bearer |
| 1585 | # 2) x-goog-iap-jwt-assertion |
| 1586 | # 3) access_token query parameter |
| 1587 | # |
| 1588 | # Default locations can be specified as followings: |
| 1589 | # jwt_locations: |
| 1590 | # - header: Authorization |
| 1591 | # value_prefix: "Bearer " |
| 1592 | # - header: x-goog-iap-jwt-assertion |
| 1593 | # - query: access_token |
| 1594 | { # Specifies a location to extract JWT from an API request. |
| 1595 | "query": "A String", # Specifies URL query parameter name to extract JWT token. |
| 1596 | "header": "A String", # Specifies HTTP header name to extract JWT token. |
| 1597 | "valuePrefix": "A String", # The value prefix. The value format is "value_prefix{token}" |
| 1598 | # Only applies to "in" header type. Must be empty for "in" query type. |
| 1599 | # If not empty, the header value has to match (case sensitive) this prefix. |
| 1600 | # If not matched, JWT will not be extracted. If matched, JWT will be |
| 1601 | # extracted after the prefix is removed. |
| 1602 | # |
| 1603 | # For example, for "Authorization: Bearer {JWT}", |
| 1604 | # value_prefix="Bearer " with a space at the end. |
| 1605 | }, |
| 1606 | ], |
| 1607 | "audiences": "A String", # The list of JWT |
| 1608 | # [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3). |
| 1609 | # that are allowed to access. A JWT containing any of these audiences will |
| 1610 | # be accepted. When this setting is absent, JWTs with audiences: |
| 1611 | # - "https://[service.name]/[google.protobuf.Api.name]" |
| 1612 | # - "https://[service.name]/" |
| 1613 | # will be accepted. |
| 1614 | # For example, if no audiences are in the setting, LibraryService API will |
| 1615 | # accept JWTs with the following audiences: |
| 1616 | # - |
| 1617 | # https://library-example.googleapis.com/google.example.library.v1.LibraryService |
| 1618 | # - https://library-example.googleapis.com/ |
| 1619 | # |
| 1620 | # Example: |
| 1621 | # |
| 1622 | # audiences: bookstore_android.apps.googleusercontent.com, |
| 1623 | # bookstore_web.apps.googleusercontent.com |
| 1624 | "authorizationUrl": "A String", # Redirect URL if JWT token is required but not present or is expired. |
| 1625 | # Implement authorizationUrl of securityDefinitions in OpenAPI spec. |
| 1626 | }, |
| 1627 | ], |
| 1628 | "rules": [ # A list of authentication rules that apply to individual API methods. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1629 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1630 | # **NOTE:** All service configuration rules follow "last one wins" order. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1631 | { # Authentication rules for the service. |
| 1632 | # |
| 1633 | # By default, if a method has any authentication requirements, every request |
| 1634 | # must include a valid credential matching one of the requirements. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1635 | # It's an error to include more than one kind of credential in a single |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1636 | # request. |
| 1637 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1638 | # If a method doesn't have any auth requirements, request credentials will be |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1639 | # ignored. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1640 | "selector": "A String", # Selects the methods to which this rule applies. |
| 1641 | # |
| 1642 | # Refer to selector for syntax details. |
| 1643 | "requirements": [ # Requirements for additional authentication providers. |
| 1644 | { # User-defined authentication requirements, including support for |
| 1645 | # [JSON Web Token |
| 1646 | # (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32). |
| 1647 | "providerId": "A String", # id from authentication provider. |
| 1648 | # |
| 1649 | # Example: |
| 1650 | # |
| 1651 | # provider_id: bookstore_auth |
| 1652 | "audiences": "A String", # NOTE: This will be deprecated soon, once AuthProvider.audiences is |
| 1653 | # implemented and accepted in all the runtime components. |
| 1654 | # |
| 1655 | # The list of JWT |
| 1656 | # [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3). |
| 1657 | # that are allowed to access. A JWT containing any of these audiences will |
| 1658 | # be accepted. When this setting is absent, only JWTs with audience |
| 1659 | # "https://Service_name/API_name" |
| 1660 | # will be accepted. For example, if no audiences are in the setting, |
| 1661 | # LibraryService API will only accept JWTs with the following audience |
| 1662 | # "https://library-example.googleapis.com/google.example.library.v1.LibraryService". |
| 1663 | # |
| 1664 | # Example: |
| 1665 | # |
| 1666 | # audiences: bookstore_android.apps.googleusercontent.com, |
| 1667 | # bookstore_web.apps.googleusercontent.com |
| 1668 | }, |
| 1669 | ], |
| 1670 | "oauth": { # OAuth scopes are a way to define data and permissions on data. For example, # The requirements for OAuth credentials. |
| 1671 | # there are scopes defined for "Read-only access to Google Calendar" and |
| 1672 | # "Access to Cloud Platform". Users can consent to a scope for an application, |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1673 | # giving it permission to access that data on their behalf. |
| 1674 | # |
| 1675 | # OAuth scope specifications should be fairly coarse grained; a user will need |
| 1676 | # to see and understand the text description of what your scope means. |
| 1677 | # |
| 1678 | # In most cases: use one or at most two OAuth scopes for an entire family of |
| 1679 | # products. If your product has multiple APIs, you should probably be sharing |
| 1680 | # the OAuth scope across all of those APIs. |
| 1681 | # |
| 1682 | # When you need finer grained OAuth consent screens: talk with your product |
| 1683 | # management about how developers will use them in practice. |
| 1684 | # |
| 1685 | # Please note that even though each of the canonical scopes is enough for a |
| 1686 | # request to be accepted and passed to the backend, a request can still fail |
| 1687 | # due to the backend requiring additional scopes or permissions. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1688 | "canonicalScopes": "A String", # The list of publicly documented OAuth scopes that are allowed access. An |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1689 | # OAuth token containing any of these scopes will be accepted. |
| 1690 | # |
| 1691 | # Example: |
| 1692 | # |
| 1693 | # canonical_scopes: https://www.googleapis.com/auth/calendar, |
| 1694 | # https://www.googleapis.com/auth/calendar.read |
| 1695 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1696 | "allowWithoutCredential": True or False, # If true, the service accepts API keys without any other credential. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1697 | }, |
| 1698 | ], |
| 1699 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1700 | "usage": { # Configuration controlling usage of a service. # Configuration controlling usage of this service. |
| 1701 | "rules": [ # A list of usage rules that apply to individual API methods. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1702 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1703 | # **NOTE:** All service configuration rules follow "last one wins" order. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1704 | { # Usage configuration rules for the service. |
| 1705 | # |
| 1706 | # NOTE: Under development. |
| 1707 | # |
| 1708 | # |
| 1709 | # Use this rule to configure unregistered calls for the service. Unregistered |
| 1710 | # calls are calls that do not contain consumer project identity. |
| 1711 | # (Example: calls that do not contain an API key). |
| 1712 | # By default, API methods do not allow unregistered calls, and each method call |
| 1713 | # must be identified by a consumer project identity. Use this rule to |
| 1714 | # allow/disallow unregistered calls. |
| 1715 | # |
| 1716 | # Example of an API that wants to allow unregistered calls for entire service. |
| 1717 | # |
| 1718 | # usage: |
| 1719 | # rules: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1720 | # - selector: "*" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1721 | # allow_unregistered_calls: true |
| 1722 | # |
| 1723 | # Example of a method that wants to allow unregistered calls. |
| 1724 | # |
| 1725 | # usage: |
| 1726 | # rules: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1727 | # - selector: "google.example.library.v1.LibraryService.CreateBook" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1728 | # allow_unregistered_calls: true |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1729 | "skipServiceControl": True or False, # If true, the selected method should skip service control and the control |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1730 | # plane features, such as quota and billing, will not be available. |
| 1731 | # This flag is used by Google Cloud Endpoints to bypass checks for internal |
| 1732 | # methods, such as service health check methods. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1733 | "selector": "A String", # Selects the methods to which this rule applies. Use '*' to indicate all |
| 1734 | # methods in all APIs. |
| 1735 | # |
| 1736 | # Refer to selector for syntax details. |
| 1737 | "allowUnregisteredCalls": True or False, # If true, the selected method allows unregistered calls, e.g. calls |
| 1738 | # that don't identify any user or application. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1739 | }, |
| 1740 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1741 | "requirements": [ # Requirements that must be satisfied before a consumer project can use the |
| 1742 | # service. Each requirement is of the form <service.name>/<requirement-id>; |
| 1743 | # for example 'serviceusage.googleapis.com/billing-enabled'. |
| 1744 | "A String", |
| 1745 | ], |
| 1746 | "producerNotificationChannel": "A String", # The full resource name of a channel used for sending notifications to the |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1747 | # service producer. |
| 1748 | # |
| 1749 | # Google Service Management currently only supports |
| 1750 | # [Google Cloud Pub/Sub](https://cloud.google.com/pubsub) as a notification |
| 1751 | # channel. To use Google Cloud Pub/Sub as the channel, this must be the name |
| 1752 | # of a Cloud Pub/Sub topic that uses the Cloud Pub/Sub topic name format |
| 1753 | # documented in https://cloud.google.com/pubsub/docs/overview. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1754 | "serviceIdentity": { # The per-product per-project service identity for a service. # The configuration of a per-product per-project service identity. |
| 1755 | # |
| 1756 | # |
| 1757 | # Use this field to configure per-product per-project service identity. |
| 1758 | # Example of a service identity configuration. |
| 1759 | # |
| 1760 | # usage: |
| 1761 | # service_identity: |
| 1762 | # - service_account_parent: "projects/123456789" |
| 1763 | # display_name: "Cloud XXX Service Agent" |
| 1764 | # description: "Used as the identity of Cloud XXX to access resources" |
| 1765 | "description": "A String", # Optional. A user-specified opaque description of the service account. |
| 1766 | # Must be less than or equal to 256 UTF-8 bytes. |
| 1767 | "serviceAccountParent": "A String", # A service account project that hosts the service accounts. |
| 1768 | # |
| 1769 | # An example name would be: |
| 1770 | # `projects/123456789` |
| 1771 | "displayName": "A String", # Optional. A user-specified name for the service account. |
| 1772 | # Must be less than or equal to 100 UTF-8 bytes. |
| 1773 | }, |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1774 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1775 | "endpoints": [ # Configuration for network endpoints. Contains only the names and aliases |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1776 | # of the endpoints. |
| 1777 | { # `Endpoint` describes a network endpoint that serves a set of APIs. |
| 1778 | # A service may expose any number of endpoints, and all endpoints share the |
| 1779 | # same service configuration, such as quota configuration and monitoring |
| 1780 | # configuration. |
| 1781 | # |
| 1782 | # Example service configuration: |
| 1783 | # |
| 1784 | # name: library-example.googleapis.com |
| 1785 | # endpoints: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1786 | # # Below entry makes 'google.example.library.v1.Library' |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1787 | # # API be served from endpoint address library-example.googleapis.com. |
| 1788 | # # It also allows HTTP OPTIONS calls to be passed to the backend, for |
| 1789 | # # it to decide whether the subsequent cross-origin request is |
| 1790 | # # allowed to proceed. |
| 1791 | # - name: library-example.googleapis.com |
| 1792 | # allow_cors: true |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1793 | "features": [ # The list of features enabled on this endpoint. |
| 1794 | "A String", |
| 1795 | ], |
| 1796 | "allowCors": True or False, # Allowing |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1797 | # [CORS](https://en.wikipedia.org/wiki/Cross-origin_resource_sharing), aka |
| 1798 | # cross-domain traffic, would allow the backends served from this endpoint to |
| 1799 | # receive and respond to HTTP OPTIONS requests. The response will be used by |
| 1800 | # the browser to determine whether the subsequent cross-origin request is |
| 1801 | # allowed to proceed. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1802 | "name": "A String", # The canonical name of this endpoint. |
| 1803 | "aliases": [ # DEPRECATED: This field is no longer supported. Instead of using aliases, |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1804 | # please specify multiple google.api.Endpoint for each of the intended |
| 1805 | # aliases. |
| 1806 | # |
| 1807 | # Additional names that this endpoint will be hosted on. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1808 | "A String", |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1809 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1810 | "target": "A String", # The specification of an Internet routable address of API frontend that will |
| 1811 | # handle requests to this [API |
| 1812 | # Endpoint](https://cloud.google.com/apis/design/glossary). It should be |
| 1813 | # either a valid IPv4 address or a fully-qualified domain name. For example, |
| 1814 | # "8.8.8.8" or "myservice.appspot.com". |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1815 | }, |
| 1816 | ], |
| 1817 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1818 | "state": "A String", # Whether or not the service has been enabled for use by the consumer. |
| 1819 | "parent": "A String", # The resource name of the consumer. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1820 | # |
| 1821 | # A valid name would be: |
| 1822 | # - projects/123 |
| 1823 | }</pre> |
| 1824 | </div> |
| 1825 | |
| 1826 | <div class="method"> |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1827 | <code class="details" id="list">list(parent, pageSize=None, pageToken=None, filter=None, x__xgafv=None)</code> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1828 | <pre>List all services available to the specified project, and the current |
| 1829 | state of those services with respect to the project. The list includes |
| 1830 | all public services, all services for which the calling user has the |
| 1831 | `servicemanagement.services.bind` permission, and all services that have |
| 1832 | already been enabled on the project. The list can be filtered to |
| 1833 | only include services in a specific state, for example to only include |
| 1834 | services enabled on the project. |
| 1835 | |
| 1836 | Args: |
| 1837 | parent: string, Parent to search for services on. |
| 1838 | |
| 1839 | An example name would be: |
| 1840 | `projects/123` where `123` is the project number. (required) |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1841 | pageSize: integer, Requested size of the next page of data. |
| 1842 | Requested page size cannot exceed 200. |
| 1843 | If not set, the default page size is 50. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1844 | pageToken: string, Token identifying which result to start with, which is returned by a |
| 1845 | previous list call. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1846 | filter: string, Only list services that conform to the given filter. |
| 1847 | The allowed filter strings are `state:ENABLED` and `state:DISABLED`. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1848 | x__xgafv: string, V1 error format. |
| 1849 | Allowed values |
| 1850 | 1 - v1 error format |
| 1851 | 2 - v2 error format |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1852 | |
| 1853 | Returns: |
| 1854 | An object of the form: |
| 1855 | |
| 1856 | { # Response message for the `ListServices` method. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1857 | "nextPageToken": "A String", # Token that can be passed to `ListServices` to resume a paginated |
| 1858 | # query. |
| 1859 | "services": [ # The available services for the requested project. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1860 | { # A service that is available for use by the consumer. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1861 | "name": "A String", # The resource name of the consumer and service. |
| 1862 | # |
| 1863 | # A valid name would be: |
| 1864 | # - projects/123/services/serviceusage.googleapis.com |
| 1865 | "config": { # The configuration of the service. # The service configuration of the available service. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1866 | # Some fields may be filtered out of the configuration in responses to |
| 1867 | # the `ListServices` method. These fields are present only in responses to |
| 1868 | # the `GetService` method. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1869 | "quota": { # Quota configuration helps to achieve fairness and budgeting in service # Quota configuration. |
| 1870 | # usage. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1871 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1872 | # The metric based quota configuration works this way: |
| 1873 | # - The service configuration defines a set of metrics. |
| 1874 | # - For API calls, the quota.metric_rules maps methods to metrics with |
| 1875 | # corresponding costs. |
| 1876 | # - The quota.limits defines limits on the metrics, which will be used for |
| 1877 | # quota checks at runtime. |
| 1878 | # |
| 1879 | # An example quota configuration in yaml format: |
| 1880 | # |
| 1881 | # quota: |
| 1882 | # limits: |
| 1883 | # |
| 1884 | # - name: apiWriteQpsPerProject |
| 1885 | # metric: library.googleapis.com/write_calls |
| 1886 | # unit: "1/min/{project}" # rate limit for consumer projects |
| 1887 | # values: |
| 1888 | # STANDARD: 10000 |
| 1889 | # |
| 1890 | # |
| 1891 | # # The metric rules bind all methods to the read_calls metric, |
| 1892 | # # except for the UpdateBook and DeleteBook methods. These two methods |
| 1893 | # # are mapped to the write_calls metric, with the UpdateBook method |
| 1894 | # # consuming at twice rate as the DeleteBook method. |
| 1895 | # metric_rules: |
| 1896 | # - selector: "*" |
| 1897 | # metric_costs: |
| 1898 | # library.googleapis.com/read_calls: 1 |
| 1899 | # - selector: google.example.library.v1.LibraryService.UpdateBook |
| 1900 | # metric_costs: |
| 1901 | # library.googleapis.com/write_calls: 2 |
| 1902 | # - selector: google.example.library.v1.LibraryService.DeleteBook |
| 1903 | # metric_costs: |
| 1904 | # library.googleapis.com/write_calls: 1 |
| 1905 | # |
| 1906 | # Corresponding Metric definition: |
| 1907 | # |
| 1908 | # metrics: |
| 1909 | # - name: library.googleapis.com/read_calls |
| 1910 | # display_name: Read requests |
| 1911 | # metric_kind: DELTA |
| 1912 | # value_type: INT64 |
| 1913 | # |
| 1914 | # - name: library.googleapis.com/write_calls |
| 1915 | # display_name: Write requests |
| 1916 | # metric_kind: DELTA |
| 1917 | # value_type: INT64 |
| 1918 | # |
| 1919 | "limits": [ # List of `QuotaLimit` definitions for the service. |
| 1920 | { # `QuotaLimit` defines a specific limit that applies over a specified duration |
| 1921 | # for a limit type. There can be at most one limit for a duration and limit |
| 1922 | # type combination defined within a `QuotaGroup`. |
| 1923 | "displayName": "A String", # User-visible display name for this limit. |
| 1924 | # Optional. If not set, the UI will provide a default display name based on |
| 1925 | # the quota configuration. This field can be used to override the default |
| 1926 | # display name generated from the configuration. |
| 1927 | "freeTier": "A String", # Free tier value displayed in the Developers Console for this limit. |
| 1928 | # The free tier is the number of tokens that will be subtracted from the |
| 1929 | # billed amount when billing is enabled. |
| 1930 | # This field can only be set on a limit with duration "1d", in a billable |
| 1931 | # group; it is invalid on any other limit. If this field is not set, it |
| 1932 | # defaults to 0, indicating that there is no free tier for this service. |
| 1933 | # |
| 1934 | # Used by group-based quotas only. |
| 1935 | "values": { # Tiered limit values. You must specify this as a key:value pair, with an |
| 1936 | # integer value that is the maximum number of requests allowed for the |
| 1937 | # specified unit. Currently only STANDARD is supported. |
| 1938 | "a_key": "A String", |
| 1939 | }, |
| 1940 | "name": "A String", # Name of the quota limit. |
| 1941 | # |
| 1942 | # The name must be provided, and it must be unique within the service. The |
| 1943 | # name can only include alphanumeric characters as well as '-'. |
| 1944 | # |
| 1945 | # The maximum length of the limit name is 64 characters. |
| 1946 | "description": "A String", # Optional. User-visible, extended description for this quota limit. |
| 1947 | # Should be used only when more context is needed to understand this limit |
| 1948 | # than provided by the limit's display name (see: `display_name`). |
| 1949 | "maxLimit": "A String", # Maximum number of tokens that can be consumed during the specified |
| 1950 | # duration. Client application developers can override the default limit up |
| 1951 | # to this maximum. If specified, this value cannot be set to a value less |
| 1952 | # than the default limit. If not specified, it is set to the default limit. |
| 1953 | # |
| 1954 | # To allow clients to apply overrides with no upper bound, set this to -1, |
| 1955 | # indicating unlimited maximum quota. |
| 1956 | # |
| 1957 | # Used by group-based quotas only. |
| 1958 | "metric": "A String", # The name of the metric this quota limit applies to. The quota limits with |
| 1959 | # the same metric will be checked together during runtime. The metric must be |
| 1960 | # defined within the service config. |
| 1961 | "unit": "A String", # Specify the unit of the quota limit. It uses the same syntax as |
| 1962 | # Metric.unit. The supported unit kinds are determined by the quota |
| 1963 | # backend system. |
| 1964 | # |
| 1965 | # Here are some examples: |
| 1966 | # * "1/min/{project}" for quota per minute per project. |
| 1967 | # |
| 1968 | # Note: the order of unit components is insignificant. |
| 1969 | # The "1" at the beginning is required to follow the metric unit syntax. |
| 1970 | "duration": "A String", # Duration of this limit in textual notation. Must be "100s" or "1d". |
| 1971 | # |
| 1972 | # Used by group-based quotas only. |
| 1973 | "defaultLimit": "A String", # Default number of tokens that can be consumed during the specified |
| 1974 | # duration. This is the number of tokens assigned when a client |
| 1975 | # application developer activates the service for his/her project. |
| 1976 | # |
| 1977 | # Specifying a value of 0 will block all requests. This can be used if you |
| 1978 | # are provisioning quota to selected consumers and blocking others. |
| 1979 | # Similarly, a value of -1 will indicate an unlimited quota. No other |
| 1980 | # negative values are allowed. |
| 1981 | # |
| 1982 | # Used by group-based quotas only. |
| 1983 | }, |
| 1984 | ], |
| 1985 | "metricRules": [ # List of `MetricRule` definitions, each one mapping a selected method to one |
| 1986 | # or more metrics. |
| 1987 | { # Bind API methods to metrics. Binding a method to a metric causes that |
| 1988 | # metric's configured quota behaviors to apply to the method call. |
| 1989 | "selector": "A String", # Selects the methods to which this rule applies. |
| 1990 | # |
| 1991 | # Refer to selector for syntax details. |
| 1992 | "metricCosts": { # Metrics to update when the selected methods are called, and the associated |
| 1993 | # cost applied to each metric. |
| 1994 | # |
| 1995 | # The key of the map is the metric name, and the values are the amount |
| 1996 | # increased for the metric against which the quota limits are defined. |
| 1997 | # The value must not be negative. |
| 1998 | "a_key": "A String", |
| 1999 | }, |
| 2000 | }, |
| 2001 | ], |
| 2002 | }, |
| 2003 | "apis": [ # A list of API interfaces exported by this service. Contains only the names, |
| 2004 | # versions, and method names of the interfaces. |
| 2005 | { # Api is a light-weight descriptor for an API Interface. |
| 2006 | # |
| 2007 | # Interfaces are also described as "protocol buffer services" in some contexts, |
| 2008 | # such as by the "service" keyword in a .proto file, but they are different |
| 2009 | # from API Services, which represent a concrete implementation of an interface |
| 2010 | # as opposed to simply a description of methods and bindings. They are also |
| 2011 | # sometimes simply referred to as "APIs" in other contexts, such as the name of |
| 2012 | # this message itself. See https://cloud.google.com/apis/design/glossary for |
| 2013 | # detailed terminology. |
| 2014 | "name": "A String", # The fully qualified name of this interface, including package name |
| 2015 | # followed by the interface's simple name. |
| 2016 | "options": [ # Any metadata attached to the interface. |
| 2017 | { # A protocol buffer option, which can be attached to a message, field, |
| 2018 | # enumeration, etc. |
| 2019 | "name": "A String", # The option's name. For protobuf built-in options (options defined in |
| 2020 | # descriptor.proto), this is the short name. For example, `"map_entry"`. |
| 2021 | # For custom options, it should be the fully-qualified name. For example, |
| 2022 | # `"google.api.http"`. |
| 2023 | "value": { # The option's value packed in an Any message. If the value is a primitive, |
| 2024 | # the corresponding wrapper type defined in google/protobuf/wrappers.proto |
| 2025 | # should be used. If the value is an enum, it should be stored as an int32 |
| 2026 | # value using the google.protobuf.Int32Value type. |
| 2027 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 2028 | }, |
| 2029 | }, |
| 2030 | ], |
| 2031 | "syntax": "A String", # The source syntax of the service. |
| 2032 | "methods": [ # The methods of this interface, in unspecified order. |
| 2033 | { # Method represents a method of an API interface. |
| 2034 | "responseStreaming": True or False, # If true, the response is streamed. |
| 2035 | "name": "A String", # The simple name of this method. |
| 2036 | "syntax": "A String", # The source syntax of this method. |
| 2037 | "options": [ # Any metadata attached to the method. |
| 2038 | { # A protocol buffer option, which can be attached to a message, field, |
| 2039 | # enumeration, etc. |
| 2040 | "name": "A String", # The option's name. For protobuf built-in options (options defined in |
| 2041 | # descriptor.proto), this is the short name. For example, `"map_entry"`. |
| 2042 | # For custom options, it should be the fully-qualified name. For example, |
| 2043 | # `"google.api.http"`. |
| 2044 | "value": { # The option's value packed in an Any message. If the value is a primitive, |
| 2045 | # the corresponding wrapper type defined in google/protobuf/wrappers.proto |
| 2046 | # should be used. If the value is an enum, it should be stored as an int32 |
| 2047 | # value using the google.protobuf.Int32Value type. |
| 2048 | "a_key": "", # Properties of the object. Contains field @type with type URL. |
| 2049 | }, |
| 2050 | }, |
| 2051 | ], |
| 2052 | "requestStreaming": True or False, # If true, the request is streamed. |
| 2053 | "requestTypeUrl": "A String", # A URL of the input message type. |
| 2054 | "responseTypeUrl": "A String", # The URL of the output message type. |
| 2055 | }, |
| 2056 | ], |
| 2057 | "sourceContext": { # `SourceContext` represents information about the source of a # Source context for the protocol buffer service represented by this |
| 2058 | # message. |
| 2059 | # protobuf element, like the file in which it is defined. |
| 2060 | "fileName": "A String", # The path-qualified name of the .proto file that contained the associated |
| 2061 | # protobuf element. For example: `"google/protobuf/source_context.proto"`. |
| 2062 | }, |
| 2063 | "version": "A String", # A version string for this interface. If specified, must have the form |
| 2064 | # `major-version.minor-version`, as in `1.10`. If the minor version is |
| 2065 | # omitted, it defaults to zero. If the entire version field is empty, the |
| 2066 | # major version is derived from the package name, as outlined below. If the |
| 2067 | # field is not empty, the version in the package name will be verified to be |
| 2068 | # consistent with what is provided here. |
| 2069 | # |
| 2070 | # The versioning schema uses [semantic |
| 2071 | # versioning](http://semver.org) where the major version number |
| 2072 | # indicates a breaking change and the minor version an additive, |
| 2073 | # non-breaking change. Both version numbers are signals to users |
| 2074 | # what to expect from different versions, and should be carefully |
| 2075 | # chosen based on the product plan. |
| 2076 | # |
| 2077 | # The major version is also reflected in the package name of the |
| 2078 | # interface, which must end in `v<major-version>`, as in |
| 2079 | # `google.feature.v1`. For major versions 0 and 1, the suffix can |
| 2080 | # be omitted. Zero major versions must only be used for |
| 2081 | # experimental, non-GA interfaces. |
| 2082 | "mixins": [ # Included interfaces. See Mixin. |
| 2083 | { # Declares an API Interface to be included in this interface. The including |
| 2084 | # interface must redeclare all the methods from the included interface, but |
| 2085 | # documentation and options are inherited as follows: |
| 2086 | # |
| 2087 | # - If after comment and whitespace stripping, the documentation |
| 2088 | # string of the redeclared method is empty, it will be inherited |
| 2089 | # from the original method. |
| 2090 | # |
| 2091 | # - Each annotation belonging to the service config (http, |
| 2092 | # visibility) which is not set in the redeclared method will be |
| 2093 | # inherited. |
| 2094 | # |
| 2095 | # - If an http annotation is inherited, the path pattern will be |
| 2096 | # modified as follows. Any version prefix will be replaced by the |
| 2097 | # version of the including interface plus the root path if |
| 2098 | # specified. |
| 2099 | # |
| 2100 | # Example of a simple mixin: |
| 2101 | # |
| 2102 | # package google.acl.v1; |
| 2103 | # service AccessControl { |
| 2104 | # // Get the underlying ACL object. |
| 2105 | # rpc GetAcl(GetAclRequest) returns (Acl) { |
| 2106 | # option (google.api.http).get = "/v1/{resource=**}:getAcl"; |
| 2107 | # } |
| 2108 | # } |
| 2109 | # |
| 2110 | # package google.storage.v2; |
| 2111 | # service Storage { |
| 2112 | # // rpc GetAcl(GetAclRequest) returns (Acl); |
| 2113 | # |
| 2114 | # // Get a data record. |
| 2115 | # rpc GetData(GetDataRequest) returns (Data) { |
| 2116 | # option (google.api.http).get = "/v2/{resource=**}"; |
| 2117 | # } |
| 2118 | # } |
| 2119 | # |
| 2120 | # Example of a mixin configuration: |
| 2121 | # |
| 2122 | # apis: |
| 2123 | # - name: google.storage.v2.Storage |
| 2124 | # mixins: |
| 2125 | # - name: google.acl.v1.AccessControl |
| 2126 | # |
| 2127 | # The mixin construct implies that all methods in `AccessControl` are |
| 2128 | # also declared with same name and request/response types in |
| 2129 | # `Storage`. A documentation generator or annotation processor will |
| 2130 | # see the effective `Storage.GetAcl` method after inherting |
| 2131 | # documentation and annotations as follows: |
| 2132 | # |
| 2133 | # service Storage { |
| 2134 | # // Get the underlying ACL object. |
| 2135 | # rpc GetAcl(GetAclRequest) returns (Acl) { |
| 2136 | # option (google.api.http).get = "/v2/{resource=**}:getAcl"; |
| 2137 | # } |
| 2138 | # ... |
| 2139 | # } |
| 2140 | # |
| 2141 | # Note how the version in the path pattern changed from `v1` to `v2`. |
| 2142 | # |
| 2143 | # If the `root` field in the mixin is specified, it should be a |
| 2144 | # relative path under which inherited HTTP paths are placed. Example: |
| 2145 | # |
| 2146 | # apis: |
| 2147 | # - name: google.storage.v2.Storage |
| 2148 | # mixins: |
| 2149 | # - name: google.acl.v1.AccessControl |
| 2150 | # root: acls |
| 2151 | # |
| 2152 | # This implies the following inherited HTTP annotation: |
| 2153 | # |
| 2154 | # service Storage { |
| 2155 | # // Get the underlying ACL object. |
| 2156 | # rpc GetAcl(GetAclRequest) returns (Acl) { |
| 2157 | # option (google.api.http).get = "/v2/acls/{resource=**}:getAcl"; |
| 2158 | # } |
| 2159 | # ... |
| 2160 | # } |
| 2161 | "name": "A String", # The fully qualified name of the interface which is included. |
| 2162 | "root": "A String", # If non-empty specifies a path under which inherited HTTP paths |
| 2163 | # are rooted. |
| 2164 | }, |
| 2165 | ], |
| 2166 | }, |
| 2167 | ], |
| 2168 | "title": "A String", # The product title for this service. |
| 2169 | "documentation": { # `Documentation` provides the information for describing a service. # Additional API documentation. Contains only the summary and the |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2170 | # documentation URL. |
| 2171 | # |
| 2172 | # Example: |
| 2173 | # <pre><code>documentation: |
| 2174 | # summary: > |
| 2175 | # The Google Calendar API gives access |
| 2176 | # to most calendar features. |
| 2177 | # pages: |
| 2178 | # - name: Overview |
| 2179 | # content: &#40;== include google/foo/overview.md ==&#41; |
| 2180 | # - name: Tutorial |
| 2181 | # content: &#40;== include google/foo/tutorial.md ==&#41; |
| 2182 | # subpages; |
| 2183 | # - name: Java |
| 2184 | # content: &#40;== include google/foo/tutorial_java.md ==&#41; |
| 2185 | # rules: |
| 2186 | # - selector: google.calendar.Calendar.Get |
| 2187 | # description: > |
| 2188 | # ... |
| 2189 | # - selector: google.calendar.Calendar.Put |
| 2190 | # description: > |
| 2191 | # ... |
| 2192 | # </code></pre> |
| 2193 | # Documentation is provided in markdown syntax. In addition to |
| 2194 | # standard markdown features, definition lists, tables and fenced |
| 2195 | # code blocks are supported. Section headers can be provided and are |
| 2196 | # interpreted relative to the section nesting of the context where |
| 2197 | # a documentation fragment is embedded. |
| 2198 | # |
| 2199 | # Documentation from the IDL is merged with documentation defined |
| 2200 | # via the config at normalization time, where documentation provided |
| 2201 | # by config rules overrides IDL provided. |
| 2202 | # |
| 2203 | # A number of constructs specific to the API platform are supported |
| 2204 | # in documentation text. |
| 2205 | # |
| 2206 | # In order to reference a proto element, the following |
| 2207 | # notation can be used: |
| 2208 | # <pre><code>&#91;fully.qualified.proto.name]&#91;]</code></pre> |
| 2209 | # To override the display text used for the link, this can be used: |
| 2210 | # <pre><code>&#91;display text]&#91;fully.qualified.proto.name]</code></pre> |
| 2211 | # Text can be excluded from doc using the following notation: |
| 2212 | # <pre><code>&#40;-- internal comment --&#41;</code></pre> |
| 2213 | # |
| 2214 | # A few directives are available in documentation. Note that |
| 2215 | # directives must appear on a single line to be properly |
| 2216 | # identified. The `include` directive includes a markdown file from |
| 2217 | # an external source: |
| 2218 | # <pre><code>&#40;== include path/to/file ==&#41;</code></pre> |
| 2219 | # The `resource_for` directive marks a message to be the resource of |
| 2220 | # a collection in REST view. If it is not specified, tools attempt |
| 2221 | # to infer the resource from the operations in a collection: |
| 2222 | # <pre><code>&#40;== resource_for v1.shelves.books ==&#41;</code></pre> |
| 2223 | # The directive `suppress_warning` does not directly affect documentation |
| 2224 | # and is documented together with service config validation. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2225 | "serviceRootUrl": "A String", # Specifies the service root url if the default one (the service name |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2226 | # from the yaml file) is not suitable. This can be seen in any fully |
| 2227 | # specified service urls as well as sections that show a base that other |
| 2228 | # urls are relative to. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2229 | "documentationRootUrl": "A String", # The URL to the root of documentation. |
| 2230 | "summary": "A String", # A short summary of what the service does. Can only be provided by |
| 2231 | # plain text. |
| 2232 | "pages": [ # The top level pages for the documentation set. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2233 | { # Represents a documentation page. A page can contain subpages to represent |
| 2234 | # nested documentation set structure. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2235 | "subpages": [ # Subpages of this page. The order of subpages specified here will be |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2236 | # honored in the generated docset. |
| 2237 | # Object with schema name: Page |
| 2238 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2239 | "name": "A String", # The name of the page. It will be used as an identity of the page to |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2240 | # generate URI of the page, text of the link to this page in navigation, |
| 2241 | # etc. The full page name (start from the root page name to this page |
| 2242 | # concatenated with `.`) can be used as reference to the page in your |
| 2243 | # documentation. For example: |
| 2244 | # <pre><code>pages: |
| 2245 | # - name: Tutorial |
| 2246 | # content: &#40;== include tutorial.md ==&#41; |
| 2247 | # subpages: |
| 2248 | # - name: Java |
| 2249 | # content: &#40;== include tutorial_java.md ==&#41; |
| 2250 | # </code></pre> |
| 2251 | # You can reference `Java` page using Markdown reference link syntax: |
| 2252 | # `Java`. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2253 | "content": "A String", # The Markdown content of the page. You can use <code>&#40;== include {path} |
| 2254 | # ==&#41;</code> to include content from a Markdown file. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2255 | }, |
| 2256 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2257 | "overview": "A String", # Declares a single overview page. For example: |
| 2258 | # <pre><code>documentation: |
| 2259 | # summary: ... |
| 2260 | # overview: &#40;== include overview.md ==&#41; |
| 2261 | # </code></pre> |
| 2262 | # This is a shortcut for the following declaration (using pages style): |
| 2263 | # <pre><code>documentation: |
| 2264 | # summary: ... |
| 2265 | # pages: |
| 2266 | # - name: Overview |
| 2267 | # content: &#40;== include overview.md ==&#41; |
| 2268 | # </code></pre> |
| 2269 | # Note: you cannot specify both `overview` field and `pages` field. |
| 2270 | "rules": [ # A list of documentation rules that apply to individual API elements. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2271 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2272 | # **NOTE:** All service configuration rules follow "last one wins" order. |
| 2273 | { # A documentation rule provides information about individual API elements. |
| 2274 | "deprecationDescription": "A String", # Deprecation description of the selected element(s). It can be provided if |
| 2275 | # an element is marked as `deprecated`. |
| 2276 | "description": "A String", # Description of the selected API(s). |
| 2277 | "selector": "A String", # The selector is a comma-separated list of patterns. Each pattern is a |
| 2278 | # qualified name of the element which may end in "*", indicating a wildcard. |
| 2279 | # Wildcards are only allowed at the end and for a whole component of the |
| 2280 | # qualified name, i.e. "foo.*" is ok, but not "foo.b*" or "foo.*.bar". A |
| 2281 | # wildcard will match one or more components. To specify a default for all |
| 2282 | # applicable elements, the whole pattern "*" is used. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2283 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2284 | ], |
| 2285 | }, |
| 2286 | "name": "A String", # The DNS address at which this service is available. |
| 2287 | # |
| 2288 | # An example DNS address would be: |
| 2289 | # `calendar.googleapis.com`. |
| 2290 | "authentication": { # `Authentication` defines the authentication configuration for an API. # Auth configuration. Contains only the OAuth rules. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2291 | # |
| 2292 | # Example for an API targeted for external use: |
| 2293 | # |
| 2294 | # name: calendar.googleapis.com |
| 2295 | # authentication: |
| 2296 | # providers: |
| 2297 | # - id: google_calendar_auth |
| 2298 | # jwks_uri: https://www.googleapis.com/oauth2/v1/certs |
| 2299 | # issuer: https://securetoken.google.com |
| 2300 | # rules: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2301 | # - selector: "*" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2302 | # requirements: |
| 2303 | # provider_id: google_calendar_auth |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2304 | "providers": [ # Defines a set of authentication providers that a service supports. |
| 2305 | { # Configuration for an authentication provider, including support for |
| 2306 | # [JSON Web Token |
| 2307 | # (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32). |
| 2308 | "jwksUri": "A String", # URL of the provider's public key set to validate signature of the JWT. See |
| 2309 | # [OpenID |
| 2310 | # Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata). |
| 2311 | # Optional if the key set document: |
| 2312 | # - can be retrieved from |
| 2313 | # [OpenID |
| 2314 | # Discovery](https://openid.net/specs/openid-connect-discovery-1_0.html of |
| 2315 | # the issuer. |
| 2316 | # - can be inferred from the email domain of the issuer (e.g. a Google |
| 2317 | # service account). |
| 2318 | # |
| 2319 | # Example: https://www.googleapis.com/oauth2/v1/certs |
| 2320 | "issuer": "A String", # Identifies the principal that issued the JWT. See |
| 2321 | # https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.1 |
| 2322 | # Usually a URL or an email address. |
| 2323 | # |
| 2324 | # Example: https://securetoken.google.com |
| 2325 | # Example: 1234567-compute@developer.gserviceaccount.com |
| 2326 | "id": "A String", # The unique identifier of the auth provider. It will be referred to by |
| 2327 | # `AuthRequirement.provider_id`. |
| 2328 | # |
| 2329 | # Example: "bookstore_auth". |
| 2330 | "jwtLocations": [ # Defines the locations to extract the JWT. |
| 2331 | # |
| 2332 | # JWT locations can be either from HTTP headers or URL query parameters. |
| 2333 | # The rule is that the first match wins. The checking order is: checking |
| 2334 | # all headers first, then URL query parameters. |
| 2335 | # |
| 2336 | # If not specified, default to use following 3 locations: |
| 2337 | # 1) Authorization: Bearer |
| 2338 | # 2) x-goog-iap-jwt-assertion |
| 2339 | # 3) access_token query parameter |
| 2340 | # |
| 2341 | # Default locations can be specified as followings: |
| 2342 | # jwt_locations: |
| 2343 | # - header: Authorization |
| 2344 | # value_prefix: "Bearer " |
| 2345 | # - header: x-goog-iap-jwt-assertion |
| 2346 | # - query: access_token |
| 2347 | { # Specifies a location to extract JWT from an API request. |
| 2348 | "query": "A String", # Specifies URL query parameter name to extract JWT token. |
| 2349 | "header": "A String", # Specifies HTTP header name to extract JWT token. |
| 2350 | "valuePrefix": "A String", # The value prefix. The value format is "value_prefix{token}" |
| 2351 | # Only applies to "in" header type. Must be empty for "in" query type. |
| 2352 | # If not empty, the header value has to match (case sensitive) this prefix. |
| 2353 | # If not matched, JWT will not be extracted. If matched, JWT will be |
| 2354 | # extracted after the prefix is removed. |
| 2355 | # |
| 2356 | # For example, for "Authorization: Bearer {JWT}", |
| 2357 | # value_prefix="Bearer " with a space at the end. |
| 2358 | }, |
| 2359 | ], |
| 2360 | "audiences": "A String", # The list of JWT |
| 2361 | # [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3). |
| 2362 | # that are allowed to access. A JWT containing any of these audiences will |
| 2363 | # be accepted. When this setting is absent, JWTs with audiences: |
| 2364 | # - "https://[service.name]/[google.protobuf.Api.name]" |
| 2365 | # - "https://[service.name]/" |
| 2366 | # will be accepted. |
| 2367 | # For example, if no audiences are in the setting, LibraryService API will |
| 2368 | # accept JWTs with the following audiences: |
| 2369 | # - |
| 2370 | # https://library-example.googleapis.com/google.example.library.v1.LibraryService |
| 2371 | # - https://library-example.googleapis.com/ |
| 2372 | # |
| 2373 | # Example: |
| 2374 | # |
| 2375 | # audiences: bookstore_android.apps.googleusercontent.com, |
| 2376 | # bookstore_web.apps.googleusercontent.com |
| 2377 | "authorizationUrl": "A String", # Redirect URL if JWT token is required but not present or is expired. |
| 2378 | # Implement authorizationUrl of securityDefinitions in OpenAPI spec. |
| 2379 | }, |
| 2380 | ], |
| 2381 | "rules": [ # A list of authentication rules that apply to individual API methods. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2382 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2383 | # **NOTE:** All service configuration rules follow "last one wins" order. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2384 | { # Authentication rules for the service. |
| 2385 | # |
| 2386 | # By default, if a method has any authentication requirements, every request |
| 2387 | # must include a valid credential matching one of the requirements. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2388 | # It's an error to include more than one kind of credential in a single |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2389 | # request. |
| 2390 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2391 | # If a method doesn't have any auth requirements, request credentials will be |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2392 | # ignored. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2393 | "selector": "A String", # Selects the methods to which this rule applies. |
| 2394 | # |
| 2395 | # Refer to selector for syntax details. |
| 2396 | "requirements": [ # Requirements for additional authentication providers. |
| 2397 | { # User-defined authentication requirements, including support for |
| 2398 | # [JSON Web Token |
| 2399 | # (JWT)](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32). |
| 2400 | "providerId": "A String", # id from authentication provider. |
| 2401 | # |
| 2402 | # Example: |
| 2403 | # |
| 2404 | # provider_id: bookstore_auth |
| 2405 | "audiences": "A String", # NOTE: This will be deprecated soon, once AuthProvider.audiences is |
| 2406 | # implemented and accepted in all the runtime components. |
| 2407 | # |
| 2408 | # The list of JWT |
| 2409 | # [audiences](https://tools.ietf.org/html/draft-ietf-oauth-json-web-token-32#section-4.1.3). |
| 2410 | # that are allowed to access. A JWT containing any of these audiences will |
| 2411 | # be accepted. When this setting is absent, only JWTs with audience |
| 2412 | # "https://Service_name/API_name" |
| 2413 | # will be accepted. For example, if no audiences are in the setting, |
| 2414 | # LibraryService API will only accept JWTs with the following audience |
| 2415 | # "https://library-example.googleapis.com/google.example.library.v1.LibraryService". |
| 2416 | # |
| 2417 | # Example: |
| 2418 | # |
| 2419 | # audiences: bookstore_android.apps.googleusercontent.com, |
| 2420 | # bookstore_web.apps.googleusercontent.com |
| 2421 | }, |
| 2422 | ], |
| 2423 | "oauth": { # OAuth scopes are a way to define data and permissions on data. For example, # The requirements for OAuth credentials. |
| 2424 | # there are scopes defined for "Read-only access to Google Calendar" and |
| 2425 | # "Access to Cloud Platform". Users can consent to a scope for an application, |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2426 | # giving it permission to access that data on their behalf. |
| 2427 | # |
| 2428 | # OAuth scope specifications should be fairly coarse grained; a user will need |
| 2429 | # to see and understand the text description of what your scope means. |
| 2430 | # |
| 2431 | # In most cases: use one or at most two OAuth scopes for an entire family of |
| 2432 | # products. If your product has multiple APIs, you should probably be sharing |
| 2433 | # the OAuth scope across all of those APIs. |
| 2434 | # |
| 2435 | # When you need finer grained OAuth consent screens: talk with your product |
| 2436 | # management about how developers will use them in practice. |
| 2437 | # |
| 2438 | # Please note that even though each of the canonical scopes is enough for a |
| 2439 | # request to be accepted and passed to the backend, a request can still fail |
| 2440 | # due to the backend requiring additional scopes or permissions. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2441 | "canonicalScopes": "A String", # The list of publicly documented OAuth scopes that are allowed access. An |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2442 | # OAuth token containing any of these scopes will be accepted. |
| 2443 | # |
| 2444 | # Example: |
| 2445 | # |
| 2446 | # canonical_scopes: https://www.googleapis.com/auth/calendar, |
| 2447 | # https://www.googleapis.com/auth/calendar.read |
| 2448 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2449 | "allowWithoutCredential": True or False, # If true, the service accepts API keys without any other credential. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2450 | }, |
| 2451 | ], |
| 2452 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2453 | "usage": { # Configuration controlling usage of a service. # Configuration controlling usage of this service. |
| 2454 | "rules": [ # A list of usage rules that apply to individual API methods. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2455 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2456 | # **NOTE:** All service configuration rules follow "last one wins" order. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2457 | { # Usage configuration rules for the service. |
| 2458 | # |
| 2459 | # NOTE: Under development. |
| 2460 | # |
| 2461 | # |
| 2462 | # Use this rule to configure unregistered calls for the service. Unregistered |
| 2463 | # calls are calls that do not contain consumer project identity. |
| 2464 | # (Example: calls that do not contain an API key). |
| 2465 | # By default, API methods do not allow unregistered calls, and each method call |
| 2466 | # must be identified by a consumer project identity. Use this rule to |
| 2467 | # allow/disallow unregistered calls. |
| 2468 | # |
| 2469 | # Example of an API that wants to allow unregistered calls for entire service. |
| 2470 | # |
| 2471 | # usage: |
| 2472 | # rules: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2473 | # - selector: "*" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2474 | # allow_unregistered_calls: true |
| 2475 | # |
| 2476 | # Example of a method that wants to allow unregistered calls. |
| 2477 | # |
| 2478 | # usage: |
| 2479 | # rules: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2480 | # - selector: "google.example.library.v1.LibraryService.CreateBook" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2481 | # allow_unregistered_calls: true |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2482 | "skipServiceControl": True or False, # If true, the selected method should skip service control and the control |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2483 | # plane features, such as quota and billing, will not be available. |
| 2484 | # This flag is used by Google Cloud Endpoints to bypass checks for internal |
| 2485 | # methods, such as service health check methods. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2486 | "selector": "A String", # Selects the methods to which this rule applies. Use '*' to indicate all |
| 2487 | # methods in all APIs. |
| 2488 | # |
| 2489 | # Refer to selector for syntax details. |
| 2490 | "allowUnregisteredCalls": True or False, # If true, the selected method allows unregistered calls, e.g. calls |
| 2491 | # that don't identify any user or application. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2492 | }, |
| 2493 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2494 | "requirements": [ # Requirements that must be satisfied before a consumer project can use the |
| 2495 | # service. Each requirement is of the form <service.name>/<requirement-id>; |
| 2496 | # for example 'serviceusage.googleapis.com/billing-enabled'. |
| 2497 | "A String", |
| 2498 | ], |
| 2499 | "producerNotificationChannel": "A String", # The full resource name of a channel used for sending notifications to the |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 2500 | # service producer. |
| 2501 | # |
| 2502 | # Google Service Management currently only supports |
| 2503 | # [Google Cloud Pub/Sub](https://cloud.google.com/pubsub) as a notification |
| 2504 | # channel. To use Google Cloud Pub/Sub as the channel, this must be the name |
| 2505 | # of a Cloud Pub/Sub topic that uses the Cloud Pub/Sub topic name format |
| 2506 | # documented in https://cloud.google.com/pubsub/docs/overview. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2507 | "serviceIdentity": { # The per-product per-project service identity for a service. # The configuration of a per-product per-project service identity. |
| 2508 | # |
| 2509 | # |
| 2510 | # Use this field to configure per-product per-project service identity. |
| 2511 | # Example of a service identity configuration. |
| 2512 | # |
| 2513 | # usage: |
| 2514 | # service_identity: |
| 2515 | # - service_account_parent: "projects/123456789" |
| 2516 | # display_name: "Cloud XXX Service Agent" |
| 2517 | # description: "Used as the identity of Cloud XXX to access resources" |
| 2518 | "description": "A String", # Optional. A user-specified opaque description of the service account. |
| 2519 | # Must be less than or equal to 256 UTF-8 bytes. |
| 2520 | "serviceAccountParent": "A String", # A service account project that hosts the service accounts. |
| 2521 | # |
| 2522 | # An example name would be: |
| 2523 | # `projects/123456789` |
| 2524 | "displayName": "A String", # Optional. A user-specified name for the service account. |
| 2525 | # Must be less than or equal to 100 UTF-8 bytes. |
| 2526 | }, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2527 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2528 | "endpoints": [ # Configuration for network endpoints. Contains only the names and aliases |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2529 | # of the endpoints. |
| 2530 | { # `Endpoint` describes a network endpoint that serves a set of APIs. |
| 2531 | # A service may expose any number of endpoints, and all endpoints share the |
| 2532 | # same service configuration, such as quota configuration and monitoring |
| 2533 | # configuration. |
| 2534 | # |
| 2535 | # Example service configuration: |
| 2536 | # |
| 2537 | # name: library-example.googleapis.com |
| 2538 | # endpoints: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2539 | # # Below entry makes 'google.example.library.v1.Library' |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2540 | # # API be served from endpoint address library-example.googleapis.com. |
| 2541 | # # It also allows HTTP OPTIONS calls to be passed to the backend, for |
| 2542 | # # it to decide whether the subsequent cross-origin request is |
| 2543 | # # allowed to proceed. |
| 2544 | # - name: library-example.googleapis.com |
| 2545 | # allow_cors: true |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2546 | "features": [ # The list of features enabled on this endpoint. |
| 2547 | "A String", |
| 2548 | ], |
| 2549 | "allowCors": True or False, # Allowing |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2550 | # [CORS](https://en.wikipedia.org/wiki/Cross-origin_resource_sharing), aka |
| 2551 | # cross-domain traffic, would allow the backends served from this endpoint to |
| 2552 | # receive and respond to HTTP OPTIONS requests. The response will be used by |
| 2553 | # the browser to determine whether the subsequent cross-origin request is |
| 2554 | # allowed to proceed. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2555 | "name": "A String", # The canonical name of this endpoint. |
| 2556 | "aliases": [ # DEPRECATED: This field is no longer supported. Instead of using aliases, |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2557 | # please specify multiple google.api.Endpoint for each of the intended |
| 2558 | # aliases. |
| 2559 | # |
| 2560 | # Additional names that this endpoint will be hosted on. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2561 | "A String", |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2562 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2563 | "target": "A String", # The specification of an Internet routable address of API frontend that will |
| 2564 | # handle requests to this [API |
| 2565 | # Endpoint](https://cloud.google.com/apis/design/glossary). It should be |
| 2566 | # either a valid IPv4 address or a fully-qualified domain name. For example, |
| 2567 | # "8.8.8.8" or "myservice.appspot.com". |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2568 | }, |
| 2569 | ], |
| 2570 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2571 | "state": "A String", # Whether or not the service has been enabled for use by the consumer. |
| 2572 | "parent": "A String", # The resource name of the consumer. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2573 | # |
| 2574 | # A valid name would be: |
| 2575 | # - projects/123 |
| 2576 | }, |
| 2577 | ], |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2578 | }</pre> |
| 2579 | </div> |
| 2580 | |
| 2581 | <div class="method"> |
| 2582 | <code class="details" id="list_next">list_next(previous_request, previous_response)</code> |
| 2583 | <pre>Retrieves the next page of results. |
| 2584 | |
| 2585 | Args: |
| 2586 | previous_request: The request for the previous page. (required) |
| 2587 | previous_response: The response from the request for the previous page. (required) |
| 2588 | |
| 2589 | Returns: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 2590 | A request object that you can call 'execute()' on to request the next |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 2591 | page. Returns None if there are no more items in the collection. |
| 2592 | </pre> |
| 2593 | </div> |
| 2594 | |
| 2595 | </body></html> |