Skip to content

feat: enhance OIDC configuration handling and discovery process#1848

Open
paustint wants to merge 1 commit into
mainfrom
feat/improve-oidc-form-setup
Open

feat: enhance OIDC configuration handling and discovery process#1848
paustint wants to merge 1 commit into
mainfrom
feat/improve-oidc-form-setup

Conversation

@paustint

@paustint paustint commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

No description provided.

Copilot AI review requested due to automatic review settings July 7, 2026 15:56

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR shifts OIDC endpoint discovery from an explicit client “auto-discover” action to an authoritative server-side discovery step during OIDC config save (and emphasizes re-discovery during login), while improving the SSO configuration UX and adding regression tests.

Changes:

  • Remove the client/API “OIDC discover” endpoint and instead resolve IdP endpoints server-side at save time.
  • Update the Teams UI and docs to reflect that endpoints are discovered automatically when saving (plus inline error surfacing in the modal).
  • Add unit + e2e regression tests ensuring OIDC config saves successfully when the client omits endpoint fields.

Reviewed changes

Copilot reviewed 13 out of 13 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
libs/shared/data/src/lib/client-data.ts Removes client helper for OIDC discovery POST call.
libs/features/teams/src/lib/TeamDashboard/sso-configuration/ConfigureSsoOidcForm.tsx Removes “Auto-Discover Endpoints” UX and makes endpoints informational/read-only.
libs/features/teams/src/lib/TeamDashboard/sso-configuration/ConfigureSsoModal.tsx Adds persistent inline save error display and clears it on provider changes.
libs/auth/types/src/lib/auth-types.ts Makes OIDC endpoint fields optional/nullish on the save-request schema.
libs/auth/types/src/lib/tests/auth-types.spec.ts Adds schema regression tests covering omitted/null endpoints and URL validation.
apps/jetstream-e2e/src/tests/authentication/team/sso/sso-oidc-config-save.api.spec.ts Adds e2e test verifying server discovers/persists endpoints when client omits them.
apps/docs/docs/team-management/sso/sso-okta.mdx Updates Okta setup instructions to reflect save-time discovery + “Fetch Metadata” wording.
apps/docs/docs/team-management/sso/sso-google.mdx Updates Google setup instructions to reflect save-time discovery.
apps/docs/docs/team-management/sso/sso-generic.mdx Updates generic OIDC docs to reflect save-time discovery from discovery document.
apps/docs/docs/team-management/sso/sso-azure.mdx Updates Azure setup instructions to reflect save-time discovery.
apps/api/src/app/routes/team.routes.ts Removes the /:teamId/sso/oidc/discover route.
apps/api/src/app/db/team.db.ts Tightens DB-layer OIDC save signature to require discovered non-null endpoint fields.
apps/api/src/app/controllers/team.controller.ts Performs OIDC discovery during save, enforces SSRF guard in prod, and uses UserFacingError for key validation failures.

Comment thread apps/api/src/app/controllers/team.controller.ts
Comment thread apps/api/src/app/controllers/team.controller.ts
Comment thread libs/auth/types/src/lib/auth-types.ts Outdated
Copilot AI review requested due to automatic review settings July 9, 2026 14:02
@paustint paustint force-pushed the feat/improve-oidc-form-setup branch from 915f479 to 1b1b6b0 Compare July 9, 2026 14:02

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 13 out of 13 changed files in this pull request and generated 1 comment.

Comment on lines +1292 to +1293
// The IdP endpoints are non-nullable columns resolved from OIDC discovery by the controller, so
// they are required here even though they are optional on the wire request.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants