Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 18 additions & 3 deletions .generator/schemas/v2/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -88613,10 +88613,14 @@ components:
enum:
- suppressions
- critical_assets
- security_filters
- rules
type: string
x-enum-varnames:
- SUPPRESSIONS
- CRITICAL_ASSETS
- SECURITY_FILTERS
- RULES
SecurityMonitoringThirdPartyRootQuery:
description: A query to be combined with the third party case query.
properties:
Expand Down Expand Up @@ -177097,8 +177101,9 @@ paths:
description: |-
Export multiple security monitoring resources to Terraform, packaged as a zip archive.
The `resource_type` path parameter specifies the type of resources to export
and must be one of `suppressions` or `critical_assets`.
and must be one of `suppressions`, `critical_assets`, `security_filters`, or `rules`.
A maximum of 1000 resources can be exported in a single request.
For `rules`, partner rules cannot be exported and return a 400 error.
operationId: BulkExportSecurityMonitoringTerraformResources
parameters:
- $ref: "#/components/parameters/SecurityMonitoringTerraformResourceType"
Expand Down Expand Up @@ -177143,6 +177148,8 @@ paths:
- security_monitoring_suppressions_read
- AuthZ:
- security_monitoring_rules_read
- AuthZ:
- security_monitoring_filters_read
summary: Export security monitoring resources to Terraform
tags:
- Security Monitoring
Expand All @@ -177152,13 +177159,14 @@ paths:
permissions:
- security_monitoring_suppressions_read
- security_monitoring_rules_read
- security_monitoring_filters_read
x-unstable: "**Note**: This endpoint is in Preview. If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/)."
/api/v2/security_monitoring/terraform/{resource_type}/convert:
post:
description: |-
Convert a security monitoring resource that doesn't (yet) exist from JSON to Terraform.
The `resource_type` path parameter specifies the type of resource to convert
and must be one of `suppressions` or `critical_assets`.
and must be one of `suppressions`, `critical_assets`, `security_filters`, or `rules`.
operationId: ConvertSecurityMonitoringTerraformResource
parameters:
- $ref: "#/components/parameters/SecurityMonitoringTerraformResourceType"
Expand Down Expand Up @@ -177211,6 +177219,8 @@ paths:
- security_monitoring_suppressions_read
- AuthZ:
- security_monitoring_rules_read
- AuthZ:
- security_monitoring_filters_read
summary: Convert security monitoring resource to Terraform
tags:
- Security Monitoring
Expand All @@ -177220,13 +177230,15 @@ paths:
permissions:
- security_monitoring_suppressions_read
- security_monitoring_rules_read
- security_monitoring_filters_read
x-unstable: "**Note**: This endpoint is in Preview. If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/)."
/api/v2/security_monitoring/terraform/{resource_type}/{resource_id}:
get:
description: |-
Export a security monitoring resource to a Terraform configuration.
The `resource_type` path parameter specifies the type of resource to export
and must be one of `suppressions` or `critical_assets`.
and must be one of `suppressions`, `critical_assets`, `security_filters`, or `rules`.
For `rules`, partner rules cannot be exported and return a 400 error.
operationId: ExportSecurityMonitoringTerraformResource
parameters:
- $ref: "#/components/parameters/SecurityMonitoringTerraformResourceType"
Expand Down Expand Up @@ -177261,6 +177273,8 @@ paths:
- security_monitoring_suppressions_read
- AuthZ:
- security_monitoring_rules_read
- AuthZ:
- security_monitoring_filters_read
summary: Export security monitoring resource to Terraform
tags:
- Security Monitoring
Expand All @@ -177269,6 +177283,7 @@ paths:
permissions:
- security_monitoring_suppressions_read
- security_monitoring_rules_read
- security_monitoring_filters_read
x-unstable: "**Note**: This endpoint is in Preview. If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/)."
/api/v2/sensitive-data-scanner/config:
get:
Expand Down
14 changes: 8 additions & 6 deletions lib/datadog_api_client/v2/api/security_monitoring_api.rb
Original file line number Diff line number Diff line change
Expand Up @@ -888,8 +888,9 @@ def bulk_export_security_monitoring_terraform_resources(resource_type, body, opt
#
# Export multiple security monitoring resources to Terraform, packaged as a zip archive.
# The `resource_type` path parameter specifies the type of resources to export
# and must be one of `suppressions` or `critical_assets`.
# and must be one of `suppressions`, `critical_assets`, `security_filters`, or `rules`.
# A maximum of 1000 resources can be exported in a single request.
# For `rules`, partner rules cannot be exported and return a 400 error.
#
# @param resource_type [SecurityMonitoringTerraformResourceType] The type of security monitoring resource to export.
# @param body [SecurityMonitoringTerraformBulkExportRequest] The resource IDs to export.
Expand All @@ -911,7 +912,7 @@ def bulk_export_security_monitoring_terraform_resources_with_http_info(resource_
fail ArgumentError, "Missing the required parameter 'resource_type' when calling SecurityMonitoringAPI.bulk_export_security_monitoring_terraform_resources"
end
# verify enum value
allowable_values = ['suppressions', 'critical_assets']
allowable_values = ['suppressions', 'critical_assets', 'security_filters', 'rules']
if @api_client.config.client_side_validation && !allowable_values.include?(resource_type)
fail ArgumentError, "invalid value for \"resource_type\", must be one of #{allowable_values}"
end
Expand Down Expand Up @@ -1262,7 +1263,7 @@ def convert_security_monitoring_terraform_resource(resource_type, body, opts = {
#
# Convert a security monitoring resource that doesn't (yet) exist from JSON to Terraform.
# The `resource_type` path parameter specifies the type of resource to convert
# and must be one of `suppressions` or `critical_assets`.
# and must be one of `suppressions`, `critical_assets`, `security_filters`, or `rules`.
#
# @param resource_type [SecurityMonitoringTerraformResourceType] The type of security monitoring resource to export.
# @param body [SecurityMonitoringTerraformConvertRequest] The resource JSON to convert.
Expand All @@ -1284,7 +1285,7 @@ def convert_security_monitoring_terraform_resource_with_http_info(resource_type,
fail ArgumentError, "Missing the required parameter 'resource_type' when calling SecurityMonitoringAPI.convert_security_monitoring_terraform_resource"
end
# verify enum value
allowable_values = ['suppressions', 'critical_assets']
allowable_values = ['suppressions', 'critical_assets', 'security_filters', 'rules']
if @api_client.config.client_side_validation && !allowable_values.include?(resource_type)
fail ArgumentError, "invalid value for \"resource_type\", must be one of #{allowable_values}"
end
Expand Down Expand Up @@ -4088,7 +4089,8 @@ def export_security_monitoring_terraform_resource(resource_type, resource_id, op
#
# Export a security monitoring resource to a Terraform configuration.
# The `resource_type` path parameter specifies the type of resource to export
# and must be one of `suppressions` or `critical_assets`.
# and must be one of `suppressions`, `critical_assets`, `security_filters`, or `rules`.
# For `rules`, partner rules cannot be exported and return a 400 error.
#
# @param resource_type [SecurityMonitoringTerraformResourceType] The type of security monitoring resource to export.
# @param resource_id [String] The ID of the security monitoring resource to export.
Expand All @@ -4110,7 +4112,7 @@ def export_security_monitoring_terraform_resource_with_http_info(resource_type,
fail ArgumentError, "Missing the required parameter 'resource_type' when calling SecurityMonitoringAPI.export_security_monitoring_terraform_resource"
end
# verify enum value
allowable_values = ['suppressions', 'critical_assets']
allowable_values = ['suppressions', 'critical_assets', 'security_filters', 'rules']
if @api_client.config.client_side_validation && !allowable_values.include?(resource_type)
fail ArgumentError, "invalid value for \"resource_type\", must be one of #{allowable_values}"
end
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,7 @@ class SecurityMonitoringTerraformResourceType

SUPPRESSIONS = "suppressions".freeze
CRITICAL_ASSETS = "critical_assets".freeze
SECURITY_FILTERS = "security_filters".freeze
RULES = "rules".freeze
end
end
Loading