datadog_api_client 2.35.0 → 2.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.apigentools-info +4 -4
- data/.generator/schemas/v1/openapi.yaml +0 -3
- data/.generator/schemas/v2/openapi.yaml +355 -0
- data/CHANGELOG.md +17 -0
- data/examples/v2/csm-threats/CreateCSMThreatsAgentRule_1295653933.rb +3 -0
- data/examples/v2/logs-custom-destinations/CreateLogsCustomDestination_1735989579.rb +30 -0
- data/examples/v2/microsoft-teams-integration/CreateWorkflowsWebhookHandle_1716851881.rb +1 -1
- data/examples/v2/teams/AddMemberTeam.rb +15 -0
- data/examples/v2/teams/ListMemberTeams.rb +8 -0
- data/examples/v2/teams/ListMemberTeams_1662850354.rb +8 -0
- data/examples/v2/teams/RemoveMemberTeam.rb +8 -0
- data/lib/datadog_api_client/configuration.rb +3 -0
- data/lib/datadog_api_client/inflector.rb +8 -0
- data/lib/datadog_api_client/v1/models/synthetics_basic_auth_web.rb +2 -31
- data/lib/datadog_api_client/v2/api/teams_api.rb +254 -0
- data/lib/datadog_api_client/v2/models/add_member_team_request.rb +123 -0
- data/lib/datadog_api_client/v2/models/change_event_custom_attributes_author_type.rb +2 -0
- data/lib/datadog_api_client/v2/models/cloud_configuration_rule_payload.rb +21 -1
- data/lib/datadog_api_client/v2/models/cloud_workload_security_agent_rule_action.rb +11 -1
- data/lib/datadog_api_client/v2/models/custom_destination_forward_destination.rb +2 -1
- data/lib/datadog_api_client/v2/models/custom_destination_forward_destination_microsoft_sentinel.rb +228 -0
- data/lib/datadog_api_client/v2/models/custom_destination_forward_destination_microsoft_sentinel_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/custom_destination_response_forward_destination.rb +2 -1
- data/lib/datadog_api_client/v2/models/custom_destination_response_forward_destination_microsoft_sentinel.rb +228 -0
- data/lib/datadog_api_client/v2/models/custom_destination_response_forward_destination_microsoft_sentinel_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/member_team.rb +144 -0
- data/lib/datadog_api_client/v2/models/member_team_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_rule_case.rb +11 -1
- data/lib/datadog_api_client/v2/models/security_monitoring_rule_type_create.rb +1 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_rule_type_read.rb +1 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_rule_update_payload.rb +21 -1
- data/lib/datadog_api_client/v2/models/security_monitoring_signal_rule_payload.rb +21 -1
- data/lib/datadog_api_client/v2/models/security_monitoring_signal_rule_response.rb +21 -1
- data/lib/datadog_api_client/v2/models/security_monitoring_standard_rule_payload.rb +21 -1
- data/lib/datadog_api_client/v2/models/security_monitoring_standard_rule_query.rb +11 -1
- data/lib/datadog_api_client/v2/models/security_monitoring_standard_rule_response.rb +21 -1
- data/lib/datadog_api_client/v2/models/security_monitoring_third_party_rule_case.rb +11 -1
- data/lib/datadog_api_client/v2/models/sensitive_data_scanner_group_attributes.rb +15 -3
- data/lib/datadog_api_client/v2/models/sensitive_data_scanner_samplings.rb +137 -0
- data/lib/datadog_api_client/version.rb +1 -1
- metadata +14 -1
@@ -267,6 +267,9 @@ module DatadogAPIClient
|
|
267
267
|
"v2.create_slo_report_job": false,
|
268
268
|
"v2.get_slo_report": false,
|
269
269
|
"v2.get_slo_report_job_status": false,
|
270
|
+
"v2.add_member_team": false,
|
271
|
+
"v2.list_member_teams": false,
|
272
|
+
"v2.remove_member_team": false,
|
270
273
|
"v2.create_incident_team": false,
|
271
274
|
"v2.delete_incident_team": false,
|
272
275
|
"v2.get_incident_team": false,
|
@@ -955,6 +955,7 @@ module DatadogAPIClient
|
|
955
955
|
"v2.active_billing_dimensions_body" => "ActiveBillingDimensionsBody",
|
956
956
|
"v2.active_billing_dimensions_response" => "ActiveBillingDimensionsResponse",
|
957
957
|
"v2.active_billing_dimensions_type" => "ActiveBillingDimensionsType",
|
958
|
+
"v2.add_member_team_request" => "AddMemberTeamRequest",
|
958
959
|
"v2.advisory" => "Advisory",
|
959
960
|
"v2.annotation" => "Annotation",
|
960
961
|
"v2.annotation_display" => "AnnotationDisplay",
|
@@ -1512,6 +1513,8 @@ module DatadogAPIClient
|
|
1512
1513
|
"v2.custom_destination_forward_destination_elasticsearch_type" => "CustomDestinationForwardDestinationElasticsearchType",
|
1513
1514
|
"v2.custom_destination_forward_destination_http" => "CustomDestinationForwardDestinationHttp",
|
1514
1515
|
"v2.custom_destination_forward_destination_http_type" => "CustomDestinationForwardDestinationHttpType",
|
1516
|
+
"v2.custom_destination_forward_destination_microsoft_sentinel" => "CustomDestinationForwardDestinationMicrosoftSentinel",
|
1517
|
+
"v2.custom_destination_forward_destination_microsoft_sentinel_type" => "CustomDestinationForwardDestinationMicrosoftSentinelType",
|
1515
1518
|
"v2.custom_destination_forward_destination_splunk" => "CustomDestinationForwardDestinationSplunk",
|
1516
1519
|
"v2.custom_destination_forward_destination_splunk_type" => "CustomDestinationForwardDestinationSplunkType",
|
1517
1520
|
"v2.custom_destination_http_destination_auth" => "CustomDestinationHttpDestinationAuth",
|
@@ -1527,6 +1530,8 @@ module DatadogAPIClient
|
|
1527
1530
|
"v2.custom_destination_response_forward_destination_elasticsearch_type" => "CustomDestinationResponseForwardDestinationElasticsearchType",
|
1528
1531
|
"v2.custom_destination_response_forward_destination_http" => "CustomDestinationResponseForwardDestinationHttp",
|
1529
1532
|
"v2.custom_destination_response_forward_destination_http_type" => "CustomDestinationResponseForwardDestinationHttpType",
|
1533
|
+
"v2.custom_destination_response_forward_destination_microsoft_sentinel" => "CustomDestinationResponseForwardDestinationMicrosoftSentinel",
|
1534
|
+
"v2.custom_destination_response_forward_destination_microsoft_sentinel_type" => "CustomDestinationResponseForwardDestinationMicrosoftSentinelType",
|
1530
1535
|
"v2.custom_destination_response_forward_destination_splunk" => "CustomDestinationResponseForwardDestinationSplunk",
|
1531
1536
|
"v2.custom_destination_response_forward_destination_splunk_type" => "CustomDestinationResponseForwardDestinationSplunkType",
|
1532
1537
|
"v2.custom_destination_response_http_destination_auth" => "CustomDestinationResponseHttpDestinationAuth",
|
@@ -2199,6 +2204,8 @@ module DatadogAPIClient
|
|
2199
2204
|
"v2.logs_storage_tier" => "LogsStorageTier",
|
2200
2205
|
"v2.logs_warning" => "LogsWarning",
|
2201
2206
|
"v2.log_type" => "LogType",
|
2207
|
+
"v2.member_team" => "MemberTeam",
|
2208
|
+
"v2.member_team_type" => "MemberTeamType",
|
2202
2209
|
"v2.metadata" => "Metadata",
|
2203
2210
|
"v2.metric" => "Metric",
|
2204
2211
|
"v2.metric_active_configuration_type" => "MetricActiveConfigurationType",
|
@@ -3098,6 +3105,7 @@ module DatadogAPIClient
|
|
3098
3105
|
"v2.sensitive_data_scanner_rule_update" => "SensitiveDataScannerRuleUpdate",
|
3099
3106
|
"v2.sensitive_data_scanner_rule_update_request" => "SensitiveDataScannerRuleUpdateRequest",
|
3100
3107
|
"v2.sensitive_data_scanner_rule_update_response" => "SensitiveDataScannerRuleUpdateResponse",
|
3108
|
+
"v2.sensitive_data_scanner_samplings" => "SensitiveDataScannerSamplings",
|
3101
3109
|
"v2.sensitive_data_scanner_standard_pattern" => "SensitiveDataScannerStandardPattern",
|
3102
3110
|
"v2.sensitive_data_scanner_standard_pattern_attributes" => "SensitiveDataScannerStandardPatternAttributes",
|
3103
3111
|
"v2.sensitive_data_scanner_standard_pattern_data" => "SensitiveDataScannerStandardPatternData",
|
@@ -22,13 +22,13 @@ module DatadogAPIClient::V1
|
|
22
22
|
include BaseGenericModel
|
23
23
|
|
24
24
|
# Password to use for the basic authentication.
|
25
|
-
|
25
|
+
attr_accessor :password
|
26
26
|
|
27
27
|
# The type of basic authentication to use when performing the test.
|
28
28
|
attr_accessor :type
|
29
29
|
|
30
30
|
# Username to use for the basic authentication.
|
31
|
-
|
31
|
+
attr_accessor :username
|
32
32
|
|
33
33
|
attr_accessor :additional_properties
|
34
34
|
|
@@ -83,35 +83,6 @@ module DatadogAPIClient::V1
|
|
83
83
|
end
|
84
84
|
end
|
85
85
|
|
86
|
-
# Check to see if the all the properties in the model are valid
|
87
|
-
# @return true if the model is valid
|
88
|
-
# @!visibility private
|
89
|
-
def valid?
|
90
|
-
return false if @password.nil?
|
91
|
-
return false if @username.nil?
|
92
|
-
true
|
93
|
-
end
|
94
|
-
|
95
|
-
# Custom attribute writer method with validation
|
96
|
-
# @param password [Object] Object to be assigned
|
97
|
-
# @!visibility private
|
98
|
-
def password=(password)
|
99
|
-
if password.nil?
|
100
|
-
fail ArgumentError, 'invalid value for "password", password cannot be nil.'
|
101
|
-
end
|
102
|
-
@password = password
|
103
|
-
end
|
104
|
-
|
105
|
-
# Custom attribute writer method with validation
|
106
|
-
# @param username [Object] Object to be assigned
|
107
|
-
# @!visibility private
|
108
|
-
def username=(username)
|
109
|
-
if username.nil?
|
110
|
-
fail ArgumentError, 'invalid value for "username", username cannot be nil.'
|
111
|
-
end
|
112
|
-
@username = username
|
113
|
-
end
|
114
|
-
|
115
86
|
# Returns the object in the form of hash, with additionalProperties support.
|
116
87
|
# @return [Hash] Returns the object in the form of hash
|
117
88
|
# @!visibility private
|
@@ -23,6 +23,85 @@ module DatadogAPIClient::V2
|
|
23
23
|
@api_client = api_client
|
24
24
|
end
|
25
25
|
|
26
|
+
# Add a member team.
|
27
|
+
#
|
28
|
+
# @see #add_member_team_with_http_info
|
29
|
+
def add_member_team(super_team_id, body, opts = {})
|
30
|
+
add_member_team_with_http_info(super_team_id, body, opts)
|
31
|
+
nil
|
32
|
+
end
|
33
|
+
|
34
|
+
# Add a member team.
|
35
|
+
#
|
36
|
+
# Add a member team.
|
37
|
+
# Adds the team given by the `id` in the body as a member team of the super team.
|
38
|
+
#
|
39
|
+
# @param super_team_id [String] None
|
40
|
+
# @param body [AddMemberTeamRequest]
|
41
|
+
# @param opts [Hash] the optional parameters
|
42
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
43
|
+
def add_member_team_with_http_info(super_team_id, body, opts = {})
|
44
|
+
unstable_enabled = @api_client.config.unstable_operations["v2.add_member_team".to_sym]
|
45
|
+
if unstable_enabled
|
46
|
+
@api_client.config.logger.warn format("Using unstable operation '%s'", "v2.add_member_team")
|
47
|
+
else
|
48
|
+
raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.add_member_team"))
|
49
|
+
end
|
50
|
+
|
51
|
+
if @api_client.config.debugging
|
52
|
+
@api_client.config.logger.debug 'Calling API: TeamsAPI.add_member_team ...'
|
53
|
+
end
|
54
|
+
# verify the required parameter 'super_team_id' is set
|
55
|
+
if @api_client.config.client_side_validation && super_team_id.nil?
|
56
|
+
fail ArgumentError, "Missing the required parameter 'super_team_id' when calling TeamsAPI.add_member_team"
|
57
|
+
end
|
58
|
+
# verify the required parameter 'body' is set
|
59
|
+
if @api_client.config.client_side_validation && body.nil?
|
60
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling TeamsAPI.add_member_team"
|
61
|
+
end
|
62
|
+
# resource path
|
63
|
+
local_var_path = '/api/v2/team/{super_team_id}/member_teams'.sub('{super_team_id}', CGI.escape(super_team_id.to_s).gsub('%2F', '/'))
|
64
|
+
|
65
|
+
# query parameters
|
66
|
+
query_params = opts[:query_params] || {}
|
67
|
+
|
68
|
+
# header parameters
|
69
|
+
header_params = opts[:header_params] || {}
|
70
|
+
# HTTP header 'Accept' (if needed)
|
71
|
+
header_params['Accept'] = @api_client.select_header_accept(['*/*'])
|
72
|
+
# HTTP header 'Content-Type'
|
73
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
74
|
+
|
75
|
+
# form parameters
|
76
|
+
form_params = opts[:form_params] || {}
|
77
|
+
|
78
|
+
# http body (model)
|
79
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
|
80
|
+
|
81
|
+
# return_type
|
82
|
+
return_type = opts[:debug_return_type]
|
83
|
+
|
84
|
+
# auth_names
|
85
|
+
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
|
86
|
+
|
87
|
+
new_options = opts.merge(
|
88
|
+
:operation => :add_member_team,
|
89
|
+
:header_params => header_params,
|
90
|
+
:query_params => query_params,
|
91
|
+
:form_params => form_params,
|
92
|
+
:body => post_body,
|
93
|
+
:auth_names => auth_names,
|
94
|
+
:return_type => return_type,
|
95
|
+
:api_version => "V2"
|
96
|
+
)
|
97
|
+
|
98
|
+
data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, new_options)
|
99
|
+
if @api_client.config.debugging
|
100
|
+
@api_client.config.logger.debug "API called: TeamsAPI#add_member_team\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
101
|
+
end
|
102
|
+
return data, status_code, headers
|
103
|
+
end
|
104
|
+
|
26
105
|
# Create a team.
|
27
106
|
#
|
28
107
|
# @see #create_team_with_http_info
|
@@ -869,6 +948,105 @@ module DatadogAPIClient::V2
|
|
869
948
|
return data, status_code, headers
|
870
949
|
end
|
871
950
|
|
951
|
+
# Get all member teams.
|
952
|
+
#
|
953
|
+
# @see #list_member_teams_with_http_info
|
954
|
+
def list_member_teams(super_team_id, opts = {})
|
955
|
+
data, _status_code, _headers = list_member_teams_with_http_info(super_team_id, opts)
|
956
|
+
data
|
957
|
+
end
|
958
|
+
|
959
|
+
# Get all member teams.
|
960
|
+
#
|
961
|
+
# Get all member teams.
|
962
|
+
#
|
963
|
+
# @param super_team_id [String] None
|
964
|
+
# @param opts [Hash] the optional parameters
|
965
|
+
# @option opts [Integer] :page_size Size for a given page. The maximum allowed value is 100.
|
966
|
+
# @option opts [Integer] :page_number Specific page number to return.
|
967
|
+
# @option opts [Array<TeamsField>] :fields_team List of fields that need to be fetched.
|
968
|
+
# @return [Array<(TeamsResponse, Integer, Hash)>] TeamsResponse data, response status code and response headers
|
969
|
+
def list_member_teams_with_http_info(super_team_id, opts = {})
|
970
|
+
unstable_enabled = @api_client.config.unstable_operations["v2.list_member_teams".to_sym]
|
971
|
+
if unstable_enabled
|
972
|
+
@api_client.config.logger.warn format("Using unstable operation '%s'", "v2.list_member_teams")
|
973
|
+
else
|
974
|
+
raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.list_member_teams"))
|
975
|
+
end
|
976
|
+
|
977
|
+
if @api_client.config.debugging
|
978
|
+
@api_client.config.logger.debug 'Calling API: TeamsAPI.list_member_teams ...'
|
979
|
+
end
|
980
|
+
# verify the required parameter 'super_team_id' is set
|
981
|
+
if @api_client.config.client_side_validation && super_team_id.nil?
|
982
|
+
fail ArgumentError, "Missing the required parameter 'super_team_id' when calling TeamsAPI.list_member_teams"
|
983
|
+
end
|
984
|
+
# resource path
|
985
|
+
local_var_path = '/api/v2/team/{super_team_id}/member_teams'.sub('{super_team_id}', CGI.escape(super_team_id.to_s).gsub('%2F', '/'))
|
986
|
+
|
987
|
+
# query parameters
|
988
|
+
query_params = opts[:query_params] || {}
|
989
|
+
query_params[:'page[size]'] = opts[:'page_size'] if !opts[:'page_size'].nil?
|
990
|
+
query_params[:'page[number]'] = opts[:'page_number'] if !opts[:'page_number'].nil?
|
991
|
+
query_params[:'fields[team]'] = @api_client.build_collection_param(opts[:'fields_team'], :csv) if !opts[:'fields_team'].nil?
|
992
|
+
|
993
|
+
# header parameters
|
994
|
+
header_params = opts[:header_params] || {}
|
995
|
+
# HTTP header 'Accept' (if needed)
|
996
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
997
|
+
|
998
|
+
# form parameters
|
999
|
+
form_params = opts[:form_params] || {}
|
1000
|
+
|
1001
|
+
# http body (model)
|
1002
|
+
post_body = opts[:debug_body]
|
1003
|
+
|
1004
|
+
# return_type
|
1005
|
+
return_type = opts[:debug_return_type] || 'TeamsResponse'
|
1006
|
+
|
1007
|
+
# auth_names
|
1008
|
+
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
|
1009
|
+
|
1010
|
+
new_options = opts.merge(
|
1011
|
+
:operation => :list_member_teams,
|
1012
|
+
:header_params => header_params,
|
1013
|
+
:query_params => query_params,
|
1014
|
+
:form_params => form_params,
|
1015
|
+
:body => post_body,
|
1016
|
+
:auth_names => auth_names,
|
1017
|
+
:return_type => return_type,
|
1018
|
+
:api_version => "V2"
|
1019
|
+
)
|
1020
|
+
|
1021
|
+
data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, new_options)
|
1022
|
+
if @api_client.config.debugging
|
1023
|
+
@api_client.config.logger.debug "API called: TeamsAPI#list_member_teams\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1024
|
+
end
|
1025
|
+
return data, status_code, headers
|
1026
|
+
end
|
1027
|
+
|
1028
|
+
# Get all member teams.
|
1029
|
+
#
|
1030
|
+
# Provide a paginated version of {#list_member_teams}, returning all items.
|
1031
|
+
#
|
1032
|
+
# To use it you need to use a block: list_member_teams_with_pagination { |item| p item }
|
1033
|
+
#
|
1034
|
+
# @yield [Team] Paginated items
|
1035
|
+
def list_member_teams_with_pagination(super_team_id, opts = {})
|
1036
|
+
api_version = "V2"
|
1037
|
+
page_size = @api_client.get_attribute_from_path(opts, "page_size", 10)
|
1038
|
+
@api_client.set_attribute_from_path(api_version, opts, "page_size", Integer, page_size)
|
1039
|
+
@api_client.set_attribute_from_path(api_version, opts, "page_number", Integer, 0)
|
1040
|
+
while true do
|
1041
|
+
response = list_member_teams(super_team_id, opts)
|
1042
|
+
@api_client.get_attribute_from_path(response, "data").each { |item| yield(item) }
|
1043
|
+
if @api_client.get_attribute_from_path(response, "data").length < page_size
|
1044
|
+
break
|
1045
|
+
end
|
1046
|
+
@api_client.set_attribute_from_path(api_version, opts, "page_number", Integer, @api_client.get_attribute_from_path(opts, "page_number", 0) + 1)
|
1047
|
+
end
|
1048
|
+
end
|
1049
|
+
|
872
1050
|
# Get all teams.
|
873
1051
|
#
|
874
1052
|
# @see #list_teams_with_http_info
|
@@ -971,6 +1149,82 @@ module DatadogAPIClient::V2
|
|
971
1149
|
end
|
972
1150
|
end
|
973
1151
|
|
1152
|
+
# Remove a member team.
|
1153
|
+
#
|
1154
|
+
# @see #remove_member_team_with_http_info
|
1155
|
+
def remove_member_team(super_team_id, member_team_id, opts = {})
|
1156
|
+
remove_member_team_with_http_info(super_team_id, member_team_id, opts)
|
1157
|
+
nil
|
1158
|
+
end
|
1159
|
+
|
1160
|
+
# Remove a member team.
|
1161
|
+
#
|
1162
|
+
# Remove a super team's member team identified by `member_team_id`.
|
1163
|
+
#
|
1164
|
+
# @param super_team_id [String] None
|
1165
|
+
# @param member_team_id [String] None
|
1166
|
+
# @param opts [Hash] the optional parameters
|
1167
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
1168
|
+
def remove_member_team_with_http_info(super_team_id, member_team_id, opts = {})
|
1169
|
+
unstable_enabled = @api_client.config.unstable_operations["v2.remove_member_team".to_sym]
|
1170
|
+
if unstable_enabled
|
1171
|
+
@api_client.config.logger.warn format("Using unstable operation '%s'", "v2.remove_member_team")
|
1172
|
+
else
|
1173
|
+
raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.remove_member_team"))
|
1174
|
+
end
|
1175
|
+
|
1176
|
+
if @api_client.config.debugging
|
1177
|
+
@api_client.config.logger.debug 'Calling API: TeamsAPI.remove_member_team ...'
|
1178
|
+
end
|
1179
|
+
# verify the required parameter 'super_team_id' is set
|
1180
|
+
if @api_client.config.client_side_validation && super_team_id.nil?
|
1181
|
+
fail ArgumentError, "Missing the required parameter 'super_team_id' when calling TeamsAPI.remove_member_team"
|
1182
|
+
end
|
1183
|
+
# verify the required parameter 'member_team_id' is set
|
1184
|
+
if @api_client.config.client_side_validation && member_team_id.nil?
|
1185
|
+
fail ArgumentError, "Missing the required parameter 'member_team_id' when calling TeamsAPI.remove_member_team"
|
1186
|
+
end
|
1187
|
+
# resource path
|
1188
|
+
local_var_path = '/api/v2/team/{super_team_id}/member_teams/{member_team_id}'.sub('{super_team_id}', CGI.escape(super_team_id.to_s).gsub('%2F', '/')).sub('{member_team_id}', CGI.escape(member_team_id.to_s).gsub('%2F', '/'))
|
1189
|
+
|
1190
|
+
# query parameters
|
1191
|
+
query_params = opts[:query_params] || {}
|
1192
|
+
|
1193
|
+
# header parameters
|
1194
|
+
header_params = opts[:header_params] || {}
|
1195
|
+
# HTTP header 'Accept' (if needed)
|
1196
|
+
header_params['Accept'] = @api_client.select_header_accept(['*/*'])
|
1197
|
+
|
1198
|
+
# form parameters
|
1199
|
+
form_params = opts[:form_params] || {}
|
1200
|
+
|
1201
|
+
# http body (model)
|
1202
|
+
post_body = opts[:debug_body]
|
1203
|
+
|
1204
|
+
# return_type
|
1205
|
+
return_type = opts[:debug_return_type]
|
1206
|
+
|
1207
|
+
# auth_names
|
1208
|
+
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
|
1209
|
+
|
1210
|
+
new_options = opts.merge(
|
1211
|
+
:operation => :remove_member_team,
|
1212
|
+
:header_params => header_params,
|
1213
|
+
:query_params => query_params,
|
1214
|
+
:form_params => form_params,
|
1215
|
+
:body => post_body,
|
1216
|
+
:auth_names => auth_names,
|
1217
|
+
:return_type => return_type,
|
1218
|
+
:api_version => "V2"
|
1219
|
+
)
|
1220
|
+
|
1221
|
+
data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, new_options)
|
1222
|
+
if @api_client.config.debugging
|
1223
|
+
@api_client.config.logger.debug "API called: TeamsAPI#remove_member_team\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1224
|
+
end
|
1225
|
+
return data, status_code, headers
|
1226
|
+
end
|
1227
|
+
|
974
1228
|
# Update a team.
|
975
1229
|
#
|
976
1230
|
# @see #update_team_with_http_info
|
@@ -0,0 +1,123 @@
|
|
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
|
+
Contact: support@datadoghq.com
|
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 'date'
|
17
|
+
require 'time'
|
18
|
+
|
19
|
+
module DatadogAPIClient::V2
|
20
|
+
# Request to add a member team to super team's hierarchy
|
21
|
+
class AddMemberTeamRequest
|
22
|
+
include BaseGenericModel
|
23
|
+
|
24
|
+
# A member team
|
25
|
+
attr_reader :data
|
26
|
+
|
27
|
+
attr_accessor :additional_properties
|
28
|
+
|
29
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
30
|
+
# @!visibility private
|
31
|
+
def self.attribute_map
|
32
|
+
{
|
33
|
+
:'data' => :'data'
|
34
|
+
}
|
35
|
+
end
|
36
|
+
|
37
|
+
# Attribute type mapping.
|
38
|
+
# @!visibility private
|
39
|
+
def self.openapi_types
|
40
|
+
{
|
41
|
+
:'data' => :'MemberTeam'
|
42
|
+
}
|
43
|
+
end
|
44
|
+
|
45
|
+
# Initializes the object
|
46
|
+
# @param attributes [Hash] Model attributes in the form of hash
|
47
|
+
# @!visibility private
|
48
|
+
def initialize(attributes = {})
|
49
|
+
if (!attributes.is_a?(Hash))
|
50
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::AddMemberTeamRequest` initialize method"
|
51
|
+
end
|
52
|
+
|
53
|
+
self.additional_properties = {}
|
54
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
55
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
56
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
57
|
+
self.additional_properties[k.to_sym] = v
|
58
|
+
else
|
59
|
+
h[k.to_sym] = v
|
60
|
+
end
|
61
|
+
}
|
62
|
+
|
63
|
+
if attributes.key?(:'data')
|
64
|
+
self.data = attributes[:'data']
|
65
|
+
end
|
66
|
+
end
|
67
|
+
|
68
|
+
# Check to see if the all the properties in the model are valid
|
69
|
+
# @return true if the model is valid
|
70
|
+
# @!visibility private
|
71
|
+
def valid?
|
72
|
+
return false if @data.nil?
|
73
|
+
true
|
74
|
+
end
|
75
|
+
|
76
|
+
# Custom attribute writer method with validation
|
77
|
+
# @param data [Object] Object to be assigned
|
78
|
+
# @!visibility private
|
79
|
+
def data=(data)
|
80
|
+
if data.nil?
|
81
|
+
fail ArgumentError, 'invalid value for "data", data cannot be nil.'
|
82
|
+
end
|
83
|
+
@data = data
|
84
|
+
end
|
85
|
+
|
86
|
+
# Returns the object in the form of hash, with additionalProperties support.
|
87
|
+
# @return [Hash] Returns the object in the form of hash
|
88
|
+
# @!visibility private
|
89
|
+
def to_hash
|
90
|
+
hash = {}
|
91
|
+
self.class.attribute_map.each_pair do |attr, param|
|
92
|
+
value = self.send(attr)
|
93
|
+
if value.nil?
|
94
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
95
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
96
|
+
end
|
97
|
+
|
98
|
+
hash[param] = _to_hash(value)
|
99
|
+
end
|
100
|
+
self.additional_properties.each_pair do |attr, value|
|
101
|
+
hash[attr] = value
|
102
|
+
end
|
103
|
+
hash
|
104
|
+
end
|
105
|
+
|
106
|
+
# Checks equality by comparing each attribute.
|
107
|
+
# @param o [Object] Object to be compared
|
108
|
+
# @!visibility private
|
109
|
+
def ==(o)
|
110
|
+
return true if self.equal?(o)
|
111
|
+
self.class == o.class &&
|
112
|
+
data == o.data &&
|
113
|
+
additional_properties == o.additional_properties
|
114
|
+
end
|
115
|
+
|
116
|
+
# Calculates hash code according to all attributes.
|
117
|
+
# @return [Integer] Hash code
|
118
|
+
# @!visibility private
|
119
|
+
def hash
|
120
|
+
[data, additional_properties].hash
|
121
|
+
end
|
122
|
+
end
|
123
|
+
end
|
@@ -28,6 +28,12 @@ module DatadogAPIClient::V2
|
|
28
28
|
# How to generate compliance signals. Useful for cloud_configuration rules only.
|
29
29
|
attr_reader :compliance_signal_options
|
30
30
|
|
31
|
+
# Custom/Overridden message for generated signals (used in case of Default rule update).
|
32
|
+
attr_accessor :custom_message
|
33
|
+
|
34
|
+
# Custom/Overridden name of the rule (used in case of Default rule update).
|
35
|
+
attr_accessor :custom_name
|
36
|
+
|
31
37
|
# Additional queries to filter matched events before they are processed.
|
32
38
|
attr_accessor :filters
|
33
39
|
|
@@ -57,6 +63,8 @@ module DatadogAPIClient::V2
|
|
57
63
|
{
|
58
64
|
:'cases' => :'cases',
|
59
65
|
:'compliance_signal_options' => :'complianceSignalOptions',
|
66
|
+
:'custom_message' => :'customMessage',
|
67
|
+
:'custom_name' => :'customName',
|
60
68
|
:'filters' => :'filters',
|
61
69
|
:'is_enabled' => :'isEnabled',
|
62
70
|
:'message' => :'message',
|
@@ -73,6 +81,8 @@ module DatadogAPIClient::V2
|
|
73
81
|
{
|
74
82
|
:'cases' => :'Array<CloudConfigurationRuleCaseCreate>',
|
75
83
|
:'compliance_signal_options' => :'CloudConfigurationRuleComplianceSignalOptions',
|
84
|
+
:'custom_message' => :'String',
|
85
|
+
:'custom_name' => :'String',
|
76
86
|
:'filters' => :'Array<SecurityMonitoringFilter>',
|
77
87
|
:'is_enabled' => :'Boolean',
|
78
88
|
:'message' => :'String',
|
@@ -111,6 +121,14 @@ module DatadogAPIClient::V2
|
|
111
121
|
self.compliance_signal_options = attributes[:'compliance_signal_options']
|
112
122
|
end
|
113
123
|
|
124
|
+
if attributes.key?(:'custom_message')
|
125
|
+
self.custom_message = attributes[:'custom_message']
|
126
|
+
end
|
127
|
+
|
128
|
+
if attributes.key?(:'custom_name')
|
129
|
+
self.custom_name = attributes[:'custom_name']
|
130
|
+
end
|
131
|
+
|
114
132
|
if attributes.key?(:'filters')
|
115
133
|
if (value = attributes[:'filters']).is_a?(Array)
|
116
134
|
self.filters = value
|
@@ -245,6 +263,8 @@ module DatadogAPIClient::V2
|
|
245
263
|
self.class == o.class &&
|
246
264
|
cases == o.cases &&
|
247
265
|
compliance_signal_options == o.compliance_signal_options &&
|
266
|
+
custom_message == o.custom_message &&
|
267
|
+
custom_name == o.custom_name &&
|
248
268
|
filters == o.filters &&
|
249
269
|
is_enabled == o.is_enabled &&
|
250
270
|
message == o.message &&
|
@@ -259,7 +279,7 @@ module DatadogAPIClient::V2
|
|
259
279
|
# @return [Integer] Hash code
|
260
280
|
# @!visibility private
|
261
281
|
def hash
|
262
|
-
[cases, compliance_signal_options, filters, is_enabled, message, name, options, tags, type, additional_properties].hash
|
282
|
+
[cases, compliance_signal_options, custom_message, custom_name, filters, is_enabled, message, name, options, tags, type, additional_properties].hash
|
263
283
|
end
|
264
284
|
end
|
265
285
|
end
|
@@ -24,6 +24,9 @@ module DatadogAPIClient::V2
|
|
24
24
|
# SECL expression used to target the container to apply the action on
|
25
25
|
attr_accessor :filter
|
26
26
|
|
27
|
+
# An empty object indicating the hash action
|
28
|
+
attr_accessor :_hash
|
29
|
+
|
27
30
|
# Kill system call applied on the container matching the rule
|
28
31
|
attr_accessor :kill
|
29
32
|
|
@@ -40,6 +43,7 @@ module DatadogAPIClient::V2
|
|
40
43
|
def self.attribute_map
|
41
44
|
{
|
42
45
|
:'filter' => :'filter',
|
46
|
+
:'_hash' => :'hash',
|
43
47
|
:'kill' => :'kill',
|
44
48
|
:'metadata' => :'metadata',
|
45
49
|
:'set' => :'set'
|
@@ -51,6 +55,7 @@ module DatadogAPIClient::V2
|
|
51
55
|
def self.openapi_types
|
52
56
|
{
|
53
57
|
:'filter' => :'String',
|
58
|
+
:'_hash' => :'Hash<String, Object>',
|
54
59
|
:'kill' => :'CloudWorkloadSecurityAgentRuleKill',
|
55
60
|
:'metadata' => :'CloudWorkloadSecurityAgentRuleActionMetadata',
|
56
61
|
:'set' => :'CloudWorkloadSecurityAgentRuleActionSet'
|
@@ -79,6 +84,10 @@ module DatadogAPIClient::V2
|
|
79
84
|
self.filter = attributes[:'filter']
|
80
85
|
end
|
81
86
|
|
87
|
+
if attributes.key?(:'_hash')
|
88
|
+
self._hash = attributes[:'_hash']
|
89
|
+
end
|
90
|
+
|
82
91
|
if attributes.key?(:'kill')
|
83
92
|
self.kill = attributes[:'kill']
|
84
93
|
end
|
@@ -119,6 +128,7 @@ module DatadogAPIClient::V2
|
|
119
128
|
return true if self.equal?(o)
|
120
129
|
self.class == o.class &&
|
121
130
|
filter == o.filter &&
|
131
|
+
_hash == o._hash &&
|
122
132
|
kill == o.kill &&
|
123
133
|
metadata == o.metadata &&
|
124
134
|
set == o.set &&
|
@@ -129,7 +139,7 @@ module DatadogAPIClient::V2
|
|
129
139
|
# @return [Integer] Hash code
|
130
140
|
# @!visibility private
|
131
141
|
def hash
|
132
|
-
[filter, kill, metadata, set, additional_properties].hash
|
142
|
+
[filter, _hash, kill, metadata, set, additional_properties].hash
|
133
143
|
end
|
134
144
|
end
|
135
145
|
end
|
@@ -28,7 +28,8 @@ module DatadogAPIClient::V2
|
|
28
28
|
[
|
29
29
|
:'CustomDestinationForwardDestinationHttp',
|
30
30
|
:'CustomDestinationForwardDestinationSplunk',
|
31
|
-
:'CustomDestinationForwardDestinationElasticsearch'
|
31
|
+
:'CustomDestinationForwardDestinationElasticsearch',
|
32
|
+
:'CustomDestinationForwardDestinationMicrosoftSentinel'
|
32
33
|
]
|
33
34
|
end
|
34
35
|
# Builds the object
|