#083Guide3 min
Set up a pre-deployment gate
Use a specific saved analysis to inform a release decision, without confusing it with verification of a pull-request commit.
Hackaiz team · updated 21/11/2026

01Define what the gate can actually validate
A deployment gate is a decision point that stops a release until agreed checks have passed. Hackaiz provides a connected command-line client with a verify command for a particular saved-platform analysis. This is not a built-in guarantee that the code about to deploy was analyzed. The command reports the scope as saved_platform_not_pr_commit. Decide which saved project represents your release and document how your team will establish the relationship with the release candidate.
The prepared client is in tools/hackaiz-cli and is not published as an npm package. Autonomous processing must be configured and deployed for connected requests to run. A template being present in the project does not demonstrate a successful execution in your GitHub environment. If that service is unavailable, do not call the resulting job a successful security check; keep the request reference and investigate the configuration before relying on it.
02Create one request and keep its identifier
Use a personal HACKAIZ_API_KEY with read and launch access, the saved project identifier, and the prepared client in a trusted execution environment. An analysis of a website or API still requires current domain ownership proof and consent. That proof can be a DNS TXT record at _hackaiz or the HTTPS file /.well-known/hackaiz-verification.txt; you can also ask your project’s AI to create that file. Connecting automation does not bypass authorization.
Run node tools/hackaiz-cli/bin/hackaiz.mjs analyze <project-id> <request-key>, replacing the placeholders with your identifiers. Keep the requestId returned by the command. The client submits the request and polls its status; closing it does not cancel autonomous work. For an interrupted connection, use node tools/hackaiz-cli/bin/hackaiz.mjs status <project-id> <request-id> to inspect the same request instead of creating a replacement. Analysis work consumes credits, so retries must not be treated as harmless new launches.
03Use verify rather than the launch exit code
After the request finishes, run node tools/hackaiz-cli/bin/hackaiz.mjs verify <project-id> <request-id>. The launch command can return a successful process exit for either a successful or a partial analysis. That makes its exit code unsuitable as the sole deployment decision. The verify command requires a successful analysis linked to the requested run, then reads all pages of open findings for that exact analysis.
The verification result is pass with exit code 0 when there are no open high or critical technical findings, fail with exit code 1 when such findings remain, or inconclusive with exit code 2 when the required complete result cannot be established. Invalid or inconsistent finding pages also produce an inconclusive result. These technical thresholds are not identical to the report’s three customer labels: Danger, To fix and To watch. In particular, high findings are shown as To fix and still block this gate.
04Make the release depend on the right result
Configure your own delivery system to require the verification job before deployment. Merely running an analysis or posting a comment on a pull request does not create that dependency. The supplied connected GitHub workflow launches an analysis and comments a project link; it does not itself execute verify. Add the verification step and the release dependency in your repository after review, and test that fail and inconclusive both stop the release.
Keep the run identifier, verification output and release reference together for human review. A pass describes the recorded findings and selected coverage, not a promise that the application is safe. Unticked checks are not executed or billed. If a correction is needed, Hackaiz fixes are draft GitHub pull requests reviewed and approved by a human, never merged automatically. Apply and test the approved change, then obtain fresh evidence for the release rather than reusing an older pass.
Frequently asked questions
Take the next step
Was this article helpful?