Skip to main content
Sends real HTTP requests to every contracted endpoint and reports health.

Usage

Options

string
Access token for authenticated endpoints.
string
Auto-login email.
string
Auto-login password.
string
default:"GET"
HTTP method to use when testing.
boolean
Allow testing of write endpoints (POST, PUT, PATCH, DELETE).
boolean
Mock mode. Does not send real HTTP requests.
boolean
Test all endpoints regardless of status.
string[]
Skip specific endpoints by URL.
boolean
Run the tests through Newman. Bazable generates a temporary Postman collection and executes it.
string
default:"cli"
Comma-separated Newman reporters (for example cli, junit, cli,junit). Only used with --newman.
string[]
Environment variables passed to Newman as key=value. May be repeated. Only used with --newman.
Use --write with care against live APIs. It will send POST, PUT, PATCH, and DELETE requests.

Newman mode

With --newman, Bazable:
  1. Reads your contract.
  2. Generates a Postman collection (same logic as bazable export --postman).
  3. Runs newman run on that collection.
  4. Exits with code 0 if all tests pass, 1 otherwise.
If you have stored credentials from bazable login, the token is automatically injected as the token environment variable in the Newman run.
Newman is optional. If it is not installed globally, Bazable falls back to npx newman. Install with npm i -g newman for faster runs in CI.

Examples

See Postman Integration for the full Postman/Newman workflow.