Skip to content
This repository has been archived by the owner on Oct 20, 2023. It is now read-only.

Latest commit

 

History

History
19 lines (16 loc) · 450 Bytes

saveMindfulSession().md

File metadata and controls

19 lines (16 loc) · 450 Bytes

Each mindfulness sample represents a period of time with a startDate and an endDate. the options must contain startDate and endDate

let options = {
    startDate: (new Date(2016,10,1)).toISOString(), // required
    endDate: (new Date()).toISOString(), // optional; default now
};
AppleHealthKit.saveMindfulSession(options, (err, res) => {
  if (err) return {
    return
  }
  console.log('Mindful session saved')
});