> ## 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.

# Provider Context

> Pass specialty and provider role with `kProviderContext` in setSessionContext for specialty-aware notes

Provider context lets you tell Suki which specialty and role apply to the encounter so generated notes follow the right clinical conventions.

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

<ResponseField name="SukiAmbientConstant.kProviderContext" type="dictionary" required={false}>
  Use this parameter to provide information about the healthcare provider to tailor note generation to your specialty and role.

  <Expandable title="properties" defaultOpen={true}>
    <ResponseField name="SukiAmbientConstant.kSpeciality" type="string" required={false}>
      The provider's medical specialty (e.g., "FAMILY\_MEDICINE", "CARDIOLOGY"). This helps format notes according to your specialty's conventions.
    </ResponseField>

    <ResponseField name="SukiAmbientConstant.kProviderRole" type="string" required={false}>
      The provider's role in the encounter. Valid values: "Primary/Attending" or "Consulting". This helps distinguish between primary care providers and consulting specialists.
    </ResponseField>
  </Expandable>
</ResponseField>

**Code example**:

```swift Swift theme={"theme":{"light":"one-light","dark":"material-theme-darker"}}
do {
    let contextDetail: [String: AnyHashable] = [
        SukiAmbientConstant.kProviderContext: [
            SukiAmbientConstant.kSpeciality: "FAMILY_MEDICINE",
            SukiAmbientConstant.kProviderRole: "PRIMARY/ATTENDING" // Optional: PRIMARY/ATTENDING or CONSULTING
        ]
    ]

    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" /> **[Visit context](/mobile-sdk/ambient-guides/visit-context)** - Pass visit type, encounter setting, and reason for visit.

<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.