idk-tn / yii2-google-apiclient

A Yii2 wrapper for the official Google API PHP Client
MIT License
7 stars 3 forks source link

Invalid request error when trying to configure the scope #2

Closed gitmasta closed 6 years ago

gitmasta commented 6 years ago

Hello, when i got in configuration and try to choose the scopes i want it give me a url i had to open in my browser so i get a verification code but the problem is when i open the given url it doesnt open

i chosed the following scope : https://www.googleapis.com/auth/drive and get that url :

https://accounts.google.com/o/oauth2/auth?response_type=code&redirect_uri=&client_id=xxxxxx.apps.googleusercontent.com&scope=https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fdrive&access_type=offline&approval_prompt=auto

but it give me an invalid_request error

machour commented 6 years ago

The error mention "redirect_url" being empty, which should not be.

When creating your OAuth client id, if you're using application type "Web Application", then you must provide an URL where you will be redirected once authenticated.

If you don't need that, pick Other in the choice list:

screen shot 2017-11-30 at 1 03 33 pm
machour commented 6 years ago

I will gladly accept a PR with some documentation :)

machour commented 6 years ago

Closing this as no feedback was provided. Feel free to re-open this issue if the problem remains unsolved.