places

Places & Maps

Directions & Routing

Directions & Routing is a places & maps capability available through Mapbox, Google Maps, HERE on Aweb. Calculate optimal routes between locations with turn-by-turn navigation. Access it through a single unified API with automatic failover and intelligent routing.

Try Directions & RoutingAPI docs

Best for

Highest quality

Mapbox, Google Maps

Premium tier

Contract

Max Latency3000ms

Providers (3)

ProviderScoreQualityPricing
MapboxDEFAULT
92premiumstandard
Google Maps
97premiumstandard
HERE
92premiumstandard

Quick start

Call Directions & Routing through Alfred — automatic provider selection, failover, and load balancing included.

cURL

curl -X POST https://api.alfred-ai.app/v1/execute \
  -H "Authorization: Bearer $ALFRED_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "capability": "places.directions",
    "input": { "prompt": "Hello world" }
  }'

TypeScript

import { Alfred } from '@alfred/core';

const alfred = new Alfred({ apiKey: process.env.ALFRED_API_KEY });

// Alfred automatically selects the best provider
const result = await alfred.execute({
  capability: 'places.directions',
  input: { prompt: 'Hello world' },
});

console.log(result.output);

Orchestration pipeline

import { Alfred } from '@alfred/core';

const alfred = new Alfred({ apiKey: process.env.ALFRED_API_KEY });

// Multi-step pipeline with automatic failover
const result = await alfred.orchestrate({
  steps: [
    { id: 'step1', capability: 'places.directions', input: { prompt: 'Hello world' } },
    { id: 'step2', capability: 'llm.chat', dependsOn: ['step1'],
      input: { prompt: 'Summarize: $step1.output' } },
  ],
});

Related Places & Maps capabilities

Geocoding

places

Isochrone Analysis

places

Places Search

places

Distance Matrix

places

Geofencing

places

Address Validation

places

Getting started →API reference →All providers →All capabilities →