datadog_api_client 2.34.0 → 2.35.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 +59 -3
- data/.generator/schemas/v2/openapi.yaml +738 -69
- data/.generator/src/generator/formatter.py +2 -2
- data/.generator/src/generator/openapi.py +1 -1
- data/.github/workflows/release.yml +1 -1
- data/CHANGELOG.md +19 -0
- data/Gemfile +1 -0
- data/examples/v1/monitors/CreateMonitor_1539578087.rb +1 -0
- data/examples/v1/monitors/CreateMonitor_440013737.rb +1 -0
- data/examples/v1/synthetics/CreateSyntheticsAPITest_1279271422.rb +142 -0
- data/examples/v2/csm-threats/CreateCSMThreatsAgentRule_1295653933.rb +32 -0
- data/examples/v2/dora-metrics/CreateDORADeployment.rb +0 -3
- data/examples/v2/dora-metrics/CreateDORAFailure.rb +30 -0
- data/examples/v2/dora-metrics/CreateDORAIncident.rb +11 -9
- data/examples/v2/dora-metrics/CreateDORAIncident_1768887482.rb +25 -0
- data/examples/v2/on-call/GetTeamOnCallUsers.rb +11 -0
- data/examples/v2/security-monitoring/ListFindings_2932019633.rb +11 -0
- data/examples/v2/software-catalog/DeleteCatalogKind.rb +5 -0
- data/examples/v2/software-catalog/ListCatalogKind.rb +5 -0
- data/examples/v2/software-catalog/ListCatalogKind_3806205775.rb +5 -0
- data/examples/v2/software-catalog/UpsertCatalogKind.rb +9 -0
- data/lib/datadog_api_client/configuration.rb +0 -2
- data/lib/datadog_api_client/inflector.rb +34 -6
- data/lib/datadog_api_client/v1/api/snapshots_api.rb +2 -1
- data/lib/datadog_api_client/v1/models/monitor.rb +17 -1
- data/lib/datadog_api_client/v1/models/monitor_draft_status.rb +32 -0
- data/lib/datadog_api_client/v1/models/monitor_options.rb +1 -1
- data/lib/datadog_api_client/v1/models/monitor_update_request.rb +17 -1
- data/lib/datadog_api_client/v1/models/synthetics_api_test_step_subtype.rb +6 -0
- data/lib/datadog_api_client/v1/models/synthetics_test_request.rb +32 -2
- data/lib/datadog_api_client/v2/api/dora_metrics_api.rb +79 -15
- data/lib/datadog_api_client/v2/api/on_call_api.rb +67 -0
- data/lib/datadog_api_client/v2/api/restriction_policies_api.rb +5 -3
- data/lib/datadog_api_client/v2/api/security_monitoring_api.rb +13 -0
- data/lib/datadog_api_client/v2/api/software_catalog_api.rb +221 -0
- data/lib/datadog_api_client/v2/models/action_query_spec_inputs.rb +1 -1
- data/lib/datadog_api_client/v2/models/cloud_workload_security_agent_rule_action.rb +23 -3
- data/lib/datadog_api_client/v2/models/cloud_workload_security_agent_rule_action_metadata.rb +125 -0
- data/lib/datadog_api_client/v2/models/cloud_workload_security_agent_rule_action_set.rb +165 -0
- data/lib/datadog_api_client/v2/models/cloud_workload_security_agent_rule_attributes.rb +37 -1
- data/lib/datadog_api_client/v2/models/cloud_workload_security_agent_rule_create_attributes.rb +57 -1
- data/lib/datadog_api_client/v2/models/cloud_workload_security_agent_rule_update_attributes.rb +57 -1
- data/lib/datadog_api_client/v2/models/dora_deployment_request_attributes.rb +21 -1
- data/lib/datadog_api_client/v2/models/{dora_incident_request.rb → dora_failure_request.rb} +4 -4
- data/lib/datadog_api_client/v2/models/{dora_incident_request_attributes.rb → dora_failure_request_attributes.rb} +31 -11
- data/lib/datadog_api_client/v2/models/{dora_incident_request_data.rb → dora_failure_request_data.rb} +4 -4
- data/lib/datadog_api_client/v2/models/{dora_incident_response.rb → dora_failure_response.rb} +5 -5
- data/lib/datadog_api_client/v2/models/{dora_incident_response_data.rb → dora_failure_response_data.rb} +6 -6
- data/lib/datadog_api_client/v2/models/{dora_incident_type.rb → dora_failure_type.rb} +3 -3
- data/lib/datadog_api_client/v2/models/escalation.rb +143 -0
- data/lib/datadog_api_client/v2/models/escalation_relationships.rb +105 -0
- data/lib/datadog_api_client/v2/models/escalation_relationships_responders.rb +107 -0
- data/lib/datadog_api_client/v2/models/escalation_relationships_responders_data_items.rb +144 -0
- data/lib/datadog_api_client/v2/models/escalation_relationships_responders_data_items_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/escalation_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/finding_attributes.rb +31 -1
- data/lib/datadog_api_client/v2/models/kind_attributes.rb +143 -0
- data/lib/datadog_api_client/v2/models/kind_data.rb +153 -0
- data/lib/datadog_api_client/v2/models/kind_metadata.rb +115 -0
- data/lib/datadog_api_client/v2/models/kind_obj.rb +143 -0
- data/lib/datadog_api_client/v2/models/kind_response_meta.rb +105 -0
- data/lib/datadog_api_client/v2/models/list_kind_catalog_response.rb +117 -0
- data/lib/datadog_api_client/v2/models/team_on_call_responders.rb +117 -0
- data/lib/datadog_api_client/v2/models/team_on_call_responders_data.rb +143 -0
- data/lib/datadog_api_client/v2/models/team_on_call_responders_data_relationships.rb +115 -0
- data/lib/datadog_api_client/v2/models/team_on_call_responders_data_relationships_escalations.rb +107 -0
- data/lib/datadog_api_client/v2/models/team_on_call_responders_data_relationships_escalations_data_items.rb +144 -0
- data/lib/datadog_api_client/v2/models/team_on_call_responders_data_relationships_escalations_data_items_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/team_on_call_responders_data_relationships_responders.rb +107 -0
- data/lib/datadog_api_client/v2/models/team_on_call_responders_data_relationships_responders_data_items.rb +144 -0
- data/lib/datadog_api_client/v2/models/team_on_call_responders_data_relationships_responders_data_items_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/team_on_call_responders_data_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/team_on_call_responders_included.rb +63 -0
- data/lib/datadog_api_client/v2/models/upsert_catalog_kind_request.rb +63 -0
- data/lib/datadog_api_client/v2/models/upsert_catalog_kind_response.rb +117 -0
- data/lib/datadog_api_client/version.rb +1 -1
- data/repository.datadog.yaml +8 -0
- metadata +44 -7
@@ -17,14 +17,14 @@ require 'date'
|
|
17
17
|
require 'time'
|
18
18
|
|
19
19
|
module DatadogAPIClient::V2
|
20
|
-
# Response after receiving a DORA
|
21
|
-
class
|
20
|
+
# Response after receiving a DORA failure event.
|
21
|
+
class DORAFailureResponseData
|
22
22
|
include BaseGenericModel
|
23
23
|
|
24
|
-
# The ID of the received DORA
|
24
|
+
# The ID of the received DORA failure event.
|
25
25
|
attr_reader :id
|
26
26
|
|
27
|
-
# JSON:API type for DORA
|
27
|
+
# JSON:API type for DORA failure events.
|
28
28
|
attr_accessor :type
|
29
29
|
|
30
30
|
attr_accessor :additional_properties
|
@@ -43,7 +43,7 @@ module DatadogAPIClient::V2
|
|
43
43
|
def self.openapi_types
|
44
44
|
{
|
45
45
|
:'id' => :'String',
|
46
|
-
:'type' => :'
|
46
|
+
:'type' => :'DORAFailureType'
|
47
47
|
}
|
48
48
|
end
|
49
49
|
|
@@ -52,7 +52,7 @@ module DatadogAPIClient::V2
|
|
52
52
|
# @!visibility private
|
53
53
|
def initialize(attributes = {})
|
54
54
|
if (!attributes.is_a?(Hash))
|
55
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::
|
55
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::DORAFailureResponseData` initialize method"
|
56
56
|
end
|
57
57
|
|
58
58
|
self.additional_properties = {}
|
@@ -17,10 +17,10 @@ require 'date'
|
|
17
17
|
require 'time'
|
18
18
|
|
19
19
|
module DatadogAPIClient::V2
|
20
|
-
# JSON:API type for DORA
|
21
|
-
class
|
20
|
+
# JSON:API type for DORA failure events.
|
21
|
+
class DORAFailureType
|
22
22
|
include BaseEnumModel
|
23
23
|
|
24
|
-
|
24
|
+
DORA_FAILURE = "dora_failure".freeze
|
25
25
|
end
|
26
26
|
end
|
@@ -0,0 +1,143 @@
|
|
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
|
+
# Represents an escalation policy step.
|
21
|
+
class Escalation
|
22
|
+
include BaseGenericModel
|
23
|
+
|
24
|
+
# Unique identifier of the escalation step.
|
25
|
+
attr_accessor :id
|
26
|
+
|
27
|
+
# Contains the relationships of an escalation object, including its responders.
|
28
|
+
attr_accessor :relationships
|
29
|
+
|
30
|
+
# Represents the resource type for individual steps in an escalation policy used during incident response.
|
31
|
+
attr_reader :type
|
32
|
+
|
33
|
+
attr_accessor :additional_properties
|
34
|
+
|
35
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
36
|
+
# @!visibility private
|
37
|
+
def self.attribute_map
|
38
|
+
{
|
39
|
+
:'id' => :'id',
|
40
|
+
:'relationships' => :'relationships',
|
41
|
+
:'type' => :'type'
|
42
|
+
}
|
43
|
+
end
|
44
|
+
|
45
|
+
# Attribute type mapping.
|
46
|
+
# @!visibility private
|
47
|
+
def self.openapi_types
|
48
|
+
{
|
49
|
+
:'id' => :'String',
|
50
|
+
:'relationships' => :'EscalationRelationships',
|
51
|
+
:'type' => :'EscalationType'
|
52
|
+
}
|
53
|
+
end
|
54
|
+
|
55
|
+
# Initializes the object
|
56
|
+
# @param attributes [Hash] Model attributes in the form of hash
|
57
|
+
# @!visibility private
|
58
|
+
def initialize(attributes = {})
|
59
|
+
if (!attributes.is_a?(Hash))
|
60
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::Escalation` initialize method"
|
61
|
+
end
|
62
|
+
|
63
|
+
self.additional_properties = {}
|
64
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
65
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
66
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
67
|
+
self.additional_properties[k.to_sym] = v
|
68
|
+
else
|
69
|
+
h[k.to_sym] = v
|
70
|
+
end
|
71
|
+
}
|
72
|
+
|
73
|
+
if attributes.key?(:'id')
|
74
|
+
self.id = attributes[:'id']
|
75
|
+
end
|
76
|
+
|
77
|
+
if attributes.key?(:'relationships')
|
78
|
+
self.relationships = attributes[:'relationships']
|
79
|
+
end
|
80
|
+
|
81
|
+
if attributes.key?(:'type')
|
82
|
+
self.type = attributes[:'type']
|
83
|
+
end
|
84
|
+
end
|
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 @type.nil?
|
91
|
+
true
|
92
|
+
end
|
93
|
+
|
94
|
+
# Custom attribute writer method with validation
|
95
|
+
# @param type [Object] Object to be assigned
|
96
|
+
# @!visibility private
|
97
|
+
def type=(type)
|
98
|
+
if type.nil?
|
99
|
+
fail ArgumentError, 'invalid value for "type", type cannot be nil.'
|
100
|
+
end
|
101
|
+
@type = type
|
102
|
+
end
|
103
|
+
|
104
|
+
# Returns the object in the form of hash, with additionalProperties support.
|
105
|
+
# @return [Hash] Returns the object in the form of hash
|
106
|
+
# @!visibility private
|
107
|
+
def to_hash
|
108
|
+
hash = {}
|
109
|
+
self.class.attribute_map.each_pair do |attr, param|
|
110
|
+
value = self.send(attr)
|
111
|
+
if value.nil?
|
112
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
113
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
114
|
+
end
|
115
|
+
|
116
|
+
hash[param] = _to_hash(value)
|
117
|
+
end
|
118
|
+
self.additional_properties.each_pair do |attr, value|
|
119
|
+
hash[attr] = value
|
120
|
+
end
|
121
|
+
hash
|
122
|
+
end
|
123
|
+
|
124
|
+
# Checks equality by comparing each attribute.
|
125
|
+
# @param o [Object] Object to be compared
|
126
|
+
# @!visibility private
|
127
|
+
def ==(o)
|
128
|
+
return true if self.equal?(o)
|
129
|
+
self.class == o.class &&
|
130
|
+
id == o.id &&
|
131
|
+
relationships == o.relationships &&
|
132
|
+
type == o.type &&
|
133
|
+
additional_properties == o.additional_properties
|
134
|
+
end
|
135
|
+
|
136
|
+
# Calculates hash code according to all attributes.
|
137
|
+
# @return [Integer] Hash code
|
138
|
+
# @!visibility private
|
139
|
+
def hash
|
140
|
+
[id, relationships, type, additional_properties].hash
|
141
|
+
end
|
142
|
+
end
|
143
|
+
end
|
@@ -0,0 +1,105 @@
|
|
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
|
+
# Contains the relationships of an escalation object, including its responders.
|
21
|
+
class EscalationRelationships
|
22
|
+
include BaseGenericModel
|
23
|
+
|
24
|
+
# Lists the users involved in a specific step of the escalation policy.
|
25
|
+
attr_accessor :responders
|
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
|
+
:'responders' => :'responders'
|
34
|
+
}
|
35
|
+
end
|
36
|
+
|
37
|
+
# Attribute type mapping.
|
38
|
+
# @!visibility private
|
39
|
+
def self.openapi_types
|
40
|
+
{
|
41
|
+
:'responders' => :'EscalationRelationshipsResponders'
|
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::EscalationRelationships` 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?(:'responders')
|
64
|
+
self.responders = attributes[:'responders']
|
65
|
+
end
|
66
|
+
end
|
67
|
+
|
68
|
+
# Returns the object in the form of hash, with additionalProperties support.
|
69
|
+
# @return [Hash] Returns the object in the form of hash
|
70
|
+
# @!visibility private
|
71
|
+
def to_hash
|
72
|
+
hash = {}
|
73
|
+
self.class.attribute_map.each_pair do |attr, param|
|
74
|
+
value = self.send(attr)
|
75
|
+
if value.nil?
|
76
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
77
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
78
|
+
end
|
79
|
+
|
80
|
+
hash[param] = _to_hash(value)
|
81
|
+
end
|
82
|
+
self.additional_properties.each_pair do |attr, value|
|
83
|
+
hash[attr] = value
|
84
|
+
end
|
85
|
+
hash
|
86
|
+
end
|
87
|
+
|
88
|
+
# Checks equality by comparing each attribute.
|
89
|
+
# @param o [Object] Object to be compared
|
90
|
+
# @!visibility private
|
91
|
+
def ==(o)
|
92
|
+
return true if self.equal?(o)
|
93
|
+
self.class == o.class &&
|
94
|
+
responders == o.responders &&
|
95
|
+
additional_properties == o.additional_properties
|
96
|
+
end
|
97
|
+
|
98
|
+
# Calculates hash code according to all attributes.
|
99
|
+
# @return [Integer] Hash code
|
100
|
+
# @!visibility private
|
101
|
+
def hash
|
102
|
+
[responders, additional_properties].hash
|
103
|
+
end
|
104
|
+
end
|
105
|
+
end
|
@@ -0,0 +1,107 @@
|
|
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
|
+
# Lists the users involved in a specific step of the escalation policy.
|
21
|
+
class EscalationRelationshipsResponders
|
22
|
+
include BaseGenericModel
|
23
|
+
|
24
|
+
# Array of user references assigned as responders for this escalation step.
|
25
|
+
attr_accessor :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' => :'Array<EscalationRelationshipsRespondersDataItems>'
|
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::EscalationRelationshipsResponders` 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
|
+
if (value = attributes[:'data']).is_a?(Array)
|
65
|
+
self.data = value
|
66
|
+
end
|
67
|
+
end
|
68
|
+
end
|
69
|
+
|
70
|
+
# Returns the object in the form of hash, with additionalProperties support.
|
71
|
+
# @return [Hash] Returns the object in the form of hash
|
72
|
+
# @!visibility private
|
73
|
+
def to_hash
|
74
|
+
hash = {}
|
75
|
+
self.class.attribute_map.each_pair do |attr, param|
|
76
|
+
value = self.send(attr)
|
77
|
+
if value.nil?
|
78
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
79
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
80
|
+
end
|
81
|
+
|
82
|
+
hash[param] = _to_hash(value)
|
83
|
+
end
|
84
|
+
self.additional_properties.each_pair do |attr, value|
|
85
|
+
hash[attr] = value
|
86
|
+
end
|
87
|
+
hash
|
88
|
+
end
|
89
|
+
|
90
|
+
# Checks equality by comparing each attribute.
|
91
|
+
# @param o [Object] Object to be compared
|
92
|
+
# @!visibility private
|
93
|
+
def ==(o)
|
94
|
+
return true if self.equal?(o)
|
95
|
+
self.class == o.class &&
|
96
|
+
data == o.data &&
|
97
|
+
additional_properties == o.additional_properties
|
98
|
+
end
|
99
|
+
|
100
|
+
# Calculates hash code according to all attributes.
|
101
|
+
# @return [Integer] Hash code
|
102
|
+
# @!visibility private
|
103
|
+
def hash
|
104
|
+
[data, additional_properties].hash
|
105
|
+
end
|
106
|
+
end
|
107
|
+
end
|
@@ -0,0 +1,144 @@
|
|
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
|
+
# Represents a user assigned to an escalation step.
|
21
|
+
class EscalationRelationshipsRespondersDataItems
|
22
|
+
include BaseGenericModel
|
23
|
+
|
24
|
+
# Unique identifier of the user assigned to the escalation step.
|
25
|
+
attr_reader :id
|
26
|
+
|
27
|
+
# Represents the resource type for users assigned as responders in an escalation step.
|
28
|
+
attr_reader :type
|
29
|
+
|
30
|
+
attr_accessor :additional_properties
|
31
|
+
|
32
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
33
|
+
# @!visibility private
|
34
|
+
def self.attribute_map
|
35
|
+
{
|
36
|
+
:'id' => :'id',
|
37
|
+
:'type' => :'type'
|
38
|
+
}
|
39
|
+
end
|
40
|
+
|
41
|
+
# Attribute type mapping.
|
42
|
+
# @!visibility private
|
43
|
+
def self.openapi_types
|
44
|
+
{
|
45
|
+
:'id' => :'String',
|
46
|
+
:'type' => :'EscalationRelationshipsRespondersDataItemsType'
|
47
|
+
}
|
48
|
+
end
|
49
|
+
|
50
|
+
# Initializes the object
|
51
|
+
# @param attributes [Hash] Model attributes in the form of hash
|
52
|
+
# @!visibility private
|
53
|
+
def initialize(attributes = {})
|
54
|
+
if (!attributes.is_a?(Hash))
|
55
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::EscalationRelationshipsRespondersDataItems` initialize method"
|
56
|
+
end
|
57
|
+
|
58
|
+
self.additional_properties = {}
|
59
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
60
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
61
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
62
|
+
self.additional_properties[k.to_sym] = v
|
63
|
+
else
|
64
|
+
h[k.to_sym] = v
|
65
|
+
end
|
66
|
+
}
|
67
|
+
|
68
|
+
if attributes.key?(:'id')
|
69
|
+
self.id = attributes[:'id']
|
70
|
+
end
|
71
|
+
|
72
|
+
if attributes.key?(:'type')
|
73
|
+
self.type = attributes[:'type']
|
74
|
+
end
|
75
|
+
end
|
76
|
+
|
77
|
+
# Check to see if the all the properties in the model are valid
|
78
|
+
# @return true if the model is valid
|
79
|
+
# @!visibility private
|
80
|
+
def valid?
|
81
|
+
return false if @id.nil?
|
82
|
+
return false if @type.nil?
|
83
|
+
true
|
84
|
+
end
|
85
|
+
|
86
|
+
# Custom attribute writer method with validation
|
87
|
+
# @param id [Object] Object to be assigned
|
88
|
+
# @!visibility private
|
89
|
+
def id=(id)
|
90
|
+
if id.nil?
|
91
|
+
fail ArgumentError, 'invalid value for "id", id cannot be nil.'
|
92
|
+
end
|
93
|
+
@id = id
|
94
|
+
end
|
95
|
+
|
96
|
+
# Custom attribute writer method with validation
|
97
|
+
# @param type [Object] Object to be assigned
|
98
|
+
# @!visibility private
|
99
|
+
def type=(type)
|
100
|
+
if type.nil?
|
101
|
+
fail ArgumentError, 'invalid value for "type", type cannot be nil.'
|
102
|
+
end
|
103
|
+
@type = type
|
104
|
+
end
|
105
|
+
|
106
|
+
# Returns the object in the form of hash, with additionalProperties support.
|
107
|
+
# @return [Hash] Returns the object in the form of hash
|
108
|
+
# @!visibility private
|
109
|
+
def to_hash
|
110
|
+
hash = {}
|
111
|
+
self.class.attribute_map.each_pair do |attr, param|
|
112
|
+
value = self.send(attr)
|
113
|
+
if value.nil?
|
114
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
115
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
116
|
+
end
|
117
|
+
|
118
|
+
hash[param] = _to_hash(value)
|
119
|
+
end
|
120
|
+
self.additional_properties.each_pair do |attr, value|
|
121
|
+
hash[attr] = value
|
122
|
+
end
|
123
|
+
hash
|
124
|
+
end
|
125
|
+
|
126
|
+
# Checks equality by comparing each attribute.
|
127
|
+
# @param o [Object] Object to be compared
|
128
|
+
# @!visibility private
|
129
|
+
def ==(o)
|
130
|
+
return true if self.equal?(o)
|
131
|
+
self.class == o.class &&
|
132
|
+
id == o.id &&
|
133
|
+
type == o.type &&
|
134
|
+
additional_properties == o.additional_properties
|
135
|
+
end
|
136
|
+
|
137
|
+
# Calculates hash code according to all attributes.
|
138
|
+
# @return [Integer] Hash code
|
139
|
+
# @!visibility private
|
140
|
+
def hash
|
141
|
+
[id, type, additional_properties].hash
|
142
|
+
end
|
143
|
+
end
|
144
|
+
end
|
@@ -0,0 +1,26 @@
|
|
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
|
+
# Represents the resource type for users assigned as responders in an escalation step.
|
21
|
+
class EscalationRelationshipsRespondersDataItemsType
|
22
|
+
include BaseEnumModel
|
23
|
+
|
24
|
+
USERS = "users".freeze
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,26 @@
|
|
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
|
+
# Represents the resource type for individual steps in an escalation policy used during incident response.
|
21
|
+
class EscalationType
|
22
|
+
include BaseEnumModel
|
23
|
+
|
24
|
+
ESCALATION_POLICY_STEPS = "escalation_policy_steps".freeze
|
25
|
+
end
|
26
|
+
end
|
@@ -21,12 +21,21 @@ module DatadogAPIClient::V2
|
|
21
21
|
class FindingAttributes
|
22
22
|
include BaseGenericModel
|
23
23
|
|
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
|
+
|
24
30
|
# The evaluation of the finding.
|
25
31
|
attr_accessor :evaluation
|
26
32
|
|
27
33
|
# The date on which the evaluation for this finding changed (Unix ms).
|
28
34
|
attr_reader :evaluation_changed_at
|
29
35
|
|
36
|
+
# The cloud-based ID for the resource related to the finding.
|
37
|
+
attr_accessor :external_id
|
38
|
+
|
30
39
|
# Information about the mute status of this finding.
|
31
40
|
attr_accessor :mute
|
32
41
|
|
@@ -57,8 +66,11 @@ module DatadogAPIClient::V2
|
|
57
66
|
# @!visibility private
|
58
67
|
def self.attribute_map
|
59
68
|
{
|
69
|
+
:'datadog_link' => :'datadog_link',
|
70
|
+
:'description' => :'description',
|
60
71
|
:'evaluation' => :'evaluation',
|
61
72
|
:'evaluation_changed_at' => :'evaluation_changed_at',
|
73
|
+
:'external_id' => :'external_id',
|
62
74
|
:'mute' => :'mute',
|
63
75
|
:'resource' => :'resource',
|
64
76
|
:'resource_discovery_date' => :'resource_discovery_date',
|
@@ -74,8 +86,11 @@ module DatadogAPIClient::V2
|
|
74
86
|
# @!visibility private
|
75
87
|
def self.openapi_types
|
76
88
|
{
|
89
|
+
:'datadog_link' => :'String',
|
90
|
+
:'description' => :'String',
|
77
91
|
:'evaluation' => :'FindingEvaluation',
|
78
92
|
:'evaluation_changed_at' => :'Integer',
|
93
|
+
:'external_id' => :'String',
|
79
94
|
:'mute' => :'FindingMute',
|
80
95
|
:'resource' => :'String',
|
81
96
|
:'resource_discovery_date' => :'Integer',
|
@@ -105,6 +120,14 @@ module DatadogAPIClient::V2
|
|
105
120
|
end
|
106
121
|
}
|
107
122
|
|
123
|
+
if attributes.key?(:'datadog_link')
|
124
|
+
self.datadog_link = attributes[:'datadog_link']
|
125
|
+
end
|
126
|
+
|
127
|
+
if attributes.key?(:'description')
|
128
|
+
self.description = attributes[:'description']
|
129
|
+
end
|
130
|
+
|
108
131
|
if attributes.key?(:'evaluation')
|
109
132
|
self.evaluation = attributes[:'evaluation']
|
110
133
|
end
|
@@ -113,6 +136,10 @@ module DatadogAPIClient::V2
|
|
113
136
|
self.evaluation_changed_at = attributes[:'evaluation_changed_at']
|
114
137
|
end
|
115
138
|
|
139
|
+
if attributes.key?(:'external_id')
|
140
|
+
self.external_id = attributes[:'external_id']
|
141
|
+
end
|
142
|
+
|
116
143
|
if attributes.key?(:'mute')
|
117
144
|
self.mute = attributes[:'mute']
|
118
145
|
end
|
@@ -203,8 +230,11 @@ module DatadogAPIClient::V2
|
|
203
230
|
def ==(o)
|
204
231
|
return true if self.equal?(o)
|
205
232
|
self.class == o.class &&
|
233
|
+
datadog_link == o.datadog_link &&
|
234
|
+
description == o.description &&
|
206
235
|
evaluation == o.evaluation &&
|
207
236
|
evaluation_changed_at == o.evaluation_changed_at &&
|
237
|
+
external_id == o.external_id &&
|
208
238
|
mute == o.mute &&
|
209
239
|
resource == o.resource &&
|
210
240
|
resource_discovery_date == o.resource_discovery_date &&
|
@@ -220,7 +250,7 @@ module DatadogAPIClient::V2
|
|
220
250
|
# @return [Integer] Hash code
|
221
251
|
# @!visibility private
|
222
252
|
def hash
|
223
|
-
[evaluation, evaluation_changed_at, mute, resource, resource_discovery_date, resource_type, rule, status, tags, vulnerability_type, additional_properties].hash
|
253
|
+
[datadog_link, description, evaluation, evaluation_changed_at, external_id, mute, resource, resource_discovery_date, resource_type, rule, status, tags, vulnerability_type, additional_properties].hash
|
224
254
|
end
|
225
255
|
end
|
226
256
|
end
|