diff --git a/docs/deployments/deploy-expo.mdx b/docs/deployments/deploy-expo.mdx index f3d9bf8750..59b5571fdf 100644 --- a/docs/deployments/deploy-expo.mdx +++ b/docs/deployments/deploy-expo.mdx @@ -17,11 +17,21 @@ Clerk ensures that security critical nonces will be passed only to allowlisted U So for maximum security in your production instances, you need to allowlist your custom redirect URLs: -1. Navigate to the [Clerk Dashboard](https://dashboard.clerk.com/last-active?path=user-authentication/sso-connections). -1. In the top navigation, select **Configure**. Then in the sidebar, select **SSO Connections**. +1. In the Clerk Dashboard, navigate to the [**SSO Connections**](https://dashboard.clerk.com/last-active?path=user-authentication/sso-connections) page. 1. Scroll to the **Allowlist for mobile OAuth redirect** section and add your redirect URLs. - 1. The default is `your-app-scheme://oauth-native-callback` - 1. If you'd like to pass a custom redirect url, make sure you add that to the allowlist. + 1. The default is `://oauth-native-callback` + 1. If you'd like to pass a custom redirect URL, make sure you add that to the allowlist. The format is `/{PATH}`. For example, the redirect URL for the following code example is `myapp://dashboard`. + ```ts + const { startOAuthFlow } = useOAuth({ strategy: `oauth_apple` }) + + const onPress = React.useCallback(async () => { + const { createdSessionId, setActive } = await startOAuthFlow({ + redirectUrl: Linking.createURL('dashboard', { scheme: 'myapp' }), + }) + + // The rest of your code... + }, []) + ``` > [!TIP] > You can also add redirect URLs via [the Backend API](/docs/reference/backend-api/tag/Redirect-URLs#operation/CreateRedirectURL).