@@ -26,7 +26,7 @@ export interface Http {
2626 fullyDecodeReservedExpansion : boolean ;
2727}
2828/**
29- * # gRPC Transcoding
29+ * gRPC Transcoding
3030 *
3131 * gRPC Transcoding is a feature for mapping between a gRPC method and one or
3232 * more HTTP REST endpoints. It allows developers to build a single API service
@@ -67,9 +67,8 @@ export interface Http {
6767 *
6868 * This enables an HTTP REST to gRPC mapping as below:
6969 *
70- * HTTP | gRPC
71- * -----|-----
72- * `GET /v1/messages/123456` | `GetMessage(name: "messages/123456")`
70+ * - HTTP: `GET /v1/messages/123456`
71+ * - gRPC: `GetMessage(name: "messages/123456")`
7372 *
7473 * Any fields in the request message which are not bound by the path template
7574 * automatically become HTTP query parameters if there is no HTTP request body.
@@ -93,11 +92,9 @@ export interface Http {
9392 *
9493 * This enables a HTTP JSON to RPC mapping as below:
9594 *
96- * HTTP | gRPC
97- * -----|-----
98- * `GET /v1/messages/123456?revision=2&sub.subfield=foo` |
99- * `GetMessage(message_id: "123456" revision: 2 sub: SubMessage(subfield:
100- * "foo"))`
95+ * - HTTP: `GET /v1/messages/123456?revision=2&sub.subfield=foo`
96+ * - gRPC: `GetMessage(message_id: "123456" revision: 2 sub:
97+ * SubMessage(subfield: "foo"))`
10198 *
10299 * Note that fields which are mapped to URL query parameters must have a
103100 * primitive type or a repeated primitive type or a non-repeated message type.
@@ -127,10 +124,8 @@ export interface Http {
127124 * representation of the JSON in the request body is determined by
128125 * protos JSON encoding:
129126 *
130- * HTTP | gRPC
131- * -----|-----
132- * `PATCH /v1/messages/123456 { "text": "Hi!" }` | `UpdateMessage(message_id:
133- * "123456" message { text: "Hi!" })`
127+ * - HTTP: `PATCH /v1/messages/123456 { "text": "Hi!" }`
128+ * - gRPC: `UpdateMessage(message_id: "123456" message { text: "Hi!" })`
134129 *
135130 * The special name `*` can be used in the body mapping to define that
136131 * every field not bound by the path template should be mapped to the
@@ -153,10 +148,8 @@ export interface Http {
153148 *
154149 * The following HTTP JSON to RPC mapping is enabled:
155150 *
156- * HTTP | gRPC
157- * -----|-----
158- * `PATCH /v1/messages/123456 { "text": "Hi!" }` | `UpdateMessage(message_id:
159- * "123456" text: "Hi!")`
151+ * - HTTP: `PATCH /v1/messages/123456 { "text": "Hi!" }`
152+ * - gRPC: `UpdateMessage(message_id: "123456" text: "Hi!")`
160153 *
161154 * Note that when using `*` in the body mapping, it is not possible to
162155 * have HTTP parameters, as all fields not bound by the path end in
@@ -184,29 +177,32 @@ export interface Http {
184177 *
185178 * This enables the following two alternative HTTP JSON to RPC mappings:
186179 *
187- * HTTP | gRPC
188- * -----|-----
189- * `GET /v1/messages/123456` | `GetMessage(message_id: "123456")`
190- * `GET /v1/users/me/messages/123456` | `GetMessage(user_id: "me" message_id:
191- * "123456")`
180+ * - HTTP: `GET /v1/messages/123456`
181+ * - gRPC: `GetMessage(message_id: "123456")`
192182 *
193- * ## Rules for HTTP mapping
183+ * - HTTP: `GET /v1/users/me/messages/123456`
184+ * - gRPC: `GetMessage(user_id: "me" message_id: "123456")`
185+ *
186+ * Rules for HTTP mapping
194187 *
195188 * 1. Leaf request fields (recursive expansion nested messages in the request
196189 * message) are classified into three categories:
197190 * - Fields referred by the path template. They are passed via the URL path.
198- * - Fields referred by the [HttpRule.body][google.api.HttpRule.body]. They are passed via the HTTP
191+ * - Fields referred by the [HttpRule.body][google.api.HttpRule.body]. They
192+ * are passed via the HTTP
199193 * request body.
200194 * - All other fields are passed via the URL query parameters, and the
201195 * parameter name is the field path in the request message. A repeated
202196 * field can be represented as multiple query parameters under the same
203197 * name.
204- * 2. If [HttpRule.body][google.api.HttpRule.body] is "*", there is no URL query parameter, all fields
198+ * 2. If [HttpRule.body][google.api.HttpRule.body] is "*", there is no URL
199+ * query parameter, all fields
205200 * are passed via URL path and HTTP request body.
206- * 3. If [HttpRule.body][google.api.HttpRule.body] is omitted, there is no HTTP request body, all
201+ * 3. If [HttpRule.body][google.api.HttpRule.body] is omitted, there is no HTTP
202+ * request body, all
207203 * fields are passed via URL path and URL query parameters.
208204 *
209- * ### Path template syntax
205+ * Path template syntax
210206 *
211207 * Template = "/" Segments [ Verb ] ;
212208 * Segments = Segment { "/" Segment } ;
@@ -245,7 +241,7 @@ export interface Http {
245241 * Document](https://developers.google.com/discovery/v1/reference/apis) as
246242 * `{+var}`.
247243 *
248- * ## Using gRPC API Service Configuration
244+ * Using gRPC API Service Configuration
249245 *
250246 * gRPC API Service Configuration (service config) is a configuration language
251247 * for configuring a gRPC service to become a user-facing product. The
@@ -260,15 +256,14 @@ export interface Http {
260256 * specified in the service config will override any matching transcoding
261257 * configuration in the proto.
262258 *
263- * Example :
259+ * The following example selects a gRPC method and applies an `HttpRule` to it :
264260 *
265261 * http:
266262 * rules:
267- * # Selects a gRPC method and applies HttpRule to it.
268263 * - selector: example.v1.Messaging.GetMessage
269264 * get: /v1/messages/{message_id}/{sub.subfield}
270265 *
271- * ## Special notes
266+ * Special notes
272267 *
273268 * When gRPC Transcoding is used to map a gRPC to JSON REST endpoints, the
274269 * proto to JSON conversion must follow the [proto3
@@ -300,7 +295,8 @@ export interface HttpRule {
300295 /**
301296 * Selects a method to which this rule applies.
302297 *
303- * Refer to [selector][google.api.DocumentationRule.selector] for syntax details.
298+ * Refer to [selector][google.api.DocumentationRule.selector] for syntax
299+ * details.
304300 */
305301 selector : string ;
306302 /**
0 commit comments