Am trying to connect the twiiter account through HybridAuth am getting this error “Expecting a non-null oauth_token to continue the authorization flow” Please check and let me know

This sounds like a HybridAuth specific error - it’s hard to tell what can be wrong without having the exact endpoint called and parameters used, and the Twitter API response. I’m guessing the oauth token is missing or not loaded correctly somehow.

oauth token not loading .How can pass the parameters oauth token in HybridAuth and let me know how to fix the problem
please find the code snaps

$config = [
‘callback’ => $this->siteConfigs[‘clienturl’] . ‘/myprofile/socialConnect’,
‘enabled’ => true,
‘keys’ => [ ‘key’ => ‘’, ‘secret’ => ‘’ ], // OAuth1 uses ‘key’ not ‘id’
‘scope’ => ‘full’
];
$hybridauth = new Hybridauth($config);
$authProvider = $hybridauth->authenticate(‘Twitter’);

this looks like the line:

‘keys’ => [ ‘key’ => ‘’, ‘secret’ => ‘’ ], // OAuth1 uses ‘key’ not ‘id’

I assume where it’s key they want the Consumer Key, and secret they want the Consumer Secret. They are left blank for you to define.

‘keys’ => [ ‘key’ => ‘’, ‘secret’ => ‘’ ], i have given the consumer key and secret when am calling Api.
this is the syntax am fallowing in this syntax how to pass the Oauth tocken value

In that case, if you’re providing the keys correctly and there’s nothing wrong with the environment, it might be something specific to how Hybridauth is doing things - something in that PHP code i guess.

How to fix the issue?

It looks like there’s an existing issue open against the library.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.