This content is likely not relevant anymore. Try searching or browse recent questions.
Hi, m newbie with google API and stuck into a typical situation.
I am building a php based centralized admin area where admin can see all his business locations, reviews, ratings etc.
I am building a php based centralized admin area where admin can see all his business locations, reviews, ratings etc.
I am using google-api-php-client and some-how I manage to install it with composer. the login pert went well and i have successfully store user token to DB (for future access).
} }else{ $client->setRedirectUri($URL.'social_report.php?tab=gp'); if(isset($_GET['code']) && $_GET['code']!="" ){ $client->authenticate($_GET['code']); $_SESSION['google_access_token'] = $client->getAccessToken(); @mysql_query("UPDATE `user` SET `user_gp_token`='".$_SESSION['google_access_token']."' WHERE `user_id`='".$_SESSION["user_id"]."'; "); ?> <script> window.location="<?=$URL.'social_report.php?tab=gp'?>"; </script> <?php }else{ $auth_url = $client->createAuthUrl(); ?> <div class="row text-center" style="margin:80px 0px;"> <a href="<?=$auth_url?>"> <img src="img/sign-in-google.png" alt="Google Login" /> </a> </div> <?php }
And, it successfully accessing "google_feeds.php".
FYI, Above code is working and asking permission for all four Scopes ( 'auth/books' is used for testing ans it is working and returning data). Project ID approved for MyBusiness API access from google end.
Now, in google_feeds.php I am trying to call the "Google_Service_Mybusiness", for that purpose i downloaded 'google-api-services-mybusiness-v3-php-rev-20160505-1' from GIT and paste the 'Mybusiness.php' to 'google_sdk/vendor/google/apiclient/src/Google/Service/'.
Please check the 'google_feeds.php':
And it is Catching the error:
Error calling GET https://www.googleapis.com/v3/accounts?key=AIzaSyDo4h3OjOcUImlqC0iPUYOK68ZQmZvGjiE: (404) Not Found
Also, I have tried with 'https://developers.google.com/oauthplayground/' but it also returning error:
{
"error": {
"status": "NOT_FOUND",
"message": "Method not found.",
"code": 404
}
}Please let me know what i am missing here. Thank you for your time and patience.
Details
Link to post
Delete post?
This will remove the reply from the Answers section.
Notifications are off
Your notifications are currently off and you won't receive subscription updates. To turn them on, go to Notifications preferences on your Profile page.