Skip to content

Replace the coach's hidden player-metric set

PUT
/api/me/hidden-metrics/
curl --request PUT \
--url http://localhost:8000/api/me/hidden-metrics/ \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "activity": "running", "exercise": "", "hidden": [ "example" ] }'

Idempotent full-replace of the hidden metric-group set for one (activity, exercise). The player sends the COMPLETE hidden set after each hide / restore (not a patch), so a dropped concurrent write can’t silently re-show a hidden card. Keys are normalised (deduped, blank / over-long dropped, capped at 64); an empty hidden clears the curation. Returns the stored set. Per-admin — no owner gate.

PUT /api/me/hidden-metrics/ request — replace the hidden set for one (activity, exercise). Idempotent full-replace (not a patch): the player sends the complete hidden set after each hide/restore, so a dropped concurrent write can’t silently re-show a hidden card.

object
activity
required
  • running - Running
  • walking - Walking
  • jump - Vertical Jump
  • weightlifting - Weightlifting
  • mobility - Mobility Assessment
  • workspace_wellness - Workspace Wellness
  • agility - Agility
  • fencing - Fencing
  • cycling - Cycling
  • tennis - Tennis
  • padel - Padel Tennis
  • bowling - Bowling
  • baseball - Baseball
  • football - Football
  • badminton - Badminton
  • cricket - Cricket
  • basketball - Basketball
  • scuba_diving - Scuba Diving
  • ice_hockey - Ice Hockey
  • american_football - American Football
  • fri - Falls Risk Indicator
string
Allowed values: running walking jump weightlifting mobility workspace_wellness agility fencing cycling tennis padel bowling baseball football badminton cricket basketball scuba_diving ice_hockey american_football fri
exercise

Exercise within the activity; ‘’ for the activity-level set.

string
"" <= 120 characters
hidden
required

Metric-group keys to hide. Empty clears the curation.

Array<string>
<= 64 items
Media typeapplication/json

GET/PUT /api/me/hidden-metrics/ response — the coach’s hidden metric-group set for one (activity, exercise) pair (#424).

Server-side curation moved off device-local localStorage so the server-rendered session PDF prints the same visible set the coach curated in the player. hidden lists metric group keys (the groupLeftRight output — a metric key for singletons, a bilateral stem for L/R pairs), not raw metric keys.

object
activity
required
string
exercise
required
string
hidden
required
Array<string>
Examplegenerated
{
"activity": "example",
"exercise": "example",
"hidden": [
"example"
]
}
Media typeapplication/json
object
detail
required

Human-readable message, or a stable machine code for the cases a client branches on. The standard envelope for 400 (validation — a field-keyed object may appear instead), 401 (missing / invalid credentials), 403 (authenticated but not permitted), and 404 (absent — cross-team records are collapsed to 404 so the API never leaks the existence of another team’s data).

string
Examplegenerated
{
"detail": "example"
}
Media typeapplication/json
object
detail
required

Human-readable message, or a stable machine code for the cases a client branches on. The standard envelope for 400 (validation — a field-keyed object may appear instead), 401 (missing / invalid credentials), 403 (authenticated but not permitted), and 404 (absent — cross-team records are collapsed to 404 so the API never leaks the existence of another team’s data).

string
Examplegenerated
{
"detail": "example"
}