Documentation Index
Fetch the complete documentation index at: https://docs.onvy.health/llms.txt
Use this file to discover all available pages before exploring further.
health-api is built around one stable internal model. Many different inputs (provider clouds, mobile SDKs, customer-supplied data) are normalized into a small set of harmonized records that power records, scores, facts, and AI summaries. Your integration reads against that stable model, not against per-provider formats.
Two integration paths
There are two clear entry paths into the platform that converge into the same downstream model:| Path | How data arrives | Typical source |
|---|---|---|
| OAuth providers | Provider cloud → ONVY ingestion webhook → harmonization | oura, fitbit, garmin, withings, strava, polar |
| SDK providers | Mobile app → upload endpoint → harmonization | healthkit, health_connect, samsung_health |
daily_records, activities, facts, meals, and ai_summaries.
Raw, harmonized, merged
Three layers describe how provider input becomes the data your integration reads:raw: provider- or SDK-specific input as it enters the platformharmonized: the same input mapped into ONVY’s common schema, primarily arounddaily,activity, andsleepmerged: overlapping inputs combined into the higher-level user view that powers records, scores, facts, and downstream delivery
High-level flow
- ONVY receives provider or application data.
- Raw payloads are stored and queued for processing.
- Calculation workers harmonize data into stable record families.
- Downstream services generate summaries, scores, and webhook events.
Source provenance
Every harmonized record carries source information so you can tell where a data point came from:provider, for exampleGARMIN,APPLE,OURAapp_id, for examplecom.apple.Health
Deterministic record IDs
Harmonized records use deterministic IDs so the same logical event keeps the same identity even if the same payload is delivered more than once.dailyrecords use the user’s local calendar day. Example:daily-2024-02-04-APPLE-com.apple.Healthactivityandsleeprecords use a normalized start timestamp. Example:activity-2024-02-04T06:00:00+00:00-GARMIN-garmin,sleep-2024-02-03T22:30:00+00:00-OURA-oura
Terra ingestion pattern
The Terra pipeline is the main example of delayed ingestion:- A Terra webhook writes raw data and schedules work in DynamoDB.
- A delayed SQS message gives related payloads time to accumulate.
- The calculation Lambda processes scheduled items in batches by user.
- Harmonized outputs become available through routes such as
daily_records,activities, andbaselines.
What processing produces
daily_recordsfor user-facing scores, zones, and logsfactsfor durable AI personalization contextactivitiesandmealsfor structured event historyai_summariescovering meal nutrition analysis, sleep insights, workouts, and daily, weekly, nutrition, trend, and impact summaries
ai_summaries. See /ai-capabilities for the full type catalog and how each summary is generated.
Sync state and historical loads
Historical sync is treated as a first-class workflow. Provider, sync type, and sync status are tracked under each user, and changes emit ausers.data_syncs:updated webhook. Provider-specific constraints, such as a single deep-history request per user for some providers, are handled by ONVY rather than by your integration.
Schema versioning
Schema evolution withinv1 is additive. Breaking changes require a new major version. Track changes through release notes and adjust client parsing accordingly.
AI surfaces in the pipeline
AI features consume the same underlying user context:- Chat completions enrich prompts with ONVY context unless the request opts out of selected sections
- AI summaries persist generated results so you can list, fetch, and audit them later
Internal EventBridge events use a flat
detail.data shape. The batched events[] envelope described in /webhooks is only for external webhook delivery.