Get started

Itineraries

Itinerary

The itinerary query of the Data API. Every request is a POST to https://data.mountaya.com/graphql with a publishable key and a session token: see Authentication.

itinerary

POST
/graphql

Read a single itinerary by identifier, with its ordered segments and waypoints.

Arguments

input

ItineraryInput!

required

The itinerary to read.

Returns

itinerary

ItineraryResult!

required

A single itinerary with its segments and waypoints.

Errors A field the API refuses is answered 200, its entry in errors beside the data that resolved. See Errors.

curl https://data.mountaya.com/graphql \
  -H "X-API-Key: pk_your_publishable_key" \
  -H "X-Session-Token: sess_your_session_token" \
  -H "Content-Type: application/json" \
  -d '{
    "query": "query Itinerary($input: ItineraryInput!) { itinerary(input: $input) { ascent distance name segments { distance name } } }",
    "variables": {"input": {"id": "0b6d1a4e-6d3f-4f7a-9c2e-1f0a5b8c3d21"}}
  }'