Skip to content
This repository has been archived by the owner on May 19, 2020. It is now read-only.
/ pysensu Public archive

[Unmaintained] Small python package to interact with Sensu

License

Notifications You must be signed in to change notification settings

ryndaniels/pysensu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pysensu

This is a simple python package to interact with Sensu

Installing

pip install pysensu

Example Usage

Pysensu uses the hostname and port where your sensu-api is running.

from pysensu import pysensu

client = pysensu.Pysensu("sensu.organization.com", port=4567)

# Stashes
client.create_stash('server1')
client.delete_stash('server2')
client.get_all_stashes()

# Clients
client.get_client('server1')
client.get_client_history('server1')
client.delete_client('server2')
client.get_all_clients()

# Checks
client.get_check('check_dns')
client.get_all_checks()
client.request_check('check_api_process', ['api-servers'])

# Events
client.get_all_events()
client.get_all_client_events('server1')
client.get_event('server1', 'check_dns')
client.delete_event('server1', 'check_dns')
client.resolve_event('server1', 'check_dns')

It can optionally use basic auth with or without SSL:

from pysensu import pysensu
client = pysensu.Pysensu("sensu.organization.com", port=4567, user='sensu', password='secret', ssl=True)
...

About

[Unmaintained] Small python package to interact with Sensu

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages