Add EV Routing to your existing app in under 3 weeks
Adding EV routing to your application seems like a big undertaking. However, there are only three elements needed to get this feature off the ground. A car selector, a page to plan your trip and a journey overview. It is as simple as that. In this article, I will walk you through the steps required in order to make your app ready for routing electric mobility.
The car selector
First things first. We need to know what vehicle your end-user is driving. With our
carList query, you can quickly get a list of all the vehicles in our database. All cars come with an image in the same style so that they can be easily loaded into your front end. We also provide a field called
chargetrip_edition. This field is added to make consistent naming of vehicles available for your application.
Here is an example that shows you what a car search can look like. It also has a link to Github, so you can see exactly how we created it.
Plan your trip
Now that a user can select a car, we need to know where they are going. You can easily create a route using our
newRoute mutation. Simply fill in the
destination, and your
stateOfCharge. These are the basics, but with our API you can add additional features including making routing even more accurate by adding telemetry data or adding operator preferences.
Show your journey!
Now you are ready to display the route on a map. From our API you can request, a
legs with charging stops, the
duration of the route, the
consumption of the vehicle and much more.
Here we have created a simple example that shows you exactly how to create a route and display that route in your front end.
That’s all there is to it. Now all you need is some coffee and a software sprint. And if for some reason you can’t find time on your roadmap, our White-label application can be live on your website within a month!
Want to know more?
Plan a demo with our technical team, and we will help you get started.