fix: OAuth credentials invisible in Configure connection modal#4506
Merged
midigofrank merged 3 commits intomainfrom Mar 9, 2026
Merged
fix: OAuth credentials invisible in Configure connection modal#4506midigofrank merged 3 commits intomainfrom
midigofrank merged 3 commits intomainfrom
Conversation
OAuth credentials set their schema to "oauth" instead of the adaptor name (e.g., "salesforce"). The backend needs this for token lifecycle management. But the Configure connection modal filtered credentials by matching schema against the adaptor name, so "oauth" !== "salesforce" failed silently. There was a fuzzy fallback matching oauth_client_name against the adaptor name, but if the name didn't contain the adaptor name (or was null), the credential fell through every filter and became invisible. Fix: treat unmatched OAuth credentials as universal (like HTTP and raw) so they appear in "Other Credentials" instead of vanishing.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #4506 +/- ##
==========================================
- Coverage 89.55% 89.54% -0.01%
==========================================
Files 425 425
Lines 20295 20295
==========================================
- Hits 18175 18173 -2
- Misses 2120 2122 +2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
midigofrank
approved these changes
Mar 9, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR fixes a bug where OAuth credentials created in the collaborative editor don't appear in the "Configure connection" modal.
The root cause: OAuth credentials have
schema: "oauth"(needed by the backend for token lifecycle management), so they fail the adaptor-name matching filter (c.schema === adaptorName). There's a "smart matching" fallback that fuzzy-matches theoauth_client_nameagainst the adaptor name, but when the client name doesn't contain the adaptor name (e.g., "Corporate SSO Provider" for a Salesforce job) or is null, the credential falls through all filter sections and becomes invisible.The fix treats OAuth credentials the same as
httpandraw— as universal credentials that appear in the "Other Credentials" section when they don't match by name. OAuth credentials that do match by name still appear in the primary "Matching Credentials" section as before.Closes #4499
Validation steps
cd assets && npm test -- --run ConfigureAdaptorModal— all 52 tests pass (3 new)Additional notes for the reviewer
source_schemacolumn to credentials so the backend can track both the auth type and the original adaptor affinity. However, this adds migration overhead and thesource_schemacould go stale if users change the adaptor. The universal-fallback approach is simpler and covers all cases.normalizeStringhelper was also moved outside the filter callback to avoid re-creating it on every iteration — minor cleanup, no behavior change.AI Usage
Pre-submission checklist
/reviewwith Claude Code)
(e.g.,
:owner,:admin,:editor,:viewer)