Skip to content

Commit 3e295f5

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 439ac6f1 of spec repo
1 parent 584f4e8 commit 3e295f5

File tree

9 files changed

+120
-12
lines changed

9 files changed

+120
-12
lines changed

.apigentools-info

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
"spec_versions": {
55
"v1": {
66
"apigentools_version": "1.6.6",
7-
"regenerated": "2025-05-27 17:12:13.372089",
8-
"spec_repo_commit": "ed439f7c"
7+
"regenerated": "2025-06-02 13:17:14.284403",
8+
"spec_repo_commit": "439ac6f1"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.6",
12-
"regenerated": "2025-05-27 17:12:13.387673",
13-
"spec_repo_commit": "ed439f7c"
12+
"regenerated": "2025-06-02 13:17:14.300973",
13+
"spec_repo_commit": "439ac6f1"
1414
}
1515
}
1616
}

.generator/schemas/v2/openapi.yaml

Lines changed: 41 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15123,6 +15123,10 @@ components:
1512315123
FindingAttributes:
1512415124
description: The JSON:API attributes of the finding.
1512515125
properties:
15126+
datadog_link:
15127+
$ref: '#/components/schemas/FindingDatadogLink'
15128+
description:
15129+
$ref: '#/components/schemas/FindingDescription'
1512615130
evaluation:
1512715131
$ref: '#/components/schemas/FindingEvaluation'
1512815132
evaluation_changed_at:
@@ -15144,6 +15148,22 @@ components:
1514415148
vulnerability_type:
1514515149
$ref: '#/components/schemas/FindingVulnerabilityType'
1514615150
type: object
15151+
FindingDatadogLink:
15152+
description: The Datadog relative link for this finding.
15153+
example: /security/compliance?panels=cpfinding%7Cevent%7CruleId%3Adef-000-u5t%7CresourceId%3Ae8c9ab7c52ebd7bf2fdb4db641082d7d%7CtabId%3Aoverview
15154+
type: string
15155+
FindingDescription:
15156+
description: The description and remediation steps for this finding.
15157+
example: '## Remediation
15158+
15159+
15160+
1. In the console, go to **Storage Account**.
15161+
15162+
2. For each Storage Account, navigate to **Data Protection**.
15163+
15164+
3. Select **Set soft delete enabled** and enter the number of days to retain
15165+
soft deleted data.'
15166+
type: string
1514715167
FindingEvaluation:
1514815168
description: The evaluation of the finding.
1514915169
enum:
@@ -52695,13 +52715,19 @@ paths:
5269552715
the equal sign: `filter[evaluation_changed_at]=>=1678809373257`.\n\nQuery
5269652716
parameters must be only among the documented ones and with values of correct
5269752717
types. Duplicated query parameters (e.g. `filter[status]=low&filter[status]=info`)
52698-
are not allowed.\n\n### Response\n\nThe response includes an array of finding
52699-
objects, pagination metadata, and a count of items that match the query.\n\nEach
52700-
finding object contains the following:\n\n- The finding ID that can be used
52701-
in a `GetFinding` request to retrieve the full finding details.\n- Core attributes,
52702-
including status, evaluation, high-level resource details, muted state, and
52703-
rule details.\n- `evaluation_changed_at` and `resource_discovery_date` time
52704-
stamps.\n- An array of associated tags.\n"
52718+
are not allowed.\n\n### Additional extension fields\n\nAdditional extension
52719+
fields are available for some findings.\n\nThe data is available when you
52720+
include the query parameter `?detailed_findings=true` in the request.\n\nThe
52721+
following fields are available for findings:\n- `external_id`: The resource
52722+
external ID related to the finding.\n- `description`: The description and
52723+
remediation steps for the finding.\n- `datadog_link`: The Datadog relative
52724+
link for the finding.\n\n### Response\n\nThe response includes an array of
52725+
finding objects, pagination metadata, and a count of items that match the
52726+
query.\n\nEach finding object contains the following:\n\n- The finding ID
52727+
that can be used in a `GetFinding` request to retrieve the full finding details.\n-
52728+
Core attributes, including status, evaluation, high-level resource details,
52729+
muted state, and rule details.\n- `evaluation_changed_at` and `resource_discovery_date`
52730+
time stamps.\n- An array of associated tags.\n"
5270552731
operationId: ListFindings
5270652732
parameters:
5270752733
- description: Limit the number of findings returned. Must be <= 1000.
@@ -52804,6 +52830,14 @@ paths:
5280452830
items:
5280552831
$ref: '#/components/schemas/FindingVulnerabilityType'
5280652832
type: array
52833+
- description: Return additional fields for some findings.
52834+
example:
52835+
- true
52836+
in: query
52837+
name: detailed_findings
52838+
required: false
52839+
schema:
52840+
type: boolean
5280752841
responses:
5280852842
'200':
5280952843
content:
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
2025-05-20T12:11:24.321Z

