Skip to content

Commit 1c031ac

Browse files
author
ci.datadog-api-spec
committed
Regenerate client from commit 1920836f of spec repo
1 parent fdc8194 commit 1c031ac

File tree

13 files changed

+610
-4
lines changed

13 files changed

+610
-4
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-01-07 19:53:43.056949",
8-
"spec_repo_commit": "d63fa330"
7+
"regenerated": "2025-01-08 14:02:25.736805",
8+
"spec_repo_commit": "1920836f"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.6",
12-
"regenerated": "2025-01-07 19:53:43.071705",
13-
"spec_repo_commit": "d63fa330"
12+
"regenerated": "2025-01-08 14:02:25.752564",
13+
"spec_repo_commit": "1920836f"
1414
}
1515
}
1616
}

.generator/schemas/v2/openapi.yaml

Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2732,6 +2732,57 @@ components:
27322732
$ref: '#/components/schemas/AwsCURConfig'
27332733
type: array
27342734
type: object
2735+
AwsScanOptionsAttributes:
2736+
description: Attributes for the AWS scan options.
2737+
properties:
2738+
lambda:
2739+
description: Indicates if scanning of Lambda functions is enabled.
2740+
example: true
2741+
type: boolean
2742+
sensitive_data:
2743+
description: Indicates if scanning for sensitive data is enabled.
2744+
example: false
2745+
type: boolean
2746+
vuln_containers_os:
2747+
description: Indicates if scanning for vulnerabilities in containers is
2748+
enabled.
2749+
example: true
2750+
type: boolean
2751+
vuln_host_os:
2752+
description: Indicates if scanning for vulnerabilities in hosts is enabled.
2753+
example: true
2754+
type: boolean
2755+
type: object
2756+
AwsScanOptionsData:
2757+
description: Single AWS Scan Options entry.
2758+
properties:
2759+
attributes:
2760+
$ref: '#/components/schemas/AwsScanOptionsAttributes'
2761+
id:
2762+
description: The ID of the AWS account.
2763+
example: '184366314700'
2764+
type: string
2765+
type:
2766+
$ref: '#/components/schemas/AwsScanOptionsType'
2767+
type: object
2768+
AwsScanOptionsResponse:
2769+
description: Response object that includes a list of AWS scan options.
2770+
properties:
2771+
data:
2772+
description: A list of AWS scan options.
2773+
items:
2774+
$ref: '#/components/schemas/AwsScanOptionsData'
2775+
type: array
2776+
type: object
2777+
AwsScanOptionsType:
2778+
default: aws_scan_options
2779+
description: The type of the resource. The value should always be `aws_scan_options`.
2780+
enum:
2781+
- aws_scan_options
2782+
example: aws_scan_options
2783+
type: string
2784+
x-enum-varnames:
2785+
- AWS_SCAN_OPTIONS
27352786
AzureUCConfig:
27362787
description: Azure config.
27372788
properties:
@@ -30222,6 +30273,24 @@ info:
3022230273
version: '1.0'
3022330274
openapi: 3.0.0
3022430275
paths:
30276+
/api/v2/agentless_scanning/accounts/aws:
30277+
get:
30278+
description: Fetches the scan options configured for AWS accounts.
30279+
operationId: ListAwsScanOptions
30280+
responses:
30281+
'200':
30282+
content:
30283+
application/json:
30284+
schema:
30285+
$ref: '#/components/schemas/AwsScanOptionsResponse'
30286+
description: OK
30287+
'403':
30288+
$ref: '#/components/responses/NotAuthorizedResponse'
30289+
'429':
30290+
$ref: '#/components/responses/TooManyRequestsResponse'
30291+
summary: Get AWS Scan Options
30292+
tags:
30293+
- Agentless Scanning
3022530294
/api/v2/api_keys:
3022630295
get:
3022730296
description: List all API keys available for your account.
@@ -48131,6 +48200,11 @@ tags:
4813148200
externalDocs:
4813248201
url: https://docs.datadoghq.com/integrations/amazon_web_services/#log-collection
4813348202
name: AWS Logs Integration
48203+
- description: "Datadog Agentless Scanning provides visibility into risks and vulnerabilities\nwithin
48204+
your hosts, running containers, and serverless functions\u2014all without\nrequiring
48205+
teams to install Agents on every host or where Agents cannot be installed.\nGo
48206+
to https://www.datadoghq.com/blog/agentless-scanning/ to learn more"
48207+
name: Agentless Scanning
4813448208
- description: Datadog App Builder provides a low-code solution to rapidly develop
4813548209
and integrate secure, customized applications into your monitoring stack that
4813648210
are built to accelerate remediation at scale. These API endpoints allow you to
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
2024-12-18T15:40:11.636Z

