hubcaps
hubcaps copied to clipboard
Support Code Scanning APIs
💡 Feature description
Supporting the GitHub Code Scanning API would allow us to automatically pull security alerts from GitHub and perform actions on those results.
https://docs.github.com/en/enterprise-cloud@latest/rest/code-scanning#list-code-scanning-alerts-for-a-repository
💻 Basic example
let owner = "softprops";
let repo = "hubcaps";
let alerts: Vec<CodeScanningAlerts> = github.repo(owner, repo).code_scanning().alerts().await?;
for alert in alerts {
println!(" >> Alert('{:#?}')", alert.rule.name);
}