google-api-php-client icon indicating copy to clipboard operation
google-api-php-client copied to clipboard

PAGINATION - Next page token is always null ?

Open minhvb opened this issue 1 year ago • 0 comments

Hi team,

I'm using your library to fetch reviews from Play Store and reply to them, however, the getTokenPagination() function always return null. I'm not sure which part I was wrong.

Below is my code

$listReviews = $this->getGoogleService()->reviews->listReviews( $this->googleConfig->name, $opt, ); dd($listReviews->getTokenPagination());

And this is the way I get the service:

    try {
        $client = new Google_Client();
        $client->setAuthConfig(json_decode($this->googleConfig->json, true));
    } catch (Throwable $e) {
        LoggerUtils::logError($this->logger, $e, 'Failed to create Google client');

        throw $e;
    }

    $client->addScope(Google_Service_AndroidPublisher::ANDROIDPUBLISHER);
    $this->service = new Google_Service_AndroidPublisher($client);

    return $this->service;

minhvb avatar Mar 01 '24 11:03 minhvb