security_events
scope to use this endpoint with private repos,public_repo
scope also grants permission to read security events on public repos only.security_events
read permission to use this endpoint.rules_count
field in the default response give the number of rules0
is returned in this field.application/sarif+json
,curl --location --request GET 'https://api.github.com/repos///code-scanning/analyses/'
{
"analysis_key": "string",
"category": "string",
"commit_sha": "stringstringstringstringstringstringstri",
"created_at": "2019-08-24T14:15:22Z",
"deletable": true,
"environment": "string",
"error": "error reading field xyz",
"id": 0,
"ref": "string",
"results_count": 0,
"rules_count": 0,
"sarif_id": "6c81cd8e-b078-4ac3-a3be-1dad7dbd0b53",
"tool": {
"guid": "string",
"name": "string",
"version": "string"
},
"url": "http://example.com",
"warning": "123 results were ignored"
}
GET /repos/{owner}/{repo}/code-scanning/analyses
operation.YYYY-MM-DDTHH:MM:SSZ
.refs/heads/<branch name>
,refs/pull/<number>/merge
, or refs/pull/<number>/head
.