{ "error" : "invalid_request", "error_description" : "Missing required parameter: code"}

3,301 views
Skip to first unread message

Keyur Eragon

unread,
May 1, 2015, 4:58:23 PM5/1/15
to adwor...@googlegroups.com
Hello

i am follow https://developers.google.com/adwords/api/docs/guides/authentication step
but i am getting below error

Log in to your AdWords account and open the following URL: https://accounts.google.com/o/oauth2/auth?response_type=code&client_id=1064417969718-shu697uugo1nvnc281ffd3tc3kg7c3t2.apps.googleusercontent.com&redirect_uri=urn%3Aietf%3Awg%3Aoauth%3A2.0%3Aoob&scope=https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fadwords&access_type=offline After approving the token enter the authorization code here: Your OAuth2 Credentials are incorrect. Please see the GetRefreshToken.php example. { "error" : "invalid_request", "error_description" : "Missing required parameter: code" }

i am set the  client_id  and client_secret in auth.ini

Josh Radcliff (AdWords API Team)

unread,
May 1, 2015, 5:01:01 PM5/1/15
to adwor...@googlegroups.com
Hi,

All examples in the PHP libraries (including the GetRefreshToken.php example) should be run from the command line. In particular, the GetRefreshToken example writes a URL for you to follow to stdout, and then reads the authorization code you type in from stdin.

Please try running the example from the command line and let me know if you still encounter issues.

Thanks,
Josh, AdWords API Team
Reply all
Reply to author
Forward
0 new messages