Skip to content

Commit

Permalink
Regenerate client from commit 061160d5 of spec repo
Browse files Browse the repository at this point in the history
  • Loading branch information
ci.datadog-api-spec committed Dec 19, 2024
1 parent e17558a commit f2b2937
Show file tree
Hide file tree
Showing 21 changed files with 1,413 additions and 4 deletions.
8 changes: 4 additions & 4 deletions .apigentools-info
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
"spec_versions": {
"v1": {
"apigentools_version": "1.6.6",
"regenerated": "2024-12-19 07:26:26.500720",
"spec_repo_commit": "5dd2cbe4"
"regenerated": "2024-12-19 17:18:40.393116",
"spec_repo_commit": "061160d5"
},
"v2": {
"apigentools_version": "1.6.6",
"regenerated": "2024-12-19 07:26:26.515806",
"spec_repo_commit": "5dd2cbe4"
"regenerated": "2024-12-19 17:18:40.408294",
"spec_repo_commit": "061160d5"
}
}
}
209 changes: 209 additions & 0 deletions .generator/schemas/v2/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7159,6 +7159,140 @@ components:
meta:
$ref: '#/components/schemas/CSMAgentsMetadata'
type: object
CsmCloudAccountsCoverageAnalysisAttributes:
description: CSM Cloud Accounts Coverage Analysis attributes.
properties:
aws_coverage:
$ref: '#/components/schemas/CsmCoverageAnalysis'
azure_coverage:
$ref: '#/components/schemas/CsmCoverageAnalysis'
gcp_coverage:
$ref: '#/components/schemas/CsmCoverageAnalysis'
org_id:
description: The ID of your organization.
example: 123456
format: int64
type: integer
total_coverage:
$ref: '#/components/schemas/CsmCoverageAnalysis'
type: object
CsmCloudAccountsCoverageAnalysisData:
description: CSM Cloud Accounts Coverage Analysis data.
properties:
attributes:
$ref: '#/components/schemas/CsmCloudAccountsCoverageAnalysisAttributes'
id:
description: The ID of your organization.
example: 66b3c6b5-5c9a-457e-b1c3-f247ca23afa3
type: string
type:
default: get_cloud_accounts_coverage_analysis_response_public_v0
description: The type of the resource. The value should always be `get_cloud_accounts_coverage_analysis_response_public_v0`.
example: get_cloud_accounts_coverage_analysis_response_public_v0
type: string
type: object
CsmCloudAccountsCoverageAnalysisResponse:
description: CSM Cloud Accounts Coverage Analysis response.
properties:
data:
$ref: '#/components/schemas/CsmCloudAccountsCoverageAnalysisData'
type: object
CsmCoverageAnalysis:
description: CSM Coverage Analysis.
properties:
configured_resources_count:
description: The number of fully configured resources.
example: 8
format: int64
type: integer
coverage:
description: The coverage percentage.
example: 0.8
format: double
type: number
partially_configured_resources_count:
description: The number of partially configured resources.
example: 0
format: int64
type: integer
total_resources_count:
description: The total number of resources.
example: 10
format: int64
type: integer
type: object
CsmHostsAndContainersCoverageAnalysisAttributes:
description: CSM Hosts and Containers Coverage Analysis attributes.
properties:
cspm_coverage:
$ref: '#/components/schemas/CsmCoverageAnalysis'
cws_coverage:
$ref: '#/components/schemas/CsmCoverageAnalysis'
org_id:
description: The ID of your organization.
example: 123456
format: int64
type: integer
total_coverage:
$ref: '#/components/schemas/CsmCoverageAnalysis'
vm_coverage:
$ref: '#/components/schemas/CsmCoverageAnalysis'
type: object
CsmHostsAndContainersCoverageAnalysisData:
description: CSM Hosts and Containers Coverage Analysis data.
properties:
attributes:
$ref: '#/components/schemas/CsmHostsAndContainersCoverageAnalysisAttributes'
id:
description: The ID of your organization.
example: 66b3c6b5-5c9a-457e-b1c3-f247ca23afa3
type: string
type:
default: get_hosts_and_containers_coverage_analysis_response_public_v0
description: The type of the resource. The value should always be `get_hosts_and_containers_coverage_analysis_response_public_v0`.
example: get_hosts_and_containers_coverage_analysis_response_public_v0
type: string
type: object
CsmHostsAndContainersCoverageAnalysisResponse:
description: CSM Hosts and Containers Coverage Analysis response.
properties:
data:
$ref: '#/components/schemas/CsmHostsAndContainersCoverageAnalysisData'
type: object
CsmServerlessCoverageAnalysisAttributes:
description: CSM Serverless Resources Coverage Analysis attributes.
properties:
cws_coverage:
$ref: '#/components/schemas/CsmCoverageAnalysis'
org_id:
description: The ID of your organization.
example: 123456
format: int64
type: integer
total_coverage:
$ref: '#/components/schemas/CsmCoverageAnalysis'
type: object
CsmServerlessCoverageAnalysisData:
description: CSM Serverless Resources Coverage Analysis data.
properties:
attributes:
$ref: '#/components/schemas/CsmServerlessCoverageAnalysisAttributes'
id:
description: The ID of your organization.
example: 66b3c6b5-5c9a-457e-b1c3-f247ca23afa3
type: string
type:
default: get_serverless_coverage_analysis_response_public_v0
description: The type of the resource. The value should always be `get_serverless_coverage_analysis_response_public_v0`.
example: get_serverless_coverage_analysis_response_public_v0
type: string
type: object
CsmServerlessCoverageAnalysisResponse:
description: CSM Serverless Resources Coverage Analysis response.
properties:
data:
$ref: '#/components/schemas/CsmServerlessCoverageAnalysisData'
type: object
CustomConnection:
description: The definition of `CustomConnection` object.
properties:
Expand Down Expand Up @@ -32844,6 +32978,72 @@ paths:
summary: Get all CSM Agents
tags:
- CSM Agents
/api/v2/csm/onboarding/coverage_analysis/cloud_accounts:
get:
description: 'Get the CSM Coverage Analysis of your Cloud Accounts.

