Turn-by-turn latitude and longitude on HERE Routing API - here-api

I want to get the latitude and longitude per instruction on the actions I get from HERE Routing API v8. I get the maneuvers from HERE Routing v7 but not on v8. I tried all the return values.
https://router.hereapi.com/v8/routes?apikey=APIKEY&origin=14.57755,121.04239&destination=14.57735,121.04274&return=polyline,summary,actions,instructions&spans=segmentId&transportMode=car
{
"routes": [{
"id": "bae447cc-a31f-48f7-83a7-2c73c34d492d",
"sections": [{
"id": "152087e3-7f61-451e-b764-e88583586f10",
"type": "vehicle",
"actions": [{
"action": "depart",
"duration": 10,
"length": 76,
"instruction": "Head toward Camiguin on Barangka Dr. Go for 76 m.",
"offset": 0
},
{
"action": "continue",
"duration": 22,
"length": 102,
"instruction": "Continue on 9 de Febrero toward Ortigas Ave/Shaw Blvd. Go for 102 m.",
"offset": 3
},
{
"action": "turn",
"duration": 12,
"length": 53,
"instruction": "Turn right onto Talumpong. Go for 53 m.",
"offset": 7,
"direction": "right",
"severity": "quite"
},
{
"action": "turn",
"duration": 29,
"length": 149,
"instruction": "Turn right onto Tabayog. Go for 149 m.",
"offset": 8,
"direction": "right",
"severity": "quite"
},
{
"action": "arrive",
"duration": 0,
"length": 0,
"instruction": "Arrive at Tabayog. Your destination is on the left.",
"offset": 13
}
],
"departure": {
"time": "2022-02-03T18:59:50+08:00",
"place": {
"type": "place",
"location": {
"lat": 14.5775706,
"lng": 121.0423584
},
"originalLocation": {
"lat": 14.5775499,
"lng": 121.04239
}
}
},
"arrival": {
"time": "2022-02-03T19:01:03+08:00",
"place": {
"type": "place",
"location": {
"lat": 14.5773811,
"lng": 121.0426889
},
"originalLocation": {
"lat": 14.5773499,
"lng": 121.04274
}
}
},
"summary": {
"duration": 73,
"length": 380,
"baseDuration": 65
},
"polyline": "BGm635bs767mHiS0MsEkD8L0KgF0FsEoGgF4IoQsdvb8L3IvRnQze3IvHzK3I9ElD",
"spans": [{
"offset": 0,
"topologySegmentId": "+here:cm:segment:46864687"
},
{
"offset": 3,
"topologySegmentId": "+here:cm:segment:47392105"
},
{
"offset": 7,
"topologySegmentId": "-here:cm:segment:26196228"
},
{
"offset": 8,
"topologySegmentId": "-here:cm:segment:23767715"
},
{
"offset": 10,
"topologySegmentId": "-here:cm:segment:21101714"
}
],
"language": "en-us",
"transport": {
"mode": "car"
}
}],
}],
}

As of 2nd day of February 2022, the position paremeter that outputs latitude and longitude in v7 is not supported in v8 under maneuverAttributes. Source

That is correct in routing V8, there is an offset into polyline in maneuver. Offset is the index into the polyline and all coordinates in V8 work this way. spans, actions, they have offset into the route shape which is an array of coordinates. Example: https://demo.routing.ext.here.com/#url=https://router.hereapi.com/v8/routes?apikey=DEFAULT_API_KEY&origin=52.551325,13.351349&destination=52.514255,13.34929&return=polyline,summary,actions,instructions&transportMode=car

Related

Here Waypoint Sequencing API Doesn't Honor Delivery Windows

I am experimenting with the HERE Waypoint Sequencing API using the new JSON request format, and it doesn't seem to take into account delivery windows specified in the times array within the plan object. I went back to the example provided in the documentation and found that the same thing was happening: Arrival and departure times are far from the specified delivery windows.
In my Example, Customer 1 has times:
"times": [["2020-07-04T08:00:00Z","2020-07-04T10:00:00Z"],["2020-07-04T16:00:00Z","2020-07-04T18:00:00Z"]]
However, the solution contains:
"time": {
"arrival": "2020-07-04T00:30:00.000+0000",
"departure": "2020-07-04T00:33:00.000+0000"
}
Which isn't even close.
Endpoint: https://wps.hereapi.com/v8/findsequence
Request:
{
"configuration": {
"optimizations": {
"traffic": "liveOrHistorical",
"waitingTime": {
"bufferTime": 15,
"reduce": false
}
}
},
"fleet": {
"profiles": [{"type":"car","name":"normal_car"}],
"types": [
{
"amount": 1,
"capacity": [10,5],
"costs": {
"distance": 0.0001,
"fixed": 22,
"time": 0.0048
},
"id": "string",
"limits": {
"maxDistance": 20000,
"shiftTime": 21600
},
"profile": "normal_car",
"shifts": [
{
"breaks": [
{
"duration": 180,
"location": {
"lat": 52.53088,
"lng": 13.38471
},
"times": [["2020-07-04T08:00:00Z","2020-07-04T10:00:00Z"],["2020-07-04T16:00:00Z","2020-07-04T18:00:00Z"]]
}
],
"end": {
"location": {
"lat": 52.53088,
"lng": 13.38471
},
"time": "2020-07-04T23:30:00Z"
},
"start": {
"location": {
"lat": 52.53088,
"lng": 13.38471
},
"time": "2020-07-04T00:30:00Z"
}
}
],
"skills": ["fridge"]
}
]
},
"id": "7f3423c2-784a-4983-b472-e14107d5a54a",
"plan": {
"jobs": [
{
"id": "string",
"places": {
"deliveries": [
{
"demand": [10,5],
"duration": 180,
"location": {
"lat": 52.53088,
"lng": 13.38471
},
"tag": "Customer 1",
"times": [["2020-07-04T08:00:00Z","2020-07-04T10:00:00Z"],["2020-07-04T16:00:00Z","2020-07-04T18:00:00Z"]]
},
{
"demand": [10,5],
"duration": 180,
"location": {
"lat": 53.53088,
"lng": 14.98471
},
"tag": "Customer 2",
"times": [["2020-07-04T08:00:00Z","2020-07-04T10:00:00Z"],["2020-07-04T16:00:00Z","2020-07-04T18:00:00Z"]]
}
],
"pickups": [
{
"demand": [10,5],
"duration": 180,
"location": {
"lat": 52.53088,
"lng": 13.98471
},
"tag": "some_tag",
"times": [["2020-07-04T08:00:00Z","2020-07-04T10:00:00Z"],["2020-07-04T16:00:00Z","2020-07-04T18:00:00Z"]]
}
]
},
"skills": ["fridge"]
}
],
"relations": [
{
"jobs": [
"string"
],
"type": "flexible",
"vehicleId": "7f3423c2-784a-4983-b472-e14107d5a54a"
}
]
}
}
Response:
{
"problemId": "7f3423c2-784a-4983-b472-e14107d5a54a",
"statistic": {
"cost": null,
"distance": 441655,
"duration": 20127,
"times": {
"break": 0,
"driving": 19587,
"serving": 540,
"waiting": 0
}
},
"tours": [
{
"vehicleId": "string",
"typeId": null,
"stops": [
{
"location": {
"lat": 52.53088,
"lng": 13.38471
},
"time": {
"arrival": null,
"departure": "2020-07-04T00:30:00.000+0000"
},
"load": [
],
"activities": [
{
"jobId": "departure",
"jobTag": "departure",
"type": null,
"location": null,
"time": null
}
]
},
{
"location": {
"lat": 52.53088,
"lng": 13.38471
},
"time": {
"arrival": "2020-07-04T00:30:00.000+0000",
"departure": "2020-07-04T00:33:00.000+0000"
},
"load": [
],
"activities": [
{
"jobId": "Customer 1",
"jobTag": "Customer 1",
"type": null,
"location": null,
"time": null
}
]
},
{
"location": {
"lat": 52.53088,
"lng": 13.98471
},
"time": {
"arrival": "2020-07-04T01:34:05.000+0000",
"departure": "2020-07-04T01:37:05.000+0000"
},
"load": [
],
"activities": [
{
"jobId": "some_tag",
"jobTag": "some_tag",
"type": null,
"location": null,
"time": null
}
]
},
{
"location": {
"lat": 53.53088,
"lng": 14.98471
},
"time": {
"arrival": "2020-07-04T03:53:37.000+0000",
"departure": "2020-07-04T03:56:37.000+0000"
},
"load": [
],
"activities": [
{
"jobId": "Customer 2",
"jobTag": "Customer 2",
"type": null,
"location": null,
"time": null
}
]
},
{
"location": {
"lat": 52.53088,
"lng": 13.38471
},
"time": {
"arrival": "2020-07-04T06:05:27.000+0000",
"departure": null
},
"load": [
],
"activities": [
{
"jobId": "arrival",
"jobTag": "arrival",
"type": null,
"location": null,
"time": null
}
]
}
],
"statistic": {
"cost": null,
"distance": 441655,
"duration": 20127,
"times": {
"break": 0,
"driving": 19587,
"serving": 540,
"waiting": 0
}
}
}
],
"unassigned": null
}
Am I missing something?

