---
title: "Fetch SDK configuration"
method: GET
path: "/sdk/config"
tags: ["Configuration"]
---

# Fetch SDK configuration

`GET /sdk/config`

Fetch auth configuration for the SDK. Called by `createSunnyChat` before
establishing a WebSocket connection. Returns Auth0 domain, client ID,
token exchange URL, and other partner-specific settings needed to
activate the chosen authentication mode.

## Headers

- `x-sunny-partner-identifier` string, required
- `x-sunny-api-key` string, required

## Response `200`

SDK configuration retrieved successfully

- SdkConfigResponse
  - `config` SdkAuthConfig, required — Server-provided auth configuration. Contains only public fields — no secrets.
    - `auth0_domain` string — Auth0 tenant domain for SAML/OIDC/token-exchange flows
    - `auth0_client_id` string — Auth0 application client ID
    - `auth0_connection` string — Auth0 connection name (e.g., SAML connection identifier)
    - `audience` string — API audience for access tokens
    - `organization` string — Auth0 organization identifier
    - `token_exchange_url` string — Custom token exchange endpoint URL (used when authType is "tokenExchange")

## Other responses

- `400` — Invalid request (missing or malformed headers)
- `401` — Invalid API key or unrecognized partner

---

[API](https://skmtc.net/sunnyhealthai/apis/sunny-agents-sdk-api.md) · [All operations](https://skmtc.net/sunnyhealthai/apis/sunny-agents-sdk-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/sunnyhealthai/sunny-agents-sdk-api/versions/1a0b76588d22/schema)
