Teevity API and CLI
To use the API or the command line tool you will need your access key. You will find your key in the preferences pages under the API section.
Teevity exposes all the features available on its web portal trough an API. The endpoints documentation is available here:
- https://api.teevity.com/light/index.html - lightweight version
- https://api.teevity.com/withSamples/index.html - complete version with samples (very large HTML page to load)
The API is based on REST services which support JSON as document formats. To authenticate you either pass the access key:
- in the query string:
- or in a header called
Command Line tool
The lastest version is available here [link pointing to our public GCS bucket].
The package contains 3 files:
- The CLI tool as a JAR file
- a shell script to invoke commands on macOS/Linux/Unix systems
- a DOS script to invoke commands on Microsoft Windows
To run the CLI you must have a Java Runtime installed (version 8 and following; tested with Java 11).
You can pass your access key as an argument or set the
TEEVITY_APIKEY environment variable
The syntax is
./teevity.sh <command> <operation> --key <TEEVITY_API_KEY> --argument <VALUE>
For example :
./teevity.sh rua get-resourceUsageAnalysis-configuration --key <TEEVITY_API_KEY>
to fetch the resources usage analysis configuration with the ID