AnpherosAnpheros PlatformDevelopers

Try it free in the sandbox · first FHIR call in 5 minutesFree · 30 synthetic patients · no card

ヘルス・トラッカーAPI

歩数、心拍数、HRV、睡眠、SpO₂などのウェアラブルデータをLOINCコード化されたFHIR Observationとして保存する方法:どのデバイスがどのヘルスストアに到達するか、Web APIが存在しない理由、動作するリクエスト例を説明します。

ヘルストラッカーAPIを使用すると、アプリケーションはウォッチ、リング、バンド、スケールが収集するデータ(ステップ数、心拍数、心拍変動、睡眠、酸素飽和度、体重)を構造化データとしてサーバーに送受信できます。 ほとんどのデバイスは共有APIを提供していません。データはスマートフォンのヘルスストア(Apple HealthKitまたはAndroid Health Connect)に到達し、アプリはそこからデータを読み取ります。Anpherosはサーバーサイドです。アプリは読み取り値をLOINCコード化されたFHIR R4 Observationとして書き込み、同意を得た他のすべてのアプリ、クリニック、またはAIエージェントは、1つのAPIを通じて同じデータを読み取ることができます。

From a watch to your backend
  1. Watch, ring, scaleApple Watch, Galaxy Watch, Fitbit, Garmin, Oura, Withings
  2. Health store on the phoneApple HealthKit or Android Health Connect
  3. Your appReads with the person's permission, per local day
  4. FHIR ObservationsLOINC-coded steps, heart rate, sleep, SpO₂, weight
  5. Your backendOne API for every device, with history and consent

どのデバイスがどのヘルスストアに到達するか

デバイス 到達先 読み取り方法
Apple Watch, iPhone, 多くのiOSアプリ Apple HealthKit iPhone上のSwift (Apple Health to FHIR)
Galaxy Watch, Wear OS, Fitbit, Garmin, Oura, Withings (Androidアプリ) Android Health Connect スマートフォン上のKotlinまたはFlutter (Health Connect to FHIR)
Health Connectに含まれないGalaxy Watchの詳細 Samsung Health Samsung Health Data SDK (Samsung Health to FHIR)

HealthKitもHealth ConnectもWeb APIやREST APIを持っていません。データはスマートフォン上に存在し、ユーザーがインストールして許可したアプリのみがそれを読み取ることができます。したがって、サーバー上のヘルス・トラッカーAPIは、常に小さなモバイルアプリから始まります。

What a health tracker API should store, coded
StepsLOINC 41950-7 · daily total, effectivePeriod = the day
Resting heart rateLOINC 40443-4 · beats per minute
Heart rate variabilityLOINC 80404-7 · RMSSD in ms
Oxygen saturationLOINC 59408-5 · percent
SleepLOINC 93832-4 duration; 93831-6 / 93830-8 stages
Active energyLOINC 41981-2 · kcal

1日のステップを記録する

curl -X POST https://platform.anpheros.com/fhir/R4/Observation \
  -H "Authorization: Bearer $KEY" -H "Content-Type: application/fhir+json" \
  -H "Idempotency-Key: steps-$PID-2026-10-15" \
  -d '{
    "resourceType": "Observation",
    "status": "final",
    "category": [{"coding": [{"system": "http://terminology.hl7.org/CodeSystem/observation-category", "code": "activity"}]}],
    "code": {"coding": [{"system": "http://loinc.org", "code": "41950-7", "display": "Number of steps in 24 hour Measured"}]},
    "subject": {"reference": "Patient/'"$PID"'"},
    "effectivePeriod": {"start": "2026-10-15T00:00:00+03:00", "end": "2026-10-16T00:00:00+03:00"},
    "valueQuantity": {"value": 8412, "unit": "steps", "system": "http://unitsofmeasure.org", "code": "{steps}"}
  }'

メトリックごとに、個人のタイムゾーンを期間に含めて、ローカルの1日につき1つのObservationを保存します。Idempotency-Keyにより、再送信は無害になります。FHIR形式のウェアラブルデータには、完全なLOINCテーブルとテスト済みの毎日のupsertが含まれています。

読み取り

# the last 30 daily step counts
curl "https://platform.anpheros.com/fhir/R4/Observation?patient=$PID&code=http://loinc.org|41950-7&_sort=-date&_count=30" \
  -H "Authorization: Bearer $KEY"

別のアプリケーションは、その人の同意を得てのみ同じデータを読み取ります(OAuth 2.1、patient/Observation.rs?category=activityのようなSMARTスコープ)。すべての読み取りは記録され、その人はそれを見ることができます。

よくある質問

無料のヘルス・トラッカーAPIはありますか?

Anpherosには無料のサンドボックスがあります。30人の合成患者のFHIR Observationとしてトラッカーデータを保存・読み取りできます。デバイスメーカー独自のAPI(Fitbit、Garmin、Oura、Withings)には、それぞれ独自のアクセスルールと利用規約があります。

Apple HealthまたはHealth Connect用のWeb APIはありますか?

いいえ。HealthKitとHealth Connectはデータを電話上に保持します。インストールされたアプリは、ユーザーの許可を得てそれを読み取り、Anpherosのようなサーバーに送信できます。

ヘルス・トラッカーAPIはどのコードを使用すべきですか?

LOINC: 41950-7 ステップ、8867-4 心拍数、40443-4 安静時心拍数、80404-7 心拍変動(RMSSD)、59408-5 酸素飽和度、93832-4 睡眠時間、29463-7 体重。単位はUCUM。

AnpherosはFitbitまたはGarminに直接接続しますか?

いいえ。それらのデータは、電話のヘルスストアとお客様のアプリを経由してAnpherosに到達します。直接のクラウド間接続はありません。

関連情報

Try it free in the sandbox · first FHIR call in 5 minutesFree · 30 synthetic patients · no card

Product updates by email

New features, guides and the end of the beta. One email a month at most.

Send me occasional Anpheros Platform updates by email (new features, API changes, guides). I'll confirm by email and can unsubscribe in one click from any email. Privacy