Commit a57351cf authored by Savas Vedova's avatar Savas Vedova

Add resolved_at field to vulnerability type in GraphQL

- Update docs
- Add changelog
parent 0db44b64
...@@ -24732,6 +24732,11 @@ type Vulnerability implements Noteable { ...@@ -24732,6 +24732,11 @@ type Vulnerability implements Noteable {
""" """
reportType: VulnerabilityReportType reportType: VulnerabilityReportType
"""
Timestamp of when the vulnerability state was changed to resolved
"""
resolvedAt: Time
""" """
Indicates whether the vulnerability is fixed on the default branch or not Indicates whether the vulnerability is fixed on the default branch or not
""" """
......
...@@ -72042,6 +72042,20 @@ ...@@ -72042,6 +72042,20 @@
"isDeprecated": false, "isDeprecated": false,
"deprecationReason": null "deprecationReason": null
}, },
{
"name": "resolvedAt",
"description": "Timestamp of when the vulnerability state was changed to resolved",
"args": [
],
"type": {
"kind": "SCALAR",
"name": "Time",
"ofType": null
},
"isDeprecated": false,
"deprecationReason": null
},
{ {
"name": "resolvedOnDefaultBranch", "name": "resolvedOnDefaultBranch",
"description": "Indicates whether the vulnerability is fixed on the default branch or not", "description": "Indicates whether the vulnerability is fixed on the default branch or not",
...@@ -3728,6 +3728,7 @@ Represents a vulnerability. ...@@ -3728,6 +3728,7 @@ Represents a vulnerability.
| `primaryIdentifier` | VulnerabilityIdentifier | Primary identifier of the vulnerability. | | `primaryIdentifier` | VulnerabilityIdentifier | Primary identifier of the vulnerability. |
| `project` | Project | The project on which the vulnerability was found | | `project` | Project | The project on which the vulnerability was found |
| `reportType` | VulnerabilityReportType | Type of the security report that found the vulnerability (SAST, DEPENDENCY_SCANNING, CONTAINER_SCANNING, DAST, SECRET_DETECTION, COVERAGE_FUZZING, API_FUZZING) | | `reportType` | VulnerabilityReportType | Type of the security report that found the vulnerability (SAST, DEPENDENCY_SCANNING, CONTAINER_SCANNING, DAST, SECRET_DETECTION, COVERAGE_FUZZING, API_FUZZING) |
| `resolvedAt` | Time | Timestamp of when the vulnerability state was changed to resolved |
| `resolvedOnDefaultBranch` | Boolean! | Indicates whether the vulnerability is fixed on the default branch or not | | `resolvedOnDefaultBranch` | Boolean! | Indicates whether the vulnerability is fixed on the default branch or not |
| `scanner` | VulnerabilityScanner | Scanner metadata for the vulnerability. | | `scanner` | VulnerabilityScanner | Scanner metadata for the vulnerability. |
| `severity` | VulnerabilitySeverity | Severity of the vulnerability (INFO, UNKNOWN, LOW, MEDIUM, HIGH, CRITICAL) | | `severity` | VulnerabilitySeverity | Severity of the vulnerability (INFO, UNKNOWN, LOW, MEDIUM, HIGH, CRITICAL) |
......
...@@ -66,6 +66,10 @@ module Types ...@@ -66,6 +66,10 @@ module Types
description: 'Timestamp of when the vulnerability state was changed to confirmed', description: 'Timestamp of when the vulnerability state was changed to confirmed',
method: :confirmed_at method: :confirmed_at
field :resolved_at, Types::TimeType, null: true,
description: 'Timestamp of when the vulnerability state was changed to resolved',
method: :resolved_at
def user_notes_count def user_notes_count
::Gitlab::Graphql::Aggregations::Vulnerabilities::LazyUserNotesCountAggregate.new(context, object) ::Gitlab::Graphql::Aggregations::Vulnerabilities::LazyUserNotesCountAggregate.new(context, object)
end end
......
---
title: Add resolved_at field to vulnerability type in GraphQL
merge_request: 49391
author:
type: changed
...@@ -25,6 +25,7 @@ RSpec.describe GitlabSchema.types['Vulnerability'] do ...@@ -25,6 +25,7 @@ RSpec.describe GitlabSchema.types['Vulnerability'] do
issueLinks issueLinks
detected_at detected_at
confirmed_at confirmed_at
resolved_at
notes notes
discussions] discussions]
end end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment