DEVELOPER REFERENCE · API V1
Calendar API
Small read-only endpoints for Gregorian month grids, ISO weeks, leap-year checks, printable exports, and proleptic Julian/Gregorian conversions.
Base URL
https://calendar-workbench-production.up.railway.app/api/v1
For local development, use http://localhost:8080/api/v1.
Examples
GET /health GET /api/v1/calendar/2027?weekStart=monday GET /api/v1/calendar/2027/1?weekStart=sunday GET /api/v1/month-grid?year=2027&month=1 GET /api/v1/iso-week?date=2021-01-01 GET /api/v1/leap-year?year=2100 GET /api/v1/convert?year=1900&month=3&day=1&from=julian&to=gregorian GET /api/v1/print?year=2027&month=1&format=pdf&paper=a4&orientation=portrait
Responses and validation
Successful requests return JSON unless an export format is selected. Invalid dates, months, years, and options return HTTP 400 with a JSON error message. Calendar generation endpoints are limited to 2026–2035; the leap-year and conversion helpers accept integer years supported by the engine.
Print formats
Use format=json, format=svg, format=html, or format=pdf. PDF generation uses the built-in vector writer and does not load a browser-rendering package. Supported paper sizes are A4 and US Letter; orientation accepts portrait or landscape.
Calendar model
The grid is proleptic Gregorian. ISO week calculation follows the ISO week-year rule. Date-only input stays independent of server locale and local daylight-saving changes. Gregorian/Julian conversion uses integer Julian Day Numbers and does not impose national adoption dates.