Address in autocomplete results

When I do an autosuggest request in the address response I only receive the label. The address object is not filled.
This is my request: https://autosuggest.search.hereapi.com/v1/autosuggest?at=48.8578817,2.2791249999999934&limit=5&q=stj&apikey=xxxx
I receive this:
"title": "Top Services (Stj)",
"id": "here:pds:place:250u09wj-afceace0a11b49bca950ea22d0f8e452",
"resultType": "place",
"address": {
"label": "********"
},
I will need to receive the formatted address without the name
How can I fix this?
thanks
We have tried to reproduce your query and it works for us, please see the following code.
Please review the documentation page for detailed information on autosuggest
Documentation link :
https://autosuggest.search.hereapi.com/v1/autosuggest?at=48.8578817,2.2791249999999934&limit=5&q=stj&apikey=XXXX.
Query Result:
{
"items": [
{
"title": "Top Services (Stj)",
"id": "here:pds:place:250u09wj-afceace0a11b49bca950ea22d0f8e452",
"resultType": "place",
"address": {
"label": "Top Services, 61 Rue du Faubourg Saint-Denis, 75010 Paris, France"
},
"position": {
"lat": 48.8721,
"lng": 2.35384
},
"access": [
{
"lat": 48.87208,
"lng": 2.35392
}
],
"distance": 5690,
"categories": [
{
"id": "700-7200-0254",
"name": "Construction",
"primary": true
},
{
"id": "700-7200-0264",
"name": "Services de conseil et de gestion"
},
{
"id": "700-7200-0277",
"name": "Entrepreneur de second œuvre"
}
],
"highlights": {
"title": [
{
"start": 14,
"end": 17
}
],
"address": {
"label": [
]
}
}
},
{
"title": "La Clinique du Scooter d'Occasion (Stj 2 Roues)",
"id": "here:pds:place:250u09tv-591de1b090c54199b11154a72f462c0d",
"resultType": "place",
"address": {
"label": "La Clinique du Scooter d'Occasion, 148 Boulevard du Montparnasse, 75014 Paris, France"
},
"position": {
"lat": 48.84039,
"lng": 2.33383
},
"access": [
{
"lat": 48.84052,
"lng": 2.33393
}
],
"distance": 4451,
"categories": [
{
"id": "400-4200-0241",
"name": "Services logistiques",
"primary": true
}
],
"highlights": {
"title": [
{
"start": 35,
"end": 38
}
],
"address": {
"label": [
]
}
}
},
{
"title": "Stjohn's",
"id": "here:pds:place:2501r4ve-43f913ba8f9b0e7046aaee61bcfe8b9b",
"resultType": "place",
"address": {
"label": "Stjohn's, 11 Rue Edmond Valentin, 75007 Paris, France"
},
"position": {
"lat": 48.85961,
"lng": 2.30159
},
"access": [
{
"lat": 48.85968,
"lng": 2.30157
}
],
"distance": 1655,
"categories": [
{
"id": "700-7400-0141",
"name": "Services aux entreprises",
"primary": true
},
{
"id": "700-7200-0252",
"name": "Publicité, marketing, communication et études de marché"
}
],
"highlights": {
"title": [
{
"start": 0,
"end": 3
}
],
"address": {
"label": [
{
"start": 0,
"end": 3
}
]
}
}
},
{
"title": "Stjohn S",
"id": "here:pds:place:250u09tv-0f38e06dd8634ab4a0d931dad94de24c",
"resultType": "place",
"address": {
"label": "Stjohn S, 4 Rue des Petits-Pères, 75002 Paris, France"
},
"position": {
"lat": 48.86601,
"lng": 2.34027
},
"access": [
{
"lat": 48.8662,
"lng": 2.34023
}
],
"distance": 4564,
"categories": [
{
"id": "700-7200-0252",
"name": "Publicité, marketing, communication et études de marché",
"primary": true
},
{
"id": "700-7200-0271",
"name": "Services financiers et d'assurance"
}
],
"highlights": {
"title": [
{
"start": 0,
"end": 3
}
],
"address": {
"label": [
{
"start": 0,
"end": 3
}
]
}
}
},
{
"title": "Espace St-Jo'",
"id": "here:pds:place:250u09te-220742c64e4a40a48b8772987e7f987c",
"resultType": "place",
"address": {
"label": "Espace St-Jo', 54 Rue du Moulin de Pierres, 92140 Clamart, France"
},
"position": {
"lat": 48.80865,
"lng": 2.26594
},
"access": [
{
"lat": 48.8087,
"lng": 2.2659
}
],
"distance": 5558,
"categories": [
{
"id": "200-2200-0000",
"name": "Théâtre, musique et culture",
"primary": true
},
{
"id": "200-2000-0015",
"name": "Salle de spectacle/concert"
},
{
"id": "550-5520-0000",
"name": "Aire de loisirs"
}
],
"references": [
{
"supplier": {
"id": "yelp"
},
"id": "xJtl5krT8OZ3QYXtMl6Leg"
}
],
"highlights": {
"title": [
{
"start": 7,
"end": 12
}
],
"address": {
"label": [
{
"start": 7,
"end": 12
}
]
}
}
}
],
"queryTerms": [
]
}

