Command-line interface for running JetClient API requests and tests.
- Java 17 or higher
- Download the latest release from GitHub Releases (
jetclient-cli.ziporjetclient-cli.tar.gz) - Extract the archive:
# For zip unzip jetclient-cli.zip # For tar.gz tar -xzf jetclient-cli.tar.gz
- The extracted folder contains:
jetclient-cli/ ├── bin/ │ ├── jetclient # Unix/macOS launcher │ └── jetclient.bat # Windows launcher └── lib/ └── ... # JAR files
Option 1: Run directly
# Unix/macOS
./jetclient-cli/bin/jetclient --help
# Windows
jetclient-cli\bin\jetclient.bat --helpOption 2: Add to PATH (recommended)
# Unix/macOS - add to ~/.bashrc or ~/.zshrc
export PATH="$PATH:/path/to/jetclient-cli/bin"
# Windows - add to system PATH via Environment Variables
# Add: C:\path\to\jetclient-cli\binThen run from anywhere:
jetclient --helpDocker images are available on GitHub Packages.
docker pull ghcr.io/jetclient/jetclient-cli:latest# Show help
docker run --rm ghcr.io/jetclient/jetclient-cli
# Run tests (mount project directory)
docker run --rm -v $(pwd):/workspace ghcr.io/jetclient/jetclient-cli run .
# With environment
docker run --rm -v $(pwd):/workspace ghcr.io/jetclient/jetclient-cli run . -e production
# Generate report
docker run --rm -v $(pwd):/workspace ghcr.io/jetclient/jetclient-cli run . \
-r junit --reporter-out junit=./results.xmljobs:
api-tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run API tests
run: |
docker run --rm \
-v ${{ github.workspace }}:/workspace \
ghcr.io/jetclient/jetclient-cli:latest \
run . -e ci -r junit --reporter-out junit=./results.xml
- name: Publish Test Results
uses: dorny/test-reporter@v1
if: always()
with:
name: API Tests
path: results.xml
reporter: java-junitCLI looks for jetclient.md in:
- Current directory
.jetclient/subdirectory
Run from project root or .jetclient/ folder.
jetclient run [PROJECT_DIR] [OPTIONS] # Execute requests and tests
jetclient version # Show CLI version| Option | Description |
|---|---|
-e, --env <ENV> |
Environment to activate (repeatable for multiple groups) |
-i, --item <ITEM> |
ID or path of request, folder, or test suite to run (repeatable) |
-V, --var <KEY=VALUE> |
Set runtime variable (repeatable, overrides all other sources) |
--proxy <URL> |
HTTP/HTTPS/SOCKS proxy URL (e.g., http://proxy:8080) |
--no-proxy <HOSTS> |
Comma-separated hosts to bypass proxy |
-k, --insecure |
Disable SSL certificate verification |
--no-color |
Disable colored output |
-r, --reporter <TYPE> |
Output reporter: cli, json, html, junit (repeatable) |
--reporter-out <TYPE=PATH> |
Reporter output path (e.g., json=./report.json) |
-n, --iterations <N> |
Number of times to run (default: 1) |
--delay <MS> |
Delay between iterations in milliseconds |
Default reporter outputs (when --reporter-out not specified):
- JSON:
./jetclient-report.json - JUnit:
./jetclient-report.xml - HTML:
./jetclient-report.html
| Variable | Description |
|---|---|
JETCLIENT_ENV |
Comma-separated environments to activate |
JETCLIENT_ITEMS |
Comma-separated item IDs or paths to run |
JETCLIENT_VAR_* |
Runtime variables (e.g., JETCLIENT_VAR_apiKey=secret) |
JETCLIENT_INSECURE |
Set to true to disable SSL verification |
JETCLIENT_PROXY |
Proxy URL (e.g., http://proxy:8080) |
JETCLIENT_NO_COLOR |
Disable colored output (any value) |
NO_COLOR |
Standard no-color convention |
NO_PROXY |
Comma-separated hosts to bypass proxy |
HTTPS_PROXY / HTTP_PROXY |
Standard proxy env vars (lower priority than JETCLIENT_PROXY) |
Run all requests in a project:
jetclient run ./my-api-projectRun with specific environment:
jetclient run ./my-api-project -e productionRun specific items:
jetclient run ./my-api-project -i "Authentication/Login" -i "Users/Get All"Run with variables:
jetclient run ./my-api-project -V "baseUrl=https://api.example.com" -V "apiKey=secret"Generate JSON report:
jetclient run ./my-api-project -r json --reporter-out json=./report.jsonNote: Items (-i) can be specified by path (contains /) or ID.
| Code | Description |
|---|---|
| 0 | All tests passed |
| 1 | One or more tests failed |
| 2 | Configuration or input error |
| 3 | Runtime error |
For more information, visit jetclient.io/docs/cli