From ea00912f482a0464d82a00974cdcf415cb5808c7 Mon Sep 17 00:00:00 2001 From: skleest Date: Thu, 30 Mar 2017 14:11:35 -0700 Subject: [PATCH] update readme --- README.md | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 90701ce..f0d18b5 100644 --- a/README.md +++ b/README.md @@ -42,6 +42,7 @@ A React Native bridge module for interacting with [Apple HealthKit] data. * [getRespiratoryRateSamples](#getrespiratoryratesamples) * [getBloodGlucoseSamples](#getbloodglucosesamples) * [getSleepSamples](#getsleepsamples) + * [saveMindfulSession](#saveMindfulSession) * [Examples](#examples) @@ -155,7 +156,8 @@ The available HealthKit permissions to use with `initHealthKit` | BloodGlucose | [HKQuantityTypeIdentifierBloodGlucose](https://developer.apple.com/reference/healthkit/hkquantitytypeidentifierbloodglucose?language=objc) | ✓ | | | SleepAnalysis | [HKCategoryTypeIdentifierSleepAnalysis](https://developer.apple.com/reference/healthkit/hkcategorytypeidentifiersleepanalysis?language=objc) | ✓ | -| +| MindfulSession | [HKCategoryTypeIdentifierMindfulSession](https://developer.apple.com/reference/healthkit/hkcategorytypeidentifiermindfulsession?language=objc) | | ✓ | + These permissions are exported as constants of the `react-native-apple-healthkit` module. @@ -911,6 +913,20 @@ AppleHealthKit.getSleepSamples(options, (err: Object, samples: Array) => }); ``` +___ + +#### **`saveMindfulSession`** +saveMindfulSession + +each mindfulness sample represents a period of time with a startDate and an endDate. +the options must contain `startDate` and `endDate` + +```javascript +let options = { + startDate: (new Date(2016,10,1)).toISOString(), // required + endDate: (new Date()).toISOString(), // optional; default now +}; +``` ## Examples -- 2.26.2