datadog_api_client 2.41.0 → 2.42.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/.generator/schemas/v1/openapi.yaml +69 -8
- data/.generator/schemas/v2/openapi.yaml +1568 -40
- data/CHANGELOG.md +15 -0
- data/examples/v2/actions-datastores/BulkWriteDatastoreItems.rb +24 -0
- data/examples/v2/actions-datastores/CreateDatastore.rb +15 -0
- data/examples/v2/actions-datastores/DeleteDatastore.rb +8 -0
- data/examples/v2/actions-datastores/DeleteDatastoreItem.rb +17 -0
- data/examples/v2/actions-datastores/GetDatastore.rb +8 -0
- data/examples/v2/actions-datastores/ListDatastoreItems.rb +8 -0
- data/examples/v2/actions-datastores/ListDatastores.rb +5 -0
- data/examples/v2/actions-datastores/UpdateDatastore.rb +18 -0
- data/examples/v2/actions-datastores/UpdateDatastoreItem.rb +18 -0
- data/examples/v2/aws-integration/CreateAWSAccount.rb +0 -3
- data/examples/v2/aws-integration/CreateAWSAccount_1716720881.rb +0 -3
- data/examples/v2/aws-integration/CreateNewAWSExternalID.rb +0 -3
- data/examples/v2/aws-integration/CreateNewAWSExternalID_364713854.rb +0 -3
- data/examples/v2/aws-integration/DeleteAWSAccount.rb +0 -3
- data/examples/v2/aws-integration/GetAWSAccount.rb +0 -3
- data/examples/v2/aws-integration/ListAWSAccounts.rb +0 -3
- data/examples/v2/aws-integration/ListAWSNamespaces.rb +0 -3
- data/examples/v2/aws-integration/ListAWSNamespaces_3031307873.rb +0 -3
- data/examples/v2/aws-integration/UpdateAWSAccount.rb +0 -3
- data/examples/v2/aws-logs-integration/ListAWSLogsServices.rb +0 -3
- data/examples/v2/ci-visibility-pipelines/CreateCIAppPipelineEvent_2836340212.rb +52 -0
- data/examples/v2/incidents/CreateIncidentNotificationRule.rb +50 -0
- data/examples/v2/incidents/CreateIncidentNotificationRule_3029800608.rb +42 -0
- data/examples/v2/incidents/DeleteIncidentNotificationRule.rb +8 -0
- data/examples/v2/incidents/DeleteIncidentNotificationRule_4148107167.rb +11 -0
- data/examples/v2/incidents/GetIncidentNotificationRule.rb +8 -0
- data/examples/v2/incidents/GetIncidentNotificationRule_67441486.rb +11 -0
- data/examples/v2/incidents/ListIncidentNotificationRules.rb +8 -0
- data/examples/v2/incidents/UpdateIncidentNotificationRule.rb +51 -0
- data/examples/v2/incidents/UpdateIncidentNotificationRule_1207309457.rb +45 -0
- data/lib/datadog_api_client/configuration.rb +5 -8
- data/lib/datadog_api_client/inflector.rb +67 -0
- data/lib/datadog_api_client/v1/api/aws_integration_api.rb +27 -0
- data/lib/datadog_api_client/v1/api/aws_logs_integration_api.rb +9 -0
- data/lib/datadog_api_client/v1/models/gcp_account.rb +18 -4
- data/lib/datadog_api_client/v1/models/gcp_monitored_resource_config.rb +118 -0
- data/lib/datadog_api_client/v1/models/gcp_monitored_resource_config_type.rb +28 -0
- data/lib/datadog_api_client/v2/api/actions_datastores_api.rb +655 -0
- data/lib/datadog_api_client/v2/api/aws_integration_api.rb +0 -42
- data/lib/datadog_api_client/v2/api/aws_logs_integration_api.rb +0 -6
- data/lib/datadog_api_client/v2/api/ci_visibility_pipelines_api.rb +2 -0
- data/lib/datadog_api_client/v2/api/incidents_api.rb +367 -0
- data/lib/datadog_api_client/v2/api/org_connections_api.rb +8 -0
- data/lib/datadog_api_client/v2/models/bulk_put_apps_datastore_items_request.rb +105 -0
- data/lib/datadog_api_client/v2/models/bulk_put_apps_datastore_items_request_data.rb +133 -0
- data/lib/datadog_api_client/v2/models/bulk_put_apps_datastore_items_request_data_attributes.rb +139 -0
- data/lib/datadog_api_client/v2/models/ci_app_create_pipeline_event_request.rb +2 -2
- data/lib/datadog_api_client/v2/models/ci_app_create_pipeline_event_request_data_single_or_array.rb +63 -0
- data/lib/datadog_api_client/v2/models/create_apps_datastore_request.rb +105 -0
- data/lib/datadog_api_client/v2/models/create_apps_datastore_request_data.rb +143 -0
- data/lib/datadog_api_client/v2/models/create_apps_datastore_request_data_attributes.rb +180 -0
- data/lib/datadog_api_client/v2/models/create_apps_datastore_request_data_attributes_org_access.rb +28 -0
- data/lib/datadog_api_client/v2/models/create_apps_datastore_response.rb +105 -0
- data/lib/datadog_api_client/v2/models/create_apps_datastore_response_data.rb +133 -0
- data/lib/datadog_api_client/v2/models/create_incident_notification_rule_request.rb +123 -0
- data/lib/datadog_api_client/v2/models/datastore.rb +105 -0
- data/lib/datadog_api_client/v2/models/datastore_array.rb +125 -0
- data/lib/datadog_api_client/v2/models/datastore_data.rb +143 -0
- data/lib/datadog_api_client/v2/models/datastore_data_attributes.rb +205 -0
- data/lib/datadog_api_client/v2/models/datastore_data_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/datastore_item_conflict_mode.rb +27 -0
- data/lib/datadog_api_client/v2/models/datastore_items_data_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/datastore_primary_key_generation_strategy.rb +27 -0
- data/lib/datadog_api_client/v2/models/delete_apps_datastore_item_request.rb +105 -0
- data/lib/datadog_api_client/v2/models/delete_apps_datastore_item_request_data.rb +133 -0
- data/lib/datadog_api_client/v2/models/delete_apps_datastore_item_request_data_attributes.rb +137 -0
- data/lib/datadog_api_client/v2/models/delete_apps_datastore_item_response.rb +105 -0
- data/lib/datadog_api_client/v2/models/delete_apps_datastore_item_response_data.rb +133 -0
- data/lib/datadog_api_client/v2/models/dora_failure_request_attributes.rb +1 -1
- data/lib/datadog_api_client/v2/models/gcp_monitored_resource_config.rb +118 -0
- data/lib/datadog_api_client/v2/models/gcp_monitored_resource_config_type.rb +28 -0
- data/lib/datadog_api_client/v2/models/gcpsts_service_account_attributes.rb +17 -2
- data/lib/datadog_api_client/v2/models/incident_notification_rule.rb +135 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_array.rb +147 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_array_meta.rb +105 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_array_meta_page.rb +125 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_attributes.rb +265 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_attributes_visibility.rb +28 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_conditions_items.rb +146 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_create_attributes.rb +201 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_create_attributes_visibility.rb +28 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_create_data.rb +154 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_create_data_relationships.rb +115 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_included_items.rb +64 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_relationships.rb +135 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_response_data.rb +164 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/incident_notification_rule_update_data.rb +175 -0
- data/lib/datadog_api_client/v2/models/incident_notification_template_object.rb +164 -0
- data/lib/datadog_api_client/v2/models/item_api_payload.rb +105 -0
- data/lib/datadog_api_client/v2/models/item_api_payload_array.rb +139 -0
- data/lib/datadog_api_client/v2/models/item_api_payload_data.rb +143 -0
- data/lib/datadog_api_client/v2/models/item_api_payload_data_attributes.rb +185 -0
- data/lib/datadog_api_client/v2/models/item_api_payload_meta.rb +115 -0
- data/lib/datadog_api_client/v2/models/item_api_payload_meta_page.rb +125 -0
- data/lib/datadog_api_client/v2/models/item_api_payload_meta_schema.rb +117 -0
- data/lib/datadog_api_client/v2/models/item_api_payload_meta_schema_field.rb +144 -0
- data/lib/datadog_api_client/v2/models/put_apps_datastore_item_response_array.rb +129 -0
- data/lib/datadog_api_client/v2/models/put_apps_datastore_item_response_data.rb +133 -0
- data/lib/datadog_api_client/v2/models/put_incident_notification_rule_request.rb +123 -0
- data/lib/datadog_api_client/v2/models/relationship_to_incident_notification_template.rb +123 -0
- data/lib/datadog_api_client/v2/models/relationship_to_incident_notification_template_data.rb +144 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_rule_convert_response.rb +11 -1
- data/lib/datadog_api_client/v2/models/update_apps_datastore_item_request.rb +105 -0
- data/lib/datadog_api_client/v2/models/update_apps_datastore_item_request_data.rb +143 -0
- data/lib/datadog_api_client/v2/models/update_apps_datastore_item_request_data_attributes.rb +158 -0
- data/lib/datadog_api_client/v2/models/update_apps_datastore_item_request_data_attributes_item_changes.rb +105 -0
- data/lib/datadog_api_client/v2/models/update_apps_datastore_item_request_data_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/update_apps_datastore_request.rb +105 -0
- data/lib/datadog_api_client/v2/models/update_apps_datastore_request_data.rb +143 -0
- data/lib/datadog_api_client/v2/models/update_apps_datastore_request_data_attributes.rb +115 -0
- data/lib/datadog_api_client/version.rb +1 -1
- metadata +87 -1
|
@@ -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
|
+
# The notification template relationship data.
|
|
21
|
+
class RelationshipToIncidentNotificationTemplateData
|
|
22
|
+
include BaseGenericModel
|
|
23
|
+
|
|
24
|
+
# The unique identifier of the notification template.
|
|
25
|
+
attr_reader :id
|
|
26
|
+
|
|
27
|
+
# Notification templates resource type.
|
|
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' => :'UUID',
|
|
46
|
+
:'type' => :'IncidentNotificationTemplateType'
|
|
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::RelationshipToIncidentNotificationTemplateData` 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
|
|
@@ -21,6 +21,9 @@ module DatadogAPIClient::V2
|
|
|
21
21
|
class SecurityMonitoringRuleConvertResponse
|
|
22
22
|
include BaseGenericModel
|
|
23
23
|
|
|
24
|
+
# the ID of the rule.
|
|
25
|
+
attr_accessor :rule_id
|
|
26
|
+
|
|
24
27
|
# Terraform string as a result of converting the rule from JSON.
|
|
25
28
|
attr_accessor :terraform_content
|
|
26
29
|
|
|
@@ -30,6 +33,7 @@ module DatadogAPIClient::V2
|
|
|
30
33
|
# @!visibility private
|
|
31
34
|
def self.attribute_map
|
|
32
35
|
{
|
|
36
|
+
:'rule_id' => :'ruleId',
|
|
33
37
|
:'terraform_content' => :'terraformContent'
|
|
34
38
|
}
|
|
35
39
|
end
|
|
@@ -38,6 +42,7 @@ module DatadogAPIClient::V2
|
|
|
38
42
|
# @!visibility private
|
|
39
43
|
def self.openapi_types
|
|
40
44
|
{
|
|
45
|
+
:'rule_id' => :'String',
|
|
41
46
|
:'terraform_content' => :'String'
|
|
42
47
|
}
|
|
43
48
|
end
|
|
@@ -60,6 +65,10 @@ module DatadogAPIClient::V2
|
|
|
60
65
|
end
|
|
61
66
|
}
|
|
62
67
|
|
|
68
|
+
if attributes.key?(:'rule_id')
|
|
69
|
+
self.rule_id = attributes[:'rule_id']
|
|
70
|
+
end
|
|
71
|
+
|
|
63
72
|
if attributes.key?(:'terraform_content')
|
|
64
73
|
self.terraform_content = attributes[:'terraform_content']
|
|
65
74
|
end
|
|
@@ -91,6 +100,7 @@ module DatadogAPIClient::V2
|
|
|
91
100
|
def ==(o)
|
|
92
101
|
return true if self.equal?(o)
|
|
93
102
|
self.class == o.class &&
|
|
103
|
+
rule_id == o.rule_id &&
|
|
94
104
|
terraform_content == o.terraform_content &&
|
|
95
105
|
additional_properties == o.additional_properties
|
|
96
106
|
end
|
|
@@ -99,7 +109,7 @@ module DatadogAPIClient::V2
|
|
|
99
109
|
# @return [Integer] Hash code
|
|
100
110
|
# @!visibility private
|
|
101
111
|
def hash
|
|
102
|
-
[terraform_content, additional_properties].hash
|
|
112
|
+
[rule_id, terraform_content, additional_properties].hash
|
|
103
113
|
end
|
|
104
114
|
end
|
|
105
115
|
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
|
+
# Request to update specific fields on an existing datastore item.
|
|
21
|
+
class UpdateAppsDatastoreItemRequest
|
|
22
|
+
include BaseGenericModel
|
|
23
|
+
|
|
24
|
+
# Data wrapper containing the item identifier and the changes to apply during the update operation.
|
|
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' => :'UpdateAppsDatastoreItemRequestData'
|
|
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::UpdateAppsDatastoreItemRequest` 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
|
+
# 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
|
+
data == o.data &&
|
|
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
|
+
[data, additional_properties].hash
|
|
103
|
+
end
|
|
104
|
+
end
|
|
105
|
+
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
|
+
# Data wrapper containing the item identifier and the changes to apply during the update operation.
|
|
21
|
+
class UpdateAppsDatastoreItemRequestData
|
|
22
|
+
include BaseGenericModel
|
|
23
|
+
|
|
24
|
+
# Attributes for updating a datastore item, including the item key and changes to apply.
|
|
25
|
+
attr_accessor :attributes
|
|
26
|
+
|
|
27
|
+
# The unique identifier of the datastore item.
|
|
28
|
+
attr_accessor :id
|
|
29
|
+
|
|
30
|
+
# The resource type for datastore items.
|
|
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
|
+
:'attributes' => :'attributes',
|
|
40
|
+
:'id' => :'id',
|
|
41
|
+
:'type' => :'type'
|
|
42
|
+
}
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
# Attribute type mapping.
|
|
46
|
+
# @!visibility private
|
|
47
|
+
def self.openapi_types
|
|
48
|
+
{
|
|
49
|
+
:'attributes' => :'UpdateAppsDatastoreItemRequestDataAttributes',
|
|
50
|
+
:'id' => :'String',
|
|
51
|
+
:'type' => :'UpdateAppsDatastoreItemRequestDataType'
|
|
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::UpdateAppsDatastoreItemRequestData` 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?(:'attributes')
|
|
74
|
+
self.attributes = attributes[:'attributes']
|
|
75
|
+
end
|
|
76
|
+
|
|
77
|
+
if attributes.key?(:'id')
|
|
78
|
+
self.id = attributes[:'id']
|
|
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
|
+
attributes == o.attributes &&
|
|
131
|
+
id == o.id &&
|
|
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
|
+
[attributes, id, type, additional_properties].hash
|
|
141
|
+
end
|
|
142
|
+
end
|
|
143
|
+
end
|
|
@@ -0,0 +1,158 @@
|
|
|
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
|
+
# Attributes for updating a datastore item, including the item key and changes to apply.
|
|
21
|
+
class UpdateAppsDatastoreItemRequestDataAttributes
|
|
22
|
+
include BaseGenericModel
|
|
23
|
+
|
|
24
|
+
# The unique identifier of the item being updated.
|
|
25
|
+
attr_accessor :id
|
|
26
|
+
|
|
27
|
+
# Changes to apply to a datastore item using set operations.
|
|
28
|
+
attr_reader :item_changes
|
|
29
|
+
|
|
30
|
+
# The primary key that identifies the item to update. Cannot exceed 256 characters.
|
|
31
|
+
attr_reader :item_key
|
|
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
|
+
:'item_changes' => :'item_changes',
|
|
41
|
+
:'item_key' => :'item_key'
|
|
42
|
+
}
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
# Attribute type mapping.
|
|
46
|
+
# @!visibility private
|
|
47
|
+
def self.openapi_types
|
|
48
|
+
{
|
|
49
|
+
:'id' => :'String',
|
|
50
|
+
:'item_changes' => :'UpdateAppsDatastoreItemRequestDataAttributesItemChanges',
|
|
51
|
+
:'item_key' => :'String'
|
|
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::UpdateAppsDatastoreItemRequestDataAttributes` 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?(:'item_changes')
|
|
78
|
+
self.item_changes = attributes[:'item_changes']
|
|
79
|
+
end
|
|
80
|
+
|
|
81
|
+
if attributes.key?(:'item_key')
|
|
82
|
+
self.item_key = attributes[:'item_key']
|
|
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 @item_changes.nil?
|
|
91
|
+
return false if @item_key.nil?
|
|
92
|
+
return false if @item_key.to_s.length > 256
|
|
93
|
+
true
|
|
94
|
+
end
|
|
95
|
+
|
|
96
|
+
# Custom attribute writer method with validation
|
|
97
|
+
# @param item_changes [Object] Object to be assigned
|
|
98
|
+
# @!visibility private
|
|
99
|
+
def item_changes=(item_changes)
|
|
100
|
+
if item_changes.nil?
|
|
101
|
+
fail ArgumentError, 'invalid value for "item_changes", item_changes cannot be nil.'
|
|
102
|
+
end
|
|
103
|
+
@item_changes = item_changes
|
|
104
|
+
end
|
|
105
|
+
|
|
106
|
+
# Custom attribute writer method with validation
|
|
107
|
+
# @param item_key [Object] Object to be assigned
|
|
108
|
+
# @!visibility private
|
|
109
|
+
def item_key=(item_key)
|
|
110
|
+
if item_key.nil?
|
|
111
|
+
fail ArgumentError, 'invalid value for "item_key", item_key cannot be nil.'
|
|
112
|
+
end
|
|
113
|
+
if item_key.to_s.length > 256
|
|
114
|
+
fail ArgumentError, 'invalid value for "item_key", the character length must be smaller than or equal to 256.'
|
|
115
|
+
end
|
|
116
|
+
@item_key = item_key
|
|
117
|
+
end
|
|
118
|
+
|
|
119
|
+
# Returns the object in the form of hash, with additionalProperties support.
|
|
120
|
+
# @return [Hash] Returns the object in the form of hash
|
|
121
|
+
# @!visibility private
|
|
122
|
+
def to_hash
|
|
123
|
+
hash = {}
|
|
124
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
125
|
+
value = self.send(attr)
|
|
126
|
+
if value.nil?
|
|
127
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
128
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
129
|
+
end
|
|
130
|
+
|
|
131
|
+
hash[param] = _to_hash(value)
|
|
132
|
+
end
|
|
133
|
+
self.additional_properties.each_pair do |attr, value|
|
|
134
|
+
hash[attr] = value
|
|
135
|
+
end
|
|
136
|
+
hash
|
|
137
|
+
end
|
|
138
|
+
|
|
139
|
+
# Checks equality by comparing each attribute.
|
|
140
|
+
# @param o [Object] Object to be compared
|
|
141
|
+
# @!visibility private
|
|
142
|
+
def ==(o)
|
|
143
|
+
return true if self.equal?(o)
|
|
144
|
+
self.class == o.class &&
|
|
145
|
+
id == o.id &&
|
|
146
|
+
item_changes == o.item_changes &&
|
|
147
|
+
item_key == o.item_key &&
|
|
148
|
+
additional_properties == o.additional_properties
|
|
149
|
+
end
|
|
150
|
+
|
|
151
|
+
# Calculates hash code according to all attributes.
|
|
152
|
+
# @return [Integer] Hash code
|
|
153
|
+
# @!visibility private
|
|
154
|
+
def hash
|
|
155
|
+
[id, item_changes, item_key, additional_properties].hash
|
|
156
|
+
end
|
|
157
|
+
end
|
|
158
|
+
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
|
+
# Changes to apply to a datastore item using set operations.
|
|
21
|
+
class UpdateAppsDatastoreItemRequestDataAttributesItemChanges
|
|
22
|
+
include BaseGenericModel
|
|
23
|
+
|
|
24
|
+
# Set operation that contains key-value pairs to set on the datastore item.
|
|
25
|
+
attr_accessor :ops_set
|
|
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
|
+
:'ops_set' => :'ops_set'
|
|
34
|
+
}
|
|
35
|
+
end
|
|
36
|
+
|
|
37
|
+
# Attribute type mapping.
|
|
38
|
+
# @!visibility private
|
|
39
|
+
def self.openapi_types
|
|
40
|
+
{
|
|
41
|
+
:'ops_set' => :'Hash<String, Object>'
|
|
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::UpdateAppsDatastoreItemRequestDataAttributesItemChanges` 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?(:'ops_set')
|
|
64
|
+
self.ops_set = attributes[:'ops_set']
|
|
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
|
+
ops_set == o.ops_set &&
|
|
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
|
+
[ops_set, additional_properties].hash
|
|
103
|
+
end
|
|
104
|
+
end
|
|
105
|
+
end
|