How to format data to algolia

I'm learning How to use Algolia and I have a few questions.
I have the table FreightDriver, which has a relationship one to many with the table Truck
id: ID!
name: String!
email: String!
phoneNumber: String!
cities: [String!]!
state: String!
country: String!
picture: String
trucks: [Truck] #connection(keyName: "byFreightDriver", fields: ["id"])
Then, the table Truck, which has a relationship one to one with the table FreightDriver, and another table, which is Box one to one as well
id: ID!
freightDriverId: ID!
boxId: ID!
brand: String!
model: String!
yearModel: Int!
// and more fields
freightDriver: FreightDriver #connection(fields: ["freightDriverId"])
box: Box #connection(fields: ["boxId"])
and the table Box:
id: ID!
type: String!
width: Float!
height: Float!
depth: Float!
I want to find trucks based on the state and city of the FreightDrivers, and also (if the user needs it), find based on the type of box and brand or model of a truck (just as an example).
Example find by state and city of a FreightDriver:
{
"data": {
"freightDriversByState": {
"items": [
{
"name": "Andrés Montoya",
"cities": [
"GUADALAJARA"
],
"state": "JALISCO",
"country": "MX",
"trucks": {
"items": [
{
"brand": "chevrolet",
"model": "12",
"yearModel": 2020,
"box": {
"type": "Ganadera",
"width": 1,
"height": 2,
"depth": 3
}
},
{
"brand": "chevrolet",
"model": "12",
"yearModel": 2020,
"box": {
"type": "Seca (abierta)",
"width": 12,
"height": 12,
"depth": 12
}
},
{
"brand": "chevrolet",
"model": "12",
"yearModel": 2020,
"box": {
"type": "Seca (abierta)",
"width": 12,
"height": 12,
"depth": 12
}
},
{
"brand": "chevrolet",
"model": "Semi",
"yearModel": 2020,
"box": {
"type": "Seca (abierta)",
"width": 1,
"height": 2,
"depth": 3
}
},
{
"brand": "chevrolet",
"model": "12",
"yearModel": 2020,
"box": {
"type": "Seca (abierta)",
"width": 1,
"height": 2,
"depth": 3
}
},
{
"brand": "chevrolet",
"model": "12",
"yearModel": 2020,
"box": {
"type": "Volcadora",
"width": 1,
"height": 2,
"depth": 3
}
},
{
"brand": "hola",
"model": "12",
"yearModel": 12,
"box": {
"type": "Plataforma",
"width": 1,
"height": 2,
"depth": 3
}
},
{
"brand": "Ford",
"model": "12",
"yearModel": 2020,
"box": {
"type": "Seca (abierta)",
"width": 1,
"height": 2,
"depth": 1
}
},
{
"brand": "dasdas",
"model": "12",
"yearModel": 12231,
"box": {
"type": "Grúa",
"width": 1,
"height": 2,
"depth": 3
}
},
{
"brand": "Tesla",
"model": "Semi",
"yearModel": 2020,
"box": {
"type": "Seca (abierta)",
"width": 4,
"height": 4,
"depth": 2
}
}
]
}
},
{
"name": "Roberto mendez",
"cities": [
"GUADALAJARA"
],
"state": "JALISCO",
"country": "MX",
"trucks": {
"items": []
}
},
{
"name": "Fletes Jalisco Sa de Cv ",
"cities": [
"GUADALAJARA"
],
"state": "JALISCO",
"country": "MX",
"trucks": {
"items": [
{
"brand": "Ford",
"model": "F-450",
"yearModel": 2018,
"box": {
"type": "Seca (cerrada)",
"width": 2.7,
"height": 2.5,
"depth": 4.5
}
},
{
"brand": "Hiundai",
"model": "H100",
"yearModel": 2009,
"box": {
"type": "Seca (abierta)",
"width": 2.3,
"height": 2,
"depth": 4
}
},
{
"brand": "Hiundai",
"model": "H100",
"yearModel": 2020,
"box": {
"type": "Seca (abierta)",
"width": 2.35,
"height": 2,
"depth": 3
}
},
{
"brand": "Ford",
"model": "F-450",
"yearModel": 2018,
"box": {
"type": "Seca (cerrada)",
"width": 2.7,
"height": 2.2,
"depth": 3
}
},
{
"brand": "Ford",
"model": "F-450",
"yearModel": 2004,
"box": {
"type": "Seca (abierta)",
"width": 2.5,
"height": 2,
"depth": 3
}
}
]
}
},
{
"name": "Cotransport",
"cities": [
"GUADALAJARA"
],
"state": "JALISCO",
"country": "MX",
"trucks": {
"items": [
{
"brand": "Chevrolet",
"model": "CX-5",
"yearModel": 2019,
"box": {
"type": "Seca (cerrada)",
"width": 4,
"height": 3,
"depth": 4
}
}
]
}
},
{
"name": "Andrés",
"cities": [
"EL LIMÓN",
"MAGDALENA",
"SANTA MARÍA DEL ORO",
"GUADALAJARA",
"ETZATLÁN"
],
"state": "JALISCO",
"country": "MX",
"trucks": {
"items": [
{
"brand": "chevrolet",
"model": "12",
"yearModel": 2020,
"box": {
"type": "Seca (abierta)",
"width": 1,
"height": 2,
"depth": 3
}
}
]
}
}
]
}
}
}
But, if I want to find using the state and city of a freight driver, the type of box and the model or brand of a truck, that's where the problem comes, because I'm using Dynamodb and this one does not have relationships, so, it's a little bit tricky to get the exact data. That's why I'd like to use Algolia, but how do I format the data for Algolia in this case? What do I need to do? thanks!
If someone is interested, here's the answer https://discourse.algolia.com/t/how-to-format-data-to-algolia/10897

