Inclusion Criteria:  Has OSA diagnosed according to the International Classification of Sleep Disorders-3 (ICSD-3) criteria and an AHI of 12-50 events/hour sleep (documented by an in-clinic PSG or at-home sleep test within the last 12 months). Participants who do not have PSG results from within 12 months available may be offered a screening home sleep test at the discretion of the principal investigator. Those who use continuous positive airway pressure (CPAP) or an oral appliance must be willing to forego this therapy during all in-clinic PSGs and during the home sleep test if one is required. Has no known history of a sleep disorder other than OSA based on interviews at the screening visit, such as, for example, restless legs syndrome accompanied by periodic leg movements of sleep. Has a regular bedtime between 9 and midnight (12 AM) and regular time in bed averaging between 6.5 and 9.0 hours/night, as verified by sleep tracking mat and sleep diary data. Has a body mass index (BMI) of 18 to 38.5 kilogram per square meter (kg/m^2) inclusive.  Exclusion Criteria:  The participant is on OSA stimulation therapy (example, hypoglossal nerve stimulator). Has an occupation requiring nighttime shift work or variable shift work within the past 2 months or has travelled with significant jet lag within 14 days before the study start or plans to travel with significant jet lag during the study. Has nicotine dependence that is likely to have an effect on sleep (example, a participant who routinely awakens at night to smoke) or challenge the conduct of this study (smokes greater than or equal to (>=) 10 cigarettes/day), or the participant is unwilling to discontinue all smoking and nicotine use during the confinement periods. Has a caffeine consumption of more than 400 milligram (mg)/day for 7 days before Period 1 Day 1 (1 serving of coffee is approximately equivalent to 120 mg of caffeine). Has diabetes with a glycosylated hemoglobin greater than 7.5 percent (%).