Follow Discord
Sweep 20 Nov 2026 · 19:55Z Build v2.1.330 547 read Stable v2.1.323 Latest v2.1.330 Next v2.1.330 Feeds RSS JSON llms.txt llms-full.txt Unofficial
One capture · claude-docs

One read of Claude Documentationclaude-docs-20261122T180705Z

1 pages moved out of 297 read.

Pages moved 1 significant first
Pages read 297 in this capture
Captured 18:07 UTC
Corpus hash 64c38db2f2ab corpus-hash

What this read moved

1-1 of 1

third-party/claude-desktop/gateway Changed · +22 / -11 lines

from line 57
5757 
5858**2. Configure your gateway to validate the token**
5959 
60Tell your gateway to accept the bearer token only if it was issued by your tenant **for this application**. In LiteLLM that looks like:
60Tell your gateway to accept the bearer token only if it was issued by your tenant **for this application**.
6161 
62In LiteLLM, this setup requires a LiteLLM Enterprise license, a database, and a master key. For the full configuration, see LiteLLM's [JWT-based Auth](https://docs.litellm.ai/docs/proxy/token_auth) guide. Merge these settings into your LiteLLM `config.yaml`:
63 
6264```yaml theme={null}
65environment_variables:
66 JWT_PUBLIC_KEY_URL: https://login.microsoftonline.com/YOUR_TENANT_ID/discovery/v2.0/keys
67 JWT_AUDIENCE: YOUR_CLIENT_ID
68 JWT_ISSUER: https://login.microsoftonline.com/YOUR_TENANT_ID/v2.0
69 
6370general_settings:
71 enable_jwt_auth: true
6472 litellm_jwtauth:
65 public_key_url: https://login.microsoftonline.com/YOUR_TENANT_ID/discovery/v2.0/keys
66 audience: YOUR_CLIENT_ID
6773 user_id_jwt_field: oid
6874```
6975 
70Replace `YOUR_TENANT_ID` and `YOUR_CLIENT_ID` with the values from step 1.
76Replace `YOUR_TENANT_ID` and `YOUR_CLIENT_ID` with the values from step 1. Set `JWT_ISSUER` to the `iss` claim of the token your gateway receives. By default the app sends an ID token, and its `iss` is the **Issuer URL** you enter in the next step.
7177 
78LiteLLM rejects a user who has no LiteLLM user record. Create each record with the user's `oid` value as its user ID. To create records automatically at first sign-in, see [Map users at the gateway](#map-users-at-the-gateway).
79 
7280> [!WARNING]
7381>
74> The `audience` line is required. Without it, your gateway accepts tokens issued to any application in your tenant, not just this one.
82> The `JWT_AUDIENCE` line is required. Without it, your gateway accepts tokens issued to any application in your tenant, not just this one.
7583 
76For Kong, Envoy, or Azure API Management, configure the equivalent JWT validation policy with the same JWKS URL and audience.
84For Kong, Envoy, or Azure API Management, configure the equivalent JWT validation policy with the same JWKS URL, audience, and issuer.
7785 
7886**3. Configure in the app**
7987 
from line 117
109117>
110118> Use the **issuer** value, not the **Metadata URI**. Okta's admin console shows the metadata URI (ending in `/.well-known/openid-configuration`) prominently — that is the discovery document the app fetches *from* the issuer, not the issuer itself. If you are unsure, open the metadata URI in a browser and copy the `"issuer"` field from the JSON response. For a custom Okta authorization server the issuer is `https://YOUR_ORG.okta.com/oauth2/AUTH_SERVER_ID`.
111119 
112Point your gateway's JWT validation at `https://YOUR_ORG.okta.com/oauth2/v1/keys` with `audience` set to the Okta client ID.
120Point your gateway's JWT validation at `https://YOUR_ORG.okta.com/oauth2/v1/keys`, or for a custom authorization server, at the `jwks_uri` value from its metadata document. Set the audience to the Okta client ID and the issuer to your **Issuer URL**. In LiteLLM, also set `user_id_jwt_field` to `sub`.
113121 
114122#### Map users at the gateway
115123 
from line 130
122130| Entra ID | `oid` |
123131| Okta and most other OIDC providers | `sub` |
124132 
125If your gateway has no existing user records to preserve, the simplest setup is to auto-provision on first sign-in. For LiteLLM, extend the validation block from step 2:
133If your gateway has no existing user records to preserve, the simplest setup is to auto-provision on first sign-in. For LiteLLM, add `user_email_jwt_field` and `user_id_upsert` to the validation block from step 2. With the values from [Using Okta instead](#using-okta-instead), the block looks like this:
126134 
127135```yaml theme={null}
136environment_variables:
137 JWT_PUBLIC_KEY_URL: https://YOUR_ORG.okta.com/oauth2/v1/keys
138 JWT_AUDIENCE: YOUR_CLIENT_ID
139 JWT_ISSUER: https://YOUR_ORG.okta.com
140 
128141general_settings:
129142 enable_jwt_auth: true
130143 litellm_jwtauth:
131 public_key_url: https://YOUR_ORG.okta.com/oauth2/v1/keys
132 audience: YOUR_CLIENT_ID
133144 user_id_jwt_field: sub # use "oid" for Entra ID
134145 user_email_jwt_field: email
135146 user_id_upsert: true
Feedback