child-safety
Get Guardian Links
Returns the active + pending guardian/child links for the current user in a UI-ready shape. Replaces the older "raw column dump" format that forced the frontend to guess names and roles (which produced the "Linked member" garbage on /family).
Each row in the returned array has shape:
{ id, link_status, relationship_type, verified, linked_at, invite_code, # pending rows only
viewer_role: 'guardian'|'child'|'unknown',
other_user_role:'guardian'|'child'|'unknown',
child_user_id, guardian_user_id,
child: {id, name, first_name, last_name, photo, age_band, date_of_birth} | null,
guardian: {id, name, first_name, last_name, photo} | null,
display_title: string, # who this card is "about" from viewer's POV
display_subtitle: string, # role · relationship · status
primary_action: 'dashboard'|'view_guardian'|'share_invite'|'cancel_invite',
}
2026-04-28 fixes:
- dropped phantom uc.age_band SELECT (column doesn't exist; was 500-ing every call → "No family links yet" even when active links existed)
- LEFT JOINs so pending rows with one side NULL still surface
- compute child_age_band in Python from date_of_birth
- role-aware display_title / display_subtitle so the UI never falls back to "Linked member"
- include profile photos for both sides so the cards anchor on faces
- include invite_code on pending rows so the frontend can render share-the-code UI without a second fetch
get/api/child-safety/guardian/links
Request
- Base URL: https://api.activitia.net (the document declares no server; this is the origin it was published from)
- URL: https://api.activitia.net/api/child-safety/guardian/links
- Auth: none declared
Headers
authorizationstring
Response
Successful Response
unknown required
Changes
No recorded changes to this operation across all 1 revision of this API.