curl --request POST \
--url https://api.iklim.co/v1/enroute/register \
--header 'Content-Type: application/json' \
--data '
{
"origin": {
"lng": 32.857358,
"lat": 39.93504
},
"destination": {
"lng": 32.857358,
"lat": 39.93504
},
"departureTime": "2023-11-07T05:31:56Z",
"distanceMeters": 123,
"durationSeconds": 123,
"geometry": {
"encodedPolyline": "<string>",
"polylinePrecision": 123,
"coordinates": [
{
"lng": 32.857358,
"lat": 39.93504
}
]
},
"waypoints": [
{
"lng": 32.857358,
"lat": 39.93504
}
]
}
'import requests
url = "https://api.iklim.co/v1/enroute/register"
payload = {
"origin": {
"lng": 32.857358,
"lat": 39.93504
},
"destination": {
"lng": 32.857358,
"lat": 39.93504
},
"departureTime": "2023-11-07T05:31:56Z",
"distanceMeters": 123,
"durationSeconds": 123,
"geometry": {
"encodedPolyline": "<string>",
"polylinePrecision": 123,
"coordinates": [
{
"lng": 32.857358,
"lat": 39.93504
}
]
},
"waypoints": [
{
"lng": 32.857358,
"lat": 39.93504
}
]
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
origin: {lng: 32.857358, lat: 39.93504},
destination: {lng: 32.857358, lat: 39.93504},
departureTime: '2023-11-07T05:31:56Z',
distanceMeters: 123,
durationSeconds: 123,
geometry: {
encodedPolyline: '<string>',
polylinePrecision: 123,
coordinates: [{lng: 32.857358, lat: 39.93504}]
},
waypoints: [{lng: 32.857358, lat: 39.93504}]
})
};
fetch('https://api.iklim.co/v1/enroute/register', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.iklim.co/v1/enroute/register",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'origin' => [
'lng' => 32.857358,
'lat' => 39.93504
],
'destination' => [
'lng' => 32.857358,
'lat' => 39.93504
],
'departureTime' => '2023-11-07T05:31:56Z',
'distanceMeters' => 123,
'durationSeconds' => 123,
'geometry' => [
'encodedPolyline' => '<string>',
'polylinePrecision' => 123,
'coordinates' => [
[
'lng' => 32.857358,
'lat' => 39.93504
]
]
],
'waypoints' => [
[
'lng' => 32.857358,
'lat' => 39.93504
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.iklim.co/v1/enroute/register"
payload := strings.NewReader("{\n \"origin\": {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n },\n \"destination\": {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n },\n \"departureTime\": \"2023-11-07T05:31:56Z\",\n \"distanceMeters\": 123,\n \"durationSeconds\": 123,\n \"geometry\": {\n \"encodedPolyline\": \"<string>\",\n \"polylinePrecision\": 123,\n \"coordinates\": [\n {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n }\n ]\n },\n \"waypoints\": [\n {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.iklim.co/v1/enroute/register")
.header("Content-Type", "application/json")
.body("{\n \"origin\": {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n },\n \"destination\": {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n },\n \"departureTime\": \"2023-11-07T05:31:56Z\",\n \"distanceMeters\": 123,\n \"durationSeconds\": 123,\n \"geometry\": {\n \"encodedPolyline\": \"<string>\",\n \"polylinePrecision\": 123,\n \"coordinates\": [\n {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n }\n ]\n },\n \"waypoints\": [\n {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.iklim.co/v1/enroute/register")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"origin\": {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n },\n \"destination\": {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n },\n \"departureTime\": \"2023-11-07T05:31:56Z\",\n \"distanceMeters\": 123,\n \"durationSeconds\": 123,\n \"geometry\": {\n \"encodedPolyline\": \"<string>\",\n \"polylinePrecision\": 123,\n \"coordinates\": [\n {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n }\n ]\n },\n \"waypoints\": [\n {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"routeId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"expirationTime": "2023-11-07T05:31:56Z",
"distanceUnit": "<string>",
"status": {
"progressPercentage": 123,
"distanceTraveled": 123,
"remainingDistance": 123,
"timeElapsedSeconds": 123,
"estimatedTimeRemainingSeconds": 123,
"scheduleDeviationSeconds": 123,
"expectedSegmentIndex": 123,
"estimatedArrivalTime": "2023-11-07T05:31:56Z"
},
"currentSegment": {
"index": 123,
"h3Address": "<string>",
"eta": "2023-11-07T05:31:56Z",
"etd": "2023-11-07T05:31:56Z",
"distanceToEntry": 123,
"distanceToExit": 123,
"arrivalPoint": {
"lng": 32.857358,
"lat": 39.93504
},
"departurePoint": {
"lng": 32.857358,
"lat": 39.93504
},
"weatherEvents": {
"temperature": 123,
"apparentTemperature": 123,
"humidity": 123,
"cloudCover": 123,
"windSpeed": 123,
"windGust": 123,
"windDirection": 123,
"snowFall": 123,
"precipitation": 123,
"precipitationProbability": 123,
"visibility": 123,
"lightningSummary": {
"windowMinutes": 123,
"bucketMinutes": 123,
"totalEventCount": 123,
"cgFlashCount": 123,
"icPulseCount": 123,
"lastEventAgeSec": 123,
"lastFlashAgeSec": 123,
"lastPulseAgeSec": 123,
"nearestEventDistance": 123,
"nearestFlashDistance": 123,
"nearestPulseDistance": 123,
"maxPeakCurrent": 123,
"avgPeakCurrent": 123,
"avgSensorCount": 123,
"confidenceScore": 123,
"riskIndex": 123
},
"thunderstormSummary": {
"windowMinutes": 123,
"bucketMinutes": 123,
"summary": {
"stormCount": 123,
"activeStorms": 123,
"insideAnyThreatBoundary": true,
"nearestThreatBoundaryDistance": 123,
"nearestStormCentroidDistance": 123,
"lastEventAge": 123,
"riskScore": 123
},
"activeStorms": [
{
"eventId": "<string>",
"eventStartUtcEpoch": 123,
"eventEndUtcEpoch": 123,
"eventAge": 123,
"cell": {
"area": 123,
"speed": 123,
"direction": 123,
"centroidDistance": 123,
"bearingFromDriver": 123
},
"flashRates": {
"inCloud": 123,
"cloudToGround": 123,
"total": 123,
"cloudToGroundRatio": 123
},
"threat": {
"insideThreatPolygon": true,
"distanceToThreatBoundary": 123,
"bearingFromDriver": 123
},
"score": {
"stormRiskScore": 123
}
}
]
},
"precipitationSummary": {
"windowMinutes": 123,
"bucketMinutes": 123,
"isPrecipitating": true,
"radarTimeStamp": 123,
"dataAgeSec": 123,
"radarSnapshotCount": 123,
"expectedEndSec": 123,
"expectedStartSec": 123
}
}
},
"upcomingSegments": [
{
"index": 123,
"h3Address": "<string>",
"eta": "2023-11-07T05:31:56Z",
"etd": "2023-11-07T05:31:56Z",
"distanceToEntry": 123,
"distanceToExit": 123,
"arrivalPoint": {
"lng": 32.857358,
"lat": 39.93504
},
"departurePoint": {
"lng": 32.857358,
"lat": 39.93504
},
"weatherEvents": {
"temperature": 123,
"apparentTemperature": 123,
"humidity": 123,
"cloudCover": 123,
"windSpeed": 123,
"windGust": 123,
"windDirection": 123,
"snowFall": 123,
"precipitation": 123,
"precipitationProbability": 123,
"visibility": 123
}
}
]
}Register a route
Registers a new route with departure time and duration. Returns weather and location status for the current and upcoming segments.
curl --request POST \
--url https://api.iklim.co/v1/enroute/register \
--header 'Content-Type: application/json' \
--data '
{
"origin": {
"lng": 32.857358,
"lat": 39.93504
},
"destination": {
"lng": 32.857358,
"lat": 39.93504
},
"departureTime": "2023-11-07T05:31:56Z",
"distanceMeters": 123,
"durationSeconds": 123,
"geometry": {
"encodedPolyline": "<string>",
"polylinePrecision": 123,
"coordinates": [
{
"lng": 32.857358,
"lat": 39.93504
}
]
},
"waypoints": [
{
"lng": 32.857358,
"lat": 39.93504
}
]
}
'import requests
url = "https://api.iklim.co/v1/enroute/register"
payload = {
"origin": {
"lng": 32.857358,
"lat": 39.93504
},
"destination": {
"lng": 32.857358,
"lat": 39.93504
},
"departureTime": "2023-11-07T05:31:56Z",
"distanceMeters": 123,
"durationSeconds": 123,
"geometry": {
"encodedPolyline": "<string>",
"polylinePrecision": 123,
"coordinates": [
{
"lng": 32.857358,
"lat": 39.93504
}
]
},
"waypoints": [
{
"lng": 32.857358,
"lat": 39.93504
}
]
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
origin: {lng: 32.857358, lat: 39.93504},
destination: {lng: 32.857358, lat: 39.93504},
departureTime: '2023-11-07T05:31:56Z',
distanceMeters: 123,
durationSeconds: 123,
geometry: {
encodedPolyline: '<string>',
polylinePrecision: 123,
coordinates: [{lng: 32.857358, lat: 39.93504}]
},
waypoints: [{lng: 32.857358, lat: 39.93504}]
})
};
fetch('https://api.iklim.co/v1/enroute/register', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.iklim.co/v1/enroute/register",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'origin' => [
'lng' => 32.857358,
'lat' => 39.93504
],
'destination' => [
'lng' => 32.857358,
'lat' => 39.93504
],
'departureTime' => '2023-11-07T05:31:56Z',
'distanceMeters' => 123,
'durationSeconds' => 123,
'geometry' => [
'encodedPolyline' => '<string>',
'polylinePrecision' => 123,
'coordinates' => [
[
'lng' => 32.857358,
'lat' => 39.93504
]
]
],
'waypoints' => [
[
'lng' => 32.857358,
'lat' => 39.93504
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.iklim.co/v1/enroute/register"
payload := strings.NewReader("{\n \"origin\": {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n },\n \"destination\": {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n },\n \"departureTime\": \"2023-11-07T05:31:56Z\",\n \"distanceMeters\": 123,\n \"durationSeconds\": 123,\n \"geometry\": {\n \"encodedPolyline\": \"<string>\",\n \"polylinePrecision\": 123,\n \"coordinates\": [\n {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n }\n ]\n },\n \"waypoints\": [\n {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.iklim.co/v1/enroute/register")
.header("Content-Type", "application/json")
.body("{\n \"origin\": {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n },\n \"destination\": {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n },\n \"departureTime\": \"2023-11-07T05:31:56Z\",\n \"distanceMeters\": 123,\n \"durationSeconds\": 123,\n \"geometry\": {\n \"encodedPolyline\": \"<string>\",\n \"polylinePrecision\": 123,\n \"coordinates\": [\n {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n }\n ]\n },\n \"waypoints\": [\n {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.iklim.co/v1/enroute/register")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"origin\": {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n },\n \"destination\": {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n },\n \"departureTime\": \"2023-11-07T05:31:56Z\",\n \"distanceMeters\": 123,\n \"durationSeconds\": 123,\n \"geometry\": {\n \"encodedPolyline\": \"<string>\",\n \"polylinePrecision\": 123,\n \"coordinates\": [\n {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n }\n ]\n },\n \"waypoints\": [\n {\n \"lng\": 32.857358,\n \"lat\": 39.93504\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"routeId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"expirationTime": "2023-11-07T05:31:56Z",
"distanceUnit": "<string>",
"status": {
"progressPercentage": 123,
"distanceTraveled": 123,
"remainingDistance": 123,
"timeElapsedSeconds": 123,
"estimatedTimeRemainingSeconds": 123,
"scheduleDeviationSeconds": 123,
"expectedSegmentIndex": 123,
"estimatedArrivalTime": "2023-11-07T05:31:56Z"
},
"currentSegment": {
"index": 123,
"h3Address": "<string>",
"eta": "2023-11-07T05:31:56Z",
"etd": "2023-11-07T05:31:56Z",
"distanceToEntry": 123,
"distanceToExit": 123,
"arrivalPoint": {
"lng": 32.857358,
"lat": 39.93504
},
"departurePoint": {
"lng": 32.857358,
"lat": 39.93504
},
"weatherEvents": {
"temperature": 123,
"apparentTemperature": 123,
"humidity": 123,
"cloudCover": 123,
"windSpeed": 123,
"windGust": 123,
"windDirection": 123,
"snowFall": 123,
"precipitation": 123,
"precipitationProbability": 123,
"visibility": 123,
"lightningSummary": {
"windowMinutes": 123,
"bucketMinutes": 123,
"totalEventCount": 123,
"cgFlashCount": 123,
"icPulseCount": 123,
"lastEventAgeSec": 123,
"lastFlashAgeSec": 123,
"lastPulseAgeSec": 123,
"nearestEventDistance": 123,
"nearestFlashDistance": 123,
"nearestPulseDistance": 123,
"maxPeakCurrent": 123,
"avgPeakCurrent": 123,
"avgSensorCount": 123,
"confidenceScore": 123,
"riskIndex": 123
},
"thunderstormSummary": {
"windowMinutes": 123,
"bucketMinutes": 123,
"summary": {
"stormCount": 123,
"activeStorms": 123,
"insideAnyThreatBoundary": true,
"nearestThreatBoundaryDistance": 123,
"nearestStormCentroidDistance": 123,
"lastEventAge": 123,
"riskScore": 123
},
"activeStorms": [
{
"eventId": "<string>",
"eventStartUtcEpoch": 123,
"eventEndUtcEpoch": 123,
"eventAge": 123,
"cell": {
"area": 123,
"speed": 123,
"direction": 123,
"centroidDistance": 123,
"bearingFromDriver": 123
},
"flashRates": {
"inCloud": 123,
"cloudToGround": 123,
"total": 123,
"cloudToGroundRatio": 123
},
"threat": {
"insideThreatPolygon": true,
"distanceToThreatBoundary": 123,
"bearingFromDriver": 123
},
"score": {
"stormRiskScore": 123
}
}
]
},
"precipitationSummary": {
"windowMinutes": 123,
"bucketMinutes": 123,
"isPrecipitating": true,
"radarTimeStamp": 123,
"dataAgeSec": 123,
"radarSnapshotCount": 123,
"expectedEndSec": 123,
"expectedStartSec": 123
}
}
},
"upcomingSegments": [
{
"index": 123,
"h3Address": "<string>",
"eta": "2023-11-07T05:31:56Z",
"etd": "2023-11-07T05:31:56Z",
"distanceToEntry": 123,
"distanceToExit": 123,
"arrivalPoint": {
"lng": 32.857358,
"lat": 39.93504
},
"departurePoint": {
"lng": 32.857358,
"lat": 39.93504
},
"weatherEvents": {
"temperature": 123,
"apparentTemperature": 123,
"humidity": 123,
"cloudCover": 123,
"windSpeed": 123,
"windGust": 123,
"windDirection": 123,
"snowFall": 123,
"precipitation": 123,
"precipitationProbability": 123,
"visibility": 123
}
}
]
}Body
Starting point of the route
Show child attributes
Show child attributes
Destination point of the route
Show child attributes
Show child attributes
Planned departure time, expressed as Unix epoch milliseconds
Total route distance in meters
Expected total travel duration in seconds
Route geometry, provided as an encoded polyline or a list of coordinates
Show child attributes
Show child attributes
Optional list of user-defined intermediate stops (e.g. fuel stops, rest areas); these are semantic waypoints, not dense road path coordinates
Show child attributes
Show child attributes
Response
Route registered successfully
Unique identifier assigned to the registered route
Expiration time of the route registration, expressed as Unix epoch milliseconds
Unit used for distance values in this response
Current location and progress status of the driver along the route
Show child attributes
Show child attributes
The route segment the driver is currently in
Show child attributes
Show child attributes
List of upcoming route segments ahead of the driver
Show child attributes
Show child attributes