This is calculated based on the number of your Cloud Accounts that are

scanned for security issues.'
operationId: GetCSMCloudAccountsCoverageAnalysis
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/CsmCloudAccountsCoverageAnalysisResponse'
description: OK
'403':
$ref: '#/components/responses/NotAuthorizedResponse'
'429':
$ref: '#/components/responses/TooManyRequestsResponse'
summary: Get the CSM Cloud Accounts Coverage Analysis
tags:
- CSM Coverage Analysis
/api/v2/csm/onboarding/coverage_analysis/hosts_and_containers:
get:
description: 'Get the CSM Coverage Analysis of your Hosts and Containers.

This is calculated based on the number of agents running on your Hosts

and Containers with CSM feature(s) enabled.'
operationId: GetCSMHostsAndContainersCoverageAnalysis
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/CsmHostsAndContainersCoverageAnalysisResponse'
description: OK
'403':
$ref: '#/components/responses/NotAuthorizedResponse'
'429':
$ref: '#/components/responses/TooManyRequestsResponse'
summary: Get the CSM Hosts and Containers Coverage Analysis
tags:
- CSM Coverage Analysis
/api/v2/csm/onboarding/coverage_analysis/serverless:
get:
description: 'Get the CSM Coverage Analysis of your Serverless Resources.

This is calculated based on the number of agents running on your Serverless

Resources with CSM feature(s) enabled.'
operationId: GetCSMServerlessCoverageAnalysis
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/CsmServerlessCoverageAnalysisResponse'
description: OK
'403':
$ref: '#/components/responses/NotAuthorizedResponse'
'429':
$ref: '#/components/responses/TooManyRequestsResponse'
summary: Get the CSM Serverless Coverage Analysis
tags:
- CSM Coverage Analysis
/api/v2/csm/onboarding/serverless/agents:
get:
description: Get the list of all CSM Serverless Agents running on your hosts
Expand Down Expand Up @@ -46613,6 +46813,15 @@ tags:

Go to https://docs.datadoghq.com/security/cloud_security_management to learn more'
name: CSM Agents
- description: 'Datadog Cloud Security Management (CSM) delivers real-time threat
detection

and continuous configuration audits across your entire cloud infrastructure,

all in a unified view for seamless collaboration and faster remediation.

