Questions tagged [google-php-sdk]
43 questions
4
votes
2 answers
Changing event start date from "date" to "dateTime"
I am trying to patch an existing event with new start and end date using the Google API Explorer
So my event at the moment looks like this
{
"kind": "calendar#event",
"etag": "\"2912997881756000\"",
"id": "3fpkrr85sdfdgsdfsdsdflgn7vk74qhiv2o",
…

Optimus
- 1,703
- 4
- 22
- 41
3
votes
2 answers
Google API: How to increase access token expiration date?
Google API expiration date is 1 hour, the problem is that I'm using the API in order allow users to use admin SDK features (List groups, add members to a group etc.)
No one can do any of that in one hour, that would require users to login to their…

Lynob
- 5,059
- 15
- 64
- 114
3
votes
3 answers
Google Oauth2 authentication takes about 15 seconds
I am using google-php-api for authentication.
this takes most of the time just under 6 seconds,
$client->authenticate($code);
this takes most of the time about 3 seconds,
$token = $client->getAccessToken();
this takes most of the time just under 6…

kak3n
- 71
- 1
- 7
3
votes
1 answer
Google login API: force to type password?
I'm using several social providers on my site, including Google. I would like to ask for password to Google account each time user requests one of my actions. This is for security reasons.
With Facebook, we can send auth_type=reauthenticate…

Robo Robok
- 21,132
- 17
- 68
- 126
2
votes
1 answer
Google Analytics Reporting API - Get Activity data via Client ID
I am trying to get user activity data via his client id using Google Analytics api. Take a look at the below image:
Now highlighted text is users client id, it could be user id too, and when I trying to get it via Google's playground, I get the…

Alexa Martin
- 85
- 5
2
votes
2 answers
Google App Engine PHP, Couldn't resolve host
Tonight we started getting curl errors with Google App Engine involved in resolving hostnames that are many including google.
Error: "Couldn't resolve host 'maps.google.com'" - Code: 6
Yes, Billing is enabled, and this has been working for months…

keoir
- 429
- 1
- 5
- 12
2
votes
2 answers
Google+ scope PLUS.LOGIN not asking for Google Circle Connection permission
I am trying to get Google+ connections that are visible.
by referring to documentation https://developers.google.com/+/web/samples/php,
it is clear that on adding 'plus.login' scope fetches G+ connections, age range and language.
But in my case this…

Gunnrryy
- 350
- 1
- 5
- 17
2
votes
1 answer
Filter by country
I want get all regions for a country from my Google Analytics account. I wrote the below code to get all regions:
$metrics = 'ga:visits';
$dimensions = 'ga:country=$iso,ga:region,ga:regionId';
$ga = $this->getGa();
$gaResponse =…

ramiromd
- 2,019
- 8
- 33
- 62
2
votes
1 answer
google app script function does not return form response
in google app script i write following code to read response from google forms
function formResponse()
{
var form = FormApp.openById('form-id');
var formResponses = form.getResponses();
for (var i = 0; i < formResponses.length; i++)
…

Kalyanakannan padivasu
- 685
- 1
- 6
- 19
2
votes
0 answers
How to validate Google App ID and App Secret?
I'm using Google SDK to make some flows automatic. The user provides his own application ID and secret, then logs in.
How can I check whether Google Application ID and Application Secret are valid?

Robo Robok
- 21,132
- 17
- 68
- 126
1
vote
4 answers
"Login with Google" in PHP - Google+ API shutdown migration - how to migrate away from plus.people.get?
I got a warning email from Google reminding me of Google+'s EOL which is supposed to break my current "Login with Google", but I am unsure what exactly should I change.
Let me show you my (simplified) login code:
google-login.php
new class {
…

The Onin
- 5,068
- 2
- 38
- 55
1
vote
0 answers
silently failing to push images to user's Google Drive via PHP SDK
I am making an open source application where a user can backup their facebook albums to google drive using PHP SDK. I am done with the facebook part and now stuck with google's awfully written documentation. So here is how I am working with is step…

sameer manek
- 735
- 1
- 11
- 34
1
vote
0 answers
Fatal error: Uncaught Error: Class 'Google_client' not found despite adding library through composer
Getting error Fatal error: Uncaught Error: Class 'Google_client' not found.
Using php -v 7.1.21
Installed google api php client via composer using
composer require google/apiclient:"^2.0"
Using
require 'vendor/autoload.php';
to include…

user3286746
- 21
- 2
1
vote
1 answer
Getting 400 bad request error on google Talent Solutions api - symfony 4
On implementation of google Talent solutions API, I am getting this error,
{
"error": {
"code": 400,
"message": "Creation request should not have name set.. Request ID for tracking:…

Jason
- 661
- 5
- 17
1
vote
1 answer
Upload File to Teamdrives with Drive API and PHP
I want to upload files to my teamdrive but it fail. Upload to my drive works.
I call the function with a local file, array with folder id in my Teamdrive and the Team Drive ID.
$service a Google_Service_Drive Object and $client a Google_Client
I use…

yannik995
- 307
- 1
- 12