> ## Documentation Index
> Fetch the complete documentation index at: https://developer.suki.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Visit Context

> Pass visit type, encounter setting, reason for visit, and chief complaint with `kVisitContext`

Visit context lets you describe the type and purpose of the encounter so Suki can structure the note for that visit and care setting.

Pass `SukiAmbientConstant.kVisitContext` in `setSessionContext(with:)` after you create the session. All fields are optional.

<ResponseField name="SukiAmbientConstant.kVisitContext" type="dictionary" required={false}>
  Use this parameter to provide visit-related metadata that provides context about the type and purpose of the encounter.

  <Expandable title="properties" defaultOpen={true}>
    <ResponseField name="SukiAmbientConstant.kVisitType" type="string" required={false}>
      The type of patient visit. Valid values: "New Patient / Intake", "Established patient", "Wellness", "ED". This helps format notes appropriately for the visit type.
    </ResponseField>

    <ResponseField name="SukiAmbientConstant.kEncounterType" type="string" required={false}>
      The setting where the encounter occurs. Valid values: "ambulatory", "inpatient", "ED". This helps structure notes for the appropriate care setting.
    </ResponseField>

    <ResponseField name="SukiAmbientConstant.kReasonForVisit" type="string" required={false}>
      A free-text description explaining why the patient is visiting. Maximum 255 characters. This helps focus the note on the primary reason for the visit.
    </ResponseField>

    <ResponseField name="SukiAmbientConstant.kChiefComplaint" type="string" required={false}>
      The patient's primary complaint or concern. Maximum 255 characters. This helps structure the note's chief complaint section.
    </ResponseField>
  </Expandable>
</ResponseField>

**Code example**:

```swift Swift theme={"theme":{"light":"one-light","dark":"material-theme-darker"}}
do {
    let contextDetail: [String: AnyHashable] = [
        SukiAmbientConstant.kVisitContext: [
            SukiAmbientConstant.kVisitType: "ESTABLISHED_PATIENT", // Optional: NEW_PATIENT, ESTABLISHED_PATIENT, WELLNESS, ED
            SukiAmbientConstant.kEncounterType: "AMBULATORY", // Optional: ambulatory, inpatient, ED
            SukiAmbientConstant.kReasonForVisit: "Annual checkup", // Optional: String, max 255 characters
            SukiAmbientConstant.kChiefComplaint: "Routine follow-up" // Optional: String, max 255 characters
        ]
    ]

    try SukiAmbientCoreManager.shared.setSessionContext(with: contextDetail) { result in
        switch result {
        case .success:
            print("Context updated successfully")
        case .failure(let error):
            print("Error updating context: \(error)")
        }
    }
} catch {
    print(error)
}
```

## Next steps

<Icon icon="file-lines" iconType="solid" /> **[Provide clinical context](/mobile-sdk/ambient-guides/provide-clinical-context)** - Full `setSessionContext` overview and combined example.

<Icon icon="file-lines" iconType="solid" /> **[EMR info](/mobile-sdk/ambient-guides/emr-info)** - Identify which EMR applies to the session.

<Icon icon="file-lines" iconType="solid" /> **[Recording controls](/mobile-sdk/ambient-guides/recording)** - Start, pause, and resume recording.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.