I'm having some problems with zabbixAPI on symfony5(using confirm-it-solutions/php-zabbix-api lib with php8) and im recieving this error: Warning: Undefined property: ZabbixApi\ZabbixApi::$authToken and to be honest i have no idea whats wrong, after trying using like getHosts or almost big part of them im getting this error. After using getApiUrl im getting data.
class ZabbixController
{
/**
* @Route (path="zabbix",name="zabbix_worker")
* @return Response
*/
function zabbixGraph(): Response
{
$zabbixUrl = 'url';
$zabbixUser = 'user';
$zabbixPassword = 'passwd';
$zabbixData = [$zabbixUrl,$zabbixUser, $zabbixPassword];
try {
$api = new ZabbixApi($zabbixData);
} catch (Exception $e) {
echo $e->getMessage();
}
$GetGraphId = $api->graphGet(array(
'output' => 'extend',
'filter' => array('host' =>'abros'),
'search' => array('name' => 'Network traffic on')
));
echo($GetGraphId);
return new Response($GetGraphId);
}}
here's screen of my error Huge thanks for any kind of help/clue/anything