API & MCP
Everything a person can do on Sizewise Life in Weeks, a program or AI agent can do with the same inputs and get the identical result.
HTTP API
POST https://sizewiselifeweeks.usefulweb.app/api/v1/calculate– run Sizewise Life in WeeksGET https://sizewiselifeweeks.usefulweb.app/api/v1/tool– inputs, output schema, examples- OpenAPI 3.1: /openapi.json · /openapi.yaml
- Errors:
application/problem+json;422includes per-fielderrors.
Sizewise Life in Weeks
Draws a life-in-weeks grid from a birth date — one row per year, 52 boxes per row — with the current week, your milestones and exact counts of days, weeks, Sundays and leap days lived. Nothing is stored.
| Field | Type | Default | Description |
|---|---|---|---|
birthDate | date | "1990-06-15" | Birth date |
today | date | — | Count up to (empty = today) |
years | integer | 90 | Years in the grid |
milestones | textarea | — | Milestones (one per line: date, then a label). For example “2012-09-01 First job”. |
Example request
Born 15 June 1990, on 8 November 2026
curl -X POST https://sizewiselifeweeks.usefulweb.app/api/v1/calculate -H 'content-type: application/json' -d '{"birthDate":"1990-06-15","today":"2026-11-08","years":90,"milestones":"1996-09-02 First day at school\n2008-07-01 First job"}'
Every result contains
inputs (normalised, defaults applied), summary, result (validated against the published schema), units, assumptions, sources, warnings, computedAt and links.
MCP (Model Context Protocol)
- Streamable HTTP endpoint:
https://sizewiselifeweeks.usefulweb.app/mcp– protocol revisions 2026-07-28 (stateless) and 2025-11-25 / 2025-06-18 / 2025-03-26 (initialize handshake). - Tools:
sizewise_life_weeks - Local stdio connector:
node src/mcp-stdio.ts --tool=sizewise-life-weeks
{
"mcpServers": {
"sizewise-life-weeks": { "type": "http", "url": "https://sizewiselifeweeks.usefulweb.app/mcp" }
}
}