TrainerDay API

Build integrations with TrainerDay. Access workouts, calendars, activities, and athlete data.

Get Your API Key Explore the API

Personal API Keys

Generate a key instantly to access your own data. No OAuth setup needed for personal use.

📅

Calendar Management

Full CRUD on your training calendar. Create, update, and delete workouts and notes.

🔗

OAuth 2.0 for Apps

For established organizations building training apps or products that need access to user data.

API Endpoints

Method Endpoint Description Scope
GET /api/v1/athlete Your profile, FTP, zones athlete:read
GET /api/v1/calendar Calendar workouts (startDate, endDate) calendar:read
POST /api/v1/calendar/events Create calendar event calendar:write
PUT /api/v1/calendar/events/:id Update calendar event calendar:write
DELETE /api/v1/calendar/events/:id Delete calendar event calendar:write
GET /api/v1/activities Completed activities activities:read
POST /api/v1/activities/upload Upload activity file (TCX/GPX/FIT) activities:write

Quick Start

# 1. Get your API key at /developer

# 2. Fetch your athlete profile
curl -H "Authorization: Bearer td_your_api_key" \
  https://api.trainerday.com/api/v1/athlete

# 3. Read your calendar
curl -H "Authorization: Bearer td_your_api_key" \
  "https://api.trainerday.com/api/v1/calendar?startDate=2026-01-01&endDate=2026-01-31"

# 4. Add a workout to your calendar
curl -X POST -H "Authorization: Bearer td_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{"calendarDate":"2026-01-15","embedWorkout":{"title":"Easy Spin","durationMinutes":30,"segments":[[10,50,50],[10,60,60],[10,45,45]]}}' \
  https://api.trainerday.com/api/v1/calendar/events

OAuth 2.0 for Third-Party Apps

For organizations

Do you have a training app or platform that's already live? We offer OAuth 2.0 integration so your users can connect their TrainerDay accounts. Contact us to get started.

Register Your Application

Contact us at trainerday.com/contact-us to apply for access to receive a client_id and client_secret.

Redirect User to Authorize

GET https://api.trainerday.com/oauth/authorize?
  client_id=YOUR_CLIENT_ID&
  response_type=code&
  redirect_uri=https://yourapp.com/callback&
  scope=athlete:read calendar:read

Exchange Code for Tokens

POST https://api.trainerday.com/oauth/token
Content-Type: application/x-www-form-urlencoded

grant_type=authorization_code&
code=AUTH_CODE&
redirect_uri=https://yourapp.com/callback&
client_id=YOUR_CLIENT_ID&
client_secret=YOUR_CLIENT_SECRET

Make API Requests

curl -H "Authorization: Bearer ACCESS_TOKEN" \
  https://api.trainerday.com/api/v1/athlete

Access tokens expire after 6 hours. Use the refresh token to get a new one via grant_type=refresh_token.

Available Scopes

athlete:read View profile
athlete:write Edit profile
workout:read View workouts
workout:write Create workouts
calendar:read View calendar
calendar:write Modify calendar
activities:read View activities
activities:write Upload activities

Additional OAuth Endpoints

POST /oauth/token Exchange code or refresh token
POST /oauth/token/revoke Revoke a token
POST /oauth/token/introspection Validate a token