Surveil API Client Library
Project description
This is a client library for Surveil built on the Surveil API.
Command-line API
Installing this package gets you a shell command, surveil, that you can use to interact with the Surveil API.
You’ll need to provide the Surveil API URL. You can do this with the --surveil-api-url parameter, but it’s easier to just set it as environment variable:
export SURVEIL_API_URL=http://localhost:8080/v2 export SURVEIL_AUTH_URL=http://localhost:8080/v2/auth
You’ll find complete documentation on the shell by running surveil help.
Bash completion
Basic command tab completion can be enabled by sourcing the bash completion script:
source /usr/local/share/surveil.bash_completion
Python API
To use the python API, simply create a client with the endpoint:
from surveilclient import client c = client.Client('http://localhost:8080/v2', auth_url='http://localhost:8080/v2/auth', version='2_0') hosts = c.config.hosts.list()
How to use it
Config-host-update:
surveil config-host-update [host_name] --address [ADDRESS] --custom_fields '{"_field1": "value1", "_field2": "value2"}'
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
python-surveilclient-0.5.0.tar.gz
(18.7 kB
view hashes)
Built Distribution
Close
Hashes for python-surveilclient-0.5.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 65f0b684d591237d36642198d8bbed221f7fd499e3895c647a7272969a317545 |
|
MD5 | cf40dcfe59abe53eb801e03957ae2012 |
|
BLAKE2b-256 | 1667112dfe0f0170c5ad94ba4cd19ca62b49e4d7b2f77fb47eb41c9de6165cd8 |
Close
Hashes for python_surveilclient-0.5.0-py2-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a67283c4019ac335351fe5aa5d301792406470a86e7533500936ae18ee133d37 |
|
MD5 | 4a5ac3b92bfd9d907d86f917ac98c13a |
|
BLAKE2b-256 | 59036e03bdf35c2389c841ec1dcc09cba6606a027414a734baedc7eeb5dfea0d |