# Miles > Miles turns a trip (flights, trains, cars, buses, ferries) into an animated map video. Agents can create a trip from a user's bookings and hand back a link. Nothing is stored: the trip lives in the link. ## Create a trip with a link (no API call needed) https://www.createmiles.com/create?r=STOPS&m=MODES&d=DATES&n=TITLE - r: stops in travel order, comma-separated. Airport codes for flights (DEL), city names otherwise (Agra, "London, GB" to pin a country). - m: one mode per leg, comma-separated: flight, train, car, bus, ferry (taxi/uber = car). Omit if all flights. - d: one YYYY-MM-DD per leg, comma-separated (optional). - n: trip title, URL-encoded (optional). Example: https://www.createmiles.com/create?r=BOM,DEL,Agra,Jaipur&m=flight,train,car&d=2026-11-02,2026-11-04,2026-11-06&n=Golden%20triangle Use /t instead of /create for a watch-only page with the same parameters. ## Create a trip with the API POST https://www.createmiles.com/api/trips Content-Type: application/json {"title":"Golden triangle","legs":[{"from":"BOM","to":"DEL","mode":"flight","date":"2026-11-02"},{"from":"DEL","to":"Agra","mode":"train"}]} Returns editUrl (open to edit and export), shareUrl (watch-only), previewImage, a summary of the resolved legs, and any stops that could not be matched (unresolved). OpenAPI description: https://www.createmiles.com/openapi.json ## Get the video file (MP4) POST https://www.createmiles.com/api/videos with the same trip JSON (or {"query": ""}). Returns id, status, videoUrl and statusUrl. Rendering takes a few minutes: poll statusUrl until status is "done", then send the user videoUrl (a 720p H.264 MP4 that plays in iMessage and WhatsApp). The same trip is only rendered once; repeat requests return the cached video. ## Connect over MCP MCP server (Streamable HTTP, stateless, no auth): https://www.createmiles.com/mcp Tools: render_video (legs → an MP4 videoUrl; waits up to ~55 s), create_trip (legs in travel order → shareUrl, editUrl, previewImage, unresolved), find_place (check how a stop will match), list_looks. ## Guidance - Only include travel the user actually took. Put stops in the order travelled. - Taxi or Uber rides under ~30 km add little to a map; leave them out. - Up to 20 legs per trip (5 on the free plan). ## Docs - [For agents](https://www.createmiles.com/agents) - [Privacy](https://www.createmiles.com/privacy)