CLI Runner - amitsri/rostyman-releases GitHub Wiki

CLI Runner (rosty-cli)

Newman-style command-line runner for executing collections in CI/CD pipelines.

Usage

rosty-cli run <collection-file> [options]

Options

Option Description Default
--environment <file> Load environment variables from JSON
--globals <file> Load global variables from JSON
--iteration-count <n> Run the collection N times 1
--delay-request <ms> Wait between requests 0
--timeout <ms> Request timeout 30000
--bail Stop on first test failure false
--reporters <list> Output format: cli, json, junit cli
--reporter-json-export <file> Save JSON report to file
--reporter-junit-export <file> Save JUnit XML report to file

Examples

# Run a collection
rosty-cli run MyAPI.postman_collection.json

# With environment variables
rosty-cli run collection.json --environment dev.json

# Multiple iterations with delay
rosty-cli run collection.json --iteration-count 3 --delay-request 500

# CI/CD with JUnit output
rosty-cli run collection.json --reporters cli,junit --reporter-junit-export results.xml

# Stop on first failure
rosty-cli run collection.json --bail --timeout 10000

Reporters

  • cli — console output with pass/fail per request
  • json — structured results for post-processing
  • junit — XML format for CI tools (Jenkins, GitHub Actions, etc.)

Combine reporters with commas: --reporters cli,json,junit

Environment Files

Supports two formats:

Postman format:

{
  "values": [
    { "key": "base_url", "value": "https://api.example.com", "enabled": true }
  ]
}

Simple format:

{
  "base_url": "https://api.example.com",
  "api_key": "sk-..."
}

Built-in Variables

Variable Description
{{$timestamp}} Current Unix timestamp
{{$randomUUID}} Random UUID v4

Environment, collection, and global variables are also resolved automatically.

Exit Codes

  • 0 — all tests passed
  • 1 — one or more failures or errors
⚠️ **GitHub.com Fallback** ⚠️