Skip to content
skcal
Esc
↑↓navigate↵open⌘Jpreview

Log a weigh-in

Records a manual body-weight reading for the caller.

POST/api/weight
Authorization
__Secure-better-auth.session_tokenAPI key · cookierequired

Better Auth session. Signing in (Google or email magic link) sets an HttpOnly session cookie that scopes every request to that account. The web app and CLI use this; agents use the OAuth 2.1 flow of the MCP server.

or
AuthorizationBearer token · headerrequired

Personal API key sent as Authorization: Bearer skcal_…. Create and scope keys in the app under your profile → API keys. Keys default to full access; a scoped key is limited to its granted resource:action permissions and cannot manage other keys.

Request body
requiredapplication/json

The weigh-in to record.

weightKgnumberrequired

Body weight to log, in kilograms.

min 9 · max 320
bodyFatPctnumber | null

Optional body-fat percentage for the weigh-in.

min 1 · max 80
notestring

Optional note (truncated to 500 characters).

max length 500
Responses
200

The reading was stored.

okbooleanrequired

Always true.

400

The request body or parameters failed validation.

errorstringrequired

Human-readable failure reason.

detailstring

Optional extra context, present on upstream failures.

Try it
Server
Authorization
Bodyapplication/json
Request
curl -X POST 'https://app.skcal.fit/api/weight' \
  -H 'Cookie: __Secure-better-auth.session_token=YOUR_API_KEY' \
  -H 'Accept: application/json' \
  -H 'Content-Type: application/json' \
  -d '{
  "weightKg": 72.6,
  "bodyFatPct": 17.4,
  "note": "morning, fasted"
}'
Response
{
  "ok": true
}

Was this page helpful?