herd
herd

Reputation: 195

Read the sleep schedule using HealthKit

Using the Health app, the user can define a bedtime and a wake up time.

Can we get this data using the HealthKit framework?

I'm not interested in the actual time the user spent in bed, but in the time the user scheduled to go to bed, so different kinds of data.

Unfortunately I could not find anything in the documentation: https://developer.apple.com/documentation/healthkit/data_types

Upvotes: 3

Views: 692

Answers (1)

Rob Napier
Rob Napier

Reputation: 299585

I am fairly certain this is not in HealthKit (since it's not a health record). It's part of the Focus system, and we have extremely little access to that beyond INFocusStatus.isFocused.

Upvotes: 3

Related Questions