php - Google Calendar API - Daily Limit for Unauthenticated Use Exceeded. Continued use requires signup -


i'm using google calendar api , when tried use freebusy, got error. follow post in stackoverflow error it's not work me. please help

public function index() {     session_start();     if (isset($_session['access_token']) && $_session['access_token']) {         $client = new google_client();         $client->setauthconfig('client_secret.json');         $client->addscope(google_service_calendar::calendar);          $client->setaccesstype("offline");        // offline access         $client->setincludegrantedscopes(true);   // incremental auth          $guzzleclient = new \guzzlehttp\client(array('curl' => array(curlopt_ssl_verifypeer => false)));         $client->sethttpclient($guzzleclient);          $cal = new google_service_calendar($client);         $freebusy_req = new google_service_calendar_freebusyrequest();         $freebusy_req->settimemin(date(datetime::atom, strtotime('2017-05-01t08:00:00.000z')));         $freebusy_req->settimemax(date(datetime::atom, strtotime('2017-05-19t17:00:00.000z')));         $freebusy_req->settimezone('europe/london');         $freebusy_req->setcalendarexpansionmax(10);         $freebusy_req->setgroupexpansionmax(10);          $item = new google_service_calendar_freebusyrequestitem();         $item->setid('primary');         $freebusy_req->setitems(array($item));           $query = $cal->freebusy->query($freebusy_req);         $response_calendar = $query->getcalendars();         dd($query);     } else {         return redirect()->route('oauthcallback');     } } 

when tried dd($query), got error:

 (1/1) google_service_exception  { "error": { "errors": [ { "domain": "usagelimits", "reason": "dailylimitexceededunreg", "message": "daily limit unauthenticated use exceeded. continued use requires signup.", "extendedhelp": "https://code.google.com/apis/console" } ], "code": 403, "message": "daily limit unauthenticated use exceeded. continued use requires signup." } } 

please help.


Comments

Popular posts from this blog

ubuntu - PHP script to find files of certain extensions in a directory, returns populated array when run in browser, but empty array when run from terminal -

php - How can i create a user dashboard -

javascript - How to detect toggling of the fullscreen-toolbar in jQuery Mobile? -