-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Description
Before opening, please confirm:
- I have searched for duplicate or closed issues and discussions.
- I have read the guide for submitting bug reports.
- I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.
JavaScript Framework
React Native
Amplify APIs
Authentication
Amplify Version
v6
Amplify Categories
auth
Backend
Amplify CLI
Environment information
System:
OS: Windows 11 10.0.22631
CPU: (12) x64 11th Gen Intel(R) Core(TM) i5-11400H @ 2.70GHz
Memory: 16.82 GB / 39.73 GB
Binaries:
Node: 18.17.0 - C:\Program Files\nodejs\node.EXE
Yarn: 1.22.19 - C:\Program Files (x86)\Yarn\bin\yarn.CMD
npm: 2.15.12 - ~\Desktop\Renz\Programming\Projects\random-chat-app-repos\meant\node_modules\.bin\npm.CMD
Browsers:
Edge: Chromium (127.0.2651.74)
Internet Explorer: 11.0.22621.3527
npmPackages:
@aws-amplify/auth: ^6.0.12 => 6.3.0
@aws-amplify/auth/cognito: undefined ()
@aws-amplify/auth/cognito/server: undefined ()
@aws-amplify/auth/enable-oauth-listener: undefined ()
@aws-amplify/auth/server: undefined ()
@aws-amplify/datastore-storage-adapter: ^2.0.40 => 2.1.32
@aws-amplify/react-native: ^1.0.28 => 1.1.0
@aws-amplify/rtn-web-browser: ^1.1.1 => 1.1.1
@aws-sdk/client-gamelift: ^3.556.0 => 3.572.0
@aws-sdk/client-s3: ^3.685.0 => 3.685.0
@aws-sdk/s3-presigned-post: ^3.685.0 => 3.685.0
@azure/core-asynciterator-polyfill: ^1.0.2 => 1.0.2
@babel/core: ^7.24.0 => 7.24.5
@expo/vector-icons: ^13.0.0 => 13.0.0
@gorhom/bottom-sheet: ^4.6.4 => 4.6.4
@miblanchard/react-native-slider: ^2.6.0 => 2.6.0
@ptomasroos/react-native-multi-slider: ^2.2.2 => 2.2.2
@react-native-async-storage/async-storage: 1.18.2 => 1.18.2
@react-native-community/datetimepicker: 7.2.0 => 7.2.0
@react-native-community/netinfo: ^9.3.10 => 9.3.10
@react-native-community/slider: ^4.5.2 => 4.5.2
@react-native-picker/picker: 2.4.10 => 2.4.10
@react-navigation/native: ^6.0.2 => 6.1.17
@shopify/flash-list: 1.4.3 => 1.4.3
@shopify/react-native-skia: 0.1.196 => 0.1.196
@types/react: ~18.2.79 => 18.2.79
@zamplyy/react-native-nice-avatar: ^1.1.2 => 1.1.2
HelloWorld: 0.0.1
aws-amplify: ^6.0.27 => 6.3.0
aws-amplify/adapter-core: undefined ()
aws-amplify/analytics: undefined ()
aws-amplify/analytics/kinesis: undefined ()
aws-amplify/analytics/kinesis-firehose: undefined ()
aws-amplify/analytics/personalize: undefined ()
aws-amplify/analytics/pinpoint: undefined ()
aws-amplify/api: undefined ()
aws-amplify/api/server: undefined ()
aws-amplify/auth: undefined ()
aws-amplify/auth/cognito: undefined ()
aws-amplify/auth/cognito/server: undefined ()
aws-amplify/auth/enable-oauth-listener: undefined ()
aws-amplify/auth/server: undefined ()
aws-amplify/data: undefined ()
aws-amplify/data/server: undefined ()
aws-amplify/datastore: undefined ()
aws-amplify/in-app-messaging: undefined ()
aws-amplify/in-app-messaging/pinpoint: undefined ()
aws-amplify/push-notifications: undefined ()
aws-amplify/push-notifications/pinpoint: undefined ()
aws-amplify/storage: undefined ()
aws-amplify/storage/s3: undefined ()
aws-amplify/storage/s3/server: undefined ()
aws-amplify/storage/server: undefined ()
aws-amplify/utils: undefined ()
babel-plugin-module-resolver: ^5.0.0 => 5.0.2
benchmark-uuid: undefined ()
expo: ^49.0.3 => 49.0.3
expo-blur: ~12.4.1 => 12.4.1
expo-build-properties: ~0.8.3 => 0.8.3
expo-clipboard: ^7.0.0 => 7.0.0
expo-file-system: ~15.4.5 => 15.4.5
expo-font: ~11.4.0 => 11.4.0
expo-haptics: ~12.4.0 => 12.4.0
expo-image: ~1.3.5 => 1.3.5
expo-image-manipulator: ~11.3.0 => 11.3.0
expo-image-picker: ~14.3.2 => 14.3.2
expo-linear-gradient: ~12.3.0 => 12.3.0
expo-linking: ~5.0.2 => 5.0.2
expo-location: ^17.0.1 => 17.0.1
expo-media-library: ~15.4.1 => 15.4.1
expo-router: ^2.0.0 => 2.0.15
expo-secure-store: ~12.3.1 => 12.3.1
expo-splash-screen: ~0.20.5 => 0.20.5
expo-sqlite: ~11.3.3 => 11.3.3
expo-status-bar: ~1.6.0 => 1.6.0
expo-system-ui: ~2.4.0 => 2.4.0
expo-video: ^1.2.7 => 1.2.7
expo-web-browser: ~12.3.2 => 12.3.2
firebase: ^10.7.1 => 10.11.1
firebase/analytics: undefined ()
firebase/app: undefined ()
firebase/app-check: undefined ()
firebase/auth: undefined ()
firebase/auth/cordova: undefined ()
firebase/auth/web-extension: undefined ()
firebase/compat: undefined ()
firebase/compat/analytics: undefined ()
firebase/compat/app: undefined ()
firebase/compat/app-check: undefined ()
firebase/compat/auth: undefined ()
firebase/compat/database: undefined ()
firebase/compat/firestore: undefined ()
firebase/compat/functions: undefined ()
firebase/compat/installations: undefined ()
firebase/compat/messaging: undefined ()
firebase/compat/performance: undefined ()
firebase/compat/remote-config: undefined ()
firebase/compat/storage: undefined ()
firebase/database: undefined ()
firebase/firestore: undefined ()
firebase/firestore/lite: undefined ()
firebase/functions: undefined ()
firebase/installations: undefined ()
firebase/messaging: undefined ()
firebase/messaging/sw: undefined ()
firebase/performance: undefined ()
firebase/remote-config: undefined ()
firebase/storage: undefined ()
jest: ^29.2.1 => 29.7.0
jest-expo: ~49.0.0 => 49.0.0
latest: ^0.2.0 => 0.2.0
lodash: ^4.17.21 => 4.17.21 (4.17.4, 3.10.1)
lottie-react-native: 5.1.6 => 5.1.6
metro-react-native-babel-preset: ^0.77.0 => 0.77.0 (0.76.8)
moment: ^2.30.1 => 2.30.1
moti: ^0.29.0 => 0.29.0
nativewind: ^2.0.11 => 2.0.11
pullstate: ^1.25.0 => 1.25.0
react: 18.2.0 => 18.2.0
react-dom: 18.2.0 => 18.2.0 (16.14.0)
react-native: 0.72.10 => 0.72.10
react-native-animatable: ^1.4.0 => 1.4.0 (1.3.3)
react-native-animated-pagination-dots: ^0.1.43 => 0.1.73
react-native-compressor: ^1.9.0 => 1.9.0
react-native-context-menu-view: ^1.16.0 => 1.16.0
react-native-countdown-circle-timer: ^3.2.1 => 3.2.1
react-native-deck-swiper: ^2.0.16 => 2.0.17
react-native-drag-sort: ^2.4.4 => 2.4.4
react-native-element-dropdown: ^2.12.1 => 2.12.1
react-native-flash-message: ^0.4.2 => 0.4.2
react-native-gesture-handler: ~2.12.0 => 2.12.1
react-native-get-random-values: ~1.9.0 => 1.9.0
react-native-international-phone-number: ^0.7.5 => 0.7.6
react-native-modal: ^13.0.1 => 13.0.1
react-native-modalfy: ^3.5.3 => 3.5.3
react-native-pager-view: 6.2.0 => 6.2.0
react-native-phone-number-input: ^2.1.0 => 2.1.0
react-native-progress: ^5.0.1 => 5.0.1
react-native-reanimated: ^3.3.0 => 3.3.0
react-native-recaptcha-that-works: ^2.0.0 => 2.0.0
react-native-redash: ^18.1.3 => 18.1.3 (12.6.1)
react-native-safe-area-context: 4.6.3 => 4.6.3
react-native-screens: ~3.22.0 => 3.22.1
react-native-shadow-2: ^7.0.8 => 7.0.8
react-native-sqlite-storage: ^6.0.1 => 6.0.1
react-native-svg: 13.9.0 => 13.9.0
react-native-ui-lib: ^7.20.3 => 7.21.2
react-native-url-polyfill: ^2.0.0 => 2.0.0
react-native-video: ^6.7.0 => 6.7.0
react-native-virtualized-view: ^1.0.0 => 1.0.0
react-native-web: ~0.19.10 => 0.19.11 (0.9.13)
react-native-webview: 13.2.2 => 13.2.2
react-native-wheel-pick: ^1.2.0 => 1.2.2
react-test-renderer: 18.2.0 => 18.2.0
tailwindcss: 3.3.2 => 3.3.2
typescript: ^5.1.3 => 5.4.5
uilib-native: 4.1.3
uuid: ^11.0.3 => 11.0.3 (9.0.1, 8.3.2, 3.1.0, 2.0.3, 3.4.0, 7.0.3)
web-streams-polyfill: ^4.0.0 => 4.0.0
zustand: ^4.5.2 => 4.5.2
npmGlobalPackages:
@aws-amplify/cli: 12.10.1
eas-cli: 9.0.0
expo-cli: 6.3.10
nextui-cli: 0.2.1
node: 18.17.0
nodemon: 2.0.22
npm: 9.8.1
wscat: 5.2.0
Describe the bug
I'm encountering an issue while trying to implement Google Sign-In using AWS Amplify in my Expo Go app. When I use await signInWithRedirect({ provider: 'Google' })
, I get the following error: [OAuthNotConfigureException: oauth param not configured.]
Here’s what my amplifyconfiguration.json looks like:
{
"aws_project_region": "us-east-1",
"aws_cognito_identity_pool_id": "{hidden}",
"aws_cognito_region": "us-east-1",
"aws_user_pools_id": "{hidden}",
"aws_user_pools_web_client_id": "{hidden}",
"oauth": {
"domain": "us-east-1{hidden}.auth.us-east-1.amazoncognito.com"
},
"federationTarget": "COGNITO_IDENTITY_POOLS",
"aws_cognito_username_attributes": [
"EMAIL"
],
"aws_cognito_social_providers": [
"GOOGLE"
],
"aws_cognito_signup_attributes": [],
"aws_cognito_mfa_configuration": "OFF",
"aws_cognito_mfa_types": [],
"aws_cognito_password_protection_settings": {
"passwordPolicyMinLength": 8,
"passwordPolicyCharacters": [
"REQUIRES_LOWERCASE",
"REQUIRES_UPPERCASE",
"REQUIRES_NUMBERS",
"REQUIRES_SYMBOLS"
]
},
"aws_cognito_verification_mechanisms": [
"EMAIL",
"PHONE_NUMBER"
]
}
Expected behavior
After following everything from https://docs.amplify.aws/gen1/react-native/build-a-backend/auth/add-social-provider/ I expect the Hosted UI to show up.
Reproduction steps
Do every step here: https://docs.amplify.aws/gen1/react-native/build-a-backend/auth/add-social-provider/
-
Set-up social auth provider (Google)
-
Set-up Cognito on AWS Console
- User Pool
- Application Type: Single-Page Application (SPA)
- Options for sign-in identifiers: Email and Phone Number
- Required Attributes: None
- App Client
- Identity Providers: Cognito User Pool and Google
- OAuth 2.0 Grant Types: Authorization Code Grant and Implicit Grant
- Authentication Flows: Only ALLOW_CUSTOM_AUTH
- OpenID Connect Scopes: Email, OpenID, Phone
- Federated Identity Provider Sign-in
- Google
- Authorized Scopes: profile email openid
- Attribute Mapping: email (email) and username (sub)
- Google
- Identity Pool
- User Access: Authenticated Access and Guest Access
- Authenticated Identity Sources: Amazon Cognito User Pool and Google
Other else are using the default values.
- User Pool
-
Configure Auth Category
- amplify import auth
- Cognito User Pool and Identity Pool
- amplify push
- amplify import auth
-
Going back to Google Developer Console (console.cloud.google.com) -> APIs & Services -> Credentials
- Add corresponding domains to
Authorized Javascript Origins
andAuthorized Redirect URIs
- Add corresponding domains to
-
Installed
npm install @aws-amplify/rtn-web-browser
-
Run the app in Expo Go
Code Snippet
// Put your code below this line.
Log output
// Put your logs below this line
aws-exports.js
/* eslint-disable */
// WARNING: DO NOT EDIT. This file is automatically generated by AWS Amplify. It will be overwritten.
const awsmobile = {
"aws_project_region": "us-east-1",
"aws_cognito_identity_pool_id": "{hidden}",
"aws_cognito_region": "us-east-1",
"aws_user_pools_id": "{hidden}",
"aws_user_pools_web_client_id": "{hidden}",
"oauth": {
"domain": "us-east-1{hidden}.auth.us-east-1.amazoncognito.com"
},
"federationTarget": "COGNITO_IDENTITY_POOLS",
"aws_cognito_username_attributes": [
"EMAIL"
],
"aws_cognito_social_providers": [
"GOOGLE"
],
"aws_cognito_signup_attributes": [],
"aws_cognito_mfa_configuration": "OFF",
"aws_cognito_mfa_types": [],
"aws_cognito_password_protection_settings": {
"passwordPolicyMinLength": 8,
"passwordPolicyCharacters": [
"REQUIRES_LOWERCASE",
"REQUIRES_UPPERCASE",
"REQUIRES_NUMBERS",
"REQUIRES_SYMBOLS"
]
},
"aws_cognito_verification_mechanisms": [
"EMAIL",
"PHONE_NUMBER"
]
};
export default awsmobile;
Manual configuration
No response
Additional configuration
No response
Mobile Device
iPhone X
Mobile Operating System
No response
Mobile Browser
No response
Mobile Browser Version
No response
Additional information and screenshots
No response