Symptom
A route calculation using xRoute returns a 400 response with the following error:
{
"faultInfo": {
"$type": "RouteNotFoundFault",
"hint": "Make sure that the waypoint in question is connected with the next waypoint by segments valid for the given vehicle.",
"waypointIndex": 0
},
"message": "No route found for the given vehicle."
}
The issue occurs when using a custom truck profile compared to a standard PTV truck profile.
Example:
- Working profile:
truck11_99t - Failing profile:
truck11_99t_noIM_del
The waypoints are defined as OffRoadWaypoint.
Cause
First, compare the working and failing routing profiles carefully.
This behavior is expected and is caused by the routing constraints defined in the custom routing profile.
The main difference is that the failing profile explicitly enables:
<themes id="PTV_TruckAttributes" enabled="true" />
This activates truck-specific access restrictions from the map data.
Additionally, the profile contains:
<violations enabled="false"/>
This means:
- truck restriction violations are strictly forbidden,
- only roads fully compliant with truck restrictions may be used.
Why the route calculation fails
When using OffRoadWaypoint, xRoute must first connect the coordinates to nearby routable road segments.
With PTV_TruckAttributes enabled:
- the routing engine validates truck accessibility,
- nearby roads may become invalid for the configured vehicle,
- and if no compliant connection exists, route calculation fails.
This results in: RouteNotFoundFault
The standard profile truck11_99t does not enable PTV_TruckAttributes, therefore fewer restrictions apply and the route can be calculated successfully.
Resolution
Option 1 — Temporarily allow violations for testing
Modify the routing profile: <violations enabled="true"/>
This helps confirm that the issue is caused by truck access restrictions.
Option 2 — Verify waypoint placement
Check whether the OffRoadWaypoint coordinates are located close to roads accessible for trucks.
Truck-restricted areas may include:
- delivery-only streets,
- weight restrictions,
- low bridges,
- restricted urban access zones.
Option 3 — Relax routing restrictions
If strict truck compliance is not required:
- disable some truck restrictions,
- or use a less restrictive routing profile.
Option 4 — Use standard routable waypoints
If possible, use regular road-connected waypoints instead of OffRoadWaypoint to avoid snapping and accessibility issues.
Additions hints
PTV_TruckAttributessignificantly increases routing strictness.OffRoadWaypointmay fail if no valid truck-accessible road exists nearby.- Compare both routing profiles line by line to identify additional restrictions.
- This issue is especially common in:
- city centers,
- industrial zones,
- delivery-restricted areas.