nerdbaggy / StatusPage

Public Status Page for UptimeRobot
http://projects.spencerl.com/statuspage/
MIT License
240 stars 61 forks source link

API version 2 #47

Open TomasHurtz opened 7 years ago

TomasHurtz commented 7 years ago

How could we upgrade the API implemented to version 2 ?

TomasHurtz commented 7 years ago

https://blog.uptimerobot.com/apiv2-is-ready-to-use-apiv1-will-be-retired-on-1-june-2017/

TheModernFlash commented 7 years ago

Does API 1 currently work for you?

TomasHurtz commented 7 years ago

Yes - the default install currently works fine for me - but what will happen when API v1 is retired?

TheModernFlash commented 7 years ago

I was just wondering because API1 setup isn't working for me. You can see it at https://themodernflash.com/statuspage. P.S. Someone on here has created a statuspage.php file that is compatible with API2.

TomasHurtz commented 7 years ago

not seen any api v2 reference - please elaborate.

edit - ah yes, now I see it here: https://github.com/nerdbaggy/StatusPage/issues/44

RE your page - is it vanilla instal ? If so, must be something on your server.

TheModernFlash commented 7 years ago

What build are you using and what info did you have to change? I'm just gonna start all the way over, but I want to know what steps I need to take to make sure I do it correctly. Also, I'm glad you found it.

TomasHurtz commented 7 years ago

I used public version here https://github.com/nerdbaggy/StatusPage/archive/v3.zip

I did not change anything - just add my API in config and it work for me.

TheModernFlash commented 7 years ago

Which folder do I use or do I put that entire folder in the webserver? If I paste the entire folder in to my webserver, where is the location of the config file I need to change?

TomasHurtz commented 7 years ago

I upload only the "build" folder to a hosting account on a server, then renamed the build folder to e.g. uptimestatus

Put uploaded folder in your public_html/ - example, in the root directory where your website index file is.

Then, modify config file to add your API key (get API key from UR settings page). Config file is in /build/statuspage/config.php

Save config file back to server then visit the statuspage index file via web browser.

Example, if you rename the "build" folder with uptimestatus, then point URL to yourdomain.com/uptimestatus/index.html

It should work.

solaceten commented 1 year ago

Anyone else still using this? It was good but now getting errors with phpfastcache

solaceten commented 1 year ago

OK - i found a fix for the PHP 8 issues:

In checks.php change the following:

$checks = $statusPage->getChecks ($_GET['action']));

to become:

if ($statusPage->getChecks ($_GET['action']) !== null){

    $checks = $statusPage->getChecks($_GET['action']);
    echo $statusPage->padIt(array('headers' => $tableHeaders, 'checks' => $checks));
} else {

    $checks = '';
    echo 'none';
}

Would be amazing to see this project updated... but I'm not a developer sadly.