# CalculateRouteByBearerToken
Calculates the distance for a given route
__Activity name :__ GetCalculateRouteByBearerToken
Calculates the dinstance (in KM) between the given GEO coördinates. Its possible to provide multiple stops for the calculation.
This is a read-only table function. The Loket.nl REST API may not support changing the data, or the Invantive UniversalSQL driver for Loket.nl REST does not support it. In the latter case, use the table NativePlatformScalarRequests to upload data to the Loket.nl REST API.
- Catalog: `LoketNlRest`
- Schema: `LocationService`
## Parameters of Table Function
| Name | Data Type | Required | Default Value | Documentation |
|---|:---:|:---:|:---:|---|
| `query` | `string` | ☑ | | The route as defined by the geo-coördinates. Use the following formatting -> latitude,longitude;latitude,longitude;latitude,longitude etc Atleast 2 sets of geo-coördinates have to be provided in order for a route to be calculated Please note: latitude must be a value between -90 and 90 where as longitude must be a value between -180 and 180 |
| `routeType` | `string` | ☑ | | The method of how the route is calculated. This can influence the distance to travel. Integers can be used instead of the strings 1 --> fastest / snelste 2 --> shortest / kortste (Waarden: fastest, shortest) |
## Columns
The columns of the table `CalculateRouteByBearerToken` are shown below. Each column has an SQL data type.
| Name | Data Type | Label | Required | Documentation |
|---|:---:|---|:---:|---|
| `lengthInKilometers` | `double` | | ☐ | Total length of the route |
| `routeType` | `string` | | ☐ | The method used to calculate the route |