I use the API with the calculateRoute endpoint, and
I exclude ferries (AVOID_FERRIES to 2501) and to test that it works well, I use a route from Athens to Crete which only includes a ferry route. So I get a 500 with payload:
Code: Select all
{
"errorMessage": "cannot calculate route (concerning leg 1)",
"errorKey": "2500",
"exceptionType": "com.ptvag.xserver.xroute.XRouteException"
}
Here the payload I send in the request:
Code: Select all
{
"details": {
"polygon": true
},
"callerContext": {
"properties": [
{
"key": "CoordFormat",
"value": "OG_GEODECIMAL"
},
{
"key": "Profile",
"value": "truckfast"
}
]
},
"options": [
{
"parameter": "EXCLUDE_COUNTRIES",
"value": "CH"
},
{
"parameter": "AVOID_FERRIES",
"value": "2501"
}
],
"waypoints": [
{
"coords": [
{
"point": {
"x": 25.3702,
"y": 35.307293
}
}
],
"linkType": "AUTO_LINKING"
},
{
"coords": [
{
"point": {
"x": 23.729842,
"y": 37.985466
}
}
],
"linkType": "AUTO_LINKING"
}
]
}