List secrets
Documentation Index
Fetch the complete documentation index at: https://docs.semgrep.dev/llms.txt
Use this file to discover all available pages before exploring further.
Authorizations
Get access to data with your API token. Example header:
Authorization: Bearer 2991e2fb4b540fe75b8f90677b0b892b6314e4961cb001fe6eb452eee248a628
The token can be provisioned from the Tokens section in your Settings, and requires explicitly enabling Web API access.
Path Parameters
Deployment ID (numeric). Example: 123. Can be found at /deployments, or in your Settings in the web UI.
123
Query Parameters
Cursor to paginate through the rules. Provide a cursor value from the response to retrieve the next page.
Page size to paginate through the results.
Whether the finding was validated or not.
- VALIDATION_STATE_UNSPECIFIED: Return results for all validation states (can also omit this parameter).
- VALIDATION_STATE_CONFIRMED_VALID: Secret has been tested and is confirmed valid.
- VALIDATION_STATE_CONFIRMED_INVALID: Secret has been tested and is confirmed invalid.
- VALIDATION_STATE_VALIDATION_ERROR: Secret test was attempted and there was an error.
- VALIDATION_STATE_NO_VALIDATOR: There is no validator for this secret.
VALIDATION_STATE_UNSPECIFIED, VALIDATION_STATE_CONFIRMED_VALID, VALIDATION_STATE_CONFIRMED_INVALID, VALIDATION_STATE_VALIDATION_ERROR, VALIDATION_STATE_NO_VALIDATOR Status of the finding.
- FINDING_STATUS_UNSPECIFIED: Return results for all finding statuses (if used as a parameter).
- FINDING_STATUS_OPEN: Finding is open and needs to be triaged
- FINDING_STATUS_IGNORED: Finding has been triaged and is being ignored
- FINDING_STATUS_FIXED: Finding has been fixed
- FINDING_STATUS_REMOVED: Finding has been removed
- FINDING_STATUS_UNKNOWN: Finding status is unknown
FINDING_STATUS_UNSPECIFIED, FINDING_STATUS_OPEN, FINDING_STATUS_IGNORED, FINDING_STATUS_FIXED, FINDING_STATUS_REMOVED, FINDING_STATUS_UNKNOWN, FINDING_STATUS_PROVISIONALLY_IGNORED Severity of the finding.
- SEVERITY_UNSPECIFIED: Return results for all severities (if used as a parameter).
SEVERITY_UNSPECIFIED, SEVERITY_HIGH, SEVERITY_MEDIUM, SEVERITY_LOW, SEVERITY_CRITICAL Repositories to view results for. If not specified, returns all.
Response
OK
Cursor to paginate through the results.
List of Secrets associated with the given Deployment.
{
"cursor": "Pm0ROjIwMjQtMDItMDYgMjA6MDQ6NDguMEDzNzk2fmk6NYTM2zUxOTI=",
"findings": [
{
"confidence": "CONFIDENCE_HIGH",
"createdAt": "2024-06-17T17:23:01.901204Z",
"findingPath": "src/ai.py:232",
"findingPathUrl": "https://github.com/foo/bar/blob/6ad16b240d4b6ae5bd6e326dd71053c21344e311/src/ai.py#L232",
"id": "691234",
"mode": "MODE_MONITOR",
"ref": "refs/pull/148/merge",
"refUrl": "https://github.com/foo/bar/pull/148",
"repository": {
"name": "foo/bar",
"scmType": "SCM_TYPE_GITHUB",
"url": "https://github.com/foo/bar",
"visibility": "REPOSITORY_VISIBILITY_PRIVATE"
},
"reviewComments": [
{
"externalDiscussionId": "af0433345acfb74c8f9",
"externalNoteId": "5678"
}
],
"ruleHashId": "lBU41LA",
"severity": "SEVERITY_HIGH",
"status": "FINDING_STATUS_FIXED",
"type": "OpenAI",
"updatedAt": "2024-06-20T17:33:00.669343Z",
"validationState": "VALIDATION_STATE_CONFIRMED_VALID"
},
{
"confidence": "CONFIDENCE_MEDIUM",
"createdAt": "2024-06-08T11:01:23.380293Z",
"findingPath": "config.yaml:801",
"findingPathUrl": "https://github.com/foo/baz/blob/e2b6d5ca75d830e10f5f617481a66a981bd093c0/config.yaml#L801",
"id": "6881234",
"mode": "MODE_COMMENT",
"ref": "develop",
"refUrl": "https://github.com/foo/baz/tree/develop",
"repository": {
"name": "foo/baz",
"scmType": "SCM_TYPE_GITHUB",
"url": "https://github.com/foo/baz",
"visibility": "REPOSITORY_VISIBILITY_PRIVATE"
},
"reviewComments": [
{
"externalDiscussionId": "af0476223423b74c8f9",
"externalNoteId": "6789"
}
],
"ruleHashId": "pKUYdA",
"severity": "SEVERITY_HIGH",
"status": "FINDING_STATUS_IGNORED",
"type": "Heroku",
"updatedAt": "2024-06-22T11:07:02.384500Z",
"validationState": "VALIDATION_STATE_CONFIRMED_INVALID"
}
]
}Cursor to paginate backwards through the results.