📅 Scheduler API

Lightweight, Stateless Schedule Pattern Calculation Service

Welcome to the Scheduler API!

This is a pure computation service for schedule pattern calculation and validation. It provides:

Note: This is a stateless service - no persistence, no database, just pure calculation.

API Endpoints

Rewrites the timezone field in every request body below that has one.
GET /health
Service health check and version metadata.

Try it out:

Open /health
POST /calculate
Comprehensive endpoint for schedule calculation and validation. Provides identical functionality to /validate.

Try it out:

Response:

                
POST /calculate-next-run
Calculate next run times for an abstract pattern (e.g., @daily, @tomorrow@noon, @inaweek+2d).

Try it out:

Response:

                
POST /calculate-next-run-cron
Calculate next run times for a cron expression (5-field format: minute hour day month day-of-week).

Try it out:

Response:

                
POST /pattern-to-scheduling
Convert abstract patterns to cron expressions or at commands. Recurring patterns export as cron, one-time patterns export as at commands.

Try it out:

Response:

                
POST /validate
Validate cron expressions, datetime strings, schedule patterns, or timezones.

Try it out:

Response:

                
GET /aliases
Discover all available pattern aliases and format specifications.

Try it out:

Open /aliases
GET /vocabulary
Complete reference guide for all hardcoded vocabularies and mappings. Includes day, time, and recurrence terms plus their numeric mappings for cron/at export.

Try it out:

Open /vocabulary

Spaced Repetition

Its own namespace, deliberately separate from the calendar-pattern endpoints above. These compute the next review time from review history rather than from a fixed calendar rule. Fully stateless — the caller owns the algorithm state and passes it back on each call. Nothing is persisted server-side.

POST /spaced-repetition/sm2/next-review
SM-2 (SuperMemo 2, Wozniak 1987). Stateless: caller owns and passes repetitions/ease_factor/interval_days between calls, nothing persisted server-side.

Try it out:

Response:

                
POST /spaced-repetition/fsrs6/next-review
FSRS-6 (Ye). Uses Anki's published 21-parameter default weights; no caller-supplied parameter override in this build. Stateless: caller owns and passes stability/difficulty/last_review between calls.

Try it out:

Response:

                
POST /spaced-repetition/hlr/next-review
Half-Life Regression (Settles & Meeder, Duolingo 2016), inference only. IMPORTANT: the weights shipped here are the paper's hand-derived Leitner-equivalent special case (theta = {bias:0, right:+1, wrong:-1}), not a trained model — Duolingo never published fitted interaction-feature weights. See HlrService docblock and backlog.md for the low-priority revisit item.

Try it out:

Response: