Python3 module to interact with UptimeRobot API.
pip install upytimerobot==0.2.1
Python3 module to interact with UptimeRobot API
To get the latest stable release from PyPi
$ pip install upytimerobot
To get the latest commit from GitLab
$ pip install -e git+git://gitlab.com/fboaventura/upytimerobot.git#egg=uptimerobot
Use with Python:
>>> from upytimerobot import UptimeRobot
>>> up = UptimeRobot(api_key=UPTIME_ROBOT_API_KEY)
>>> up.get_monitors()
{'stat': 'ok', 'pagination': {'offset': 0, 'limit': 1, 'total': 4}, 'monitors': [{'id': 90909090, 'friendly_name': 'my_monitor', 'url': '127.0.0.1', 'type': 3, 'sub_type': '', 'keyword_type': '', 'keyword_value': '', 'http_username': '', 'http_password': '', 'port': '', 'interval': 300, 'status': 2, 'ssl': {'brand': '', 'product': None, 'expires': 0}, 'create_datetime': 1480809958}]}
Some work was made toward improving the collection of monitors by type, status, etc..
This is functional module already, one can query all the information regarding account, monitors, alert contacts, maintenance windows and public status pages.
Also, the functions are all well documented, containing all the possible parameters that can be used to each of the queries available.
Renamed some internal usage methods to differentiate from the public ones
Improved documentation on the existing methods
The importing of some libraries
.get_monitors_by_name: Changed validation if a monitor was recovered
.get_monitors_by_id: Changed validation if a monitor was recovered
The full API is documented here: https://uptimerobot.com/api