Refresh social connections overview page#3236
Open
SarahSoutoul wants to merge 14 commits intomainfrom
Open
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
# Conflicts: # docs/guides/configure/auth-strategies/social-connections/overview.mdx
Removes the invalid `js-backend` SDK and the duplicate `expressjs` from the social connections overview frontmatter (unblocking the build), adds `expo` to the SDK list, and fixes a `/references/backend/` typo in the Astro example. Adds `see [all providers]` cross-links to the `Sign in with OAuth` and `Sign up with OAuth` sections in the native-mobile auth references, matching the existing pattern used elsewhere in those docs. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Splits the intro into web and native variants so iOS/Android readers see guidance about prebuilt views and the Clerk SDK instead of prebuilt components and the Clerk API. Consolidates "Add a social connection after sign-up" and "Connecting to social providers while signed in" into a single section with SDK-gated closing guidance that points web readers to `<UserProfile />` and native readers to `UserProfileView`. Removes a stale claim that prebuilt components aren't supported in native applications, and unifies anchor text on "build a custom OAuth flow" to match the destination page title. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Splits the combined `<If notSdk>` block so each post-sign-up section can be gated independently, then adds an iOS-only section showing how to request additional OAuth scopes via `prepareReauthorization` and `reauthorize` on an existing `ExternalAccount`. Android currently has no equivalent — `CreateExternalAccountParams` and `ExternalAccount.reauthorize()` don't accept scope parameters — so no Android section is added. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Renames "OAuth for native applications" to "Allowlist OAuth redirect URLs" and "OAuth for Apple native applications" to "Sign in with Apple" so the two no longer read as near-duplicates. Splits the enclosing `<If>` so Sign in with Apple is gated to `ios` only, not `ios + android`. Adds a parallel Android "Sign in with Google" section that links to the dedicated native-flow guide, and switches the Apple section's link to its dedicated `sign-in-with-apple` guide for parity. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Rewords the production-instances self-link to target the supported providers list directly, tightens the "Add a social connection after sign-up" example into a single sentence, unifies SDK array ordering on `["ios", "android"]`, and tightens the Sign in with Apple and Sign in with Google prose (correct terminology for ID token / authorization code, active voice, and a link to Android's Credential Manager docs). Adds a missing `return` before `res.status(401).json(...)` in the Express tab so the handler stops executing on auth/token failures. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Guards `clerkResponse.data[0].token` with optional chaining across all six backend tabs so the "Access token not found" branch is reachable when the user hasn't connected the provider. Fixes the Next.js tab returning HTTP 200 for unauthenticated requests (comment says the route is protected). Removes an undefined `json()` call in the React Router tab and returns a plain object instead, which is the correct React Router v7 loader pattern. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Switches the React Router tab to import `clerkClient` and `getAuth` from `@clerk/react-router/server` (the `ssr.server` path is deprecated) and uses `clerkClient(args)` from the request context instead of instantiating with a secret key. Changes the React Router and TanStack React Start tabs to return 401 for unauthenticated requests, matching the other tabs and the standard status for an auth failure (was 404). Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Replaces the programmatic `prepareReauthorization` + `reauthorize` example with the `.userProfileOAuthConfig(_:)` modifier on `UserProfileView` and `UserButton`, which is the direct iOS parallel to the web section's `additionalOAuthScopes` prop on `<UserProfile />` and `<UserButton />`. Matches the web section's component-tab structure. Custom-flow guidance is already covered by the page's existing "build a custom OAuth flow" links. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
swolfand
approved these changes
Apr 24, 2026
seanperez29
approved these changes
Apr 24, 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.
🔎 Previews:
What does this solve? What changed?
The social connections overview was written primarily for web SDKs, but social connections are now supported in the iOS and Android SDKs too. This PR refreshes the page so it reads well for every SDK, adds missing iOS/Android equivalents, and defers to the quickstarts for setup that's already covered elsewhere.
Multi-SDK rewrite
<TutorialHero>and added ansdk:frontmatter entry covering web, iOS, Android, and Expo<UserProfile />, native points at prebuilt views andUserProfileViewNew native content
.userProfileOAuthConfig(_:)modifier onUserProfileViewandUserButton, mirroring the web section'sadditionalOAuthScopesprop pattern<If>gate on Sign in with Apple so it's iOS-only (was incorrectly gated to iOS + Android)Cross-references
see [all providers]inline cross-links to theSign in with OAuthandSign up with OAuthsections indocs/reference/native-mobile/auth.mdxandauth.ios.mdx, matching the existing pattern used elsewhere in those files (per this discussion)manifest.jsonto group "Overview", "Sign in with Apple", and "Sign in with Google" under a new "Social connections" heading in the iOS/Android navsign-in-with-appleguide, for parity with the new Google sectionDrive-by fixes
js-backendSDK and a duplicateexpressjsfrom the overview frontmatter (was breaking the Vercel build), and corrected a/references/backend/→/reference/backend/typo in the Astro examplereturnstatements to the Express tab'sres.status(401).json(...)calls so the handler stops on auth/token failuresclerkResponse.data[0].tokenwith optional chaining across all six backend tabs so the "Access token not found" branch is reachable when the user hasn't connected the provider404to401for auth failures, matching the other tabsclerkClientandgetAuthfrom@clerk/react-router/server(thessr.serverpath is deprecated) and useclerkClient(args)from the request context instead of a statically-instantiated clientjson()call in the React Router tab and returned the plain object (correct React Router v7 loader pattern)Known gaps
CreateExternalAccountParamshas no scopes field,ExternalAccount.reauthorize()takes no parameters, and the Android UI has noOAuthConfigequivalent to iOS's.userProfileOAuthConfig(_:). Adding a section here would promise a feature that doesn't exist; this is an SDK gap, not a doc gap.@clerk/backendtab as-is. Broadening the gate raises a larger question about "which SDK owns server-side guidance" that's outside this ticket.expois in thesdk:frontmatter but the<If notSdk={["ios","android"]}>gates keep web content visible for Expo.@clerk/exposupports the web-style prebuilt components referenced, so the guidance isn't wrong. A fuller Expo-specific pass (includingexpo/native-components/pointers) is out of scope here.Deadline
No rush
Other resources