Skip to main content
The Sprout API is a RESTful API that powers the adaptive learning platform. It provides endpoints for managing learning topics, generating personalized learning paths, and tracking student progress.

Base URL

http://localhost:8000/api
For production deployments, use your configured domain.

Authentication

Currently, Sprout uses a hardcoded DEFAULT_USER_ID for simplicity. See Authentication for details.

Response Format

All responses are JSON-encoded. Successful responses return relevant data:
{
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "title": "Introduction to React",
  "createdAt": "2024-01-15T10:30:00.000Z"
}
Error responses include an error field:
{
  "error": "Resource not found"
}

HTTP Status Codes

CodeDescription
200Success
201Resource created
204Success with no content
400Bad request (missing required fields)
404Resource not found
500Internal server error

Core Resources

  • Branches - Top-level learning collections
  • Nodes - Learning graph nodes (topics, concepts, subconcepts)
  • Assessments - Diagnostic tests and questions
  • Progress - Student mastery tracking
  • Chat - Interactive tutor sessions
  • Agents - AI-powered content generation (SSE streaming)

Health Check

curl http://localhost:8000/api/health
Returns:
{
  "status": "ok",
  "timestamp": "2024-01-15T10:30:00.000Z"
}

Build docs developers (and LLMs) love