Basics
API reference
Release notes
Deprecations
Examples
Sign in / Sign up
Sign in / Sign up
Query navigation session
Mutate to recalculate navigation

Updating a navigation session

Once a navigation session has been created and a subscription is running, more data can be provided to update the navigation session. Based on locations and telemetry data, Chargetrip optimizes the route.

Mutation

To update a navigation session an id and array of location_data need to be provided. The telemetry input is optional but including it will result in better consumption predictions and more accurate routing. If the mutation executed succesfully, OK will be returned on the data object. The updates itself will be reflected on the navigationUpdatedById subscription or the navigation query. When using a query, please be aware that changes can take a little while to process.

Locations data heartbeat

The location_data array requires at least one location. If Mapbox is used as a data provider, periodical updates are received that can be stored in a local cache. Alternatively, location can be stored every 5 or 10 seconds depending on the vehicle speed.

Sending the vehicle location at least every 5 minutes is recommended.

Telemetry data

Next to location data, telemetry data is accepted. This is real-time data coming directly from the vehicle. Obtaining this data can be done via the Connect platform as described here.

Telemetry data might include the current heading of the vehicle, state_of_charge, tire_pressure or is_charging state of the vehicle. The state_of_charge can be used for sending a new state of charge value after charging at the station or to confirm rolling predictions by sending intermittend state of charge values. Tire pressure can be used to more accurately do range predictions and by using the charging state of the vehicle, visual updates can be presented.

An overview of accepted / recommended telemetry fields is displayed here. Chargetrip can easily add additional custom telemetry inputs such as; heat pumps, active weight, refrigeration, PV etc. To learn more, contact sales@chargetrip.com or your customer success representative.

Arguments

input • NavigationUpdateInput

• Required

Navigation update input

id • ID

• Required

ID of the navigation session

location_data • NavigationUpdateLocationsInput

• Required

A list of locations that were collected since the last update

geometry • PointInput

• Required

GPS location

type • PointType

• Required

Point type.

Show PointType enum values

Point

coordinates • Float

• Required

Coordinates [longitude, latitude].

properties • NavigationUpdateLocationPropertiesInput

• Required

Extra information about the location

route_leg • Int

• Required

Current route leg index corresponding to a location

speed • VehicleSpeedInput

Speed at a location

value • Float

• Required

Value of the vehicle speed.

type • SpeedUnit

• Required

Type of the vehicle speed.

Show SpeedUnit enum values

kilometers_per_hour

Return the speed in kilometers per hour.

miles_per_hour

Return the speed in miles per hour.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

timestamp • Int

• Required

UNIX timestamp at location, in seconds

elevation • ElevationInput

Elevation information

value • Float

• Required

Value of the elevation.

type • DistanceUnit

• Required

Type of the value of elevation.

Show DistanceUnit enum values

meter

Return the distance in meters.

foot

Return the distance in feet.

kilometer

Return the distance in kilometers.

mile

Return the distance in miles.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

telemetry • TelemetryInput

Telemetry data input

auxiliary_consumption • AuxiliaryConsumptionInput

Average auxiliary power consumption.

value • Float

• Required

Value of the auxiliary power consumption of the vehicle.

type • AuxiliaryConsumptionUnit

• Required

Type of auxiliary power consumption of the vehicle.

Show AuxiliaryConsumptionUnit enum values

kilowatt_hour

Return the auxiliary consumption in kilowatt hours.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

battery_current • Float

Battery current in ampere.

battery_temperature • BatteryTemperatureInput

Battery temperature.

value • Float

• Required

Value of the temperature of the battery.

type • TemperatureUnit

• Required

Type of temperature of the battery.

Show TemperatureUnit enum values

Celsius

Return the temperature in Celsius.

Fahrenheit

Return the temperature in Fahrenheit.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

battery_voltage • Float

Battery voltage in volts.

is_charging • Boolean

Is the vehicle currently charging.

charge_speed • ChargeSpeedInput

Rate of charge.

value • Float

• Required

Value of the charge speed of the battery.

type • ChargeSpeedUnit

• Required

Type of the charge speed of the battery.

Show ChargeSpeedUnit enum values

kilowatt_hour

Return the charge speed in kilowatt hours.

kilometers_per_hour

Return the charge speed in kilometers per hour.

miles_per_hour

Return the charge speed in miles per hour.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

charge_total • ChargeTotalInput

Amount charged.

value • Float

• Required

Value of the temperature of the battery.

type • StateOfChargeUnit

• Required

Type of total charge amount.

Show StateOfChargeUnit enum values

kilometer

Return the state of charge in kilometers.

mile

Return the state of charge in miles.

kilowatt_hour

Return the state of charge in kilowatt hours.

percentage

Return the state of charge as a percentage.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

total_occupant_weight • TotalOccupantWeightInput

Cumulated weight of the occupants.

value • Float

• Required

Value of the combined weight of the occupants.

type • WeightUnit

• Required

Type of the current weight of the occupants.

Show WeightUnit enum values

kilogram

Return the weight in kilograms.

pound

Return the weight in pounds.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

total_cargo_weight • TotalCargoWeightInput

Weight of the cargo.

value • Float

• Required

Value of the current weight of the cargo.

type • WeightUnit

• Required

Type of the current weight of the cargo.

Show WeightUnit enum values

kilogram

Return the weight in kilograms.

pound

Return the weight in pounds.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

elevation • ElevationInput

Current elevation.

value • Float

