Google Health API には、リプロダクティブ ヘルス、症状、ムードをトラッキングするためのデータ型が用意されています。これらの型を使用すると、月経期間、排卵検査の結果、関連する身体的および感情的な状態を記録できます。
サポートされるデータタイプ
| データ型 | 利用可能な オペレーション |
スコープ |
|---|---|---|
|
月経期間
|
create、update、batchDelete | .reproductive_health.writeonly |
|
ムード
|
create、update、batchDelete | .mindfulness.writeonly |
|
排卵検査
|
create、update、batchDelete | .reproductive_health.writeonly |
|
症状
|
create、update、batchDelete | .logged_symptoms.writeonly |
月経期間
月経期間は、ユーザーが記録した期間を表します。フィールドと説明の完全な
リストについては、
MenstrualPeriod をご覧ください。
期間の記録に関するガイドライン
- 終了日は必須: すべての期間レコードに終了日または 時刻を含める必要があります。終了日を null にすることはできません。
- 継続中の期間の処理: レコードの作成時に終了日を指定できない場合(期間が継続中の場合など)、終了日を開始日と一致するように設定します。期間が終了して最終的な終了日が確定するまで、毎日レコードを更新し、終了日を現在の日付に設定します。
- 確定した期間: すべての期間レコードは、確定した期間として扱われます。
月経期間を作成する
月経期間のエントリを作成するには、POST リクエストを menstrual-period データポイント エンドポイントに送信します。レスポンスには、name フィールド
に data-point-id が含まれます。これは、
バッチ削除または
更新(パッチ)リクエストで使用できます。
リクエスト
POST https://health.googleapis.com/v4/users/me/dataTypes/menstrual-period/dataPoints
Authorization: Bearer access-token
Content-Type: application/json
{
"menstrualPeriod": {
"interval": {
"startTime": "2026-07-01T08:00:00Z",
"endTime": "2026-07-05T20:00:00Z"
},
"notes": "Regular flow reported."
}
}レスポンス
{
"done": true,
"response": {
"@type": "type.googleapis.com/google.devicesandservices.health.v4.DataPoint",
"name": "users/user-id/dataTypes/menstrual-period/dataPoints/data-point-id",
"menstrualPeriod": {
"interval": {
"startTime": "2026-07-01T08:00:00Z",
"startUtcOffset": "0s",
"endTime": "2026-07-05T20:00:00Z",
"endUtcOffset": "0s",
"civilStartTime": {
"date": { "year": 2026, "month": 7, "day": 1 },
"time": { "hours": 8 }
},
"civilEndTime": {
"date": { "year": 2026, "month": 7, "day": 5 },
"time": { "hours": 20 }
}
},
"notes": "Regular flow reported."
}
}
}排卵検査
排卵検査の観察結果を記録します。フィールドと
説明の完全なリストについては、
OvulationTest をご覧ください。
排卵検査を作成する
排卵検査の結果を記録するには、POST リクエストを ovulation-test データポイント エンドポイントに送信します。レスポンスには、name フィールドが含まれます。このフィールドには
data-point-id が含まれており、バッチ削除または
更新(パッチ)リクエストで使用できます。
リクエスト
POST https://health.googleapis.com/v4/users/me/dataTypes/ovulation-test/dataPoints
Authorization: Bearer access-token
Content-Type: application/json
{
"ovulationTest": {
"sampleTime": {
"physicalTime": "2026-07-14T07:30:00Z"
},
"result": "LUTEINIZING_HORMONE_SURGE"
}
}レスポンス
{
"done": true,
"response": {
"@type": "type.googleapis.com/google.devicesandservices.health.v4.DataPoint",
"name": "users/user-id/dataTypes/ovulation-test/dataPoints/data-point-id",
"ovulationTest": {
"sampleTime": {
"physicalTime": "2026-07-14T07:30:00Z",
"utcOffset": "0s",
"civilTime": {
"date": { "year": 2026, "month": 7, "day": 14 },
"time": { "hours": 7, "minutes": 30 }
}
},
"result": "LUTEINIZING_HORMONE_SURGE"
}
}
}症状
特定のタイムスタンプで発生した身体的症状を記録します。フィールドと説明の完全なリストについては、
Symptoms をご覧ください。
症状ログを作成する
身体的症状を記録するには、POST リクエストを symptoms データポイント エンドポイントに送信します。レスポンスには、name フィールドが含まれます。これには data-point-id が含まれており、
バッチ削除または
更新(パッチ)リクエストで使用できます。
リクエスト
POST https://health.googleapis.com/v4/users/me/dataTypes/symptoms/dataPoints
Authorization: Bearer access-token
Content-Type: application/json
{
"symptoms": {
"sampleTime": {
"physicalTime": "2026-07-02T19:00:00Z"
},
"symptoms": [ "CRAMPS", "BLOATED", "FATIGUE" ]
}
}レスポンス
{
"done": true,
"response": {
"@type": "type.googleapis.com/google.devicesandservices.health.v4.DataPoint",
"name": "users/user-id/dataTypes/symptoms/dataPoints/data-point-id",
"symptoms": {
"sampleTime": {
"physicalTime": "2026-07-02T19:00:00Z",
"utcOffset": "0s",
"civilTime": {
"date": { "year": 2026, "month": 7, "day": 2 },
"time": { "hours": 19 }
}
},
"symptoms": [ "CRAMPS", "BLOATED", "FATIGUE" ]
}
}
}ムード
特定のタイムスタンプでの感情状態と価数を記録します。フィールドと説明の完全な
リストについては、
Moodsをご覧ください。
ムードログを作成する
感情状態を記録するには、POST リクエストを moods データポイント エンドポイントに送信します。レスポンスには、name フィールドが含まれます。これには data-point-id が含まれており、
バッチ削除または
更新(パッチ)リクエストで使用できます。
リクエスト
POST https://health.googleapis.com/v4/users/me/dataTypes/moods/dataPoints
Authorization: Bearer access-token
Content-Type: application/json
{
"moods": {
"sampleTime": {
"physicalTime": "2026-07-02T21:00:00Z"
},
"moods": [ "CALM", "CONTENT" ],
"valences": [ "PLEASANT" ]
}
}レスポンス
{
"done": true,
"response": {
"@type": "type.googleapis.com/google.devicesandservices.health.v4.DataPoint",
"name": "users/user-id/dataTypes/moods/dataPoints/data-point-id",
"moods": {
"sampleTime": {
"physicalTime": "2026-07-02T21:00:00Z",
"utcOffset": "0s",
"civilTime": {
"date": { "year": 2026, "month": 7, "day": 2 },
"time": { "hours": 21 }
}
},
"moods": [ "CALM", "CONTENT" ],
"valences": [ "PLEASANT" ]
}
}
}一括削除
1 つ以上のデータポイントを削除するには、削除するエントリのリソース名を使用して、POST リクエストを batchDelete エンドポイントに送信します。
POST https://health.googleapis.com/v4/users/me/dataTypes/data-type-name/dataPoints:batchDelete
Authorization: Bearer access-token
Content-Type: application/json
{
"names": [
"users/me/dataTypes/data-type/dataPoints/data-point-id"
]
}例: 複数のデータポイントを削除する
1 回のリクエストで複数のデータポイントを削除するには、リソース名を names 配列に含めます。
POST https://health.googleapis.com/v4/users/me/dataTypes/symptoms/dataPoints:batchDelete
Authorization: Bearer access-token
Content-Type: application/json
{
"names": [
"users/user-id/dataTypes/symptoms/dataPoints/symptom-id-1",
"users/user-id/dataTypes/symptoms/dataPoints/symptom-id-2"
]
}