datadog_api_client 2.37.0 → 2.38.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 +20 -1
- data/.generator/schemas/v2/openapi.yaml +1083 -74
- data/CHANGELOG.md +20 -0
- data/examples/v2/action-connection/GetAppKeyRegistration.rb +5 -0
- data/examples/v2/action-connection/ListAppKeyRegistrations.rb +5 -0
- data/examples/v2/action-connection/RegisterAppKey.rb +5 -0
- data/examples/v2/action-connection/UnregisterAppKey.rb +5 -0
- data/examples/v2/events/CreateEvent.rb +4 -2
- data/examples/v2/monitors/CreateMonitorUserTemplate.rb +37 -0
- data/examples/v2/monitors/DeleteMonitorUserTemplate.rb +8 -0
- data/examples/v2/monitors/GetMonitorUserTemplate.rb +11 -0
- data/examples/v2/monitors/ListMonitorUserTemplates.rb +8 -0
- data/examples/v2/monitors/UpdateMonitorUserTemplate.rb +41 -0
- data/examples/v2/monitors/ValidateExistingMonitorUserTemplate.rb +41 -0
- data/examples/v2/monitors/ValidateMonitorUserTemplate.rb +37 -0
- data/lib/datadog_api_client/configuration.rb +59 -0
- data/lib/datadog_api_client/inflector.rb +29 -0
- data/lib/datadog_api_client/v1/models/synthetics_mobile_test.rb +12 -1
- data/lib/datadog_api_client/v1/models/synthetics_test_request.rb +1 -1
- data/lib/datadog_api_client/v1/models/synthetics_test_request_dns_server_port.rb +63 -0
- data/lib/datadog_api_client/v2/api/action_connection_api.rb +263 -4
- data/lib/datadog_api_client/v2/api/app_builder_api.rb +8 -8
- data/lib/datadog_api_client/v2/api/events_api.rb +8 -4
- data/lib/datadog_api_client/v2/api/monitors_api.rb +512 -0
- data/lib/datadog_api_client/v2/api/workflow_automation_api.rb +8 -8
- data/lib/datadog_api_client/v2/models/alert_event_custom_attributes.rb +145 -0
- data/lib/datadog_api_client/v2/models/alert_event_custom_attributes_links_items.rb +152 -0
- data/lib/datadog_api_client/v2/models/alert_event_custom_attributes_links_items_category.rb +28 -0
- data/lib/datadog_api_client/v2/models/alert_event_custom_attributes_priority.rb +30 -0
- data/lib/datadog_api_client/v2/models/alert_event_custom_attributes_status.rb +28 -0
- data/lib/datadog_api_client/v2/models/app_key_registration_data.rb +133 -0
- data/lib/datadog_api_client/v2/models/app_key_registration_data_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/change_event_custom_attributes.rb +19 -33
- data/lib/datadog_api_client/v2/models/change_event_custom_attributes_author.rb +10 -31
- data/lib/datadog_api_client/v2/models/change_event_custom_attributes_changed_resource.rb +15 -32
- data/lib/datadog_api_client/v2/models/change_event_custom_attributes_changed_resource_type.rb +1 -1
- data/lib/datadog_api_client/v2/models/change_event_custom_attributes_impacted_resources_items.rb +15 -32
- data/lib/datadog_api_client/v2/models/change_event_custom_attributes_impacted_resources_items_type.rb +1 -1
- data/lib/datadog_api_client/v2/models/event_category.rb +2 -1
- data/lib/datadog_api_client/v2/models/event_create_request.rb +32 -3
- data/lib/datadog_api_client/v2/models/event_create_request_payload.rb +20 -2
- data/lib/datadog_api_client/v2/models/event_create_response.rb +3 -3
- data/lib/datadog_api_client/v2/models/event_create_response_attributes.rb +2 -2
- data/lib/datadog_api_client/v2/models/event_create_response_attributes_attributes.rb +1 -1
- data/lib/datadog_api_client/v2/models/event_create_response_attributes_attributes_evt.rb +14 -4
- data/lib/datadog_api_client/v2/models/event_create_response_payload.rb +15 -5
- data/lib/datadog_api_client/v2/models/event_create_response_payload_links.rb +105 -0
- data/lib/datadog_api_client/v2/models/event_payload.rb +48 -36
- data/lib/datadog_api_client/v2/models/event_payload_attributes.rb +3 -2
- data/lib/datadog_api_client/v2/models/event_payload_integration_id.rb +26 -0
- data/lib/datadog_api_client/v2/models/get_app_key_registration_response.rb +105 -0
- data/lib/datadog_api_client/v2/models/incident_create_attributes.rb +11 -1
- data/lib/datadog_api_client/v2/models/incident_response_attributes.rb +11 -1
- data/lib/datadog_api_client/v2/models/job_definition_from_rule.rb +1 -26
- data/lib/datadog_api_client/v2/models/list_app_key_registrations_response.rb +117 -0
- data/lib/datadog_api_client/v2/models/list_app_key_registrations_response_meta.rb +115 -0
- data/lib/datadog_api_client/v2/models/monitor_user_template.rb +200 -0
- data/lib/datadog_api_client/v2/models/monitor_user_template_create_data.rb +144 -0
- data/lib/datadog_api_client/v2/models/monitor_user_template_create_request.rb +123 -0
- data/lib/datadog_api_client/v2/models/monitor_user_template_create_response.rb +105 -0
- data/lib/datadog_api_client/v2/models/monitor_user_template_list_response.rb +107 -0
- data/lib/datadog_api_client/v2/models/monitor_user_template_request_attributes.rb +172 -0
- data/lib/datadog_api_client/v2/models/monitor_user_template_resource_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/monitor_user_template_response.rb +105 -0
- data/lib/datadog_api_client/v2/models/monitor_user_template_response_attributes.rb +188 -0
- data/lib/datadog_api_client/v2/models/monitor_user_template_response_data.rb +125 -0
- data/lib/datadog_api_client/v2/models/monitor_user_template_response_data_with_versions.rb +125 -0
- data/lib/datadog_api_client/v2/models/monitor_user_template_template_variables_items.rb +132 -0
- data/lib/datadog_api_client/v2/models/monitor_user_template_update_data.rb +165 -0
- data/lib/datadog_api_client/v2/models/monitor_user_template_update_request.rb +123 -0
- data/lib/datadog_api_client/v2/models/register_app_key_response.rb +105 -0
- data/lib/datadog_api_client/v2/models/simple_monitor_user_template.rb +188 -0
- data/lib/datadog_api_client/version.rb +1 -1
- metadata +41 -1
@@ -17,18 +17,16 @@ require 'date'
|
|
17
17
|
require 'time'
|
18
18
|
|
19
19
|
module DatadogAPIClient::V2
|
20
|
-
#
|
20
|
+
# The entity that made the change. Optional, if provided it must include `type` and `name`.
|
21
21
|
class ChangeEventCustomAttributesAuthor
|
22
22
|
include BaseGenericModel
|
23
23
|
|
24
|
-
#
|
24
|
+
# The name of the user or system that made the change. Limited to 128 characters.
|
25
25
|
attr_reader :name
|
26
26
|
|
27
27
|
# Author's type.
|
28
28
|
attr_reader :type
|
29
29
|
|
30
|
-
attr_accessor :additional_properties
|
31
|
-
|
32
30
|
# Attribute mapping from ruby-style variable name to JSON key.
|
33
31
|
# @!visibility private
|
34
32
|
def self.attribute_map
|
@@ -55,14 +53,12 @@ module DatadogAPIClient::V2
|
|
55
53
|
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::ChangeEventCustomAttributesAuthor` initialize method"
|
56
54
|
end
|
57
55
|
|
58
|
-
self.additional_properties = {}
|
59
56
|
# check to see if the attribute exists and convert string to symbol for hash key
|
60
57
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
61
58
|
if (!self.class.attribute_map.key?(k.to_sym))
|
62
|
-
|
63
|
-
else
|
64
|
-
h[k.to_sym] = v
|
59
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::ChangeEventCustomAttributesAuthor`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
65
60
|
end
|
61
|
+
h[k.to_sym] = v
|
66
62
|
}
|
67
63
|
|
68
64
|
if attributes.key?(:'name')
|
@@ -80,6 +76,7 @@ module DatadogAPIClient::V2
|
|
80
76
|
def valid?
|
81
77
|
return false if @name.nil?
|
82
78
|
return false if @name.to_s.length > 128
|
79
|
+
return false if @name.to_s.length < 1
|
83
80
|
return false if @type.nil?
|
84
81
|
true
|
85
82
|
end
|
@@ -94,6 +91,9 @@ module DatadogAPIClient::V2
|
|
94
91
|
if name.to_s.length > 128
|
95
92
|
fail ArgumentError, 'invalid value for "name", the character length must be smaller than or equal to 128.'
|
96
93
|
end
|
94
|
+
if name.to_s.length < 1
|
95
|
+
fail ArgumentError, 'invalid value for "name", the character length must be great than or equal to 1.'
|
96
|
+
end
|
97
97
|
@name = name
|
98
98
|
end
|
99
99
|
|
@@ -107,26 +107,6 @@ module DatadogAPIClient::V2
|
|
107
107
|
@type = type
|
108
108
|
end
|
109
109
|
|
110
|
-
# Returns the object in the form of hash, with additionalProperties support.
|
111
|
-
# @return [Hash] Returns the object in the form of hash
|
112
|
-
# @!visibility private
|
113
|
-
def to_hash
|
114
|
-
hash = {}
|
115
|
-
self.class.attribute_map.each_pair do |attr, param|
|
116
|
-
value = self.send(attr)
|
117
|
-
if value.nil?
|
118
|
-
is_nullable = self.class.openapi_nullable.include?(attr)
|
119
|
-
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
120
|
-
end
|
121
|
-
|
122
|
-
hash[param] = _to_hash(value)
|
123
|
-
end
|
124
|
-
self.additional_properties.each_pair do |attr, value|
|
125
|
-
hash[attr] = value
|
126
|
-
end
|
127
|
-
hash
|
128
|
-
end
|
129
|
-
|
130
110
|
# Checks equality by comparing each attribute.
|
131
111
|
# @param o [Object] Object to be compared
|
132
112
|
# @!visibility private
|
@@ -134,15 +114,14 @@ module DatadogAPIClient::V2
|
|
134
114
|
return true if self.equal?(o)
|
135
115
|
self.class == o.class &&
|
136
116
|
name == o.name &&
|
137
|
-
type == o.type
|
138
|
-
additional_properties == o.additional_properties
|
117
|
+
type == o.type
|
139
118
|
end
|
140
119
|
|
141
120
|
# Calculates hash code according to all attributes.
|
142
121
|
# @return [Integer] Hash code
|
143
122
|
# @!visibility private
|
144
123
|
def hash
|
145
|
-
[name, type
|
124
|
+
[name, type].hash
|
146
125
|
end
|
147
126
|
end
|
148
127
|
end
|
@@ -17,18 +17,16 @@ require 'date'
|
|
17
17
|
require 'time'
|
18
18
|
|
19
19
|
module DatadogAPIClient::V2
|
20
|
-
#
|
20
|
+
# A uniquely identified resource.
|
21
21
|
class ChangeEventCustomAttributesChangedResource
|
22
22
|
include BaseGenericModel
|
23
23
|
|
24
|
-
#
|
24
|
+
# The name of the resource that was changed. Limited to 128 characters.
|
25
25
|
attr_reader :name
|
26
26
|
|
27
|
-
#
|
27
|
+
# The type of the resource that was changed.
|
28
28
|
attr_reader :type
|
29
29
|
|
30
|
-
attr_accessor :additional_properties
|
31
|
-
|
32
30
|
# Attribute mapping from ruby-style variable name to JSON key.
|
33
31
|
# @!visibility private
|
34
32
|
def self.attribute_map
|
@@ -55,14 +53,12 @@ module DatadogAPIClient::V2
|
|
55
53
|
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::ChangeEventCustomAttributesChangedResource` initialize method"
|
56
54
|
end
|
57
55
|
|
58
|
-
self.additional_properties = {}
|
59
56
|
# check to see if the attribute exists and convert string to symbol for hash key
|
60
57
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
61
58
|
if (!self.class.attribute_map.key?(k.to_sym))
|
62
|
-
|
63
|
-
else
|
64
|
-
h[k.to_sym] = v
|
59
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::ChangeEventCustomAttributesChangedResource`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
65
60
|
end
|
61
|
+
h[k.to_sym] = v
|
66
62
|
}
|
67
63
|
|
68
64
|
if attributes.key?(:'name')
|
@@ -79,6 +75,8 @@ module DatadogAPIClient::V2
|
|
79
75
|
# @!visibility private
|
80
76
|
def valid?
|
81
77
|
return false if @name.nil?
|
78
|
+
return false if @name.to_s.length > 128
|
79
|
+
return false if @name.to_s.length < 1
|
82
80
|
return false if @type.nil?
|
83
81
|
true
|
84
82
|
end
|
@@ -90,6 +88,12 @@ module DatadogAPIClient::V2
|
|
90
88
|
if name.nil?
|
91
89
|
fail ArgumentError, 'invalid value for "name", name cannot be nil.'
|
92
90
|
end
|
91
|
+
if name.to_s.length > 128
|
92
|
+
fail ArgumentError, 'invalid value for "name", the character length must be smaller than or equal to 128.'
|
93
|
+
end
|
94
|
+
if name.to_s.length < 1
|
95
|
+
fail ArgumentError, 'invalid value for "name", the character length must be great than or equal to 1.'
|
96
|
+
end
|
93
97
|
@name = name
|
94
98
|
end
|
95
99
|
|
@@ -103,26 +107,6 @@ module DatadogAPIClient::V2
|
|
103
107
|
@type = type
|
104
108
|
end
|
105
109
|
|
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
110
|
# Checks equality by comparing each attribute.
|
127
111
|
# @param o [Object] Object to be compared
|
128
112
|
# @!visibility private
|
@@ -130,15 +114,14 @@ module DatadogAPIClient::V2
|
|
130
114
|
return true if self.equal?(o)
|
131
115
|
self.class == o.class &&
|
132
116
|
name == o.name &&
|
133
|
-
type == o.type
|
134
|
-
additional_properties == o.additional_properties
|
117
|
+
type == o.type
|
135
118
|
end
|
136
119
|
|
137
120
|
# Calculates hash code according to all attributes.
|
138
121
|
# @return [Integer] Hash code
|
139
122
|
# @!visibility private
|
140
123
|
def hash
|
141
|
-
[name, type
|
124
|
+
[name, type].hash
|
142
125
|
end
|
143
126
|
end
|
144
127
|
end
|
data/lib/datadog_api_client/v2/models/change_event_custom_attributes_impacted_resources_items.rb
CHANGED
@@ -17,18 +17,16 @@ require 'date'
|
|
17
17
|
require 'time'
|
18
18
|
|
19
19
|
module DatadogAPIClient::V2
|
20
|
-
# Object representing a uniquely identified resource.
|
20
|
+
# Object representing a uniquely identified resource.
|
21
21
|
class ChangeEventCustomAttributesImpactedResourcesItems
|
22
22
|
include BaseGenericModel
|
23
23
|
|
24
|
-
#
|
24
|
+
# The name of the impacted resource. Limited to 128 characters.
|
25
25
|
attr_reader :name
|
26
26
|
|
27
|
-
#
|
27
|
+
# The type of the impacted resource.
|
28
28
|
attr_reader :type
|
29
29
|
|
30
|
-
attr_accessor :additional_properties
|
31
|
-
|
32
30
|
# Attribute mapping from ruby-style variable name to JSON key.
|
33
31
|
# @!visibility private
|
34
32
|
def self.attribute_map
|
@@ -55,14 +53,12 @@ module DatadogAPIClient::V2
|
|
55
53
|
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::ChangeEventCustomAttributesImpactedResourcesItems` initialize method"
|
56
54
|
end
|
57
55
|
|
58
|
-
self.additional_properties = {}
|
59
56
|
# check to see if the attribute exists and convert string to symbol for hash key
|
60
57
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
61
58
|
if (!self.class.attribute_map.key?(k.to_sym))
|
62
|
-
|
63
|
-
else
|
64
|
-
h[k.to_sym] = v
|
59
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::ChangeEventCustomAttributesImpactedResourcesItems`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
65
60
|
end
|
61
|
+
h[k.to_sym] = v
|
66
62
|
}
|
67
63
|
|
68
64
|
if attributes.key?(:'name')
|
@@ -79,6 +75,8 @@ module DatadogAPIClient::V2
|
|
79
75
|
# @!visibility private
|
80
76
|
def valid?
|
81
77
|
return false if @name.nil?
|
78
|
+
return false if @name.to_s.length > 128
|
79
|
+
return false if @name.to_s.length < 1
|
82
80
|
return false if @type.nil?
|
83
81
|
true
|
84
82
|
end
|
@@ -90,6 +88,12 @@ module DatadogAPIClient::V2
|
|
90
88
|
if name.nil?
|
91
89
|
fail ArgumentError, 'invalid value for "name", name cannot be nil.'
|
92
90
|
end
|
91
|
+
if name.to_s.length > 128
|
92
|
+
fail ArgumentError, 'invalid value for "name", the character length must be smaller than or equal to 128.'
|
93
|
+
end
|
94
|
+
if name.to_s.length < 1
|
95
|
+
fail ArgumentError, 'invalid value for "name", the character length must be great than or equal to 1.'
|
96
|
+
end
|
93
97
|
@name = name
|
94
98
|
end
|
95
99
|
|
@@ -103,26 +107,6 @@ module DatadogAPIClient::V2
|
|
103
107
|
@type = type
|
104
108
|
end
|
105
109
|
|
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
110
|
# Checks equality by comparing each attribute.
|
127
111
|
# @param o [Object] Object to be compared
|
128
112
|
# @!visibility private
|
@@ -130,15 +114,14 @@ module DatadogAPIClient::V2
|
|
130
114
|
return true if self.equal?(o)
|
131
115
|
self.class == o.class &&
|
132
116
|
name == o.name &&
|
133
|
-
type == o.type
|
134
|
-
additional_properties == o.additional_properties
|
117
|
+
type == o.type
|
135
118
|
end
|
136
119
|
|
137
120
|
# Calculates hash code according to all attributes.
|
138
121
|
# @return [Integer] Hash code
|
139
122
|
# @!visibility private
|
140
123
|
def hash
|
141
|
-
[name, type
|
124
|
+
[name, type].hash
|
142
125
|
end
|
143
126
|
end
|
144
127
|
end
|
@@ -17,10 +17,11 @@ require 'date'
|
|
17
17
|
require 'time'
|
18
18
|
|
19
19
|
module DatadogAPIClient::V2
|
20
|
-
# Event category
|
20
|
+
# Event category identifying the type of event.
|
21
21
|
class EventCategory
|
22
22
|
include BaseEnumModel
|
23
23
|
|
24
24
|
CHANGE = "change".freeze
|
25
|
+
ALERT = "alert".freeze
|
25
26
|
end
|
26
27
|
end
|
@@ -17,15 +17,15 @@ require 'date'
|
|
17
17
|
require 'time'
|
18
18
|
|
19
19
|
module DatadogAPIClient::V2
|
20
|
-
#
|
20
|
+
# An event object.
|
21
21
|
class EventCreateRequest
|
22
22
|
include BaseGenericModel
|
23
23
|
|
24
24
|
# Event attributes.
|
25
|
-
|
25
|
+
attr_reader :attributes
|
26
26
|
|
27
27
|
# Entity type.
|
28
|
-
|
28
|
+
attr_reader :type
|
29
29
|
|
30
30
|
attr_accessor :additional_properties
|
31
31
|
|
@@ -74,6 +74,35 @@ module DatadogAPIClient::V2
|
|
74
74
|
end
|
75
75
|
end
|
76
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 @attributes.nil?
|
82
|
+
return false if @type.nil?
|
83
|
+
true
|
84
|
+
end
|
85
|
+
|
86
|
+
# Custom attribute writer method with validation
|
87
|
+
# @param attributes [Object] Object to be assigned
|
88
|
+
# @!visibility private
|
89
|
+
def attributes=(attributes)
|
90
|
+
if attributes.nil?
|
91
|
+
fail ArgumentError, 'invalid value for "attributes", attributes cannot be nil.'
|
92
|
+
end
|
93
|
+
@attributes = attributes
|
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
|
+
|
77
106
|
# Returns the object in the form of hash, with additionalProperties support.
|
78
107
|
# @return [Hash] Returns the object in the form of hash
|
79
108
|
# @!visibility private
|
@@ -21,8 +21,8 @@ module DatadogAPIClient::V2
|
|
21
21
|
class EventCreateRequestPayload
|
22
22
|
include BaseGenericModel
|
23
23
|
|
24
|
-
#
|
25
|
-
|
24
|
+
# An event object.
|
25
|
+
attr_reader :data
|
26
26
|
|
27
27
|
attr_accessor :additional_properties
|
28
28
|
|
@@ -65,6 +65,24 @@ module DatadogAPIClient::V2
|
|
65
65
|
end
|
66
66
|
end
|
67
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
|
+
|
68
86
|
# Returns the object in the form of hash, with additionalProperties support.
|
69
87
|
# @return [Hash] Returns the object in the form of hash
|
70
88
|
# @!visibility private
|
@@ -17,14 +17,14 @@ require 'date'
|
|
17
17
|
require 'time'
|
18
18
|
|
19
19
|
module DatadogAPIClient::V2
|
20
|
-
#
|
20
|
+
# Event object.
|
21
21
|
class EventCreateResponse
|
22
22
|
include BaseGenericModel
|
23
23
|
|
24
|
-
#
|
24
|
+
# Event attributes.
|
25
25
|
attr_accessor :attributes
|
26
26
|
|
27
|
-
#
|
27
|
+
# Entity type.
|
28
28
|
attr_accessor :type
|
29
29
|
|
30
30
|
attr_accessor :additional_properties
|
@@ -17,11 +17,11 @@ require 'date'
|
|
17
17
|
require 'time'
|
18
18
|
|
19
19
|
module DatadogAPIClient::V2
|
20
|
-
#
|
20
|
+
# Event attributes.
|
21
21
|
class EventCreateResponseAttributes
|
22
22
|
include BaseGenericModel
|
23
23
|
|
24
|
-
# JSON object
|
24
|
+
# JSON object for category-specific attributes.
|
25
25
|
attr_accessor :attributes
|
26
26
|
|
27
27
|
attr_accessor :additional_properties
|
@@ -21,16 +21,20 @@ module DatadogAPIClient::V2
|
|
21
21
|
class EventCreateResponseAttributesAttributesEvt
|
22
22
|
include BaseGenericModel
|
23
23
|
|
24
|
-
# Event
|
24
|
+
# Event identifier. This field is deprecated and will be removed in a future version. Use the `uid` field instead.
|
25
25
|
attr_accessor :id
|
26
26
|
|
27
|
+
# A unique identifier for the event. You can use this identifier to query or reference the event.
|
28
|
+
attr_accessor :uid
|
29
|
+
|
27
30
|
attr_accessor :additional_properties
|
28
31
|
|
29
32
|
# Attribute mapping from ruby-style variable name to JSON key.
|
30
33
|
# @!visibility private
|
31
34
|
def self.attribute_map
|
32
35
|
{
|
33
|
-
:'id' => :'id'
|
36
|
+
:'id' => :'id',
|
37
|
+
:'uid' => :'uid'
|
34
38
|
}
|
35
39
|
end
|
36
40
|
|
@@ -38,7 +42,8 @@ module DatadogAPIClient::V2
|
|
38
42
|
# @!visibility private
|
39
43
|
def self.openapi_types
|
40
44
|
{
|
41
|
-
:'id' => :'String'
|
45
|
+
:'id' => :'String',
|
46
|
+
:'uid' => :'String'
|
42
47
|
}
|
43
48
|
end
|
44
49
|
|
@@ -63,6 +68,10 @@ module DatadogAPIClient::V2
|
|
63
68
|
if attributes.key?(:'id')
|
64
69
|
self.id = attributes[:'id']
|
65
70
|
end
|
71
|
+
|
72
|
+
if attributes.key?(:'uid')
|
73
|
+
self.uid = attributes[:'uid']
|
74
|
+
end
|
66
75
|
end
|
67
76
|
|
68
77
|
# Returns the object in the form of hash, with additionalProperties support.
|
@@ -92,6 +101,7 @@ module DatadogAPIClient::V2
|
|
92
101
|
return true if self.equal?(o)
|
93
102
|
self.class == o.class &&
|
94
103
|
id == o.id &&
|
104
|
+
uid == o.uid &&
|
95
105
|
additional_properties == o.additional_properties
|
96
106
|
end
|
97
107
|
|
@@ -99,7 +109,7 @@ module DatadogAPIClient::V2
|
|
99
109
|
# @return [Integer] Hash code
|
100
110
|
# @!visibility private
|
101
111
|
def hash
|
102
|
-
[id, additional_properties].hash
|
112
|
+
[id, uid, additional_properties].hash
|
103
113
|
end
|
104
114
|
end
|
105
115
|
end
|
@@ -17,20 +17,24 @@ require 'date'
|
|
17
17
|
require 'time'
|
18
18
|
|
19
19
|
module DatadogAPIClient::V2
|
20
|
-
#
|
20
|
+
# Event creation response.
|
21
21
|
class EventCreateResponsePayload
|
22
22
|
include BaseGenericModel
|
23
23
|
|
24
|
-
#
|
24
|
+
# Event object.
|
25
25
|
attr_accessor :data
|
26
26
|
|
27
|
+
# Links to the event.
|
28
|
+
attr_accessor :links
|
29
|
+
|
27
30
|
attr_accessor :additional_properties
|
28
31
|
|
29
32
|
# Attribute mapping from ruby-style variable name to JSON key.
|
30
33
|
# @!visibility private
|
31
34
|
def self.attribute_map
|
32
35
|
{
|
33
|
-
:'data' => :'data'
|
36
|
+
:'data' => :'data',
|
37
|
+
:'links' => :'links'
|
34
38
|
}
|
35
39
|
end
|
36
40
|
|
@@ -38,7 +42,8 @@ module DatadogAPIClient::V2
|
|
38
42
|
# @!visibility private
|
39
43
|
def self.openapi_types
|
40
44
|
{
|
41
|
-
:'data' => :'EventCreateResponse'
|
45
|
+
:'data' => :'EventCreateResponse',
|
46
|
+
:'links' => :'EventCreateResponsePayloadLinks'
|
42
47
|
}
|
43
48
|
end
|
44
49
|
|
@@ -63,6 +68,10 @@ module DatadogAPIClient::V2
|
|
63
68
|
if attributes.key?(:'data')
|
64
69
|
self.data = attributes[:'data']
|
65
70
|
end
|
71
|
+
|
72
|
+
if attributes.key?(:'links')
|
73
|
+
self.links = attributes[:'links']
|
74
|
+
end
|
66
75
|
end
|
67
76
|
|
68
77
|
# Returns the object in the form of hash, with additionalProperties support.
|
@@ -92,6 +101,7 @@ module DatadogAPIClient::V2
|
|
92
101
|
return true if self.equal?(o)
|
93
102
|
self.class == o.class &&
|
94
103
|
data == o.data &&
|
104
|
+
links == o.links &&
|
95
105
|
additional_properties == o.additional_properties
|
96
106
|
end
|
97
107
|
|
@@ -99,7 +109,7 @@ module DatadogAPIClient::V2
|
|
99
109
|
# @return [Integer] Hash code
|
100
110
|
# @!visibility private
|
101
111
|
def hash
|
102
|
-
[data, additional_properties].hash
|
112
|
+
[data, links, additional_properties].hash
|
103
113
|
end
|
104
114
|
end
|
105
115
|
end
|