protected static function createAnalyticsClient(array $analyticsConfig, Google_Service_Analytics $googleService) : AnalyticsClient
 {
     $client = new AnalyticsClient($googleService, app(Repository::class));
     $client->setCacheLifeTimeInMinutes($analyticsConfig['cache_lifetime_in_minutes']);
     return $client;
 }
Example #2
0
 /**
  * Get the underlying Google_Service_Analytics object. You can use this
  * to basically call anything on the Google Analytics API.
  *
  * @return \Google_Service_Analytics
  */
 public function getAnalyticsService() : Google_Service_Analytics
 {
     return $this->client->getAnalyticsService();
 }