You want to own your fitness numbers, without paywalls, opaque metrics, or feeds. Deploy a personal API that logs workouts and calculates your training efficiency. No accounts, no third-party tracking.
Live endpoint: https://fitlog-ai.casey-digennaro.workers.dev
Most fitness tools calculate proprietary metrics you cannot see or modify. This script gives you a private endpoint for your logs and the formulas that judge your progress, which you can audit and change.
- Fork this repository.
- Deploy to Cloudflare Workers using the dashboard or
wrangler deploy. It usually deploys in seconds. - Start logging by sending POST requests to your new endpoint. Sample data is included to test first.
Your data is stored solely in your Cloudflare KV namespace.
- A simple dashboard showing your recent training trends.
- Calculates training efficiency, consistency confidence, activity decay, and recall memory.
- Log bodyweight at
/api/kgand view its history. - One-click endpoint to populate sample workout data for testing.
- Built-in health check endpoint for monitoring.
- Zero external dependencies or network calls. Everything runs in one file.
- Zero dependencies. The entire tool is one ~400-line TypeScript file. You can read every line before deploying.
- Adjustable logic. You own the formulas. Edit how efficiency is calculated directly in the code.
- Fork-first. This is a tool, not a service. Your copy is independent; no upstream updates will break it.
Change the dashboard colors, add new metrics like one-rep max, or modify the data schema. All logic is in worker.ts.
- Manual entry only. You must log workouts by sending API requests. There is no built-in UI for data entry or import from other services.
Fork the repository and build what you need. If your modifications could help others, consider opening a pull request.
A stateless Cloudflare Worker that persists data in KV using a simple JSON structure.
MIT License
Superinstance and Lucineer (DiGennaro et al.)