Console error reading inputParams googleClientId, facebookAppId
See original GitHub issueDescribe the bug
Build using - amplifyPush --environment $AWS_BRANCH in amplify.yml generates Error: auth headless init is missing the following inputParams googleClientId, facebookAppId while working with amplify push using amplify CLI.
To Reproduce Steps to reproduce the behavior:
- Using Amplify Console define backend build steps
version: 0.9
backend:
phases:
preBuild:
commands:
# Test Get Amplify CLI Cloud-Formation stack info from environment cache
- export STACKINFO="$(envCache --get stackInfo)"
build:
commands:
- echo "printing env"
- env
# Execute Amplify CLI with the helper script
- amplifyPush --environment $AWS_BRANCH
postBuild:
commands:
# Store Amplify CLI CloudFormation stack info in environment cache
- envCache --set stackInfo "$(amplify env get --json --name $AWS_BRANCH)"
- Define in googleClientId and facebookAppId amplify/team-provider-info.json
{
"prod": {
"categories": {
"auth": {
"Cognito": {
"facebookAppId": "xxxx",
"googleClientId": "xxxxx"
}
}
}
}
}
git pushto kick the build process- the build logs indicates:
# Executing command: amplifyPush --environment master
2019-01-06T02:59:10.121Z [INFO]: # Start initializing Amplify environment: master
2019-01-06T02:59:10.124Z [INFO]: # Initializing new Amplify environment: master (amplify init)
....
2019-01-06T01:59:24.985Z [WARNING]: ✔ Successfully created initial AWS cloud resources for deployments.
2019-01-06T01:59:25.123Z [WARNING]: - Initializing your environment: master
2019-01-06T01:59:25.125Z [WARNING]: ✔ Initialized provider successfully.
2019-01-06T01:59:25.134Z [WARNING]: ✖ There was an error initializing your environment.
2019-01-06T01:59:25.134Z [INFO]: init failed
2019-01-06T01:59:25.137Z [INFO]: Error: auth headless init is missing the following inputParams googleClientId, facebookAppId
at updateConfigOnEnvInit (/root/.nvm/versions/node/v8.12.0/lib/node_modules/@aws-amplify/cli/node_modules/amplify-category-auth/provider-utils/awscloudformation/index.js:237:15)
at /root/.nvm/versions/node/v8.12.0/lib/node_modules/@aws-amplify/cli/node_modules/amplify-category-auth/index.js:200:28
at /root/.nvm/versions/node/v8.12.0/lib/node_modules/@aws-amplify/cli/node_modules/promise-sequential/index.js:16:18
at <anonymous>
at process._tickDomainCallback (internal/process/next_tick.js:229:7)
2019-01-06T01:59:25.142Z [ERROR]: !!! Build failed
2019-01-06T01:59:25.142Z [ERROR]: !!! Non-Zero Exit Code detected
-
I also tried to populate the keys using Amplify Console Environment variables with:
googleClientIdandprod.categories.auth.Cognito. googleClientIdas well as populatingFACEBOOK_APP_IDandGOOGLE_CLIENT_IDper https://github.com/aws-amplify/amplify-cli/issues/572 without help -
When executing
amplify pushusing CLI the error does not occuring
Expected behavior Succesfull build
You can turn on the debug mode to provide more info for us by setting window.LOG_LEVEL = ‘DEBUG’; in your app.
Issue Analytics
- State:
- Created 5 years ago
- Comments:7 (1 by maintainers)

Top Related StackOverflow Question
Hi,
I’m getting exactly the same error. Let me know if you might find a resolution for this issue.
Thanks, Dan
This issue has been automatically locked since there hasn’t been any recent activity after it was closed. Please open a new issue for related bugs.
Looking for a help forum? We recommend joining the Amplify Community Discord server
*-helpchannels or Discussions for those types of questions.