Routes and movement

Calculate directions, travel times, matrices, reachable areas, and other network-aware geographic relationships.

Documentation navigation

How Routes work

Routes turn geographic locations into network-aware movement data. Use a route for directions and geometry, a matrix for many-to-many travel times, or an isochrone to understand what is reachable from a place.

Choose an interface

routing.ts
const route = await e2.route.route({ locations: [{ lat: 40.74, lon: -73.99 }, { lat: 40.71, lon: -74.01 }], mode: "walking" });

JavaScript SDK

routing.ts
import { EDK } from "@edk/sdk";

const e2 = new EDK();
const route = await e2.route.route({
  locations: [
    { lat: 40.74, lon: -73.99 },
    { lat: 40.71, lon: -74.01 },
  ],
  mode: "walking",
});

CLI

terminal
e2 route run --locations "40.74,-73.99;40.71,-74.01" --mode walking
e2 route matrix --sources "40.74,-73.99" --targets "40.71,-74.01"
e2 route isochrone --locations "40.74,-73.99" --contours 5,10,15

MCP and API

e2_route.json
{
  "operation": "route",
  "body": {
    "locations": [{ "lat": 40.74, "lon": -73.99 }, { "lat": 40.71, "lon": -74.01 }],
    "mode": "walking"
  }
}

MCP clients call e2_route. The same route body is used by managed routing integrations, where your server supplies the EDK API key.

Operations

OperationUse
routeTurn-by-turn route between locations.
matrixTravel times between source and target locations.
isochroneReachable areas for time or distance contours.
mapMatchMatch a shape to the road network.
locateLocate coordinates on the network.
heightRequest elevation data.