Modemix API

Step-by-step directions that combine biking, bikeshare or walking with public transit, from the same routing as the Modemix app.

Example

The request for the bike + transit route above:

curl -X POST https://api.modemix.io/v1/directions \
  -H "x-api-key: mmx_your_key_here" \
  -H "Content-Type: application/json" \
  -d '{
    "origin": { "latitude": 37.7502, "longitude": -122.4337 },
    "destination": { "latitude": 37.8115, "longitude": -122.2475 },
    "depart_at": 1796142600,
    "mode": "bike",
    "bike_speed_mps": 6.7,
    "exclude_transit": ["bus"]
  }'

Its response, shortened to that route:

{
  "region": "bay_area",
  "routes": [
    {
      "duration_seconds": 2584,
      "legs": [
        { "type": "bike", "to": { "name": "24th St/Mission" }, ... },
        { "type": "transit", "line": { "name": "Red-N", "agency": "BART" }, ... },
        { "type": "bike", "to": { "name": null }, ... }
      ]
    },
    ...
  ]
}

Coverage

742 cities and regions in the United States and Canada. See them all

Pricing

Per request, billed monthly. No monthly fee. Requests that return an error are free.

Monthly volumePer 1,000
0 – 100,000$5.00
100,001 – 500,000$4.00
500,001 – 1,000,000$3.00
1,000,001 – 5,000,000$1.50
5,000,001+$0.40

Create an account, set up billing, and make keys in the API console. You pay only for the requests you make.

Get an API key