HealthKit: Reading HKCorrelationType is not allowed Error

Payal Kandlur
Jan 8, 2021

--

HealthKit does not provide you with an option to read or share (write) correlation data types, instead, you must break their components and access.

Apple’s document clearly mentions:

“Unlike other sample types, you do not request permission to share and read correlation types directly. Instead, you request permission to share and read each of the sample types contained within the correlation.”

For example, if you need the user's Blood pressure all you have to do is:

Refer more about this in Apple’s documentation: https://developer.apple.com/documentation/healthkit/hkcorrelationquery

--

--

No responses yet