prtg-cli

CLI for PRTG Network Monitor
Installation
$ pip3 install --user --upgrade prtg-cli
Setup
For communication with PRTG, use options or set the PRTG_HOST, PRTG_USERNAME, (PRTG_PASSWORD or PRTG_PASSHASH) environment variables
Usage
$ prtg-cli
Usage: prtg-cli [OPTIONS] COMMAND [ARGS]...
Options:
--host TEXT Host of the PRTG
--username TEXT Username of the PRTG
--password TEXT Password of the PRTG
--passhash TEXT Passhash of the PRTG
--help Show this message and exit.
Commands:
duplicate
get
object
passhash
prtg_version
sensor_types
status
version
Suggestions
- Please use a unique name for
probes,groupsanddeviceson PRTG
Examples
Information
### Get all probes
$ prtg-cli get probes
### Get all groups
$ prtg-cli get groups
### Get specific group
$ prtg-cli get groups <GROUP_NAME>
### Get all devices
$ prtg-cli get devices
### Get specific device
$ prtg-cli get devices <DEVICE_NAME>
Duplication
### Duplicate a group
$ prtg-cli duplicate group --source <Source_Group> --target <Target_Group> --target-name <New_Group_Name>
### Duplicate a device
$ prtg-cli duplicate device --source <Source_Device> --target-group <Target_Group> --target-name <New_Device_Name> --target-host <New_Device_Host>
Object Manipulation
### Scan a object
$ prtg-cli object --state scan --resource devices --item <DEVICE_NAME>
### Resume a object
$ prtg-cli object --state resume --resource devices --item <DEVICE_NAME>
### Stop a object
$ prtg-cli object --state stop --resource devices --item <DEVICE_NAME>
### Delete a object
$ prtg-cli object --state delete --resource devices --item <DEVICE_NAME>
Example of Adding Multiple Devices With Config File
$ cat example.yml
# Device Name
clone: PROD_RABBITMQ_CLUSTER
# Target Group
group: PRTG_CLI
devices:
- name: CHECKOUT_RMQ_CLUSTER_01
host: 10.0.20.32
- name: CHECKOUT_RMQ_CLUSTER_02
host: 10.0.20.33
$ prtg-cli manager --config-file example.yml
- Create new 'CHECKOUT_RMQ_CLUSTER_01' device
- Create new 'CHECKOUT_RMQ_CLUSTER_02' device
Credits
Thank you for offering fabulous, amazing, incredible rest api at PRTG, it is very nice. :)
Metadata
Release files for prtg-cli 0.2.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| prtg-cli-0.2.1.tar.gz | 19.3 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| prtg_cli-0.2.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 39.9 kB
Release files / prtg-cli-0.2.1.tar.gz
| Download URL | prtg-cli-0.2.1.tar.gz |
|---|---|
| Size | 19.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9fcbf1e78127305fd4f1a697a89d6c923b4a03fdcbb52bfe418402209461f398
|
|
BLAKE2b-256 checksum How to use checksums |
9689ac88142cea3df27d57387f25192fcf8c6363dd3a51f500ca6dac69498d4c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/0.12.17 CPython/3.7.4 Darwin/19.0.0
|
Release files / prtg_cli-0.2.1-py3-none-any.whl
| Download URL | prtg_cli-0.2.1-py3-none-any.whl |
|---|---|
| Size | 20.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ed850ca889025430ebda2828b32ed90dc876415db9d0929620db4ff6e6b3b78c
|
|
BLAKE2b-256 checksum How to use checksums |
d3033ff947d63ac25397517983c6f59e303d8950437a05fcbf997f290be36574
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/0.12.17 CPython/3.7.4 Darwin/19.0.0
|
Security for prtg-cli 0.2.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.