Skip to content

Quickstart

The StudyPlug API generates educational content items for K-5 students on demand (K-8 planned). This guide walks you through your first API call, browsing the curriculum catalog, and using seeds for reproducible output.

Generate addition problems with a single request. No API key required.

Paste this in your browser — you’ll see JSON data immediately:

https://api.studyplug.org/api/v1/problems?skill=add-within-10&grade=kindergarten&count=5&seed=42

The GET /problems endpoint is the easiest way to start. Query parameters are simpler than JSON bodies, the URL is shareable, and adding seed makes the response deterministic and cacheable.

Terminal window
# Paste in browser or curl — no headers needed
curl "https://api.studyplug.org/api/v1/problems?skill=add-within-10&grade=kindergarten&count=5&seed=42"
# Single item
curl "https://api.studyplug.org/api/v1/problems/single?skill=multiply-by-3&grade=grade-3&seed=42"
# Multiple skills (comma-separated)
curl "https://api.studyplug.org/api/v1/problems?skills=add-within-10,subtract-within-10&grade=kindergarten&count=6"
# By standard code
curl "https://api.studyplug.org/api/v1/problems?standard=3.OA.C.7&count=5&seed=100"

The response includes a data object with items (the generated content) and answerKey (the answers), plus a meta object with request metadata.

The API organizes content into a hierarchy: grades contain subjects, which contain topics, which contain skills. Use the catalog endpoints to discover what is available.

Terminal window
# List all grades
curl https://api.studyplug.org/api/v1/grades
# Get a grade with its subjects
curl https://api.studyplug.org/api/v1/grades/grade-3
# List skills filtered by grade and subject
curl "https://api.studyplug.org/api/v1/skills?grade=grade-3&subject=math"
# Search skills by keyword
curl "https://api.studyplug.org/api/v1/skills?q=fraction"

Once you find a skill slug from the catalog, pass it to the problems or generate endpoint. You can request a batch of items or a single item.

Terminal window
# Batch: 10 items (default)
curl "https://api.studyplug.org/api/v1/problems?skill=multiply-by-6"
# Single item
curl "https://api.studyplug.org/api/v1/problems/single?skill=multiply-by-6"
# With seed for deterministic, cacheable output
curl "https://api.studyplug.org/api/v1/problems?skill=multiply-by-6&count=5&seed=42"

Pass a seed parameter to get the exact same content every time. This is useful for caching, testing, and sharing reproducible worksheets.

Terminal window
# Same seed = same output, every time. Paste in browser to verify!
curl "https://api.studyplug.org/api/v1/problems?skill=add-within-10&count=5&seed=42"

Seeded GET requests return Cache-Control: public, s-maxage=86400 — CDNs cache them automatically.

Seeded requests are cached server-side, so repeated calls with the same parameters return instantly.