This is an Expo project demonstrating OAuth integration with GitHub using the Integrate SDK.
- 🔐 GitHub OAuth authentication
- 📱 React Native implementation with deep linking support
- 🔄 Real-time auth state management with event listeners
- 📊 GitHub repository listing example
- 🎨 Beautiful, modern UI with ThemedComponents
-
Install dependencies
bun install
-
Configure Deep Linking
The app uses the scheme
expoexample://for OAuth callbacks. This is already configured inapp.json:"scheme": "expoexample"
Make sure your OAuth redirect URI is set to:
expoexample://oauth/callback -
Start the app
bun start
In the output, you'll find options to open the app in a:
- User taps "Connect GitHub" button
- App calls
client.authorize('github')which opens authentication in a web browser - User completes OAuth flow in the browser
- Browser redirects back to the app with the OAuth callback
- Deep linking listener catches the callback URL:
expoexample://oauth/callback - Integrate SDK automatically handles the token exchange
- Auth state is updated via event listeners (
auth:complete)
lib/integrate.ts- Client-side Integrate SDK configurationapp/(tabs)/index.tsx- Main screen with OAuth UI and deep linking
The app uses expo-linking to handle OAuth callbacks:
const handleUrl = ({ url }: { url: string }) => {
const { path, queryParams } = Linking.parse(url);
if (path === 'oauth/callback') {
// Handle OAuth callback
console.log('OAuth callback:', queryParams);
}
};
Linking.addEventListener('url', handleUrl);