Overview
Add the ability to record life events (illness, travel, special occasions, medication changes, injuries, etc.) to the user's profile. These events provide contextual data so AI agents can correlate health data patterns with real-life circumstances.
Scope
Full-stack feature spanning 4 PRs scoped to individual services:
- Biotrackr.LifeEvents.Api — New CRUD domain API (first write-capable domain API)
- Biotrackr.Mcp.Server — 3 read-only MCP tools for AI agent access
- Biotrackr.UI — Blazor CRUD page, form dialog, dashboard card, service layer CRUD methods
- Infrastructure & CI/CD — Bicep templates and GitHub Actions workflow
Key Design Decisions
- Data Model: One document per event in shared
records container with documentType = "LifeEvent"
- Multi-day events:
endDate always stored (= date for single-day events); interval overlap queries
- Categories: 21 fixed categories (Medical, Lifestyle, Environmental, Emotional/Social, General) with optional free-text notes
- Impact Areas: Optional
impactAreas field (activity, sleep, food, vitals) for filtered MCP queries
- Security: Input validation with ASI01 prompt injection scanning, rate limiting (30 writes/min), 64KB body limit
- AI Integration: Zero changes to Chat API or Reporting API — MCP tools auto-discovered
Planning Documents
- Research:
.copilot-tracking/research/2026-04-23/life-events-feature-research.md
- Plan:
.copilot-tracking/plans/2026-04-23/life-events-feature-plan.instructions.md
- Details:
.copilot-tracking/details/2026-04-23/life-events-feature-details.md
- Log:
.copilot-tracking/plans/logs/2026-04-23/life-events-feature-log.md
Overview
Add the ability to record life events (illness, travel, special occasions, medication changes, injuries, etc.) to the user's profile. These events provide contextual data so AI agents can correlate health data patterns with real-life circumstances.
Scope
Full-stack feature spanning 4 PRs scoped to individual services:
Key Design Decisions
recordscontainer withdocumentType = "LifeEvent"endDatealways stored (=datefor single-day events); interval overlap queriesimpactAreasfield (activity,sleep,food,vitals) for filtered MCP queriesPlanning Documents
.copilot-tracking/research/2026-04-23/life-events-feature-research.md.copilot-tracking/plans/2026-04-23/life-events-feature-plan.instructions.md.copilot-tracking/details/2026-04-23/life-events-feature-details.md.copilot-tracking/plans/logs/2026-04-23/life-events-feature-log.md