Go to https://docs.datadoghq.com/security/cloud_security_management to learn more.'
name: CSM Coverage Analysis
- description: Cloud Security Management Threats (CSM Threats) monitors file, network,
and process activity across your environment to detect real-time threats to your
infrastructure. See [Cloud Security Management Threats](https://docs.datadoghq.com/security/threats/)
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
/**
* Get the CSM Cloud Accounts Coverage Analysis returns "OK" response
*/

import { client, v2 } from "@datadog/datadog-api-client";

const configuration = client.createConfiguration();
const apiInstance = new v2.CSMCoverageAnalysisApi(configuration);

apiInstance
.getCSMCloudAccountsCoverageAnalysis()
.then((data: v2.CsmCloudAccountsCoverageAnalysisResponse) => {
console.log(
"API called successfully. Returned data: " + JSON.stringify(data)
);
})
.catch((error: any) => console.error(error));
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
/**
* Get the CSM Hosts and Containers Coverage Analysis returns "OK" response
*/

import { client, v2 } from "@datadog/datadog-api-client";

const configuration = client.createConfiguration();
const apiInstance = new v2.CSMCoverageAnalysisApi(configuration);

apiInstance
.getCSMHostsAndContainersCoverageAnalysis()
.then((data: v2.CsmHostsAndContainersCoverageAnalysisResponse) => {
console.log(
"API called successfully. Returned data: " + JSON.stringify(data)
);
})
.catch((error: any) => console.error(error));
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
/**
* Get the CSM Serverless Coverage Analysis returns "OK" response
*/

import { client, v2 } from "@datadog/datadog-api-client";

const configuration = client.createConfiguration();
const apiInstance = new v2.CSMCoverageAnalysisApi(configuration);

apiInstance
.getCSMServerlessCoverageAnalysis()
.then((data: v2.CsmServerlessCoverageAnalysisResponse) => {
console.log(
"API called successfully. Returned data: " + JSON.stringify(data)
);
})
.catch((error: any) => console.error(error));
9 changes: 9 additions & 0 deletions features/support/scenarios_model_mapping.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3447,6 +3447,15 @@ export const ScenariosModelMappings: {[key: string]: {[key: string]: any}} = {
},
"operationResponseType": "CsmAgentsResponse",
},
"v2.GetCSMCloudAccountsCoverageAnalysis": {
"operationResponseType": "CsmCloudAccountsCoverageAnalysisResponse",
},
"v2.GetCSMHostsAndContainersCoverageAnalysis": {
"operationResponseType": "CsmHostsAndContainersCoverageAnalysisResponse",
},
"v2.GetCSMServerlessCoverageAnalysis": {
"operationResponseType": "CsmServerlessCoverageAnalysisResponse",
},
"v2.DeleteDashboardListItems": {
"dashboardListId": {
"type": "number",
Expand Down
31 changes: 31 additions & 0 deletions features/v2/csm_coverage_analysis.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
@endpoint(csm-coverage-analysis) @endpoint(csm-coverage-analysis-v2)
Feature: CSM Coverage Analysis
Datadog Cloud Security Management (CSM) delivers real-time threat
detection and continuous configuration audits across your entire cloud
infrastructure, all in a unified view for seamless collaboration and
faster remediation. Go to
https://docs.datadoghq.com/security/cloud_security_management to learn
more.

Background:
Given a valid "apiKeyAuth" key in the system
And a valid "appKeyAuth" key in the system
And an instance of "CSMCoverageAnalysis" API

@team:DataDog/k9-cloud-security-platform
Scenario: Get the CSM Cloud Accounts Coverage Analysis returns "OK" response
Given new "GetCSMCloudAccountsCoverageAnalysis" request
When the request is sent
Then the response status is 200 OK

@team:DataDog/k9-cloud-security-platform
Scenario: Get the CSM Hosts and Containers Coverage Analysis returns "OK" response
Given new "GetCSMHostsAndContainersCoverageAnalysis" request
When the request is sent
Then the response status is 200 OK

@team:DataDog/k9-cloud-security-platform
Scenario: Get the CSM Serverless Coverage Analysis returns "OK" response
Given new "GetCSMServerlessCoverageAnalysis" request
When the request is sent
Then the response status is 200 OK
18 changes: 18 additions & 0 deletions features/v2/undo.json
Original file line number Diff line number Diff line change
Expand Up @@ -535,6 +535,24 @@
"type": "safe"
}
},
"GetCSMCloudAccountsCoverageAnalysis": {
"tag": "CSM Coverage Analysis",
"undo": {
"type": "safe"
}
},
"GetCSMHostsAndContainersCoverageAnalysis": {
"tag": "CSM Coverage Analysis",
"undo": {
"type": "safe"
}
},
"GetCSMServerlessCoverageAnalysis": {
"tag": "CSM Coverage Analysis",
"undo": {
"type": "safe"
}
},
"ListAllCSMServerlessAgents": {
"tag": "CSM Agents",
"undo": {
Expand Down
Loading

0 comments on commit f2b2937

Please sign in to comment.