title: User Pools for Amazon Cognito - CredentialsError: Missing credentials in config
body: <p>I am trying to create a Web App Authentication with help of <a href="https://mobile.awsblog.com/blog/author/Ionut+Trestian" rel="noreferrer">this</a> tutorial. Here is the code I have written - </p>
  
  <pre><code>var app = {};
  
  app.configureCognito = function(){
      AWSCognito.config.region = 'us-east-1';
  
      var poolData = {
          UserPoolId: 'userPoolId',
          ClientId: 'ClientId'
      };
  
      var userPool = new AWSCognito.CognitoIdentityServiceProvider.CognitoUserPool(poolData);
      var userData = {
                      UserName:'MyName',
                      Pool: userPool
      };
  
      var attributeList = [];
  
      var dataEmail = {
              Name: 'email',
              Value: 'mailme@mydomain.com'
      };
  
      var dataPhoneNumber = {
              Name: 'phone_number',
              Value: '+9112212212212'
      };
  
      var attributeEmail = new AWSCognito.CognitoIdentityServiceProvider.CognitoUserAttribute(dataEmail);
      var attributePhoneNumber = new AWSCognito.CognitoIdentityServiceProvider.CognitoUserAttribute(dataPhoneNumber);
  
      attributeList.push(attributeEmail);
      attributeList.push(attributePhoneNumber);
  
      var cognitoUser;
  
      userPool.signUp('userName','password',attributeList,null,function(err,result){
              if(err){
                      console.log(err);
                      alert(err);
                      return;
              }
              cognitoUser = result.user;
              console.log('User Name is: '+cognitoUser);
      });
  
  };
  </code></pre>
  
  <p>I am getting the error which says "missing credential in config", I understand that we are not doing any AWSCognito.config.credentials assignment here but isn't it supposed to use the information provided in userPool object? Is there anything wrong with the code any missing piece or something? As per the UserPoolId and client id are concerned both are 100% correct. Any help would be appreciated.</p>