Description: Returns a single Ignore Rule by its ID.
Since: 3.11
Security: Requires a valid user with the "Manage Watches" permission.
Notes: For Xray version 3.21.2 and above with Projects, a Project Admin with the Manage Assets privilege can get an Ignore Rule using this REST API in the scope of a project, by using the additional query parameter projectKey.
Usage: GET /xray/api/v1/ignore_rules/{id}
Sample Response
{
"id": string,
"created": Date,
"author": string,
"notes": string,
"expires_at": Date,
"ignore_filters": {
"vulnerabilities": [
"Vuln1",
"Vuln2"
],
"licenses": [
],
"watches": [
"Watch1",
"Watch2"
],
"components": [
{name:"docker://redis"},
{name:"Comp2", version: "2.6"},
{name:"Comp3", version: "1.03"}
]
}
}Get Ignore Rule for Specific Project
GET /api/v1/ignore_rules/{id}?projectKey=<project_key>
{
"id": string,
"created": Date,
"author": string,
"notes": string,
"expires_at": Date,
"project_key":"myproj",
"ignore_filters": {
"vulnerabilities": [
"Vuln1",
"Vuln2"
],
"licenses": [
],
"watches": [
"Watch1",
"Watch2"
],
"components": [
{name:"docker://redis"},
{name:"Comp2", version: "2.6"},
{name:"Comp3", version: "1.03"}
],
"projects": [
"myproj"
],
}
}Response Codes:
200 - OK
500 - Failed to get ignore rules
401 - Unauthorized
403 - Forbidden