@@ -143,6 +143,21 @@ message ComputeRoutesRequest {
143
143
FUEL_EFFICIENT = 1 ;
144
144
}
145
145
146
+ // Extra computations to perform while completing the request.
147
+ enum ExtraComputation {
148
+ // Not used. Requests containing this value will fail.
149
+ EXTRA_COMPUTATION_UNSPECIFIED = 0 ;
150
+
151
+ // Toll information for the route(s).
152
+ TOLLS = 1 ;
153
+
154
+ // Estimated fuel consumption for the route(s).
155
+ FUEL_CONSUMPTION = 2 ;
156
+
157
+ // Traffic aware polylines for the route(s).
158
+ TRAFFIC_ON_POLYLINE = 3 ;
159
+ }
160
+
146
161
// Required. Origin waypoint.
147
162
Waypoint origin = 1 [(google.api.field_behavior ) = REQUIRED ];
148
163
@@ -208,6 +223,13 @@ message ComputeRoutesRequest {
208
223
// parameters that would generate an optimal fuel efficient route.
209
224
repeated ReferenceRoute requested_reference_routes = 14
210
225
[(google.api.field_behavior ) = OPTIONAL ];
226
+
227
+ // Optional. A list of extra computations which may be used to complete the
228
+ // request. Note: These extra computations may return extra fields on the
229
+ // response. These extra fields must also be specified in the field mask to be
230
+ // returned in the response.
231
+ repeated ExtraComputation extra_computations = 15
232
+ [(google.api.field_behavior ) = OPTIONAL ];
211
233
}
212
234
213
235
// ComputeRoutes the response message.
@@ -228,6 +250,15 @@ message ComputeRoutesResponse {
228
250
229
251
// ComputeRouteMatrix request message
230
252
message ComputeRouteMatrixRequest {
253
+ // Extra computations to perform while completing the request.
254
+ enum ExtraComputation {
255
+ // Not used. Requests containing this value will fail.
256
+ EXTRA_COMPUTATION_UNSPECIFIED = 0 ;
257
+
258
+ // Toll information for the matrix element(s).
259
+ TOLLS = 1 ;
260
+ }
261
+
231
262
// Required. Array of origins, which determines the rows of the response
232
263
// matrix. Several size restrictions apply to the cardinality of origins and
233
264
// destinations:
@@ -262,6 +293,13 @@ message ComputeRouteMatrixRequest {
262
293
// has already occurred, the request fails.
263
294
google.protobuf.Timestamp departure_time = 5
264
295
[(google.api.field_behavior ) = OPTIONAL ];
296
+
297
+ // Optional. A list of extra computations which may be used to complete the
298
+ // request. Note: These extra computations may return extra fields on the
299
+ // response. These extra fields must also be specified in the field mask to be
300
+ // returned in the response.
301
+ repeated ExtraComputation extra_computations = 8
302
+ [(google.api.field_behavior ) = OPTIONAL ];
265
303
}
266
304
267
305
// A single origin for ComputeRouteMatrixRequest
0 commit comments