Routing API ignores closed roads

I'm testing the routing API and I'm wondering why it creates routes through closed roads.
There is my request: https://route.ls.hereapi.com/routing/7.2/calculateroute.json?waypoint0=geo!50.01568168937738,20.901489257812504&waypoint1=geo!50.0155162303763,20.879259109497074&apiKey=API-KEY-HERE&mode=balanced%3Bcar&alternatives=0
{
"response": {
"metaInfo": {
"timestamp": "2020-03-31T16:54:22Z",
"mapVersion": "8.30.107.151",
"moduleVersion": "7.2.202013-6746",
"interfaceVersion": "2.6.76",
"availableMapVersion": [
"8.30.107.151"
]
},
"route": [
{
"waypoint": [
{
"linkId": "-985497829",
"mappedPosition": {
"latitude": 50.0160635,
"longitude": 20.9021437
},
"originalPosition": {
"latitude": 50.0156817,
"longitude": 20.9014893
},
"type": "stopOver",
"spot": 1,
"sideOfStreet": "right",
"mappedRoadName": "ulica Wędkarska",
"label": "ulica Wędkarska",
"shapeIndex": 0,
"source": "user"
},
{
"linkId": "-1052271133",
"mappedPosition": {
"latitude": 50.0154679,
"longitude": 20.8792651
},
"originalPosition": {
"latitude": 50.0155162,
"longitude": 20.8792591
},
"type": "stopOver",
"spot": 0.6372549,
"sideOfStreet": "right",
"mappedRoadName": "Ostrów",
"label": "Ostrów",
"shapeIndex": 29,
"source": "user"
}
],
"mode": {
"type": "balanced",
"transportModes": [
"car"
],
"trafficMode": "disabled",
"feature": []
},
"leg": [
{
"start": {
"linkId": "-985497829",
"mappedPosition": {
"latitude": 50.0160635,
"longitude": 20.9021437
},
"originalPosition": {
"latitude": 50.0156817,
"longitude": 20.9014893
},
"type": "stopOver",
"spot": 1,
"sideOfStreet": "right",
"mappedRoadName": "ulica Wędkarska",
"label": "ulica Wędkarska",
"shapeIndex": 0,
"source": "user"
},
"end": {
"linkId": "-1052271133",
"mappedPosition": {
"latitude": 50.0154679,
"longitude": 20.8792651
},
"originalPosition": {
"latitude": 50.0155162,
"longitude": 20.8792591
},
"type": "stopOver",
"spot": 0.6372549,
"sideOfStreet": "right",
"mappedRoadName": "Ostrów",
"label": "Ostrów",
"shapeIndex": 29,
"source": "user"
},
"length": 2383,
"travelTime": 312,
"maneuver": [
{
"position": {
"latitude": 50.0160635,
"longitude": 20.9021437
},
"instruction": "Head <span class=\"heading\">east</span> on <span class=\"street\">ulica Wędkarska</span>. <span class=\"distance-description\">Go for <span class=\"length\">153 m</span>.</span>",
"travelTime": 24,
"length": 153,
"id": "M1",
"_type": "PrivateTransportManeuverType"
},
{
"position": {
"latitude": 50.0159132,
"longitude": 20.9040749
},
"instruction": "Turn <span class=\"direction\">right</span> onto <span class=\"next-street\">ulica Wędkarska</span>. <span class=\"distance-description\">Go for <span class=\"length\">108 m</span>.</span>",
"travelTime": 18,
"length": 108,
"id": "M2",
"_type": "PrivateTransportManeuverType"
},
{
"position": {
"latitude": 50.0150228,
"longitude": 20.904547
},
"instruction": "Turn <span class=\"direction\">right</span> onto <span class=\"next-street\">ulica Dunajcowa</span>. <span class=\"distance-description\">Go for <span class=\"length\">374 m</span>.</span>",
"travelTime": 55,
"length": 374,
"id": "M3",
"_type": "PrivateTransportManeuverType"
},
{
"position": {
"latitude": 50.0127375,
"longitude": 20.9007919
},
"instruction": "Turn <span class=\"direction\">slightly right</span> onto <span class=\"next-street\">ulica Do Promu</span>. <span class=\"distance-description\">Go for <span class=\"length\">75 m</span>.</span>",
"travelTime": 18,
"length": 75,
"id": "M4",
"_type": "PrivateTransportManeuverType"
},
{
"position": {
"latitude": 50.0126946,
"longitude": 20.8997512
},
"instruction": "Turn <span class=\"direction\">left</span> onto <span class=\"next-street\">ulica Do Promu</span>. <span class=\"distance-description\">Go for <span class=\"length\">249 m</span>.</span>",
"travelTime": 41,
"length": 249,
"id": "M5",
"_type": "PrivateTransportManeuverType"
},
{
"position": {
"latitude": 50.0111175,
"longitude": 20.897305
},
"instruction": "Turn <span class=\"direction\">right</span> onto <span class=\"next-street\">ulica Wincentego Witosa</span>. <span class=\"distance-description\">Go for <span class=\"length\">717 m</span>.</span>",
"travelTime": 92,
"length": 717,
"id": "M6",
"_type": "PrivateTransportManeuverType"
},
{
"position": {
"latitude": 50.0145936,
"longitude": 20.8889151
},
"instruction": "Continue on <span class=\"next-street\">Ostrów</span>. <span class=\"distance-description\">Go for <span class=\"length\">707 m</span>.</span>",
"travelTime": 64,
"length": 707,
"id": "M7",
"_type": "PrivateTransportManeuverType"
},
{
"position": {
"latitude": 50.0154679,
"longitude": 20.8792651
},
"instruction": "Arrive at <span class=\"street\">Ostrów</span>. Your destination is on the right.",
"travelTime": 0,
"length": 0,
"id": "M8",
"_type": "PrivateTransportManeuverType"
}
]
}
],
"summary": {
"distance": 2383,
"trafficTime": 312,
"baseTime": 312,
"flags": [
"builtUpArea"
],
"text": "The trip takes <span class=\"length\">2.4 km</span> and <span class=\"time\">5 mins</span>.",
"travelTime": 312,
"_type": "RouteSummaryType"
}
}
],
"language": "en-us"
}
}
The proposed route looks like that:
route through the closed bride.
The road closure info is available in the map. I've checked that in the Map Creator. Here WeGo map also knows about this and suggest an alternative route:
the valid route from Here WeGo.
Is there something wrong with my request?
Please try using following combinations for mode in your rest call. The Routing API v7 supports the following valid parameter combinations for routing modes.
Traffic-enabled:
mode=fastest;car;traffic:enabled
Traffic not enabled:
mode=fastest;car;traffic:disabled
mode=shortest;car
Also refer : https://developer.here.com/documentation/routing/dev_guide/topics/routing-mode-parameter-combinations.html
Please connect even if this doesn't result to what you are expecting the output to be

