git.security.list-secret-alertsSecrets push protection found: blocked, bypassed and resolved, plus scan gaps
Never the secret itself: a redacted preview and a fingerprint. `gaps` lists pushes the scan could not finish (fail-open past its time or size budget).
Request syntax
GET /git/api/repositories/{repoId}/security/secret-alertsPath parameters
repoIdRequiredstring
Constraints: uuid
Response
200 with `alerts` (state, ruleName, path, line, commitOid, refName, preview, fingerprint, who pushed it, and the resolution) and `gaps` (refName, commitOid, reason, blobsScanned, blobsSkipped).
A JSON response is wrapped as { "success": true, "data": … }; the CLI prints the whole body with --json.
Fields of data
alertsAlwaysarray of object
The newest 500 alerts, newest firstalerts[].idAlwaysstring
The alertalerts[].orgIdAlwaysstring
The organizationalerts[].repoIdAlwaysstring
The repositoryalerts[].stateAlwaysone of blocked, bypassed, resolved
blocked: the push was refused; bypassed: pushed anyway and in the history; resolved: someone said what was donealerts[].ruleIdAlwaysstring
The detector that matchedalerts[].ruleNameAlwaysstring
The kind of credential, in wordsalerts[].pathAlwaysstring
The file the secret is inalerts[].lineAlwaysnumber
The line it is on, from 1alerts[].blobOidAlwaysstring
The id of the file content it was found inalerts[].refNameAlwaysstring
The ref that was pushedalerts[].commitOidAlwaysstring
The pushed tip of the ref; the secret is in its historyalerts[].fingerprintAlwaysstring
A sha256 fingerprint to recognise the same secret againalerts[].previewAlwaysstring
A redacted preview; never the secret itselfalerts[].pushedByAlwaysstring
Who pushed: user:<IAM user id>, deploy:<deploy key id> or unknownalerts[].pushedByIamUserIdAlwaysstring, may be null
The IAM user who pushed; null for a deploy key or a deleted useralerts[].bypassReasonAlwaysstring, may be null
Why it was pushed anyway; null unless bypassedalerts[].resolutionAlwaysone of revoked, false_positive, used_in_tests, wont_fix, may be null
What was done about it; null until resolvedalerts[].resolutionCommentAlwaysstring, may be null
A note on the resolution, if anyalerts[].resolvedByIamUserIdAlwaysstring, may be null
Who resolved it; null until resolvedalerts[].resolvedAtAlwaysstring, may be null
When it was resolved (ISO 8601); null until thenalerts[].createdAtAlwaysstring
When the push was scanned (ISO 8601)alerts[].updatedAtAlwaysstring
When the alert last changed (ISO 8601)gapsAlwaysarray of object
The newest 50 pushes the scan could not finishgaps[].idAlwaysstring
The gapgaps[].orgIdAlwaysstring
The organizationgaps[].repoIdAlwaysstring
The repositorygaps[].refNameAlwaysstring
The ref that was pushedgaps[].commitOidAlwaysstring
The pushed tip of the refgaps[].reasonAlwaysstring
Why the scan stopped short (time or size budget)gaps[].blobsScannedAlwaysnumber
Files the scan checkedgaps[].blobsSkippedAlwaysnumber
Files the scan did not get togaps[].createdAtAlwaysstring
When the push was scanned (ISO 8601)
Checked against the handlers: every route test validates their answers against this schema.
Errors
- 400The request does not pass the schema above. The body is { "error": …, "issues": […] }, one issue per field.
- 401No credentials, or an access key that is unknown, revoked or expired.
- 403The caller's policies do not allow git:ListSecurityAlerts on this resource. The body names the action and the resource, and the refusal is recorded in the audit log.
- 404The resource does not exist in your organization.
Examples
The required parameters only, with example values. Replace id and the other placeholders with your own.
dcloud git security list-secret-alerts repoIdcurl -X GET "https://console.platform-development.deutschecloud.app/git/api/repositories/repoId/security/secret-alerts" \
-H "Authorization: EWS-ACCESS-KEY $ACCESS_KEY"Generated from the API description, the same one the API checks requests against and the CLI is built from. MCP tool: dcloud_git_security_list-secret-alerts.