Skip to content

bru run options

bru run accepts options for environments, data files, request filtering, security, and reporting. Add them after the files or folders you want to run:

bru run [files or folders...] [options]

To view the options available in your installed version:

bru run -h

The other commands document their options on their own pages: bru import and bru docs.

Options

Basic options

Option Details
-h, --help Output usage information
--version Output the version number

Setup options

Option Details
--env [string] Specify environment to run with
--global-env [string] Specify global/workspace-level environment to run with
--workspace-path [string] Specify workspace path when collection is not located at the root
--env-var [string] Overwrite a single collection-level environment variable, multiple usages possible
--global-env-var [string] Overwrite a single global environment variable, multiple usages possible. Requires --global-env.
--env-file [string] Path to the environment file (.bru or .json) to use for the collection run
--sandbox [string] Specifies the JavaScript execution sandbox mode: safe (default) or developer.

Note: Starting from v3.0.0, the default is "safe" mode. Use --sandbox=developer to enable Developer Mode features.
--csv-file-path CSV file to run the collection with
--json-file-path Path to the JSON data file
--iteration-count [number] Number of times to run the collection
-r Indicates a recursive run [boolean] [default: false]

See Running a Collection with Environments for more details.

Request options

Option Details
--delay [number] Delay between each requests (in milliseconds)
--tests-only Only run requests that have tests or active assertions
--bail Stop execution after a failure of a request, test, or assertion
--tags [string] Only run requests that have ANY of the specified tags (comma-separated)
--exclude-tags [string] Skip requests that have ANY of the specified tags (comma-separated)
--parallel Run requests in parallel order
--experimental-cache-modules Share evaluated script modules across requests in a bru run. Opt in only if CLI RSS grows without bound on large collections. Details.

Secret Manager options

Option Details
--secrets-env-file [string] Path to a dotenv file containing credentials for an external secret manager (HashiCorp Vault, AWS Secrets Manager, or Azure Key Vault). Values are injected at runtime and are never written to disk or printed in logs.

The --secrets-env-file flag is used together with --env when your environment file has an externalSecrets block configured. See Secret Managers for credential file formats and full usage examples for each provider.

bru run collection/ --env Production --secrets-env-file ./secrets.env

SSL & Security options

Option Details
--cacert [string] CA certificate to verify peer against
--ignore-truststore Use custom CA certificate exclusively and ignore default truststore [boolean] [default: false]
--client-cert-config Path to the Client certificate config file used for securing the connection
--insecure Allow insecure server connections
--disable-cookies Disable automatic saving and sending of cookies between requests [boolean] [default: false]
--noproxy Disable all proxy settings (both collection-defined and system proxies) [boolean] [default: false]

--noproxy bypasses every proxy for a single run, and --client-cert-config points to a JSON file describing per-domain client certificates. The CLI does not read certificates from the desktop app's Preferences, so mTLS in CI always goes through this flag. See Proxy & mTLS for the config file format and how CLI certificates are merged with the ones in bruno.json.

bru run --client-cert-config /path/to/client-cert-config.json

Output & Reporting options

Option Details
-o, --output [string] [DEPRECATED] Path to write file results to. Use reporter options instead
-f, --format [string] [DEPRECATED] Format of the file results. Use reporter options instead
--reporter-json [string] Path to generate a JSON report
--reporter-junit [string] Path to generate a JUnit report
--reporter-html [string] Path to generate an HTML report
--reporter-skip-all-headers Skip all headers in the report [boolean] [default: false]
--reporter-skip-headers Skip specific headers in the report [array] [default: []]
--reporter-skip-request-body Omits request bodies from reports [boolean] [default: false]
--reporter-skip-response-body Omits response bodies from reports [boolean] [default: false]
--reporter-skip-body Shorthand: omits both request and response bodies from reports [boolean] [default: false]

The three reporter flags can be combined in one run to produce several formats at once, and the --reporter-skip-* flags let you keep credentials and payloads out of the artifacts you publish in CI. See Reports for the output of each format, including the v4 change to the JUnit classname attribute.

bru run --reporter-json results.json --reporter-junit results.xml --reporter-html results.html

Next Steps

Now that you're familiar with the command options, explore these guides to get the most out of Bruno CLI:

  1. Run Collections - Worked examples for every way to run a collection with the options above
  2. Reports - Create detailed test reports in multiple formats
  3. Proxy & mTLS - Route requests through a proxy and configure client certificates
  4. Secret Managers - Fetch secrets from HashiCorp Vault, AWS Secrets Manager, or Azure Key Vault at runtime
  5. bru import - Import OpenAPI and WSDL specifications into Bruno collections
  6. bru docs - Generate and publish standalone HTML API documentation from the CLI

Support

If you encounter any issues or have any feedback or suggestions, please raise them on our GitHub repository ↗