Scans

Trigger a Gerrit change scan from CI

Stage a scan of a Gerrit change’s current patch set (the Gerrit equivalent of a PR scan), for use from an external CI system such as a Jenkins job fired by the Gerrit Trigger plugin. The change is re-fetched from the connected Gerrit server before anything is staged, so the request payload is a hint rather than trusted input. Staging matches the built-in change poller exactly: the same deduplication (re-triggering an unchanged patch set returns already_scanned with the existing scan ids), the same work-in-progress and PR-scanning-disabled skips, and the same credit admission. Results are posted back to the change as review comments, as with poller-discovered scans. To stop ZeroPath from also polling the server for changes, switch the installation’s change discovery to CI-triggered in Settings → Integrations.

post/api/v2/scans/scanGerritChange

Request

  • Base URL
    https://zeropath.com
  • Auth
    API key in header X-ZeroPath-API-Token-Id and API key in header X-ZeroPath-API-Token-Secret

Request body

OR

Response

Trigger result

OR

Changes

No recorded changes to this operation across all 1 revision of this API.