cassettes/features/v2/agentless_scanning/Get-AWS-Scan-Options-returns-OK-response.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: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Get AWS Scan Options returns "OK" response
2+
3+
require "datadog_api_client"
4+
api_instance = DatadogAPIClient::V2::AgentlessScanningAPI.new
5+
p api_instance.list_aws_scan_options()
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
@endpoint(agentless-scanning) @endpoint(agentless-scanning-v2)
2+
Feature: Agentless Scanning
3+
Datadog Agentless Scanning provides visibility into risks and
4+
vulnerabilities within your hosts, running containers, and serverless
5+
functions—all without requiring teams to install Agents on every host or
6+
where Agents cannot be installed. Go to
7+
https://www.datadoghq.com/blog/agentless-scanning/ to learn more
8+
9+
@team:DataDog/k9-cloud-security-platform
10+
Scenario: Get AWS Scan Options returns "OK" response
11+
Given a valid "apiKeyAuth" key in the system
12+
And a valid "appKeyAuth" key in the system
13+
And an instance of "AgentlessScanning" API
14+
And new "ListAwsScanOptions" request
15+
When the request is sent
16+
Then the response status is 200 OK

features/v2/undo.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
11
{
2+
"ListAwsScanOptions": {
3+
"tag": "Agentless Scanning",
4+
"undo": {
5+
"type": "safe"
6+
}
7+
},
28
"ListAPIKeys": {
39
"tag": "Key Management",
410
"undo": {

lib/datadog_api_client/inflector.rb

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1038,6 +1038,10 @@ def overrides
10381038
"v2.aws_regions_include_all" => "AWSRegionsIncludeAll",
10391039
"v2.aws_regions_include_only" => "AWSRegionsIncludeOnly",
10401040
"v2.aws_resources_config" => "AWSResourcesConfig",
1041+
"v2.aws_scan_options_attributes" => "AwsScanOptionsAttributes",
1042+
"v2.aws_scan_options_data" => "AwsScanOptionsData",
1043+
"v2.aws_scan_options_response" => "AwsScanOptionsResponse",
1044+
"v2.aws_scan_options_type" => "AwsScanOptionsType",
10411045
"v2.aws_traces_config" => "AWSTracesConfig",
10421046
"v2.azure_uc_config" => "AzureUCConfig",
10431047
"v2.azure_uc_config_pair" => "AzureUCConfigPair",
@@ -2824,6 +2828,7 @@ def overrides
28242828
"v1.usage_metering_api" => "UsageMeteringAPI",
28252829
"v1.users_api" => "UsersAPI",
28262830
"v1.webhooks_integration_api" => "WebhooksIntegrationAPI",
2831+
"v2.agentless_scanning_api" => "AgentlessScanningAPI",
28272832
"v2.api_management_api" => "APIManagementAPI",
28282833
"v2.apm_retention_filters_api" => "APMRetentionFiltersAPI",
28292834
"v2.apps_api" => "AppsAPI",
Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
=begin
2+
#Datadog API V2 Collection
3+
4+
#Collection of all Datadog Public endpoints.
5+
6+
The version of the OpenAPI document: 1.0
7+
8+
Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator
9+
10+
Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
11+
This product includes software developed at Datadog (https://www.datadoghq.com/).
12+
Copyright 2020-Present Datadog, Inc.
13+
14+
=end
15+
16+
require 'cgi'
17+
18+
module DatadogAPIClient::V2
19+
class AgentlessScanningAPI
20+
attr_accessor :api_client
21+
22+
def initialize(api_client = DatadogAPIClient::APIClient.default)
23+
@api_client = api_client
24+
end
25+
26+
# Get AWS Scan Options.
27+
#
28+
# @see #list_aws_scan_options_with_http_info
29+
def list_aws_scan_options(opts = {})
30+
data, _status_code, _headers = list_aws_scan_options_with_http_info(opts)
31+
data
32+
end
33+
34+
# Get AWS Scan Options.
35+
#
36+
# Fetches the scan options configured for AWS accounts.
37+
#
38+
# @param opts [Hash] the optional parameters
39+
# @return [Array<(AwsScanOptionsResponse, Integer, Hash)>] AwsScanOptionsResponse data, response status code and response headers
40+
def list_aws_scan_options_with_http_info(opts = {})
41+
42+
if @api_client.config.debugging
43+
@api_client.config.logger.debug 'Calling API: AgentlessScanningAPI.list_aws_scan_options ...'
44+
end
45+
# resource path
46+
local_var_path = '/api/v2/agentless_scanning/accounts/aws'
47+
48+
# query parameters
49+
query_params = opts[:query_params] || {}
50+
51+
# header parameters
52+
header_params = opts[:header_params] || {}
53+
# HTTP header 'Accept' (if needed)
54+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
55+
56+
# form parameters
57+
form_params = opts[:form_params] || {}
58+
59+
# http body (model)
60+
post_body = opts[:debug_body]
61+
62+
# return_type
63+
return_type = opts[:debug_return_type] || 'AwsScanOptionsResponse'
64+
65+
# auth_names
66+
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth]
67+
68+
new_options = opts.merge(
69+
:operation => :list_aws_scan_options,
70+
:header_params => header_params,
71+
:query_params => query_params,
72+
:form_params => form_params,
73+
:body => post_body,
74+
:auth_names => auth_names,
75+
:return_type => return_type,
76+
:api_version => "V2"
77+
)
78+
79+
data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, new_options)
80+
if @api_client.config.debugging
81+
@api_client.config.logger.debug "API called: AgentlessScanningAPI#list_aws_scan_options\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
82+
end
83+
return data, status_code, headers
84+
end
85+
end
86+
end

0 commit comments

Comments
 (0)