Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error : This identity pool does not support the specified developer provider

I am getting error when I try to execute command to for get developer identity. I have system which contain login with facebook and custom registration/login along with aws.

Here the steps I am following.

1) Register : If user is not available then I register user and create identity.

2) Pass the identity have got from getId to getOpenIdTokenForDeveloperIdentity() function and authenticate user by developer identity.

Here is my code snippet.

$GetIdentiyLib = AWS::get('CognitoIdentity');
                $result = $GetIdentiyLib->getId(array(
                    'AccountId' => 'xxxxx',
                    // IdentityPoolId is required
                    'IdentityPoolId' => 'xxxxxx',
                ));                

                $resultIdentity = $GetIdentiyLib->getOpenIdTokenForDeveloperIdentity(array(
                    // IdentityPoolId is required
                    'IdentityPoolId' => 'xxxxxx',
                    'IdentityId' => $result['IdentityId'],
                    // Logins is required
                    'Logins' => array(
                        // Associative array of custom 'IdentityProviderName' key names
                        'login.app' => 'custom',
                    // ... repeated
                    ),
                    'TokenDuration' => 1200,
                ));

When run getOpenIdTokenForDeveloperIdentity function I am getting error "This identity pool does not support the specified developer provider."

can anyone suggest me the possible cause for error?? Thank in advance,

like image 641
Bhargav Bhanderi Avatar asked Feb 08 '23 08:02

Bhargav Bhanderi


1 Answers

That exception is thrown for one of two reasons:

  • You haven't configured your identity pool for developer authenticated identities.
  • The provider name you have linked to your pool isn't the exact one you are giving to the request.

If you never set up your identity pool to manage this, you can do so via the Cognito console. Go to the pool in question, edit the pool, and configure it there. If you have, then it's likely that the provider name doesn't quite match what you setup the pool with.

like image 76
Jeff Bailey Avatar answered Feb 12 '23 11:02

Jeff Bailey