46 lines
2.1 KiB
PHP
46 lines
2.1 KiB
PHP
<?php
|
|
header('Content-Type:application/json');
|
|
set_time_limit(600);
|
|
$ts=date('c');$r=[];$base='https://weval-consulting.com';
|
|
|
|
function t($url,$name,$min=100){
|
|
$ch=curl_init($url);
|
|
curl_setopt_array($ch,[CURLOPT_RETURNTRANSFER=>1,CURLOPT_TIMEOUT=>8,CURLOPT_SSL_VERIFYPEER=>0,CURLOPT_FOLLOWLOCATION=>1]);
|
|
$body=curl_exec($ch);$code=curl_getinfo($ch,CURLINFO_HTTP_CODE);curl_close($ch);
|
|
return['n'=>$name,'c'=>$code,'s'=>strlen($body),'ok'=>$code>=200&&$code<400&&strlen($body)>$min];
|
|
}
|
|
|
|
// ALL HTML pages
|
|
foreach(glob('/var/www/html/*.html') as $f){
|
|
$n=basename($f);$r[]=t("$base/$n","pg:$n",200);
|
|
}
|
|
// ALL product pages
|
|
foreach(glob('/var/www/html/products/*.html') as $f){
|
|
$n=basename($f);$r[]=t("$base/products/$n","prod:$n",100);
|
|
}
|
|
// Key API endpoints (GET-safe only)
|
|
$apis=['ecosystem-health.php','agents-status.php','agents-catalog.php','nonreg-api.php?cat=summary',
|
|
'architecture-scanner.php','aegis-api.php','crm-api.php','ads-commander-api.php',
|
|
'wevia-master-autoheal.php','wevia-deep-test.php','agents-full-count.php','execution-map.json',
|
|
'l99-functional-test.php','architecture-autofix.php','blade-agent.php?k=BLADE2026&action=status'];
|
|
foreach($apis as $a){$r[]=t("$base/api/$a","api:$a",5);}
|
|
// Special dirs
|
|
$r[]=t("$base/wevads-ia/",'dir:wevads-ia',5000);
|
|
$r[]=t("$base/login",'dir:login',200);
|
|
// Subdomains
|
|
$subs=['crm','deerflow','paperclip','analytics','mm','monitor','n8n','mirofish','langfuse'];
|
|
foreach($subs as $s){$r[]=t("https://$s.weval-consulting.com","sub:$s",50);}
|
|
// Chat providers direct
|
|
$providers=[
|
|
['https://api.groq.com/openai/v1/models','prov:groq'],
|
|
['https://api.cerebras.ai/v1/models','prov:cerebras'],
|
|
['https://integrate.api.nvidia.com/v1/models','prov:nvidia'],
|
|
];
|
|
foreach($providers as $p){$r[]=t($p[0],$p[1],20);}
|
|
|
|
$pass=count(array_filter($r,fn($x)=>$x['ok']));$total=count($r);
|
|
$pct=$total>0?round(100*$pass/$total):0;
|
|
$fails=array_values(array_filter($r,fn($x)=>!$x['ok']));
|
|
file_put_contents('/var/log/l99-mega.log',"[$ts] $pass/$total ($pct%)\n",FILE_APPEND);
|
|
echo json_encode(['ts'=>$ts,'total'=>$total,'pass'=>$pass,'fail'=>count($fails),'pct'=>$pct,'fails'=>$fails]);
|