Ive manage to know the error:
In page received I ve added:
SETCLIPBOARD(self.ThisPage.GetValue())
message(self.ThisPage.GetValue())
self._ThrowError()
The result is:
{"results":null,"errors":["
One of parameters destination../start/end has no value assigned.
Missing equality sign? Error ID: 8f60aa0f-77c6-450f-ae17-45bc0c5e64d5"],"processingTimeDesc":null,"responseCode":"400","warnings":null,"requestId":null}
This is another example of the error description from Here:
{"results":null,"errors":["
All given waypoints have got the same coordinate. No Sequence can be calculated. Error ID: e3a39a8d-fd9d-4e66-b1d6-f496803f6166"],"processingTimeDesc":null,"responseCode":"400","warnings":null,"requestId":null}
>>>May be its a good idea to add this error description to the ThrowError message.<<<
Besides, to see what NT were sending to the API Ive added:
SETCLIPBOARD( clip(baseURL) & '/' & nhm:OptimizeRoutePath & '/' & clip(resource) & |
self.auth() & |
clip(self.CommandQueue.Waypoints) & |
'&mode=' & clip(self.CommandQueue.Mode) & |
clip(when.GetValue()) & |
'&improveFor=time' & |
'&' & clip(self.CommandQueue.URLParameters) |
)
Before: self.get( clip(baseURL) & '/' & nhm:OptimizeRoutePath & '/' & clip(resource) & |...............
The result is:
https://wse.ls.hereapi.com/2/findsequence.json?apiKey=Uru1aFINkHfp1r1Kx7jOETRWHMnfkHYqGSObPDTydms&start=SALIDA;-34.3679147,-58.7279087
&destination0=4476;-34.7913751,-58.3623777
&destination1=4477;-34.5336463,-58.4840534
........
&destination21=4499;-34.5142077,-58.5455855
&destination22=4500;-34.6502738,-58.8102467
&destination23
&mode=fastest;car;traffic:default&departure=now&improveFor=time&
As you can see the waypoint list is incomplete.
Looking at NetMaps.inc:
NetMapCommandQueueType Queue,type
Counter Long
........
Waypoints String(1024) ! getroute
........
End
1024 is too short, Here suports 120 without! traffic and 50 with traffic.
the lenght of
&destination120=4476;-34.7913751,-58.3623777
is 44
then the minimum of Waypoint must be 44*120=5280
plus the problem of the starts and end which is ofthe form:
&start=SALIDA;-34.3679147,-58.7279087
and SALIDA is the ID of the start point which can be as long as 255 (as for the NetMapWaypointsQueueType ID declaration)
Then Waypoints field must be something like 6144 (1024*6)Ive modified the NetMaps.inc with whis value and all works ok.