invalid_client: client_id parameter missing
Hi folks,
My apologies if this is not the right place for this kind of question. I have just spent the better part of the day drilling through your code and cannot for the life of me figure out what is happening. Any guidance would be appreciated.
I'm using your gem at version 2.0.8 to manage oauth access
Upon successful authentication in the 3rd party platform, I get redirected to our redirect_uri with the auth code, and right away I
1 - initialise client = Oauth2::Client.new(client_id, secret, { :site...} )
2 - call client.auth_code.get_token(code)
where code is the value I have just received back.
immediately, I get
OAuth2::Error (invalid_client: client_id parameter missing) {"error":"invalid_client","error_description":"client_id parameter missing"}
I can validate step #1 (closed) by printing client.auth_code.authorize_url
which is perfectly fine and includes the client_id.
I see that AuthCode.get_token
calls the Client.get_token
and that using the default client.options[:token_method] as :post then data will be sent along with the request. However I am assuming the gem should be passing required information (as per correct obj initialisation).
am I assuming wrong?
Any help appreciated.