Нашел, не напрямую ответ на мой первоначальный вопрос, а решение самой проблемы.
$short_url = "https://abc.app.goo.gl/12345abc";
$client = new Google_Client();
$client->addScope(Google_Service_FirebaseDynamicLinks::FIREBASE);
$client->setAuthConfig('/path/to/credentials.json');
$client->fetchAccessTokenWithAssertion();
$authorization = 'Authorization: Bearer '.$client->getAccessToken()['access_token'];
$url = "https://firebasedynamiclinks.googleapis.com/v1/".urlencode($short_url)."/linkStats?durationDays=7";
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/json' , $authorization ));
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
$ret = curl_exec($ch);
print_r($ret);
Распечатывает:
{
"linkEventStats": [
{
"count": "4",
"event": "CLICK",
"platform": "OTHER"
},
{
"count": "4",
"event": "REDIRECT",
"platform": "OTHER"
}
]
}