cassettes/features/v2/security_monitoring/List-findings-returns-OK-response-with-details.yml

Lines changed: 20 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# List findings returns "OK" response with details
2+
3+
require "datadog_api_client"
4+
DatadogAPIClient.configure do |config|
5+
config.unstable_operations["v2.list_findings".to_sym] = true
6+
end
7+
api_instance = DatadogAPIClient::V2::SecurityMonitoringAPI.new
8+
opts = {
9+
detailed_findings: true,
10+
}
11+
p api_instance.list_findings(opts)

features/scenarios_model_mapping.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1183,6 +1183,7 @@
11831183
"filter_evaluation" => "FindingEvaluation",
11841184
"filter_status" => "FindingStatus",
11851185
"filter_vulnerability_type" => "Array<FindingVulnerabilityType>",
1186+
"detailed_findings" => "Boolean",
11861187
},
11871188
"v2.MuteFindings" => {
11881189
"body" => "BulkMuteFindingsRequest",

features/v2/security_monitoring.feature

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -840,6 +840,14 @@ Feature: Security Monitoring
840840
Then the response status is 200 OK
841841
And the response "data[0].type" is equal to "finding"
842842

843+
@team:DataDog/cloud-security-posture-management
844+
Scenario: List findings returns "OK" response with details
845+
Given operation "ListFindings" enabled
846+
And new "ListFindings" request
847+
And request contains "detailed_findings" parameter with value true
848+
When the request is sent
849+
Then the response status is 200 OK
850+
843851
@generated @skip @team:DataDog/cloud-security-posture-management @with-pagination
844852
Scenario: List findings returns "OK" response with pagination
845853
Given operation "ListFindings" enabled

lib/datadog_api_client/v2/api/security_monitoring_api.rb

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2376,6 +2376,17 @@ def list_findings(opts = {})
23762376
#
23772377
# Query parameters must be only among the documented ones and with values of correct types. Duplicated query parameters (e.g. `filter[status]=low&filter[status]=info`) are not allowed.
23782378
#
2379+
# ### Additional extension fields
2380+
#
2381+
# Additional extension fields are available for some findings.
2382+
#
2383+
# The data is available when you include the query parameter `?detailed_findings=true` in the request.
2384+
#
2385+
# The following fields are available for findings:
2386+
# - `external_id`: The resource external ID related to the finding.
2387+
# - `description`: The description and remediation steps for the finding.
2388+
# - `datadog_link`: The Datadog relative link for the finding.
2389+
#
23792390
# ### Response
23802391
#
23812392
# The response includes an array of finding objects, pagination metadata, and a count of items that match the query.
@@ -2402,6 +2413,7 @@ def list_findings(opts = {})
24022413
# @option opts [FindingEvaluation] :filter_evaluation Return only `pass` or `fail` findings.
24032414
# @option opts [FindingStatus] :filter_status Return only findings with the specified status.
24042415
# @option opts [Array<FindingVulnerabilityType>] :filter_vulnerability_type Return findings that match the selected vulnerability types (repeatable).
2416+
# @option opts [Boolean] :detailed_findings Return additional fields for some findings.
24052417
# @return [Array<(ListFindingsResponse, Integer, Hash)>] ListFindingsResponse data, response status code and response headers
24062418
def list_findings_with_http_info(opts = {})
24072419
unstable_enabled = @api_client.config.unstable_operations["v2.list_findings".to_sym]
@@ -2449,6 +2461,7 @@ def list_findings_with_http_info(opts = {})
24492461
query_params[:'filter[evaluation]'] = opts[:'filter_evaluation'] if !opts[:'filter_evaluation'].nil?
24502462
query_params[:'filter[status]'] = opts[:'filter_status'] if !opts[:'filter_status'].nil?
24512463
query_params[:'filter[vulnerability_type]'] = @api_client.build_collection_param(opts[:'filter_vulnerability_type'], :multi) if !opts[:'filter_vulnerability_type'].nil?
2464+
query_params[:'detailed_findings'] = opts[:'detailed_findings'] if !opts[:'detailed_findings'].nil?
24522465

24532466
# header parameters
24542467
header_params = opts[:header_params] || {}

lib/datadog_api_client/v2/models/finding_attributes.rb

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,12 @@ module DatadogAPIClient::V2
2121
class FindingAttributes
2222
include BaseGenericModel
2323

24+
# The Datadog relative link for this finding.
25+
attr_accessor :datadog_link
26+
27+
# The description and remediation steps for this finding.
28+
attr_accessor :description
29+
2430
# The evaluation of the finding.
2531
attr_accessor :evaluation
2632

@@ -57,6 +63,8 @@ class FindingAttributes
5763
# @!visibility private
5864
def self.attribute_map
5965
{
66+
:'datadog_link' => :'datadog_link',
67+
:'description' => :'description',
6068
:'evaluation' => :'evaluation',
6169
:'evaluation_changed_at' => :'evaluation_changed_at',
6270
:'mute' => :'mute',
@@ -74,6 +82,8 @@ def self.attribute_map
7482
# @!visibility private
7583
def self.openapi_types
7684
{
85+
:'datadog_link' => :'String',
86+
:'description' => :'String',
7787
:'evaluation' => :'FindingEvaluation',
7888
:'evaluation_changed_at' => :'Integer',
7989
:'mute' => :'FindingMute',
@@ -105,6 +115,14 @@ def initialize(attributes = {})
105115
end
106116
}
107117

118+
if attributes.key?(:'datadog_link')
119+
self.datadog_link = attributes[:'datadog_link']
120+
end
121+
122+
if attributes.key?(:'description')
123+
self.description = attributes[:'description']
124+
end
125+
108126
if attributes.key?(:'evaluation')
109127
self.evaluation = attributes[:'evaluation']
110128
end
@@ -203,6 +221,8 @@ def to_hash
203221
def ==(o)
204222
return true if self.equal?(o)
205223
self.class == o.class &&
224+
datadog_link == o.datadog_link &&
225+
description == o.description &&
206226
evaluation == o.evaluation &&
207227
evaluation_changed_at == o.evaluation_changed_at &&
208228
mute == o.mute &&
@@ -220,7 +240,7 @@ def ==(o)
220240
# @return [Integer] Hash code
221241
# @!visibility private
222242
def hash
223-
[evaluation, evaluation_changed_at, mute, resource, resource_discovery_date, resource_type, rule, status, tags, vulnerability_type, additional_properties].hash
243+
[datadog_link, description, evaluation, evaluation_changed_at, mute, resource, resource_discovery_date, resource_type, rule, status, tags, vulnerability_type, additional_properties].hash
224244
end
225245
end
226246
end

0 commit comments

Comments
 (0)