route— distance and travel duration between two locations, driving or motorcyclegeocode— convert a place name or address into coordinates, ready to feed intoroute
Installation
One-line installer (macOS / Linux)
/usr/local/bin (or ~/.local/bin). No Go required. Pin a specific version:
From source (Go users)
justrouting-mcp is on your PATH. Prebuilt binaries for macOS, Linux, and Windows are also attached to every release.
Configuration
The server reads the JustRouting API key from theJUSTROUTING_API_KEY environment variable:
Tools
route
Calculate a route between two locations — driving by default, or motorcycle when requested.profile is optional: set it to "motorcycle" for a motorcycle route, or omit it (or use "car") for the default driving route. When the user mentions a motorcycle or motorbike, the assistant sets profile to "motorcycle".
Coordinates use longitude,latitude order. If the user asks about places by name or address instead of coordinates, call geocode first and pass its coordinates values here.
distance_meters— driving distance in metersduration_seconds— estimated travel time in seconds
geocode
Search for places and convert a place name or address into coordinates. Use this beforeroute when the user refers to places by name.
The search is structured: the assistant parses the user’s place reference into address components and passes only the ones it can determine — name, housenumber, street, postcode, city, country. Prefer including country (and city) when the context implies them — they are the strongest disambiguators for common, abbreviated, or misspelled names.
limit is optional and defaults to 1 (best match only); it must not exceed 10. filters is also optional, for example "filters": ["countrycode:sg"] to restrict results to Singapore.
coordinates field is ready to pass to route. If nothing matches, the tool returns an error.
Asking about places by name
For a prompt such as “how long from ‘marina bay singapore’ driving to ‘changqi airport’?”, the assistant geocodes each place and then routes:geocodewith"name": "marina bay", "country": "singapore"→ takecoordinatesgeocodewith"name": "changqi airport"→ takecoordinatesroutewith the twocoordinatesvalues asoriginanddestination(omitprofilefor driving)
Claude
Claude Code (CLI):claude_desktop_config.json:
