service.proto 6.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176
  1. // Copyright 2019 Google LLC.
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. //
  15. syntax = "proto3";
  16. package google.api;
  17. import "google/api/auth.proto";
  18. import "google/api/backend.proto";
  19. import "google/api/billing.proto";
  20. import "google/api/context.proto";
  21. import "google/api/control.proto";
  22. import "google/api/documentation.proto";
  23. import "google/api/endpoint.proto";
  24. import "google/api/http.proto";
  25. import "google/api/label.proto";
  26. import "google/api/log.proto";
  27. import "google/api/logging.proto";
  28. import "google/api/metric.proto";
  29. import "google/api/monitored_resource.proto";
  30. import "google/api/monitoring.proto";
  31. import "google/api/quota.proto";
  32. import "google/api/resource.proto";
  33. import "google/api/source_info.proto";
  34. import "google/api/system_parameter.proto";
  35. import "google/api/usage.proto";
  36. import "google/protobuf/any.proto";
  37. import "google/protobuf/api.proto";
  38. import "google/protobuf/type.proto";
  39. import "google/protobuf/wrappers.proto";
  40. option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";
  41. option java_multiple_files = true;
  42. option java_outer_classname = "ServiceProto";
  43. option java_package = "com.google.api";
  44. option objc_class_prefix = "GAPI";
  45. // `Service` is the root object of Google service configuration schema. It
  46. // describes basic information about a service, such as the name and the
  47. // title, and delegates other aspects to sub-sections. Each sub-section is
  48. // either a proto message or a repeated proto message that configures a
  49. // specific aspect, such as auth. See each proto message definition for details.
  50. //
  51. // Example:
  52. //
  53. // type: google.api.Service
  54. // config_version: 3
  55. // name: calendar.googleapis.com
  56. // title: Google Calendar API
  57. // apis:
  58. // - name: google.calendar.v3.Calendar
  59. // authentication:
  60. // providers:
  61. // - id: google_calendar_auth
  62. // jwks_uri: https://www.googleapis.com/oauth2/v1/certs
  63. // issuer: https://securetoken.google.com
  64. // rules:
  65. // - selector: "*"
  66. // requirements:
  67. // provider_id: google_calendar_auth
  68. message Service {
  69. // The semantic version of the service configuration. The config version
  70. // affects the interpretation of the service configuration. For example,
  71. // certain features are enabled by default for certain config versions.
  72. // The latest config version is `3`.
  73. google.protobuf.UInt32Value config_version = 20;
  74. // The service name, which is a DNS-like logical identifier for the
  75. // service, such as `calendar.googleapis.com`. The service name
  76. // typically goes through DNS verification to make sure the owner
  77. // of the service also owns the DNS name.
  78. string name = 1;
  79. // A unique ID for a specific instance of this message, typically assigned
  80. // by the client for tracking purpose. If empty, the server may choose to
  81. // generate one instead. Must be no longer than 60 characters.
  82. string id = 33;
  83. // The product title for this service.
  84. string title = 2;
  85. // The Google project that owns this service.
  86. string producer_project_id = 22;
  87. // A list of API interfaces exported by this service. Only the `name` field
  88. // of the [google.protobuf.Api][google.protobuf.Api] needs to be provided by the configuration
  89. // author, as the remaining fields will be derived from the IDL during the
  90. // normalization process. It is an error to specify an API interface here
  91. // which cannot be resolved against the associated IDL files.
  92. repeated google.protobuf.Api apis = 3;
  93. // A list of all proto message types included in this API service.
  94. // Types referenced directly or indirectly by the `apis` are
  95. // automatically included. Messages which are not referenced but
  96. // shall be included, such as types used by the `google.protobuf.Any` type,
  97. // should be listed here by name. Example:
  98. //
  99. // types:
  100. // - name: google.protobuf.Int32
  101. repeated google.protobuf.Type types = 4;
  102. // A list of all enum types included in this API service. Enums
  103. // referenced directly or indirectly by the `apis` are automatically
  104. // included. Enums which are not referenced but shall be included
  105. // should be listed here by name. Example:
  106. //
  107. // enums:
  108. // - name: google.someapi.v1.SomeEnum
  109. repeated google.protobuf.Enum enums = 5;
  110. // Additional API documentation.
  111. Documentation documentation = 6;
  112. // API backend configuration.
  113. Backend backend = 8;
  114. // HTTP configuration.
  115. Http http = 9;
  116. // Quota configuration.
  117. Quota quota = 10;
  118. // Auth configuration.
  119. Authentication authentication = 11;
  120. // Context configuration.
  121. Context context = 12;
  122. // Configuration controlling usage of this service.
  123. Usage usage = 15;
  124. // Configuration for network endpoints. If this is empty, then an endpoint
  125. // with the same name as the service is automatically generated to service all
  126. // defined APIs.
  127. repeated Endpoint endpoints = 18;
  128. // Configuration for the service control plane.
  129. Control control = 21;
  130. // Defines the logs used by this service.
  131. repeated LogDescriptor logs = 23;
  132. // Defines the metrics used by this service.
  133. repeated MetricDescriptor metrics = 24;
  134. // Defines the monitored resources used by this service. This is required
  135. // by the [Service.monitoring][google.api.Service.monitoring] and [Service.logging][google.api.Service.logging] configurations.
  136. repeated MonitoredResourceDescriptor monitored_resources = 25;
  137. // Billing configuration.
  138. Billing billing = 26;
  139. // Logging configuration.
  140. Logging logging = 27;
  141. // Monitoring configuration.
  142. Monitoring monitoring = 28;
  143. // System parameter configuration.
  144. SystemParameters system_parameters = 29;
  145. // Output only. The source information for this configuration if available.
  146. SourceInfo source_info = 37;
  147. }