Overview
Get complete details about a specific route by ID. The route must belong to the authenticated user.
Authentication
Required : This endpoint requires Auth0 authentication. Include a valid JWT token in the Authorization header.
Only routes belonging to the authenticated user can be accessed.
Path Parameters
The unique identifier of the route
Response
Returns a single route object with complete details:
ISO 8601 datetime when the ride started
IANA timezone identifier where the ride took place (e.g., “America/Los_Angeles”)
Encoded polyline representation of the route path (Google Encoded Polyline, precision 5)
Name of the destination (if applicable)
Address of the destination (if applicable)
Distance traveled in meters
Duration of the ride in seconds
Whether the ride was completed
Complete event information if the route was associated with an event Auth0 user ID of event creator
Event destination details
Array of weather condition strings (e.g., [“Clear”, “Cold”])
Temperature in Fahrenheit at the time/location of the ride
ISO 8601 datetime when weather data was retrieved
Human-readable weather description (e.g., “Sunny, Windy (69°F)”)
Array of route images with image_url and created_at
Optional welcome or completion message for the route
Request Example
curl "https://api.cyclemate.com/user/routes/1234/" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_JWT_TOKEN"
const routeId = 1234 ;
const response = await fetch (
`https://api.cyclemate.com/user/routes/ ${ routeId } /` ,
{
method: 'GET' ,
headers: {
'Content-Type' : 'application/json' ,
'Authorization' : `Bearer ${ yourJwtToken } ` ,
},
}
);
const route = await response . json ();
console . log ( `Route distance: ${ route . distance_traveled } m` );
import requests
route_id = 1234
url = f "https://api.cyclemate.com/user/routes/ { route_id } /"
headers = {
"Content-Type" : "application/json" ,
"Authorization" : f "Bearer { your_jwt_token } "
}
response = requests.get(url, headers = headers)
route = response.json()
Response Example
{
"id" : 1234 ,
"date_started" : "2025-11-13T14:30:00Z" ,
"local_timezone" : "America/New_York" ,
"polyline" : "encoded_polyline_string_here" ,
"destination_name" : "Central Park" ,
"destination_address" : "Central Park, New York, NY" ,
"distance_traveled" : 5280.5 ,
"duration_traveled" : 1267 ,
"completed" : true ,
"event" : {
"id" : 123 ,
"name" : "Central Park Morning Ride" ,
"alias" : "central-park-morning-ride" ,
"description" : "Casual group ride through Central Park" ,
"emoji" : "🚴" ,
"image_url" : "https://storage.googleapis.com/events/123.jpg" ,
"start_time" : "2025-11-13T08:00:00Z" ,
"end_time" : "2025-11-13T10:00:00Z" ,
"created_by" : "google-oauth2|115315991711634062214" ,
"created_at" : "2025-11-01T10:00:00Z" ,
"updated_at" : "2025-11-01T10:00:00Z" ,
"is_active" : true ,
"is_happening_now" : false ,
"is_future" : false ,
"is_current_or_future" : false ,
"is_leisure_route" : false ,
"visits_total" : 42 ,
"destination" : {
"id" : 45 ,
"name" : "Central Park" ,
"latitude" : 40.785091 ,
"longitude" : -73.968285 ,
"area_name" : "Manhattan" ,
"city" : "New York City" ,
"categories" : [
{
"id" : 1 ,
"name" : "Park" ,
"emoji" : "🌳"
}
]
},
"route" : {
"distance" : 6437 ,
"duration" : 1543 ,
"polyline" : "event_polyline_string_here"
},
"categories" : [
{
"id" : 2 ,
"name" : "Group Ride" ,
"emoji" : "👥"
}
],
"images" : [
{
"image_url" : "https://storage.googleapis.com/event-photos/1.jpg" ,
"created_at" : "2025-11-01T10:00:00Z"
}
]
},
"weather_conditions" : [ "Clear" , "Mild" ],
"temperature" : 68.5 ,
"wind_speed" : 5.2 ,
"weather_fetched_at" : "2025-11-13T14:30:00Z" ,
"weather_display" : "Clear, Mild (69°F)" ,
"images" : [
{
"image_url" : "https://storage.googleapis.com/route-photos/1234-1.jpg" ,
"created_at" : "2025-11-13T14:45:00Z"
},
{
"image_url" : "https://storage.googleapis.com/route-photos/1234-2.jpg" ,
"created_at" : "2025-11-13T15:00:00Z"
}
],
"welcome_message" : "Great ride! You completed the Central Park Morning Ride event."
}
Error Responses
Route Not Found (404)
When the route doesn’t exist or doesn’t belong to the authenticated user:
{
"error" : "Route not found"
}
User Not Found (404)
When the authenticated user doesn’t exist in the database:
{
"error" : "User not found"
}
Unauthorized (401)
{
"error" : "Authentication credentials were not provided."
}
Notes
Only routes belonging to the authenticated user can be accessed
Attempting to access another user’s route will return a 404 error
The event field includes complete event details with destination, categories, and images
Weather data is captured at the time the route is created
Images show photos uploaded during or after the ride
The completed field indicates whether the user finished the ride
Distance is in meters, duration is in seconds
Temperature is in Fahrenheit, wind speed is in mph
The polyline can be decoded and displayed on a map for route replay
Use Cases
Route Replay : Visualize the exact path taken on a map
Activity Details : Show comprehensive ride statistics and conditions
Sharing : Generate shareable ride summaries
Analytics : Analyze individual ride performance
Event Verification : Confirm participation in specific events
Photo Gallery : Display photos from the ride