Integrate with ChatGPT
Support level: Community
What is ChatGPT
ChatGPT is OpenAI's conversational AI platform that provides chat-based assistance across the web and desktop applications.
Preparation
The following placeholders are used in this guide:
authentik.companyis the FQDN of the authentik installation.
This documentation lists only the settings that you need to change from their default values. Be aware that any changes other than those explicitly mentioned in this guide could cause issues accessing your application.
ChatGPT only enables the Manage SSO wizard after you verify ownership of your domain in the ChatGPT admin console. Domain verification is outside the scope of this guide.
Configuration methods
You can configure ChatGPT to use either OIDC or SAML; this guide explains both options.
- Log in with OIDC
 - Log in with SAML
 
authentik configuration
To support the integration of ChatGPT with authentik, you need to create an application/provider pair in authentik.
Create an application and provider in authentik
- 
Log in to authentik as an administrator and open the authentik Admin interface.
 - 
Navigate to Applications > Applications and click Create with Provider to create an application and provider pair. (Alternatively you can first create a provider separately, then create the application and connect it with the provider.)
- Application: provide a descriptive name, an optional group for the type of application, the policy engine mode, and optional UI settings.
 - Choose a Provider type: select OAuth2/OpenID Connect as the provider type.
 - Configure the Provider: provide a name (or accept the auto-provided name), the authorization flow to use for this provider, and the following required configurations.
- Note the Client ID, Client Secret, and slug values because they will be required later.
 - Temporarily set a 
Strictredirect URI tohttps://temp.temp. - Select any available signing key.
 
 - Configure Bindings (optional): you can create a binding (policy, group, or user) to manage the listing and access to applications on a user's My applications page.
 
 - 
Click Submit to save the new application and provider.
 
ChatGPT configuration
- Log in to ChatGPT as an administrator and go to the identity page.
 - Under Identity Management, choose Manage SSO, then select Custom OIDC as the single sign-on method.
 - Complete the Custom OIDC wizard:
- Provide an Identity Provider Name: enter a descriptive name (for example, 
authentik). - Create an Application: copy the Login redirect URI that ChatGPT displays.
 - Add Claims: confirm ChatGPT lists the required claims (
sub,email,given_name, andfamily_name). These are provided by authentik's default OIDC property mappings when theemailandprofilescopes are enabled. - Provide your OIDC Configuration:
- Client ID: enter the client ID from authentik.
 - Client Secret: enter the client secret from authentik.
 - Discovery endpoint: 
https://authentik.company/application/o/<application_slug>/.well-known/openid-configuration 
 - Configure Application Link: review the direct sign-in link that ChatGPT generates; share it with users if needed.
 - Test Single Sign-On: run the built-in test. ChatGPT should redirect you to authentik for authentication and report success.
 
 - Provide an Identity Provider Name: enter a descriptive name (for example, 
 
Reconfigure authentik provider
- Log in to authentik as an administrator and open the authentik Admin interface.
 - Navigate to Applications > Providers and click the Edit icon of the newly created ChatGPT provider.
 - Under Protocol settings, set the Redirect URIs to the Login redirect URI from ChatGPT.
 - Click Update.
 
authentik configuration
To support the integration of ChatGPT with authentik, you need to create an application/provider pair in authentik.
Create an application and provider in authentik
- 
Log in to authentik as an administrator and open the authentik Admin interface.
 - 
Navigate to Applications > Applications and click Create with Provider to create an application and provider pair. (Alternatively you can first create a provider separately, then create the application and connect it with the provider.)
- Application: provide a descriptive name, an optional group for the type of application, the policy engine mode, and optional UI settings. Take note of the slug as it will be required later.
 - Choose a Provider type: select SAML Provider as the provider type.
 - Configure the Provider: provide a name (or accept the auto-provided name), the authorization flow to use for this provider, and the following required configurations.
- Temporarily set the ACS URL to 
https://temp.temp(you will update this after completing the ChatGPT configuration). - Under Advanced protocol settings, set Signing Certificate to use any available certificate.
 
 - Temporarily set the ACS URL to 
 - Configure Bindings (optional): you can create a binding (policy, group, or user) to manage the listing and access to applications on a user's My applications page.
 
 - 
Click Submit to save the new application and provider.
 
Download certificate file
- Log in to authentik as an administrator and open the authentik Admin interface.
 - Navigate to Applications > Providers and click on the name of the provider that you created in the previous section.
 - Under Related objects > Download signing certificate, click on Download. This downloaded file is your certificate file and it will be required in the next section.
 
ChatGPT configuration
- Log in to ChatGPT as an administrator and go to the identity page.
 - Under Identity Management, choose Manage SSO, then select Custom SAML as the single sign-on method.
 - Complete the Custom SAML wizard:
- Provide an Identity Provider Name: enter a descriptive name (for example, 
authentik). - Provide your SAML Configuration:
- Entity ID: 
authentik - Sign-in URL: 
https://authentik.company/application/saml/<application_slug>/sso/binding/redirect/ - Sign-out URL: 
https://authentik.company/application/saml/<application_slug>/slo/binding/redirect/ - X.509 Certificate: paste the contents of your certificate file.
 
 - Entity ID: 
 - Create an Application: copy the ACS URL and Audience values that ChatGPT displays.
 - Configure Application Link: review the direct sign-in link that ChatGPT generates; share it with users if needed.
 - Test Single Sign-On: run the built-in test. ChatGPT should redirect you to authentik for authentication and report success.
 
 - Provide an Identity Provider Name: enter a descriptive name (for example, 
 
Reconfigure authentik provider
- Log in to authentik as an administrator and open the authentik Admin interface.
 - Navigate to Applications > Providers and click the Edit icon of the newly created ChatGPT provider.
 - Under Protocol settings, set the following required configurations:
- ACS URL: set to the ACS URL from ChatGPT.
 - Audience: set to the Audience from ChatGPT.
 
 - Click Update.
 
Configuration verification
To verify that authentik is correctly integrated with ChatGPT, log out, then attempt to log back in by entering your email address under Email address and clicking Continue. You should be redirected to authentik and upon a successful login, redirected back to ChatGPT.