List or export Bug Scan findings
curl --request GET \
--url https://api.coderabbit.ai/v1/bug-scan/findings \
--header 'x-coderabbitai-api-key: <api-key>'import requests
url = "https://api.coderabbit.ai/v1/bug-scan/findings"
headers = {"x-coderabbitai-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-coderabbitai-api-key': '<api-key>'}};
fetch('https://api.coderabbit.ai/v1/bug-scan/findings', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"data": [
{
"state": "open",
"dismiss_reason": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"fingerprint": "<string>",
"severity": "critical",
"category": "<string>",
"path": "<string>",
"start_line": 123,
"end_line": 123,
"locations": [
{
"path": "<string>",
"start_line": 123,
"end_line": 123,
"role": "anchor"
}
],
"explanation": "<string>",
"agent_prompt": "<string>",
"verification": {
"status": "verified",
"result": "<string>",
"evidence": "<string>"
},
"rank": 123,
"organization_id": "<string>",
"organization_name": "<string>",
"repository_id": "<string>",
"repository_name": "<string>",
"scan_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
],
"next_cursor": "<string>",
"scan": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"head_commit": "<string>",
"completed_at": "2023-11-07T05:31:56Z",
"partial_coverage": true
}
}List or export Bug Scan findings
Returns one repository’s Bug Scan findings from its latest completed scan, or from scan_id. Cursor-paginated JSON by default; CSV and SARIF 2.1.0 download every matching finding of the scan (up to 50,000 records and 16 MB). Findings are in the scan’s rank order. Each finding carries its fingerprint, severity, category, location, every location it applies to, explanation, the prompt for AI agents, the verifier’s account, and its state (open, fixed or dismissed) with the dismiss reason. Requires a non-agentic API key with bug_scan:read permission, and Bug Scan enabled for the organization; other organizations receive 403 BUG_SCAN_NOT_ENABLED.
GET
/
v1
/
bug-scan
/
findings
List or export Bug Scan findings
curl --request GET \
--url https://api.coderabbit.ai/v1/bug-scan/findings \
--header 'x-coderabbitai-api-key: <api-key>'import requests
url = "https://api.coderabbit.ai/v1/bug-scan/findings"
headers = {"x-coderabbitai-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-coderabbitai-api-key': '<api-key>'}};
fetch('https://api.coderabbit.ai/v1/bug-scan/findings', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"data": [
{
"state": "open",
"dismiss_reason": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"fingerprint": "<string>",
"severity": "critical",
"category": "<string>",
"path": "<string>",
"start_line": 123,
"end_line": 123,
"locations": [
{
"path": "<string>",
"start_line": 123,
"end_line": 123,
"role": "anchor"
}
],
"explanation": "<string>",
"agent_prompt": "<string>",
"verification": {
"status": "verified",
"result": "<string>",
"evidence": "<string>"
},
"rank": 123,
"organization_id": "<string>",
"organization_name": "<string>",
"repository_id": "<string>",
"repository_name": "<string>",
"scan_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
],
"next_cursor": "<string>",
"scan": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"head_commit": "<string>",
"completed_at": "2023-11-07T05:31:56Z",
"partial_coverage": true
}
}- CLI Tool
- MCP Server
coderabbit api request "/bug-scan/findings?repo_id=$REPO_ID"
This operation isn’t a tool on the CodeRabbit MCP server. Call it over REST or from the CLI.
Authorizations
See Authentication for the key types and where to create a key.
Query Parameters
Was this page helpful?