• Required

Value of the elevation.

type • DistanceUnit

• Required

Type of the value of elevation.

Show DistanceUnit enum values

meter

Return the distance in meters.

foot

Return the distance in feet.

kilometer

Return the distance in kilometers.

mile

Return the distance in miles.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

heading • Float

Current heading in degrees.

motor_rpm • Int

RPM of the motor.

occupants • Int

Number of occupants in the vehicle.

odometer • OdometerInput

Mileage or odometer reading.

value • Float

• Required

Value of the vehicle's odometer.

type • DistanceUnit

• Required

Type of the value of the vehicle's odometer.

Show DistanceUnit enum values

meter

Return the distance in meters.

foot

Return the distance in feet.

kilometer

Return the distance in kilometers.

mile

Return the distance in miles.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

outside_temperature • OutsideTempInput

Outside temperature.

value • Float

• Required

Value of the outside temperature.

type • TemperatureUnit

• Required

Type of the value of the outside temperature.

Show TemperatureUnit enum values

Celsius

Return the temperature in Celsius.

Fahrenheit

Return the temperature in Fahrenheit.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

is_parked • Boolean

Vehicle is in park, neutral or turned off.

power • PowerInput

Vehicle power.

value • Float

• Required

Value of the positive or negative power. When negative the vehicle is charging.

type • PowerUnit

• Required

Type of the value of the power.

Show PowerUnit enum values

kilowatt

Return the power in kilowatts.

horsepower

Return the power in horsepower.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

state_of_charge • StateOfChargeInput

Battery state of charge.

value • Float

• Required

Value of the state of charge of the vehicle.

type • StateOfChargeUnit

• Required

Type of the state of charge of the vehicle.

Show StateOfChargeUnit enum values

kilometer

Return the state of charge in kilometers.

mile

Return the state of charge in miles.

kilowatt_hour

Return the state of charge in kilowatt hours.

percentage

Return the state of charge as a percentage.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

tire_pressure • TirePressureInput

Average tire pressures of all wheels, starting from the front side right to left and to the rear.

value • Float

• Required

Values for the tire pressure, starting from the front side right to left and to the rear.

type • PressureUnit

• Required

Type of the value of pressure.

Show PressureUnit enum values

bar

Return the pressure in bar.

pounds_per_square_inch

Return the pressure in pounds per square inch.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

timestamp • Int

UNIX timestamp in seconds.

vehicle_speed • VehicleSpeedInput

Vehicle speed.

value • Float

• Required

Value of the vehicle speed.

type • SpeedUnit

• Required

Type of the vehicle speed.

Show SpeedUnit enum values

kilometers_per_hour

Return the speed in kilometers per hour.

miles_per_hour

Return the speed in miles per hour.

source • TelemetryInputSource

Source of inputted data, defaults to 'manual'.

Default • manual

Show TelemetryInputSource enum values

manual

Manually inputted value.

telemetry

Value from the vehicle's telemetry.

default

Default value.

custom • JSON

Custom input fields can be added based on telemetry architecture.

Response

A response can either contain a data or an errors object. The response header will always return 200 as a status code.

Data object

When successful, a data object will be returned with the requested fields. If there are no fields present the data object will return the operation name with the appropriate return type. If the operation was a query, this output will be an object of the schema’s query root type; if the operation was a mutation, this output will be an object of the schema’s mutation root type.

Error object

If unsuccessful, an errors object will be returned with more details in the extensions object. The error object can contain any of the following objects.

Error

EMPTY_ARRAY_NOT_ALLOWED

Array $NAME should have at least one value.

Error

INVALID_COORDINATES

Coordinates provided for $LOCATION are not valid.

Error

INVALID_UNIT

Provided unit type $TYPE for $LOCATION is not valid.

Error

INVALID_VALUE

Provided value $VALUE for $LOCATION is not valid. Expected value of type $EXPECTEDTYPE.

Error

NAVIGATION_HEADING_INVALID

Heading should be a value between 0 and 360.

Error

NAVIGATION_LOCATION_INVALID

One or more locations sent are invalid.

Error

NAVIGATION_LOCATIONS_MINIMUM_LENGTH

You should send us at least one location.

Error

NAVIGATION_TELEMETRY_INVALID

Field $TELEMETRYTYPE cannot be negative.

Error

NEGATIVE_VALUE_NOT_ALLOWED

Negative value for $LOCATION is not allowed.

Error

OCCUPANTS_BELOW_ALLOWED

Provided number of occupants for $LOCATION is not valid. The value must be at least 1.

Error

OPERATION_NOT_ALLOWED

You are not allowed to execute this operation. Enable it for the current application in the dashboard or reach out to customer support.

Error

TIRE_PRESSURE_BELOW_ALLOWED

Provided tire pressure is not valid. The value must be at least 1.

Error

ZERO_OR_NEGATIVE_VALUE_NOT_ALLOWED

Zero or negative value for $LOCATION is not allowed.

  • Basics

    API Basics GraphQL Basics EV basics
  • API reference

    API Vehicles Stations Routes Routes (NEW) Emissions Navigation Tile service Isolines Vehicle connectivity
  • Products

    Website Dashboard Help center SDKs
  • Tooling

    Playground Voyager Examples API Status
  • Legal

    Terms & Conditions Privacy Policy Cookie Policy Security
Mission Statement State of charge Try Chargetrip Go

© Chargetrip 2025

Build with love in

Amsterdam ❤️