Base URL
The server runs on
localhost:8080 by default. Configure with PORT and HOST environment variables.Endpoint Categories
Course Data
Courses
Get complete course catalog with all details
Bootstrap
Get lightweight course summaries for fast initial load
Course Detail
Get detailed information for a specific course
Cache Meta
Get cache metadata and statistics
Progress Tracking
Get Progress
Retrieve saved user progress
Save Progress
Persist user progress data
File Streaming
Drive Proxy
Stream files from Google Drive with range request support
Compatible Video
Stream browser-compatible video using ffmpeg transcoding
System
| Method | Endpoint | Description |
|---|---|---|
GET | /api/health | Health check with Drive and ffmpeg status |
GET | /api/refresh | Reload courses cache (localhost only) |
GET | /api/self-check-drive | Validate cache contains only Drive IDs |
POST | /api/open-external | Open video in external player (VLC) |
Complete Endpoint List
Course Endpoints
Progress Endpoints
File Streaming Endpoints
System Endpoints
Authentication
CORS Policy
The server implements strict CORS policies:- Only accepts requests from loopback origins (
localhost,127.0.0.1,::1) - Supports
GET,POST, andOPTIONSmethods - Returns appropriate
Access-Control-Allow-Originheaders for valid origins
Response Format
All API endpoints return JSON with UTF-8 encoding:- Client sends
Accept-Encoding: gzip - Response payload is ≥1KB
Error Responses
Standard HTTP status codes are used:| Code | Meaning |
|---|---|
200 | Success |
206 | Partial content (range requests) |
400 | Bad request (invalid parameters) |
403 | Forbidden (non-localhost access) |
404 | Resource not found |
413 | Payload too large |
416 | Range not satisfiable |
502 | Bad gateway (Drive/ffmpeg errors) |
503 | Service unavailable (Drive/ffmpeg not configured) |
Rate Limiting
No rate limiting is enforced. The server is designed for local single-user access.
Next Steps
Course APIs
Learn about course data endpoints
Progress APIs
Track and save user progress
Drive Proxy
Stream files from Google Drive