Import and export
Take an itinerary out as a route file, and bring route files in as new itineraries. This page exports an itinerary as GPX, then imports that file back.
Mint a session token that names a member, as in the quickstart:
The examples export $ITINERARY_ID, a published itinerary of yours.
GET /v1/itineraries/{itinerary_id}/export answers the file itself. With the publishable key alone, it exports the published version.
Add segment_id to export one segment.
Import takes two calls. POST /v1/itineraries/preview reads the file and proposes segments without saving anything. POST /v1/itineraries/import saves the draft you send back.
Review the preview before you confirm: rename the itinerary, and pick each segment's mode.
To let a visitor download the file from your page without a key, ask the Data API's exportItinerary for a signed URL. The URL works for ten minutes, with no credential.