All API requests use the base URL https://api.tutorflow.io.
Choose Your Path
| Path | Best for | Setup |
|---|---|---|
| Agent self-serve | Autonomous AI agents, scripts, server-side integrations | One POST, no human needed |
| Dashboard | Human developers exploring the API in a browser | Sign up at tutorflow.io, create a workspace, mint a key |
The two paths produce the same API key format. Pick whichever is easier.
Agent Self-Serve (Recommended for AI Agents)
1. Register
One POST. No authentication. No email verification required to start.
curl -X POST https://api.tutorflow.io/v1/platform/agent/register \
-H "Content-Type: application/json" \
-d '{
"name": "My EdTech Agent",
"slug": "my-edtech-agent",
"email": "agent@example.com"
}'Response:
{
"organizationId": "uuid",
"apiKey": "tf_platform_a1b2c3d4e5f6g7h8i9j0klmn...",
"keyPrefix": "tf_platform_a1b2c3d4e5f6",
"trialCredits": 100,
"message": "Store your API key securely. It will not be shown again.",
"requiresEmailVerification": true,
"verifyEmailResendEndpoint": "POST /v1/platform/agent/verify-email/resend",
"nextSteps": {
"createSlide": "POST /v1/platform/slides",
"createVideo": "POST /v1/platform/videos",
"accountInfo": "GET /v1/platform/agent/account"
}
}You now have $1.00 (100 credits) to spend on any generation API. The
requiresEmailVerification: true flag is informational. It only matters
when you later try to add billing.
For trial-only experiments, email may be omitted. For any paid top-up path,
include email during registration because public agent endpoints do not add
an email later.
Rate limit: 5 registrations per IP per hour.
2. Make Your First Call
Pick whichever capability matches your use case:
# Grade an answer
curl -X POST https://api.tutorflow.io/v1/platform/evaluations \
-H "Authorization: Bearer tf_platform_..." \
-H "Content-Type: application/json" \
-d '{
"evaluationType": "open_ended",
"questionText": "What causes seasons on Earth?",
"learnerAnswer": "The tilt of Earth axis.",
"language": "en",
"maxScore": 10
}'
# Generate a slide deck
curl -X POST https://api.tutorflow.io/v1/platform/slides \
-H "Authorization: Bearer tf_platform_..." \
-H "Content-Type: application/json" \
-d '{ "prompt": "Mediterranean diet for adults", "slideCount": 6 }'
# Generate a narrated video
curl -X POST https://api.tutorflow.io/v1/platform/videos \
-H "Authorization: Bearer tf_platform_..." \
-H "Content-Type: application/json" \
-d '{ "prompt": "What is photosynthesis?", "sceneCount": 4 }'
# Generate a course
curl -X POST https://api.tutorflow.io/v1/platform/courses \
-H "Authorization: Bearer tf_platform_..." \
-H "Content-Type: application/json" \
-d '{ "prompt": "Beginner Python", "lessonCount": 5 }'
# Generate one reusable module
curl -X POST https://api.tutorflow.io/v1/platform/modules \
-H "Authorization: Bearer tf_platform_..." \
-H "Content-Type: application/json" \
-d '{ "prompt": "Data privacy basics for managers", "hasQuiz": true }'
# Generate a test
curl -X POST https://api.tutorflow.io/v1/platform/tests \
-H "Authorization: Bearer tf_platform_..." \
-H "Content-Type: application/json" \
-d '{ "prompt": "5th-grade math quiz", "itemCount": 10 }'Courses, tests, slides, and videos return shareable URLs. Modules return a
publicUrl and generated module fields. Evaluations return grading results.
For example, slide:
{
"id": "uuid",
"status": "COMPLETED",
"title": "The Mediterranean Diet, Explained",
"previewUrl": "https://tutorflow.io/en/platform/slides/edit/...",
"publicUrl": "https://tutorflow.io/en/platform/slides/...",
"priceSnapshot": {
"category": "slide",
"catalogKey": "slide.default",
"tier": "default",
"unit": "slide",
"unitPrice": 0.03,
"units": 6,
"amountUsd": 0.18,
"currency": "USD",
"source": "platform_pricing_catalog_v2"
}
}For URL-returning APIs, hand the previewUrl to a human reviewer or paste the
publicUrl into your chat reply.
3. Watch Your Balance
curl https://api.tutorflow.io/v1/platform/agent/account \
-H "Authorization: Bearer tf_platform_..."{ "creditBalance": 88, "rateLimitPerMinute": 1000, "status": "ACTIVE" }Balance is in cents. When it approaches 0, top up via
POST /v1/platform/agent/billing/session (see
Agent Onboarding).
Email verification is required before creating the billing session.
Dashboard Path (Humans)
1. Create a Workspace
Sign up at tutorflow.io and create a platform workspace from the
TutorFlow dashboard. The slug must contain only lowercase letters, numbers,
and hyphens. Verify your email through the dashboard if prompted.
2. Generate an API Key
From the dashboard, mint a Production key. The raw key is shown only once. Copy it into your secrets manager immediately.
{ "apiKey": "tf_platform_..." }3. Make Your First Call
Same as the agent path. See the curl examples above.
What's Next
| Goal | Read this |
|---|---|
| Build a course end-to-end | Create Course |
| Build one reusable module | Create Module |
| Build a slide deck end-to-end | Create Slide |
| Build a narrated video end-to-end | Create Video |
| Build a graded test | Create Test |
| Edit generated course/test/slide/video content by API key | Update Course, Update Test, Update Slide, Update Video |
| Connect via MCP (Claude, etc.) | MCP Integration |
| Stream results via webhooks | Webhooks |
| Understand pricing | Pricing & Billing |
| Handle errors and retries | Error Handling |
| Deal with rate limits | Rate Limiting |