As of January 1, 2020 this library no longer supports Python 2 on the latest released version. Library versions released prior to that date will continue to be available. For more information please visit Python 2 support on Google Cloud.

Types for Google Maps Fleetengine v1 API

class google.maps.fleetengine_v1.types.BatteryInfo(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Information about the device’s battery.

battery_status

Status of the battery, whether full or charging etc.

Type

google.maps.fleetengine_v1.types.BatteryStatus

power_source

Status of battery power source.

Type

google.maps.fleetengine_v1.types.PowerSource

battery_percentage

Current battery percentage [0-100].

Type

float

class google.maps.fleetengine_v1.types.BatteryStatus(value)[source]

Bases: proto.enums.Enum

Status of the battery, whether full or charging etc.

Values:
UNKNOWN_BATTERY_STATUS (0):

Battery status unknown.

BATTERY_STATUS_CHARGING (1):

Battery is being charged.

BATTERY_STATUS_DISCHARGING (2):

Battery is discharging.

BATTERY_STATUS_FULL (3):

Battery is full.

BATTERY_STATUS_NOT_CHARGING (4):

Battery is not charging.

BATTERY_STATUS_POWER_LOW (5):

Battery is low on power.

class google.maps.fleetengine_v1.types.BillingPlatformIdentifier(value)[source]

Bases: proto.enums.Enum

A set of values that indicate upon which platform the request was issued.

Values:
BILLING_PLATFORM_IDENTIFIER_UNSPECIFIED (0):

Default. Used for unspecified platforms.

SERVER (1):

The platform is a client server.

WEB (2):

The platform is a web browser.

ANDROID (3):

The platform is an Android mobile device.

IOS (4):

The platform is an IOS mobile device.

OTHERS (5):

Other platforms that are not listed in this enumeration.

class google.maps.fleetengine_v1.types.ConsumableTrafficPolyline(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Traffic density along a Vehicle’s path.

speed_reading_interval

Traffic speed along the path from the previous waypoint to the current waypoint.

Type

MutableSequence[google.maps.fleetengine_v1.types.SpeedReadingInterval]

encoded_path_to_waypoint

The path the driver is taking from the previous waypoint to the current waypoint. This path has landmarks in it so clients can show traffic markers along the path (see speed_reading_interval). Decoding is not yet supported.

Type

str

class google.maps.fleetengine_v1.types.CreateTripRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

CreateTrip request message.

header

The standard Fleet Engine request header.

Type

google.maps.fleetengine_v1.types.RequestHeader

parent

Required. Must be in the format providers/{provider}. The provider must be the Project ID (for example, sample-cloud-project) of the Google Cloud Project of which the service account making this call is a member.

Type

str

trip_id

Required. Unique Trip ID. Subject to the following restrictions:

  • Must be a valid Unicode string.

  • Limited to a maximum length of 64 characters.

  • Normalized according to [Unicode Normalization Form C] (http://www.unicode.org/reports/tr15/).

  • May not contain any of the following ASCII characters: ‘/’, ‘:’, ‘?’, ‘,’, or ‘#’.

Type

str

trip

Required. Trip entity to create.

When creating a Trip, the following fields are required:

  • trip_type

  • pickup_point

The following fields are used if you provide them:

  • number_of_passengers

  • vehicle_id

  • dropoff_point

  • intermediate_destinations

  • vehicle_waypoints

All other Trip fields are ignored. For example, all trips start with a trip_status of NEW even if you pass in a trip_status of CANCELED in the creation request.

Only EXCLUSIVE trips support intermediate_destinations.

When vehicle_id is set for a shared trip, you must supply the list of Trip.vehicle_waypoints to specify the order of the remaining waypoints for the vehicle, otherwise the waypoint order will be undetermined.

When you specify Trip.vehicle_waypoints, the list must contain all the remaining waypoints of the vehicle’s trips, with no extra waypoints. You must order these waypoints such that for a given trip, the pickup point is before intermediate destinations, and all intermediate destinations come before the drop-off point. An EXCLUSIVE trip’s waypoints must not interleave with any other trips.

The trip_id, waypoint_type and location fields are used, and all other TripWaypoint fields in vehicle_waypoints are ignored.

Type

google.maps.fleetengine_v1.types.Trip

class google.maps.fleetengine_v1.types.CreateVehicleRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

CreateVehicle request message.

header

The standard Fleet Engine request header.

Type

google.maps.fleetengine_v1.types.RequestHeader

parent

Required. Must be in the format providers/{provider}. The provider must be the Project ID (for example, sample-cloud-project) of the Google Cloud Project of which the service account making this call is a member.

Type

str

vehicle_id

Required. Unique Vehicle ID. Subject to the following restrictions:

  • Must be a valid Unicode string.

  • Limited to a maximum length of 64 characters.

  • Normalized according to [Unicode Normalization Form C] (http://www.unicode.org/reports/tr15/).

  • May not contain any of the following ASCII characters: ‘/’, ‘:’, ‘?’, ‘,’, or ‘#’.

Type

str

vehicle

Required. The Vehicle entity to create. When creating a Vehicle, the following fields are required:

  • vehicleState

  • supportedTripTypes

  • maximumCapacity

  • vehicleType

When creating a Vehicle, the following fields are ignored:

  • name

  • currentTrips

  • availableCapacity

  • current_route_segment

  • current_route_segment_end_point

  • current_route_segment_version

  • current_route_segment_traffic

  • route

  • waypoints

  • waypoints_version

  • remaining_distance_meters

  • remaining_time_seconds

  • eta_to_next_waypoint

  • navigation_status

All other fields are optional and used if provided.

Type

google.maps.fleetengine_v1.types.Vehicle

class google.maps.fleetengine_v1.types.DeviceSettings(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Information about various settings on the mobile device.

location_power_save_mode

How location features are set to behave on the device when battery saver is on.

Type

google.maps.fleetengine_v1.types.LocationPowerSaveMode

is_power_save_mode

Whether the device is currently in power save mode.

Type

bool

is_interactive

Whether the device is in an interactive state.

Type

bool

battery_info

Information about the battery state.

Type

google.maps.fleetengine_v1.types.BatteryInfo

class google.maps.fleetengine_v1.types.GetTripRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

GetTrip request message.

header

The standard Fleet Engine request header.

Type

google.maps.fleetengine_v1.types.RequestHeader

name

Required. Must be in the format providers/{provider}/trips/{trip}. The provider must be the Project ID (for example, sample-cloud-project) of the Google Cloud Project of which the service account making this call is a member.

Type

str

view

The subset of Trip fields that should be returned and their interpretation.

Type

google.maps.fleetengine_v1.types.TripView

current_route_segment_version

Indicates the minimum timestamp (exclusive) for which Trip.route or Trip.current_route_segment data are retrieved. If route data are unchanged since this timestamp, the route field is not set in the response. If a minimum is unspecified, the route data are always retrieved.

Type

google.protobuf.timestamp_pb2.Timestamp

remaining_waypoints_version

Indicates the minimum timestamp (exclusive) for which Trip.remaining_waypoints are retrieved. If they are unchanged since this timestamp, the remaining_waypoints are not set in the response. If this field is unspecified, remaining_waypoints is always retrieved.

Type

google.protobuf.timestamp_pb2.Timestamp

route_format_type

The returned current route format, LAT_LNG_LIST_TYPE (in Trip.route), or ENCODED_POLYLINE_TYPE (in Trip.current_route_segment). The default is LAT_LNG_LIST_TYPE.

Type

google.maps.fleetengine_v1.types.PolylineFormatType

current_route_segment_traffic_version

Indicates the minimum timestamp (exclusive) for which Trip.current_route_segment_traffic is retrieved. If traffic data are unchanged since this timestamp, the current_route_segment_traffic field is not set in the response. If a minimum is unspecified, the traffic data are always retrieved. Note that traffic is only available for On-Demand Rides and Deliveries Solution customers.

Type

google.protobuf.timestamp_pb2.Timestamp

remaining_waypoints_route_version

Indicates the minimum timestamp (exclusive) for which Trip.remaining_waypoints.traffic_to_waypoint and Trip.remaining_waypoints.path_to_waypoint data are retrieved. If data are unchanged since this timestamp, the fields above are not set in the response. If remaining_waypoints_route_version is unspecified, traffic and path are always retrieved.

Type

google.protobuf.timestamp_pb2.Timestamp

class google.maps.fleetengine_v1.types.GetVehicleRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

GetVehicle request message.

header

The standard Fleet Engine request header.

Type

google.maps.fleetengine_v1.types.RequestHeader

name

Required. Must be in the format providers/{provider}/vehicles/{vehicle}. The provider must be the Project ID (for example, sample-cloud-project) of the Google Cloud Project of which the service account making this call is a member.

Type

str

current_route_segment_version

Indicates the minimum timestamp (exclusive) for which Vehicle.current_route_segment is retrieved. If the route is unchanged since this timestamp, the current_route_segment field is not set in the response. If a minimum is unspecified, the current_route_segment is always retrieved.

Type

google.protobuf.timestamp_pb2.Timestamp

waypoints_version

Indicates the minimum timestamp (exclusive) for which Vehicle.waypoints data is retrieved. If the waypoints are unchanged since this timestamp, the vehicle.waypoints data is not set in the response. If this field is unspecified, vehicle.waypoints is always retrieved.

Type

google.protobuf.timestamp_pb2.Timestamp

class google.maps.fleetengine_v1.types.LicensePlate(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

The license plate information of the Vehicle. To avoid storing personally-identifiable information, only the minimum information about the license plate is stored as part of the entity.

country_code

Required. CLDR Country/Region Code. For example, US for United States, or IN for India.

Type

str

last_character

The last digit of the license plate or “-1” to denote no numeric value is present in the license plate.

  • “ABC 1234” -> “4”

  • “AB 123 CD” -> “3”

  • “ABCDEF” -> “-1”.

Type

str

class google.maps.fleetengine_v1.types.ListVehiclesRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

ListVehicles request message.

header

The standard Fleet Engine request header.

Type

google.maps.fleetengine_v1.types.RequestHeader

parent

Required. Must be in the format providers/{provider}. The provider must be the Project ID (for example, sample-cloud-project) of the Google Cloud Project of which the service account making this call is a member.

Type

str

page_size

The maximum number of vehicles to return. Default value: 100.

Type

int

page_token

The value of the next_page_token provided by a previous call to ListVehicles so that you can paginate through groups of vehicles. The value is undefined if the filter criteria of the request is not the same as the filter criteria for the previous call to ListVehicles.

Type

str

minimum_capacity

Specifies the required minimum capacity of the vehicle. All vehicles returned will have a maximum_capacity greater than or equal to this value. If set, must be greater or equal to 0.

Type

google.protobuf.wrappers_pb2.Int32Value

trip_types

Restricts the response to vehicles that support at least one of the specified trip types.

Type

MutableSequence[google.maps.fleetengine_v1.types.TripType]

maximum_staleness

Restricts the response to vehicles that have sent location updates to Fleet Engine within the specified duration. Stationary vehicles still transmitting their locations are not considered stale. If present, must be a valid positive duration.

Type

google.protobuf.duration_pb2.Duration

vehicle_type_categories

Required. Restricts the response to vehicles with one of the specified type categories. UNKNOWN is not allowed.

Type

MutableSequence[google.maps.fleetengine_v1.types.Vehicle.VehicleType.Category]

required_attributes

Callers can form complex logical operations using any combination of the required_attributes, required_one_of_attributes, and required_one_of_attribute_sets fields.

required_attributes is a list; required_one_of_attributes uses a message which allows a list of lists. In combination, the two fields allow the composition of this expression:

(required_attributes[0] AND required_attributes[1] AND ...)
AND
(required_one_of_attributes[0][0] OR required_one_of_attributes[0][1] OR
...)
AND
(required_one_of_attributes[1][0] OR required_one_of_attributes[1][1] OR
...)

Restricts the response to vehicles with the specified attributes. This field is a conjunction/AND operation. A max of 50 required_attributes is allowed. This matches the maximum number of attributes allowed on a vehicle. Each repeated string should be of the format “key:value”.

Type

MutableSequence[str]

required_one_of_attributes

Restricts the response to vehicles with at least one of the specified attributes in each VehicleAttributeList. Within each list, a vehicle must match at least one of the attributes. This field is an inclusive disjunction/OR operation in each VehicleAttributeList and a conjunction/AND operation across the collection of VehicleAttributeList. Each repeated string should be of the format “key1:value1|key2:value2|key3:value3”.

Type

MutableSequence[str]

required_one_of_attribute_sets

required_one_of_attribute_sets provides additional functionality.

Similar to required_one_of_attributes, required_one_of_attribute_sets uses a message which allows a list of lists, allowing expressions such as this one:

(required_attributes[0] AND required_attributes[1] AND ...)
AND
(
  (required_one_of_attribute_sets[0][0] AND
  required_one_of_attribute_sets[0][1] AND
  ...)
  OR
  (required_one_of_attribute_sets[1][0] AND
  required_one_of_attribute_sets[1][1] AND
  ...)
)

Restricts the response to vehicles that match all the attributes in a VehicleAttributeList. Within each list, a vehicle must match all of the attributes. This field is a conjunction/AND operation in each VehicleAttributeList and inclusive disjunction/OR operation across the collection of VehicleAttributeList. Each repeated string should be of the format “key1:value1|key2:value2|key3:value3”.

Type

MutableSequence[str]

vehicle_state

Restricts the response to vehicles that have this vehicle state.

Type

google.maps.fleetengine_v1.types.VehicleState

on_trip_only

Only return the vehicles with current trip(s).

Type

bool

filter

Optional. A filter query to apply when listing vehicles. See http://aip.dev/160 for examples of the filter syntax.

This field is designed to replace the required_attributes, required_one_of_attributes, and required_one_of_attributes_sets fields. If a non-empty value is specified here, the following fields must be empty: required_attributes, required_one_of_attributes, and required_one_of_attributes_sets.

This filter functions as an AND clause with other constraints, such as vehicle_state or on_trip_only.

Note that the only queries supported are on vehicle attributes (for example, attributes.<key> = <value> or attributes.<key1> = <value1> AND attributes.<key2> = <value2>). The maximum number of restrictions allowed in a filter query is 50.

Also, all attributes are stored as strings, so the only supported comparisons against attributes are string comparisons. In order to compare against number or boolean values, the values must be explicitly quoted to be treated as strings (for example, attributes.<key> = "10" or attributes.<key> = "true").

Type

str

viewport

Optional. A filter that limits the vehicles returned to those whose last known location was in the rectangular area defined by the viewport.

Type

google.geo.type.types.Viewport

class google.maps.fleetengine_v1.types.ListVehiclesResponse(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

ListVehicles response message.

vehicles

Vehicles matching the criteria in the request. The maximum number of vehicles returned is determined by the page_size field in the request.

Type

MutableSequence[google.maps.fleetengine_v1.types.Vehicle]

next_page_token

Token to retrieve the next page of vehicles, or empty if there are no more vehicles that meet the request criteria.

Type

str

total_size

Required. Total number of vehicles matching the request criteria across all pages.

Type

int

class google.maps.fleetengine_v1.types.LocationPowerSaveMode(value)[source]

Bases: proto.enums.Enum

How location features are configured to behave on the mobile device when the devices “battery saver” feature is on. (https://developer.android.com/reference/android/os/PowerManager#getLocationPowerSaveMode())

Values:
UNKNOWN_LOCATION_POWER_SAVE_MODE (0):

Undefined LocationPowerSaveMode

LOCATION_MODE_NO_CHANGE (1):

Either the location providers shouldn’t be affected by battery saver, or battery saver is off.

LOCATION_MODE_GPS_DISABLED_WHEN_SCREEN_OFF (2):

The GPS based location provider should be disabled when battery saver is on and the device is non-interactive.

LOCATION_MODE_ALL_DISABLED_WHEN_SCREEN_OFF (3):

All location providers should be disabled when battery saver is on and the device is non-interactive.

LOCATION_MODE_FOREGROUND_ONLY (4):

All the location providers will be kept available, but location fixes should only be provided to foreground apps.

LOCATION_MODE_THROTTLE_REQUESTS_WHEN_SCREEN_OFF (5):

Location will not be turned off, but LocationManager will throttle all requests to providers when the device is non-interactive.

class google.maps.fleetengine_v1.types.LocationSensor(value)[source]

Bases: proto.enums.Enum

The sensor or methodology used to determine the location.

Values:
UNKNOWN_SENSOR (0):

The sensor is unspecified or unknown.

GPS (1):

GPS or Assisted GPS.

NETWORK (2):

Assisted GPS, cell tower ID, or WiFi access point.

PASSIVE (3):

Cell tower ID or WiFi access point.

ROAD_SNAPPED_LOCATION_PROVIDER (4):

A location determined by the mobile device to be the most likely road position.

CUSTOMER_SUPPLIED_LOCATION (5):

A customer-supplied location from an independent source. Typically, this value is used for a location provided from sources other than the mobile device running Driver SDK. If the original source is described by one of the other enum values, use that value. Locations marked CUSTOMER_SUPPLIED_LOCATION are typically provided via a Vehicle’s last_location.supplemental_location_sensor.

FLEET_ENGINE_LOCATION (6):

A location calculated by Fleet Engine based on the signals available to it. Output only. This value will be rejected if it is received in a request.

FUSED_LOCATION_PROVIDER (100):

Android’s Fused Location Provider.

CORE_LOCATION (200):

The location provider on Apple operating systems.

class google.maps.fleetengine_v1.types.NavigationStatus(value)[source]

Bases: proto.enums.Enum

The vehicle’s navigation status.

Values:
UNKNOWN_NAVIGATION_STATUS (0):

Unspecified navigation status.

NO_GUIDANCE (1):

The Driver app’s navigation is in FREE_NAV mode.

ENROUTE_TO_DESTINATION (2):

Turn-by-turn navigation is available and the Driver app navigation has entered GUIDED_NAV mode.

OFF_ROUTE (3):

The vehicle has gone off the suggested route.

ARRIVED_AT_DESTINATION (4):

The vehicle is within approximately 50m of the destination.

class google.maps.fleetengine_v1.types.PolylineFormatType(value)[source]

Bases: proto.enums.Enum

The type of polyline format.

Values:
UNKNOWN_FORMAT_TYPE (0):

The format is unspecified or unknown.

LAT_LNG_LIST_TYPE (1):

A list of google.type.LatLng.

ENCODED_POLYLINE_TYPE (2):

A polyline encoded with a polyline compression algorithm. Decoding is not yet supported.

class google.maps.fleetengine_v1.types.PowerSource(value)[source]

Bases: proto.enums.Enum

Type of the charger being used to charge the battery.

Values:
UNKNOWN_POWER_SOURCE (0):

Power source unknown.

POWER_SOURCE_AC (1):

Power source is an AC charger.

POWER_SOURCE_USB (2):

Power source is a USB port.

POWER_SOURCE_WIRELESS (3):

Power source is wireless.

POWER_SOURCE_UNPLUGGED (4):

Battery is unplugged.

class google.maps.fleetengine_v1.types.ReportBillableTripRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

ReportBillableTrip request message.

name

Required. Must be in the format providers/{provider}/billableTrips/{billable_trip}. The provider must be the Project ID (for example, sample-cloud-project) of the Google Cloud Project of which the service account making this call is a member.

Type

str

country_code

Required. Two letter country code of the country where the trip takes place. Price is defined according to country code.

Type

str

platform

The platform upon which the request was issued.

Type

google.maps.fleetengine_v1.types.BillingPlatformIdentifier

related_ids

The identifiers that are directly related to the trip being reported. These are usually IDs (for example, session IDs) of pre-booking operations done before the trip ID is available. The number of related_ids is limited to 50.

Type

MutableSequence[str]

solution_type

The type of GMP product solution (for example, ON_DEMAND_RIDESHARING_AND_DELIVERIES) used for the reported trip.

Type

google.maps.fleetengine_v1.types.ReportBillableTripRequest.SolutionType

class SolutionType(value)[source]

Bases: proto.enums.Enum

Selector for different solution types of a reported trip.

Values:
SOLUTION_TYPE_UNSPECIFIED (0):

The default value. For backwards-compatibility, the API will use ON_DEMAND_RIDESHARING_AND_DELIVERIES by default which is the first supported solution type.

ON_DEMAND_RIDESHARING_AND_DELIVERIES (1):

The solution is an on-demand ridesharing and deliveries trip.

class google.maps.fleetengine_v1.types.RequestHeader(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

A RequestHeader contains fields common to all Fleet Engine RPC requests.

language_code

The BCP-47 language code, such as en-US or sr-Latn. For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. If none is specified, the response may be in any language, with a preference for English if such a name exists. Field value example: en-US.

Type

str

region_code

Required. CLDR region code of the region where the request originates. Field value example: US.

Type

str

sdk_version

Version of the calling SDK, if applicable. The version format is “major.minor.patch”, example: 1.1.2.

Type

str

os_version

Version of the operating system on which the calling SDK is running. Field value examples: 4.4.1, 12.1.

Type

str

device_model

Model of the device on which the calling SDK is running. Field value examples: iPhone12,1, SM-G920F.

Type

str

sdk_type

The type of SDK sending the request.

Type

google.maps.fleetengine_v1.types.RequestHeader.SdkType

maps_sdk_version

Version of the MapSDK which the calling SDK depends on, if applicable. The version format is “major.minor.patch”, example: 5.2.1.

Type

str

nav_sdk_version

Version of the NavSDK which the calling SDK depends on, if applicable. The version format is “major.minor.patch”, example: 2.1.0.

Type

str

platform

Platform of the calling SDK.

Type

google.maps.fleetengine_v1.types.RequestHeader.Platform

manufacturer

Manufacturer of the Android device from the calling SDK, only applicable for the Android SDKs. Field value example: Samsung.

Type

str

android_api_level

Android API level of the calling SDK, only applicable for the Android SDKs. Field value example: 23.

Type

int

trace_id

Optional ID that can be provided for logging purposes in order to identify the request.

Type

str

class Platform(value)[source]

Bases: proto.enums.Enum

The platform of the calling SDK.

Values:
PLATFORM_UNSPECIFIED (0):

The default value. This value is used if the platform is omitted.

ANDROID (1):

The request is coming from Android.

IOS (2):

The request is coming from iOS.

WEB (3):

The request is coming from the web.

class SdkType(value)[source]

Bases: proto.enums.Enum

Possible types of SDK.

Values:
SDK_TYPE_UNSPECIFIED (0):

The default value. This value is used if the sdk_type is omitted.

CONSUMER (1):

The calling SDK is Consumer.

DRIVER (2):

The calling SDK is Driver.

JAVASCRIPT (3):

The calling SDK is JavaScript.

class google.maps.fleetengine_v1.types.SearchTripsRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

SearchTrips request message.

header

The standard Fleet Engine request header.

Type

google.maps.fleetengine_v1.types.RequestHeader

parent

Required. Must be in the format providers/{provider}. The provider must be the Project ID (for example, sample-cloud-project) of the Google Cloud Project of which the service account making this call is a member.

Type

str

vehicle_id

The vehicle associated with the trips in the request. If unspecified, the returned trips do not contain:

  • current_route_segment

  • remaining_waypoints

  • remaining_distance_meters

  • eta_to_first_waypoint

Type

str

active_trips_only

If set to true, the response includes Trips that influence a driver’s route.

Type

bool

page_size

If not set, the server decides the number of results to return.

Type

int

page_token

Set this to a value previously returned in the SearchTripsResponse to continue from previous results.

Type

str

minimum_staleness

If specified, returns the trips that have not been updated after the time (current - minimum_staleness).

Type

google.protobuf.duration_pb2.Duration

class google.maps.fleetengine_v1.types.SearchTripsResponse(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

SearchTrips response message.

trips

The list of trips for the requested vehicle.

Type

MutableSequence[google.maps.fleetengine_v1.types.Trip]

next_page_token

Pass this token in the SearchTripsRequest to page through list results. The API returns a trip list on each call, and when no more results remain the trip list is empty.

Type

str

class google.maps.fleetengine_v1.types.SearchVehiclesRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

SearchVehicles request message.

header

The standard Fleet Engine request header.

Type

google.maps.fleetengine_v1.types.RequestHeader

parent

Required. Must be in the format providers/{provider}. The provider must be the Project ID (for example, sample-cloud-project) of the Google Cloud Project of which the service account making this call is a member.

Type

str

pickup_point

Required. The pickup point to search near.

Type

google.maps.fleetengine_v1.types.TerminalLocation

dropoff_point

The customer’s intended dropoff location. The field is required if trip_types contains TripType.SHARED.

Type

google.maps.fleetengine_v1.types.TerminalLocation

pickup_radius_meters

Required. Defines the vehicle search radius around the pickup point. Only vehicles within the search radius will be returned. Value must be between 400 and 10000 meters (inclusive).

Type

int

count

Required. Specifies the maximum number of vehicles to return. The value must be between 1 and 50 (inclusive).

Type

int

minimum_capacity

Required. Specifies the number of passengers being considered for a trip. The value must be greater than or equal to one. The driver is not considered in the capacity value.

Type

int

trip_types

Required. Represents the type of proposed trip. Must include exactly one type. UNKNOWN_TRIP_TYPE is not allowed. Restricts the search to only those vehicles that can support that trip type.

Type

MutableSequence[google.maps.fleetengine_v1.types.TripType]

maximum_staleness

Restricts the search to only those vehicles that have sent location updates to Fleet Engine within the specified duration. Stationary vehicles still transmitting their locations are not considered stale. If this field is not set, the server uses five minutes as the default value.

Type

google.protobuf.duration_pb2.Duration

vehicle_types

Required. Restricts the search to vehicles with one of the specified types. At least one vehicle type must be specified. VehicleTypes with a category of UNKNOWN are not allowed.

Type

MutableSequence[google.maps.fleetengine_v1.types.Vehicle.VehicleType]

required_attributes

Callers can form complex logical operations using any combination of the required_attributes, required_one_of_attributes, and required_one_of_attribute_sets fields.

required_attributes is a list; required_one_of_attributes uses a message which allows a list of lists. In combination, the two fields allow the composition of this expression:

(required_attributes[0] AND required_attributes[1] AND ...)
AND
(required_one_of_attributes[0][0] OR required_one_of_attributes[0][1] OR
...)
AND
(required_one_of_attributes[1][0] OR required_one_of_attributes[1][1] OR
...)

Restricts the search to only those vehicles with the specified attributes. This field is a conjunction/AND operation. A max of 50 required_attributes is allowed. This matches the maximum number of attributes allowed on a vehicle.

Type

MutableSequence[google.maps.fleetengine_v1.types.VehicleAttribute]

required_one_of_attributes

Restricts the search to only those vehicles with at least one of the specified attributes in each VehicleAttributeList. Within each list, a vehicle must match at least one of the attributes. This field is an inclusive disjunction/OR operation in each VehicleAttributeList and a conjunction/AND operation across the collection of VehicleAttributeList.

Type

MutableSequence[google.maps.fleetengine_v1.types.VehicleAttributeList]

required_one_of_attribute_sets

required_one_of_attribute_sets provides additional functionality.

Similar to required_one_of_attributes, required_one_of_attribute_sets uses a message which allows a list of lists, allowing expressions such as this one:

(required_attributes[0] AND required_attributes[1] AND ...)
AND
(
  (required_one_of_attribute_sets[0][0] AND
  required_one_of_attribute_sets[0][1] AND
  ...)
  OR
  (required_one_of_attribute_sets[1][0] AND
  required_one_of_attribute_sets[1][1] AND
  ...)
)

Restricts the search to only those vehicles with all the attributes in a VehicleAttributeList. Within each list, a vehicle must match all of the attributes. This field is a conjunction/AND operation in each VehicleAttributeList and inclusive disjunction/OR operation across the collection of VehicleAttributeList.

Type

MutableSequence[google.maps.fleetengine_v1.types.VehicleAttributeList]

order_by

Required. Specifies the desired ordering criterion for results.

Type

google.maps.fleetengine_v1.types.SearchVehiclesRequest.VehicleMatchOrder

include_back_to_back

This indicates if vehicles with a single active trip are eligible for this search. This field is only used when current_trips_present is unspecified. When current_trips_present is unspecified and this field is false, vehicles with assigned trips are excluded from the search results. When current_trips_present is unspecified and this field is true, search results can include vehicles with one active trip that has a status of ENROUTE_TO_DROPOFF. When current_trips_present is specified, this field cannot be set to true.

The default value is false.

Type

bool

trip_id

Indicates the trip associated with this SearchVehicleRequest.

Type

str

current_trips_present

This indicates if vehicles with active trips are eligible for this search. This must be set to something other than CURRENT_TRIPS_PRESENT_UNSPECIFIED if trip_type includes SHARED.

Type

google.maps.fleetengine_v1.types.SearchVehiclesRequest.CurrentTripsPresent

filter

Optional. A filter query to apply when searching vehicles. See http://aip.dev/160 for examples of the filter syntax.

This field is designed to replace the required_attributes, required_one_of_attributes, and required_one_of_attributes_sets fields. If a non-empty value is specified here, the following fields must be empty: required_attributes, required_one_of_attributes, and required_one_of_attributes_sets.

This filter functions as an AND clause with other constraints, such as minimum_capacity or vehicle_types.

Note that the only queries supported are on vehicle attributes (for example, attributes.<key> = <value> or attributes.<key1> = <value1> AND attributes.<key2> = <value2>). The maximum number of restrictions allowed in a filter query is 50.

Also, all attributes are stored as strings, so the only supported comparisons against attributes are string comparisons. In order to compare against number or boolean values, the values must be explicitly quoted to be treated as strings (for example, attributes.<key> = "10" or attributes.<key> = "true").

Type

str

class CurrentTripsPresent(value)[source]

Bases: proto.enums.Enum

Specifies the types of restrictions on a vehicle’s current trips.

Values:
CURRENT_TRIPS_PRESENT_UNSPECIFIED (0):

The availability of vehicles with trips present is governed by the include_back_to_back field.

NONE (1):

Vehicles without trips can appear in search results. When this value is used, include_back_to_back cannot be true.

ANY (2):

Vehicles with at most 5 current trips and 10 waypoints are included in the search results. When this value is used, include_back_to_back cannot be true.

class VehicleMatchOrder(value)[source]

Bases: proto.enums.Enum

Specifies the order of the vehicle matches in the response.

Values:
UNKNOWN_VEHICLE_MATCH_ORDER (0):

Default, used for unspecified or unrecognized vehicle matches order.

PICKUP_POINT_ETA (1):

Ascending order by vehicle driving time to the pickup point.

PICKUP_POINT_DISTANCE (2):

Ascending order by vehicle driving distance to the pickup point.

DROPOFF_POINT_ETA (3):

Ascending order by vehicle driving time to the dropoff point. This order can only be used if the dropoff point is specified in the request.

PICKUP_POINT_STRAIGHT_DISTANCE (4):

Ascending order by straight-line distance from the vehicle’s last reported location to the pickup point.

COST (5):

Ascending order by the configured match cost. Match cost is defined as a weighted calculation between straight-line distance and ETA. Weights are set with default values and can be modified per customer. Please contact Google support if these weights need to be modified for your project.

class google.maps.fleetengine_v1.types.SearchVehiclesResponse(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

SearchVehicles response message.

matches

List of vehicles that match the SearchVehiclesRequest criteria, ordered according to SearchVehiclesRequest.order_by field.

Type

MutableSequence[google.maps.fleetengine_v1.types.VehicleMatch]

class google.maps.fleetengine_v1.types.SpeedReadingInterval(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Traffic density indicator on a contiguous segment of a path. Given a path with points P_0, P_1, … , P_N (zero-based index), the SpeedReadingInterval defines an interval and describes its traffic using the following categories.

start_polyline_point_index

The starting index of this interval in the path. In JSON, when the index is 0, the field will appear to be unpopulated.

Type

int

end_polyline_point_index

The ending index of this interval in the path. In JSON, when the index is 0, the field will appear to be unpopulated.

Type

int

speed

Traffic speed in this interval.

Type

google.maps.fleetengine_v1.types.SpeedReadingInterval.Speed

class Speed(value)[source]

Bases: proto.enums.Enum

The classification of polyline speed based on traffic data.

Values:
SPEED_UNSPECIFIED (0):

Default value. This value is unused.

NORMAL (1):

Normal speed, no slowdown is detected.

SLOW (2):

Slowdown detected, but no traffic jam formed.

TRAFFIC_JAM (3):

Traffic jam detected.

class google.maps.fleetengine_v1.types.StopLocation(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

The actual location where a stop (pickup/dropoff) happened.

point

Required. Denotes the actual location.

Type

google.type.latlng_pb2.LatLng

timestamp

Indicates when the stop happened.

Type

google.protobuf.timestamp_pb2.Timestamp

stop_time

Input only. Deprecated. Use the timestamp field.

Type

google.protobuf.timestamp_pb2.Timestamp

class google.maps.fleetengine_v1.types.TerminalLocation(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Describes the location of a waypoint.

point

Required. Denotes the location of a trip waypoint.

Type

google.type.latlng_pb2.LatLng

terminal_point_id

Deprecated: Specify the point field instead.

Type

google.maps.fleetengine_v1.types.TerminalPointId

access_point_id

Deprecated: Specify the point field instead.

Type

str

trip_id

Deprecated.

Type

str

terminal_location_type

Deprecated: Vehicle.waypoint will have this data.

Type

google.maps.fleetengine_v1.types.WaypointType

class google.maps.fleetengine_v1.types.TerminalPointId(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Deprecated: TerminalPoints are no longer supported in Fleet Engine. Use TerminalLocation.point instead.

This message has oneof fields (mutually exclusive fields). For each oneof, at most one member field can be set at the same time. Setting any member of the oneof automatically clears all other members.

place_id

Deprecated.

This field is a member of oneof Id.

Type

str

generated_id

Deprecated.

This field is a member of oneof Id.

Type

str

value

Deprecated.

Type

str

class google.maps.fleetengine_v1.types.TrafficPolylineData(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Traffic conditions along the expected vehicle route.

traffic_rendering

A polyline rendering of how fast traffic is for all regions along one stretch of a customer ride.

Type

google.maps.fleetengine_v1.types.VisualTrafficReportPolylineRendering

class google.maps.fleetengine_v1.types.Trip(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Trip metadata.

name

Output only. In the format “providers/{provider}/trips/{trip}”.

Type

str

vehicle_id

ID of the vehicle making this trip.

Type

str

trip_status

Current status of the trip.

Type

google.maps.fleetengine_v1.types.TripStatus

trip_type

The type of the trip.

Type

google.maps.fleetengine_v1.types.TripType

pickup_point

Location where customer indicates they will be picked up.

Type

google.maps.fleetengine_v1.types.TerminalLocation

actual_pickup_point

Input only. The actual location when and where customer was picked up. This field is for provider to provide feedback on actual pickup information.

Type

google.maps.fleetengine_v1.types.StopLocation

actual_pickup_arrival_point

Input only. The actual time and location of the driver arrival at the pickup point. This field is for provider to provide feedback on actual arrival information at the pickup point.

Type

google.maps.fleetengine_v1.types.StopLocation

pickup_time

Output only. Either the estimated future time when the rider(s) will be picked up, or the actual time when they were picked up.

Type

google.protobuf.timestamp_pb2.Timestamp

intermediate_destinations

Intermediate stops in order that the trip requests (in addition to pickup and dropoff). Initially this will not be supported for shared trips.

Type

MutableSequence[google.maps.fleetengine_v1.types.TerminalLocation]

intermediate_destinations_version

Indicates the last time the intermediate_destinations was modified. Your server should cache this value and pass it in UpdateTripRequest when update intermediate_destination_index to ensure the intermediate_destinations is not changed.

Type

google.protobuf.timestamp_pb2.Timestamp

intermediate_destination_index

When TripStatus is ENROUTE_TO_INTERMEDIATE_DESTINATION, a number between [0..N-1] indicating which intermediate destination the vehicle will cross next. When TripStatus is ARRIVED_AT_INTERMEDIATE_DESTINATION, a number between [0..N-1] indicating which intermediate destination the vehicle is at. The provider sets this value. If there are no intermediate_destinations, this field is ignored.

Type

int

actual_intermediate_destination_arrival_points

Input only. The actual time and location of the driver’s arrival at an intermediate destination. This field is for provider to provide feedback on actual arrival information at intermediate destinations.

Type

MutableSequence[google.maps.fleetengine_v1.types.StopLocation]

actual_intermediate_destinations

Input only. The actual time and location when and where the customer was picked up from an intermediate destination. This field is for provider to provide feedback on actual pickup information at intermediate destinations.

Type

MutableSequence[google.maps.fleetengine_v1.types.StopLocation]

dropoff_point

Location where customer indicates they will be dropped off.

Type

google.maps.fleetengine_v1.types.TerminalLocation

actual_dropoff_point

Input only. The actual time and location when and where customer was dropped off. This field is for provider to provide feedback on actual dropoff information.

Type

google.maps.fleetengine_v1.types.StopLocation

dropoff_time

Output only. Either the estimated future time when the rider(s) will be dropped off at the final destination, or the actual time when they were dropped off.

Type

google.protobuf.timestamp_pb2.Timestamp

remaining_waypoints

Output only. The full path from the current location to the dropoff point, inclusive. This path could include waypoints from other trips.

Type

MutableSequence[google.maps.fleetengine_v1.types.TripWaypoint]

vehicle_waypoints

This field supports manual ordering of the waypoints for the trip. It contains all of the remaining waypoints for the assigned vehicle, as well as the pickup and drop-off waypoints for this trip. If the trip hasn’t been assigned to a vehicle, then Fleet Engine ignores this field. For privacy reasons, this field is only populated by the server on UpdateTrip and CreateTrip calls, NOT on GetTrip calls.

Type

MutableSequence[google.maps.fleetengine_v1.types.TripWaypoint]

route

Output only. Anticipated route for this trip to the first entry in remaining_waypoints. Note that the first waypoint may belong to a different trip.

Type

MutableSequence[google.type.latlng_pb2.LatLng]

current_route_segment

Output only. An encoded path to the next waypoint. Note: This field is intended only for use by the Driver SDK and Consumer SDK. Decoding is not yet supported.

Type

str

current_route_segment_version

Output only. Indicates the last time the route was modified. Note: This field is intended only for use by the Driver SDK and Consumer SDK.

Type

google.protobuf.timestamp_pb2.Timestamp

current_route_segment_traffic

Output only. Indicates the traffic conditions along the current_route_segment when they’re available.

Note: This field is intended only for use by the Driver SDK and Consumer SDK.

Type

google.maps.fleetengine_v1.types.ConsumableTrafficPolyline

current_route_segment_traffic_version

Output only. Indicates the last time the current_route_segment_traffic was modified.

Note: This field is intended only for use by the Driver SDK and Consumer SDK.

Type

google.protobuf.timestamp_pb2.Timestamp

current_route_segment_end_point

Output only. The waypoint where current_route_segment ends.

Type

google.maps.fleetengine_v1.types.TripWaypoint

remaining_distance_meters

Output only. The remaining driving distance in the current_route_segment field. The value is unspecified if the trip is not assigned to a vehicle, or the trip is completed or cancelled.

Type

google.protobuf.wrappers_pb2.Int32Value

eta_to_first_waypoint

Output only. The ETA to the next waypoint (the first entry in the remaining_waypoints field). The value is unspecified if the trip is not assigned to a vehicle, or the trip is inactive (completed or cancelled).

Type

google.protobuf.timestamp_pb2.Timestamp

remaining_time_to_first_waypoint

Output only. The duration from when the Trip data is returned to the time in Trip.eta_to_first_waypoint. The value is unspecified if the trip is not assigned to a vehicle, or the trip is inactive (completed or cancelled).

Type

google.protobuf.duration_pb2.Duration

remaining_waypoints_version

Output only. Indicates the last time that remaining_waypoints was changed (a waypoint was added, removed, or changed).

Type

google.protobuf.timestamp_pb2.Timestamp

remaining_waypoints_route_version

Output only. Indicates the last time the remaining_waypoints.path_to_waypoint and remaining_waypoints.traffic_to_waypoint were modified. Your client app should cache this value and pass it in GetTripRequest to ensure the paths and traffic for remaining_waypoints are only returned if updated.

Type

google.protobuf.timestamp_pb2.Timestamp

number_of_passengers

Immutable. Indicates the number of passengers on this trip and does not include the driver. A vehicle must have available capacity to be returned in a SearchVehicles response.

Type

int

last_location

Output only. Indicates the last reported location of the vehicle along the route.

Type

google.maps.fleetengine_v1.types.VehicleLocation

last_location_snappable

Output only. Indicates whether the vehicle’s last_location can be snapped to the current_route_segment. False if last_location or current_route_segment doesn’t exist. It is computed by Fleet Engine. Any update from clients will be ignored.

Type

bool

view

The subset of Trip fields that are populated and how they should be interpreted.

Type

google.maps.fleetengine_v1.types.TripView

class google.maps.fleetengine_v1.types.TripStatus(value)[source]

Bases: proto.enums.Enum

The status of a trip indicating its progression.

Values:
UNKNOWN_TRIP_STATUS (0):

Default, used for unspecified or unrecognized trip status.

NEW (1):

Newly created trip.

ENROUTE_TO_PICKUP (2):

The driver is on their way to the pickup point.

ARRIVED_AT_PICKUP (3):

The driver has arrived at the pickup point.

ARRIVED_AT_INTERMEDIATE_DESTINATION (7):

The driver has arrived at an intermediate destination and is waiting for the rider.

ENROUTE_TO_INTERMEDIATE_DESTINATION (8):

The driver is on their way to an intermediate destination (not the dropoff point).

ENROUTE_TO_DROPOFF (4):

The driver has picked up the rider and is on their way to the next destination.

COMPLETE (5):

The rider has been dropped off and the trip is complete.

CANCELED (6):

The trip was canceled prior to pickup by the driver, rider, or rideshare provider.

class google.maps.fleetengine_v1.types.TripType(value)[source]

Bases: proto.enums.Enum

The type of a trip.

Values:
UNKNOWN_TRIP_TYPE (0):

Default, used for unspecified or unrecognized trip types.

SHARED (1):

The trip may share a vehicle with other trips.

EXCLUSIVE (2):

The trip is exclusive to a vehicle.

class google.maps.fleetengine_v1.types.TripView(value)[source]

Bases: proto.enums.Enum

Selector for different sets of Trip fields in a GetTrip response. See AIP-157 for context. Additional views are likely to be added.

Values:
TRIP_VIEW_UNSPECIFIED (0):

The default value. For backwards-compatibility, the API will default to an SDK view. To ensure stability and support, customers are advised to select a TripView other than SDK.

SDK (1):

Includes fields that may not be interpretable or supportable using publicly available libraries.

JOURNEY_SHARING_V1S (2):

Trip fields are populated for the Journey Sharing use case. This view is intended for server-to-server communications.

class google.maps.fleetengine_v1.types.TripWaypoint(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Describes a stopping point on a vehicle’s route or an ending point on a vehicle’s trip.

location

The location of this waypoint.

Type

google.maps.fleetengine_v1.types.TerminalLocation

trip_id

The trip associated with this waypoint.

Type

str

waypoint_type

The role this waypoint plays in this trip, such as pickup or dropoff.

Type

google.maps.fleetengine_v1.types.WaypointType

path_to_waypoint

The path from the previous waypoint to the current waypoint. Undefined for the first waypoint in a list. This field is only populated when requested.

Type

MutableSequence[google.type.latlng_pb2.LatLng]

encoded_path_to_waypoint

The encoded path from the previous waypoint to the current waypoint. <p>Note: This field is intended only for use by the Driver SDK and Consumer SDK. Decoding is not yet supported.

Type

str

traffic_to_waypoint

The traffic conditions along the path to this waypoint. Note that traffic is only available for Google Map Platform Rides and Deliveries Solution customers.

Type

google.maps.fleetengine_v1.types.ConsumableTrafficPolyline

distance_meters

The path distance from the previous waypoint to the current waypoint. Undefined for the first waypoint in a list.

Type

google.protobuf.wrappers_pb2.Int32Value

eta

The estimated time of arrival at this waypoint. Undefined for the first waypoint in a list.

Type

google.protobuf.timestamp_pb2.Timestamp

duration

The travel time from previous waypoint to this point. Undefined for the first waypoint in a list.

Type

google.protobuf.duration_pb2.Duration

class google.maps.fleetengine_v1.types.UpdateTripRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

UpdateTrip request message.

header

The standard Fleet Engine request header.

Type

google.maps.fleetengine_v1.types.RequestHeader

name

Required. Must be in the format providers/{provider}/trips/{trip}. The provider must be the Project ID (for example, sample-consumer-project) of the Google Cloud Project of which the service account making this call is a member.

Type

str

trip

Required. The Trip associated with the update.

The following fields are maintained by the Fleet Engine. Do not update them using Trip.update.

  • current_route_segment

  • current_route_segment_end_point

  • current_route_segment_traffic

  • current_route_segment_traffic_version

  • current_route_segment_version

  • dropoff_time

  • eta_to_next_waypoint

  • intermediate_destinations_version

  • last_location

  • name

  • number_of_passengers

  • pickup_time

  • remaining_distance_meters

  • remaining_time_to_first_waypoint

  • remaining_waypoints

  • remaining_waypoints_version

  • route

When you update the Trip.vehicle_id for a shared trip, you must supply the list of Trip.vehicle_waypoints to specify the order of the remaining waypoints, otherwise the order will be undetermined.

When you specify Trip.vehicle_waypoints, the list must contain all the remaining waypoints of the vehicle’s trips, with no extra waypoints. You must order these waypoints such that for a given trip, the pickup point is before intermediate destinations, and all intermediate destinations come before the drop-off point. An EXCLUSIVE trip’s waypoints must not interleave with any other trips. The trip_id, waypoint_type and location fields are used, and all other TripWaypoint fields in vehicle_waypoints are ignored.

To avoid a race condition for trips with multiple destinations, you should provide Trip.intermediate_destinations_version when updating the trip status to ENROUTE_TO_INTERMEDIATE_DESTINATION. The Trip.intermediate_destinations_version passed must be consistent with Fleet Engine’s version. If it isn’t, the request fails.

Type

google.maps.fleetengine_v1.types.Trip

update_mask

Required. The field mask indicating which fields in Trip to update. The update_mask must contain at least one field.

Type

google.protobuf.field_mask_pb2.FieldMask

class google.maps.fleetengine_v1.types.UpdateVehicleAttributesRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

UpdateVehicleAttributes request message.

header

The standard Fleet Engine request header.

Type

google.maps.fleetengine_v1.types.RequestHeader

name

Required. Must be in the format providers/{provider}/vehicles/{vehicle}. The provider must be the Project ID (for example, sample-cloud-project) of the Google Cloud Project of which the service account making this call is a member.

Type

str

attributes

Required. The vehicle attributes to update. Unmentioned attributes are not altered or removed.

Type

MutableSequence[google.maps.fleetengine_v1.types.VehicleAttribute]

class google.maps.fleetengine_v1.types.UpdateVehicleAttributesResponse(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

UpdateVehicleAttributes response message.

attributes

Required. The updated full list of vehicle attributes, including new, altered, and untouched attributes.

Type

MutableSequence[google.maps.fleetengine_v1.types.VehicleAttribute]

class google.maps.fleetengine_v1.types.UpdateVehicleRequest(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

`UpdateVehicle request message.

header

The standard Fleet Engine request header.

Type

google.maps.fleetengine_v1.types.RequestHeader

name

Required. Must be in the format providers/{provider}/vehicles/{vehicle}. The {provider} must be the Project ID (for example, sample-cloud-project) of the Google Cloud Project of which the service account making this call is a member.

Type

str

vehicle

Required. The Vehicle entity values to apply. When updating a Vehicle, the following fields may not be updated as they are managed by the server.

  • available_capacity

  • current_route_segment_version

  • current_trips

  • name

  • waypoints_version

If the attributes field is updated, all the vehicle’s attributes are replaced with the attributes provided in the request. If you want to update only some attributes, see the UpdateVehicleAttributes method.

Likewise, the waypoints field can be updated, but must contain all the waypoints currently on the vehicle, and no other waypoints.

Type

google.maps.fleetengine_v1.types.Vehicle

update_mask

Required. A field mask indicating which fields of the Vehicle to update. At least one field name must be provided.

Type

google.protobuf.field_mask_pb2.FieldMask

class google.maps.fleetengine_v1.types.Vehicle(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Vehicle metadata.

name

Output only. The unique name for this vehicle. The format is providers/{provider}/vehicles/{vehicle}.

Type

str

vehicle_state

The vehicle state.

Type

google.maps.fleetengine_v1.types.VehicleState

supported_trip_types

Trip types supported by this vehicle.

Type

MutableSequence[google.maps.fleetengine_v1.types.TripType]

current_trips

Output only. List of trip_id’s for trips currently assigned to this vehicle.

Type

MutableSequence[str]

last_location

Last reported location of the vehicle.

Type

google.maps.fleetengine_v1.types.VehicleLocation

maximum_capacity

The total numbers of riders this vehicle can carry. The driver is not considered in this value. This value must be greater than or equal to one.

Type

int

attributes

List of vehicle attributes. A vehicle can have at most 100 attributes, and each attribute must have a unique key.

Type

MutableSequence[google.maps.fleetengine_v1.types.VehicleAttribute]

vehicle_type

Required. The type of this vehicle. Can be used to filter vehicles in SearchVehicles results. Also influences ETA and route calculations.

Type

google.maps.fleetengine_v1.types.Vehicle.VehicleType

license_plate

License plate information for the vehicle.

Type

google.maps.fleetengine_v1.types.LicensePlate

route

Deprecated: Use Vehicle.waypoints instead.

Type

MutableSequence[google.maps.fleetengine_v1.types.TerminalLocation]

current_route_segment

The polyline specifying the route the driver app intends to take to the next waypoint. This list is also returned in Trip.current_route_segment for all active trips assigned to the vehicle.

Note: This field is intended only for use by the Driver SDK. Decoding is not yet supported.

Type

str

current_route_segment_traffic

Input only. Fleet Engine uses this information to improve journey sharing. Note: This field is intended only for use by the Driver SDK.

Type

google.maps.fleetengine_v1.types.TrafficPolylineData

current_route_segment_version

Output only. Time when current_route_segment was set. It can be stored by the client and passed in future GetVehicle requests to prevent returning routes that haven’t changed.

Type

google.protobuf.timestamp_pb2.Timestamp

current_route_segment_end_point

The waypoint where current_route_segment ends. This can be supplied by drivers on UpdateVehicle calls either as a full trip waypoint, a waypoint LatLng, or as the last LatLng of the current_route_segment. Fleet Engine will then do its best to interpolate to an actual waypoint if it is not fully specified. This field is ignored in UpdateVehicle calls unless current_route_segment is also specified.

Type

google.maps.fleetengine_v1.types.TripWaypoint

remaining_distance_meters

The remaining driving distance for the current_route_segment. This value is also returned in Trip.remaining_distance_meters for all active trips assigned to the vehicle. The value is unspecified if the current_route_segment field is empty.

Type

google.protobuf.wrappers_pb2.Int32Value

eta_to_first_waypoint

The ETA to the first entry in the waypoints field. The value is unspecified if the waypoints field is empty or the Vehicle.current_route_segment field is empty.

When updating a vehicle, remaining_time_seconds takes precedence over eta_to_first_waypoint in the same request.

Type

google.protobuf.timestamp_pb2.Timestamp

remaining_time_seconds

Input only. The remaining driving time for the current_route_segment. The value is unspecified if the waypoints field is empty or the Vehicle.current_route_segment field is empty. This value should match eta_to_first_waypoint - current_time if all parties are using the same clock.

When updating a vehicle, remaining_time_seconds takes precedence over eta_to_first_waypoint in the same request.

Type

google.protobuf.wrappers_pb2.Int32Value

waypoints

The remaining waypoints assigned to this Vehicle.

Type

MutableSequence[google.maps.fleetengine_v1.types.TripWaypoint]

waypoints_version

Output only. Last time the waypoints field was updated. Clients should cache this value and pass it in GetVehicleRequest to ensure the waypoints field is only returned if it is updated.

Type

google.protobuf.timestamp_pb2.Timestamp

back_to_back_enabled

Indicates if the driver accepts back-to-back trips. If true, SearchVehicles may include the vehicle even if it is currently assigned to a trip. The default value is false.

Type

bool

navigation_status

The vehicle’s navigation status.

Type

google.maps.fleetengine_v1.types.NavigationStatus

device_settings

Input only. Information about settings in the mobile device being used by the driver.

Type

google.maps.fleetengine_v1.types.DeviceSettings

class VehicleType(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

The type of vehicle.

category

Vehicle type category

Type

google.maps.fleetengine_v1.types.Vehicle.VehicleType.Category

class Category(value)[source]

Bases: proto.enums.Enum

Vehicle type categories

Values:
UNKNOWN (0):

Default, used for unspecified or unrecognized vehicle categories.

AUTO (1):

An automobile.

TAXI (2):

Any vehicle that acts as a taxi (typically licensed or regulated).

TRUCK (3):

Generally, a vehicle with a large storage capacity.

TWO_WHEELER (4):

A motorcycle, moped, or other two-wheeled vehicle

BICYCLE (5):

Human-powered transport.

PEDESTRIAN (6):

A human transporter, typically walking or running, traveling along pedestrian pathways.

class google.maps.fleetengine_v1.types.VehicleAttribute(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Describes a vehicle attribute as a key-value pair. The “key:value” string length cannot exceed 256 characters.

This message has oneof fields (mutually exclusive fields). For each oneof, at most one member field can be set at the same time. Setting any member of the oneof automatically clears all other members.

key

The attribute’s key. Keys may not contain the colon character (:).

Type

str

value

The attribute’s value.

Type

str

string_value

String typed attribute value.

Note: This is identical to the value field which will eventually be deprecated. For create or update methods, either field can be used, but it’s strongly recommended to use string_value. If both string_value and value are set, they must be identical or an error will be thrown. Both fields are populated in responses.

This field is a member of oneof vehicle_attribute_value.

Type

str

bool_value

Boolean typed attribute value.

This field is a member of oneof vehicle_attribute_value.

Type

bool

number_value

Double typed attribute value.

This field is a member of oneof vehicle_attribute_value.

Type

float

class google.maps.fleetengine_v1.types.VehicleAttributeList(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

A list-of-lists datatype for vehicle attributes.

attributes

A list of attributes in this collection.

Type

MutableSequence[google.maps.fleetengine_v1.types.VehicleAttribute]

class google.maps.fleetengine_v1.types.VehicleLocation(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

The location, speed, and heading of a vehicle at a point in time.

location

The location of the vehicle. When it is sent to Fleet Engine, the vehicle’s location is a GPS location. When you receive it in a response, the vehicle’s location can be either a GPS location, a supplemental location, or some other estimated location. The source is specified in location_sensor.

Type

google.type.latlng_pb2.LatLng

horizontal_accuracy

Deprecated: Use latlng_accuracy instead.

Type

google.protobuf.wrappers_pb2.DoubleValue

latlng_accuracy

Accuracy of location in meters as a radius.

Type

google.protobuf.wrappers_pb2.DoubleValue

heading

Direction the vehicle is moving in degrees. 0 represents North. The valid range is [0,360).

Type

google.protobuf.wrappers_pb2.Int32Value

bearing_accuracy

Deprecated: Use heading_accuracy instead.

Type

google.protobuf.wrappers_pb2.DoubleValue

heading_accuracy

Accuracy of heading in degrees.

Type

google.protobuf.wrappers_pb2.DoubleValue

altitude

Altitude in meters above WGS84.

Type

google.protobuf.wrappers_pb2.DoubleValue

vertical_accuracy

Deprecated: Use altitude_accuracy instead.

Type

google.protobuf.wrappers_pb2.DoubleValue

altitude_accuracy

Accuracy of altitude in meters.

Type

google.protobuf.wrappers_pb2.DoubleValue

speed_kmph

Speed of the vehicle in kilometers per hour. Deprecated: Use speed instead.

Type

google.protobuf.wrappers_pb2.Int32Value

speed

Speed of the vehicle in meters/second

Type

google.protobuf.wrappers_pb2.DoubleValue

speed_accuracy

Accuracy of speed in meters/second.

Type

google.protobuf.wrappers_pb2.DoubleValue

update_time

The time when location was reported by the sensor according to the sensor’s clock.

Type

google.protobuf.timestamp_pb2.Timestamp

server_time

Output only. The time when the server received the location information.

Type

google.protobuf.timestamp_pb2.Timestamp

location_sensor

Provider of location data (for example, GPS).

Type

google.maps.fleetengine_v1.types.LocationSensor

is_road_snapped

Whether location is snapped to a road.

Type

google.protobuf.wrappers_pb2.BoolValue

is_gps_sensor_enabled

Input only. Indicates whether the GPS sensor is enabled on the mobile device.

Type

google.protobuf.wrappers_pb2.BoolValue

time_since_update

Input only. Time (in seconds) since this location was first sent to the server. This will be zero for the first update. If the time is unknown (for example, when the app restarts), this value resets to zero.

Type

google.protobuf.wrappers_pb2.Int32Value

num_stale_updates

Input only. Deprecated: Other signals are now used to determine if a location is stale.

Type

google.protobuf.wrappers_pb2.Int32Value

raw_location

Raw vehicle location (unprocessed by road-snapper).

Type

google.type.latlng_pb2.LatLng

raw_location_time

Timestamp associated with the raw location.

Type

google.protobuf.timestamp_pb2.Timestamp

raw_location_sensor

Source of the raw location. Defaults to GPS.

Type

google.maps.fleetengine_v1.types.LocationSensor

raw_location_accuracy

Accuracy of raw_location as a radius, in meters.

Type

google.protobuf.wrappers_pb2.DoubleValue

supplemental_location

Supplemental location provided by the integrating app.

Type

google.type.latlng_pb2.LatLng

supplemental_location_time

Timestamp associated with the supplemental location.

Type

google.protobuf.timestamp_pb2.Timestamp

supplemental_location_sensor

Source of the supplemental location. Defaults to CUSTOMER_SUPPLIED_LOCATION.

Type

google.maps.fleetengine_v1.types.LocationSensor

supplemental_location_accuracy

Accuracy of supplemental_location as a radius, in meters.

Type

google.protobuf.wrappers_pb2.DoubleValue

road_snapped

Deprecated: Use is_road_snapped instead.

Type

bool

class google.maps.fleetengine_v1.types.VehicleMatch(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Contains the vehicle and related estimates for a vehicle that match the points of active trips for the vehicle SearchVehiclesRequest.

vehicle

Required. A vehicle that matches the request.

Type

google.maps.fleetengine_v1.types.Vehicle

vehicle_pickup_eta

The vehicle’s driving ETA to the pickup point specified in the request. An empty value indicates a failure in calculating ETA for the vehicle. If SearchVehiclesRequest.include_back_to_back was true and this vehicle has an active trip, vehicle_pickup_eta includes the time required to complete the current active trip.

Type

google.protobuf.timestamp_pb2.Timestamp

vehicle_pickup_distance_meters

The distance from the Vehicle’s current location to the pickup point specified in the request, including any intermediate pickup or dropoff points for existing trips. This distance comprises the calculated driving (route) distance, plus the straight line distance between the navigation end point and the requested pickup point. (The distance between the navigation end point and the requested pickup point is typically small.) An empty value indicates an error in calculating the distance.

Type

google.protobuf.wrappers_pb2.Int32Value

vehicle_pickup_straight_line_distance_meters

Required. The straight-line distance between the vehicle and the pickup point specified in the request.

Type

google.protobuf.wrappers_pb2.Int32Value

vehicle_dropoff_eta

The complete vehicle’s driving ETA to the drop off point specified in the request. The ETA includes stopping at any waypoints before the dropoff_point specified in the request. The value will only be populated when a drop off point is specified in the request. An empty value indicates an error calculating the ETA.

Type

google.protobuf.timestamp_pb2.Timestamp

vehicle_pickup_to_dropoff_distance_meters

The vehicle’s driving distance (in meters) from the pickup point to the drop off point specified in the request. The distance is only between the two points and does not include the vehicle location or any other points that must be visited before the vehicle visits either the pickup point or dropoff point. The value will only be populated when a dropoff_point is specified in the request. An empty value indicates a failure in calculating the distance from the pickup to drop off point specified in the request.

Type

google.protobuf.wrappers_pb2.Int32Value

trip_type

Required. The trip type of the request that was used to calculate the ETA to the pickup point.

Type

google.maps.fleetengine_v1.types.TripType

vehicle_trips_waypoints

The ordered list of waypoints used to calculate the ETA. The list includes vehicle location, the pickup points of active trips for the vehicle, and the pickup points provided in the request. An empty list indicates a failure in calculating ETA for the vehicle.

Type

MutableSequence[google.maps.fleetengine_v1.types.Waypoint]

vehicle_match_type

Type of the vehicle match.

Type

google.maps.fleetengine_v1.types.VehicleMatch.VehicleMatchType

requested_ordered_by

The order requested for sorting vehicle matches.

Type

google.maps.fleetengine_v1.types.SearchVehiclesRequest.VehicleMatchOrder

ordered_by

The actual order that was used for this vehicle. Normally this will match the ‘order_by’ field from the request; however, in certain circumstances such as an internal server error, a different method may be used (such as PICKUP_POINT_STRAIGHT_DISTANCE).

Type

google.maps.fleetengine_v1.types.SearchVehiclesRequest.VehicleMatchOrder

class VehicleMatchType(value)[source]

Bases: proto.enums.Enum

Type of vehicle match.

Values:
UNKNOWN (0):

Unknown vehicle match type

EXCLUSIVE (1):

The vehicle currently has no trip assigned to it and can proceed to the pickup point.

BACK_TO_BACK (2):

The vehicle is currently assigned to a trip, but can proceed to the pickup point after completing the in-progress trip. ETA and distance calculations take the existing trip into account.

CARPOOL (3):

The vehicle has sufficient capacity for a shared ride.

CARPOOL_BACK_TO_BACK (4):

The vehicle will finish its current, active trip before proceeding to the pickup point. ETA and distance calculations take the existing trip into account.

class google.maps.fleetengine_v1.types.VehicleState(value)[source]

Bases: proto.enums.Enum

The state of a Vehicle.

Values:
UNKNOWN_VEHICLE_STATE (0):

Default, used for unspecified or unrecognized vehicle states.

OFFLINE (1):

The vehicle is not accepting new trips. Note: the vehicle may continue to operate in this state while completing a trip assigned to it.

ONLINE (2):

The vehicle is accepting new trips.

class google.maps.fleetengine_v1.types.VisualTrafficReportPolylineRendering(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Describes how clients should color one portion of the polyline along the route.

road_stretch

Optional. Road stretches that should be rendered along the polyline. Stretches are guaranteed to not overlap, and do not necessarily span the full route.

In the absence of a road stretch to style, the client should apply the default for the route.

Type

MutableSequence[google.maps.fleetengine_v1.types.VisualTrafficReportPolylineRendering.RoadStretch]

class RoadStretch(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

One road stretch that should be rendered.

style

Required. The style to apply.

Type

google.maps.fleetengine_v1.types.VisualTrafficReportPolylineRendering.RoadStretch.Style

offset_meters

Required. The style should be applied between [offset_meters, offset_meters + length_meters).

Type

int

length_meters

Required. The length of the path where to apply the style.

Type

int

class Style(value)[source]

Bases: proto.enums.Enum

The traffic style, indicating traffic speed.

Values:
STYLE_UNSPECIFIED (0):

No style selected.

SLOWER_TRAFFIC (1):

Traffic is slowing down.

TRAFFIC_JAM (2):

There is a traffic jam.

class google.maps.fleetengine_v1.types.Waypoint(mapping=None, *, ignore_unknown_fields=False, **kwargs)[source]

Bases: proto.message.Message

Describes intermediate points along a route for a VehicleMatch in a SearchVehiclesResponse. This concept is represented as a TripWaypoint in all other endpoints.

lat_lng

The location of this waypoint.

Type

google.type.latlng_pb2.LatLng

eta

The estimated time that the vehicle will arrive at this waypoint.

Type

google.protobuf.timestamp_pb2.Timestamp

class google.maps.fleetengine_v1.types.WaypointType(value)[source]

Bases: proto.enums.Enum

The type of waypoint.

Values:
UNKNOWN_WAYPOINT_TYPE (0):

Unknown or unspecified waypoint type.

PICKUP_WAYPOINT_TYPE (1):

Waypoints for picking up riders or items.

DROP_OFF_WAYPOINT_TYPE (2):

Waypoints for dropping off riders or items.

INTERMEDIATE_DESTINATION_WAYPOINT_TYPE (3):

Waypoints for intermediate destinations in a multi-destination trip.