Highchart Pie Chart not working properly with series

Sample Code
JsFiddle Example for below code.
Highcharts.chart('container', {
chart: {
plotBackgroundColor: null,
plotBorderWidth: null,
plotShadow: false,
type: 'pie'
},
title: {
text: 'Browser market shares in January, 2018'
},
tooltip: {
pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>'
},
plotOptions: {
pie: {
allowPointSelect: true,
cursor: 'pointer',
dataLabels: {
enabled: true,
format: '<b>{point.name}</b>: {point.percentage:.1f} %'
}
}
},
series: [{
name: 'Brands',
colorByPoint: true,
data: [
{
"name": "Display",
"y": 0.1,
"value": 5
},
{
"name": "Paid Social",
"y": 0,
"value": 0,
sliced: true,
selected: true
},
{
"name": "Direct",
"y": 14.5,
"value": 559
},
{
"name": "Referral",
"y": 2,
"value": 77
},
{
"name": "Email",
"y": 4,
"value": 152
},
{
"name": "Other",
"y": 0,
"value": 1
},
{
"name": "Organic Search",
"y": 23.4,
"value": 901
},
{
"name": "Meta Search",
"y": 0.2,
"value": 5
},
{
"name": "Organic Social",
"y": 2.4,
"value": 93
},
{
"name": "Directory",
"y": 0.2,
"value": 9
},
{
"name": "Other Advertising",
"y": 0.1,
"value": 3
},
{
"name": "OTA Referral Traffic",
"y": 0.7,
"value": 26
},
{
"name": "Paid Search",
"y": 27.8,
"value": 1068
},
{
"name": "Local",
"y": 24.5,
"value": 941
}]
}]
});
Scenario
I want to display dataLabels for all even y value is zero.
In Above code We have "name": "Display" y=0.1 but still it is not displaying in Pie Chart don't know why. If any one have idea about this problem please let me know.
The dataLabels are hidden due to lack of space and overlapping. As a solution you can set: padding: 0
plotOptions: {
pie: {
...,
dataLabels: {
padding: 0,
...
}
}
}
Live demo: https://jsfiddle.net/BlackLabel/g5s27tyb/
API Reference: https://api.highcharts.com/highcharts/plotOptions.pie.dataLabels.padding

Resources