feat(auth): implement linkIdentity with OIDC #776
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.
What kind of change does this PR introduce?
Feature - implements identity linking functionality using OpenID Connect credentials.
What is the current behavior?
Currently, the Swift Auth client only supports signing in with OIDC credentials but doesn't provide a way to link additional identities to an existing user account using OIDC.
What is the new behavior?
linkIdentityWithIdToken
method toAuthClient
that allows linking an OIDC identity to the current usersignInWithIdToken
method to support both sign-in and identity linking flows through an internal_signInWithIdToken
helperlinkIdentity
property toOpenIDConnectCredentials
to distinguish between sign-in and linking operationsThe new method follows the same pattern as other identity linking methods in the client.
Additional context
This implements the OIDC identity linking functionality referenced in the branch name (clibs-283). The implementation maintains backward compatibility while adding the new linking capability.
Close #588
🤖 Generated with Claude Code