hitspec integrates with any CI/CD system. This guide covers common patterns for automated API testing.
GitHub Actions
GitLab CI
General CI/CD Tips
Exit Codes
hitspec uses standard exit codes. See Exit Codes for the full list.
0 — all tests passed
1 — one or more tests failed
2 — a file could not be loaded (parse error)
3 — config error
4 — network error: the API could not be reached (a request got no response)
64 — usage error (unknown flag, bad value, missing argument), or --name/--tags matched no request
130 — interrupted (Ctrl+C or SIGTERM)
A step that only expects 0 or 1 must also handle 4.
Recommended Flags
Environment Variables
Store sensitive values as CI/CD secrets:
Parallel Testing in CI
Use --output json --output-file results.json to generate output compatible with hitspec diff for regression detection between builds.
Last modified on October 19, 2026