API & MCP
Everything a person can do on Running Pace & Splits, a program or AI agent can do with the same inputs and get the identical result.
HTTP API
POST https://runningpacecalculator.usefulweb.site/api/v1/calculate– run Running Pace & SplitsGET https://runningpacecalculator.usefulweb.site/api/v1/tool– inputs, output schema, examples- OpenAPI 3.1: /openapi.json · /openapi.yaml
- Errors:
application/problem+json;422includes per-fielderrors.
Running Pace & Splits
Enter two of distance, time and pace to get the third, in kilometres or miles. Get an even, negative or positive split table, race time predictions with the Riegel formula, the treadmill speed in km/h and mph, and track lap times.
| Field | Type | Default | Description |
|---|---|---|---|
solveFor | select (pace, time, distance) | "pace" | Calculate |
preset | select (custom, 1k, mile, 5k, 10k, 15k, 10mi, half, marathon, 50k) | "10k" | Race distance |
distance | number | — | Custom distance. Used when the race distance is "Custom distance". |
distanceUnit | select (km, mi, m) | "km" | Distance unit |
time | text | — | Time. h:mm:ss or mm:ss, e.g. 1:45:00 or 24:30. |
pace | text | — | Pace. mm:ss per km or per mile, e.g. 5:30. |
paceUnit | select (km, mi) | "km" | Pace per |
splitUnit | select (km, mi) | "km" | Splits every |
splitStrategy | select (even, negative, positive) | "even" | Split strategy |
splitPercent | number | 3 | Pace change start → finish. For negative/positive splits: how much the pace changes from the start to the finish, spread evenly. |
lapMeters | number | 400 | Track lap length |
Example request
10K in 50:00: pace and splits
curl -X POST https://runningpacecalculator.usefulweb.site/api/v1/calculate -H 'content-type: application/json' -d '{"solveFor":"pace","preset":"10k","time":"50:00","splitUnit":"km","splitStrategy":"even"}'
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://runningpacecalculator.usefulweb.site/mcp– protocol revisions 2026-07-28 (stateless) and 2025-11-25 / 2025-06-18 / 2025-03-26 (initialize handshake). - Tools:
running_pace_calculator - Local stdio connector:
node src/mcp-stdio.ts --tool=running-pace-calculator
{
"mcpServers": {
"running-pace-calculator": { "type": "http", "url": "https://runningpacecalculator.usefulweb.site/mcp" }
}
}