Create route corridor from planned route

Hi,

We are trying to plan a route (let’s say from London to Amsterdam) and use the routepoints for creating a Route Corridor using the Geofence API. The corridor is created to notify our platform when a driver is deviating from the original route.

We noticed the amount of route points will cause a 403:
“detailedError”: {
“code”: “Forbidden”,
“message”: “The request contained valid data and was understood by the server, but the server is refusing action”
}

Is there a limit on route points we can use to create the route corridor, or is there another way we achieve our goals.

How many coordinates this corridor has?

When planning a route from London to Amsterdam you get around 38.000 route points back

The documentation mentions limits for the service.

1k vertices per polygon fence

This could be understood that corridor can have no more than 1k coordinates.

In your case I’d try to split this fence in smaller ones or simplify it with turfjs or similar.

Hey Przemek,

Thanks for your answer, if I understand correctly there is not a direct relationship between TomTom RouteAPIs and Corridor Geofences?

This means that for long distance routing (like for trucks) the user of the endpoint is self responsible to create from the provided route points a corridor with a maximum of 1000 coordinates?

I cannot imagen that we are the first to run into this scenario, especially when this is not a special use-case for truck navigation and fleetmangement.

Yes, that is correct.
Those services are not connected, but the user can create fence based on data retrieved from Routing API or Search API.