Documentation Index
Fetch the complete documentation index at: https://mintlify.com/kingstinct/react-native-healthkit/llms.txt
Use this file to discover all available pages before exploring further.
saveCategorySample
Save a category sample to HealthKit.Parameters
The category type identifier. See Category Type Identifiers for all available types.
The category value. The type depends on the identifier:
- Sleep Analysis:
CategoryValueSleepAnalysis(inBed, asleepUnspecified, awake, asleepCore, asleepDeep, asleepREM) - Cervical Mucus Quality:
CategoryValueCervicalMucusQuality(dry, sticky, creamy, watery, eggWhite) - Menstrual Flow:
CategoryValueMenstrualFlow(unspecified, none, light, medium, heavy) - Ovulation Test Result:
CategoryValueOvulationTestResult(negative, luteinizingHormoneSurge, indeterminate, estrogenSurge) - Severity-based symptoms:
CategoryValueSeverity(notPresent, mild, moderate, severe, unspecified) - Presence-based symptoms:
CategoryValuePresence(notPresent, present) - Not applicable types:
CategoryValueNotApplicable.notApplicable - Others:
number(specific enum value for the type)
The start date and time of the category sample.
The end date and time of the category sample.
Optional metadata for the sample. Some category types support specific metadata keys:
Returns
The saved category sample, or
undefined if the save failed.Examples
Save Sleep Analysis
Save Mindful Session
Save Symptom with Severity
Save Menstrual Flow with Cycle Start
Save Sexual Activity with Protection
For instant events (like symptoms or one-time occurrences), set
startDate and endDate to the same value.