datadog_api_client 2.18.0 → 2.20.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/conftest.py +1 -1
- data/.generator/poetry.lock +69 -69
- data/.generator/schemas/v1/openapi.yaml +286 -55
- data/.generator/schemas/v2/openapi.yaml +2021 -226
- data/.generator/src/generator/templates/api.j2 +5 -5
- data/.generator/src/generator/templates/model_generic.j2 +2 -2
- data/CHANGELOG.md +38 -0
- data/examples/v1/azure-integration/CreateAzureIntegration.rb +4 -4
- data/examples/v1/azure-integration/DeleteAzureIntegration.rb +2 -15
- data/examples/v1/azure-integration/UpdateAzureIntegration.rb +4 -4
- data/examples/v1/gcp-integration/CreateGCPIntegration.rb +4 -5
- data/examples/v1/gcp-integration/DeleteGCPIntegration.rb +2 -14
- data/examples/v1/gcp-integration/UpdateGCPIntegration.rb +4 -5
- data/examples/v1/logs-indexes/CreateLogsIndex.rb +5 -0
- data/examples/v1/logs-indexes/UpdateLogsIndex.rb +5 -0
- data/examples/v1/service-level-objectives/CreateSLO_3765703239.rb +46 -0
- data/examples/v1/synthetics/CreateSyntheticsAPITest.rb +1 -1
- data/examples/v1/synthetics/CreateSyntheticsBrowserTest.rb +1 -1
- data/examples/v1/synthetics/TriggerCITests.rb +1 -1
- data/examples/v1/synthetics/UpdateBrowserTest.rb +1 -1
- data/examples/v1/usage-metering/GetUsageLambda.rb +5 -2
- data/examples/v2/api-management/CreateOpenAPI.rb +11 -0
- data/examples/v2/api-management/DeleteOpenAPI.rb +11 -0
- data/examples/v2/api-management/GetOpenAPI.rb +11 -0
- data/examples/v2/api-management/UpdateOpenAPI.rb +14 -0
- data/examples/v2/ci-visibility-pipelines/CreateCIAppPipelineEvent.rb +0 -3
- data/examples/v2/ci-visibility-pipelines/CreateCIAppPipelineEvent_129899466.rb +0 -3
- data/examples/v2/cloud-cost-management/CreateCostAWSCURConfig.rb +18 -0
- data/examples/v2/cloud-cost-management/CreateCostAzureUCConfigs.rb +29 -0
- data/examples/v2/cloud-cost-management/DeleteCostAWSCURConfig.rb +5 -0
- data/examples/v2/cloud-cost-management/DeleteCostAzureUCConfig.rb +5 -0
- data/examples/v2/cloud-cost-management/GetCloudCostActivity.rb +5 -0
- data/examples/v2/cloud-cost-management/ListAWSRelatedAccounts.rb +5 -0
- data/examples/v2/cloud-cost-management/ListCostAWSCURConfigs.rb +5 -0
- data/examples/v2/cloud-cost-management/ListCostAzureUCConfigs.rb +5 -0
- data/examples/v2/cloud-cost-management/UpdateCostAWSCURConfig.rb +14 -0
- data/examples/v2/cloud-cost-management/UpdateCostAzureUCConfigs.rb +14 -0
- data/examples/v2/cloudflare-integration/CreateCloudflareAccount.rb +1 -1
- data/examples/v2/cloudflare-integration/UpdateCloudflareAccount.rb +4 -1
- data/examples/v2/downtimes/ListMonitorDowntimes_3316718253.rb +5 -0
- data/examples/v2/gcp-integration/CreateGCPSTSAccount_130557025.rb +16 -0
- data/examples/v2/gcp-integration/CreateGCPSTSAccount_2597004741.rb +16 -0
- data/examples/v2/gcp-integration/CreateGCPSTSAccount_4235664992.rb +17 -0
- data/examples/v2/gcp-integration/UpdateGCPSTSAccount_3205636354.rb +19 -0
- data/examples/v2/okta-integration/CreateOktaAccount.rb +1 -1
- data/examples/v2/security-monitoring/CreateSecurityMonitoringRule_3367706049.rb +46 -0
- data/examples/v2/security-monitoring/CreateSecurityMonitoringSuppression.rb +19 -0
- data/examples/v2/security-monitoring/DeleteSecurityMonitoringSuppression.rb +8 -0
- data/examples/v2/security-monitoring/GetSecurityMonitoringSuppression.rb +8 -0
- data/examples/v2/security-monitoring/ListSecurityMonitoringSuppressions.rb +5 -0
- data/examples/v2/security-monitoring/UpdateSecurityMonitoringSuppression.rb +17 -0
- data/examples/v2/sensitive-data-scanner/CreateScanningRule.rb +7 -0
- data/examples/v2/sensitive-data-scanner/UpdateScanningRule.rb +7 -10
- data/examples/v2/teams/CreateTeamMembership.rb +6 -0
- data/examples/v2/teams/GetTeamMemberships_3799131168.rb +8 -0
- data/examples/v2/usage-metering/GetUsageLambdaTracedInvocations.rb +1 -1
- data/lib/datadog_api_client/configuration.rb +4 -1
- data/lib/datadog_api_client/inflector.rb +74 -0
- data/lib/datadog_api_client/v1/api/downtimes_api.rb +28 -7
- data/lib/datadog_api_client/v1/api/monitors_api.rb +1 -1
- data/lib/datadog_api_client/v1/api/organizations_api.rb +1 -1
- data/lib/datadog_api_client/v1/api/usage_metering_api.rb +3 -3
- data/lib/datadog_api_client/v1/models/dashboard.rb +5 -1
- data/lib/datadog_api_client/v1/models/dashboard_summary_definition.rb +2 -0
- data/lib/datadog_api_client/v1/models/gcp_account.rb +22 -2
- data/lib/datadog_api_client/v1/models/log.rb +1 -1
- data/lib/datadog_api_client/v1/models/logs_daily_limit_reset.rb +90 -0
- data/lib/datadog_api_client/v1/models/logs_index.rb +36 -1
- data/lib/datadog_api_client/v1/models/logs_index_update_request.rb +36 -1
- data/lib/datadog_api_client/v1/models/metrics_payload.rb +1 -1
- data/lib/datadog_api_client/v1/models/metrics_query_metadata.rb +1 -1
- data/lib/datadog_api_client/v1/models/organization.rb +1 -1
- data/lib/datadog_api_client/v1/models/service_level_objective.rb +11 -1
- data/lib/datadog_api_client/v1/models/service_level_objective_request.rb +11 -1
- data/lib/datadog_api_client/v1/models/slo_correction_create_request_attributes.rb +1 -1
- data/lib/datadog_api_client/v1/models/slo_correction_response_attributes.rb +1 -1
- data/lib/datadog_api_client/v1/models/slo_correction_update_request_attributes.rb +1 -1
- data/lib/datadog_api_client/v1/models/slo_data_source_query_definition.rb +62 -0
- data/lib/datadog_api_client/v1/models/slo_formula.rb +98 -0
- data/lib/datadog_api_client/v1/models/slo_history_metrics.rb +2 -2
- data/lib/datadog_api_client/v1/models/slo_history_metrics_series.rb +1 -1
- data/lib/datadog_api_client/v1/models/slo_history_monitor.rb +1 -1
- data/lib/datadog_api_client/v1/models/slo_history_sli_data.rb +1 -1
- data/lib/datadog_api_client/v1/models/slo_response_data.rb +11 -1
- data/lib/datadog_api_client/v1/models/slo_sli_spec.rb +62 -0
- data/lib/datadog_api_client/v1/models/slo_time_slice_comparator.rb +29 -0
- data/lib/datadog_api_client/v1/models/slo_time_slice_condition.rb +141 -0
- data/lib/datadog_api_client/v1/models/slo_time_slice_query.rb +131 -0
- data/lib/datadog_api_client/v1/models/slo_time_slice_spec.rb +99 -0
- data/lib/datadog_api_client/v1/models/slo_type.rb +1 -0
- data/lib/datadog_api_client/v1/models/slo_type_numeric.rb +1 -0
- data/lib/datadog_api_client/v1/models/split_config.rb +6 -6
- data/lib/datadog_api_client/v1/models/synthetics_test_request.rb +11 -1
- data/lib/datadog_api_client/v1/models/usage_lambda_hour.rb +1 -1
- data/lib/datadog_api_client/v1/models/usage_lambda_response.rb +1 -1
- data/lib/datadog_api_client/v1/models/usage_summary_date.rb +11 -1
- data/lib/datadog_api_client/v1/models/usage_summary_date_org.rb +11 -1
- data/lib/datadog_api_client/v1/models/usage_summary_response.rb +11 -1
- data/lib/datadog_api_client/v2/api/api_management_api.rb +319 -0
- data/lib/datadog_api_client/v2/api/ci_visibility_pipelines_api.rb +0 -6
- data/lib/datadog_api_client/v2/api/cloud_cost_management_api.rb +680 -0
- data/lib/datadog_api_client/v2/api/downtimes_api.rb +25 -0
- data/lib/datadog_api_client/v2/api/metrics_api.rb +3 -2
- data/lib/datadog_api_client/v2/api/organizations_api.rb +1 -1
- data/lib/datadog_api_client/v2/api/security_monitoring_api.rb +329 -0
- data/lib/datadog_api_client/v2/api/teams_api.rb +22 -0
- data/lib/datadog_api_client/v2/api/usage_metering_api.rb +3 -3
- data/lib/datadog_api_client/v2/models/aws_cur_config.rb +129 -0
- data/lib/datadog_api_client/v2/models/aws_cur_config_attributes.rb +305 -0
- data/lib/datadog_api_client/v2/models/aws_cur_config_patch_data.rb +119 -0
- data/lib/datadog_api_client/v2/models/aws_cur_config_patch_request.rb +98 -0
- data/lib/datadog_api_client/v2/models/aws_cur_config_patch_request_attributes.rb +98 -0
- data/lib/datadog_api_client/v2/models/aws_cur_config_patch_request_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/aws_cur_config_post_data.rb +119 -0
- data/lib/datadog_api_client/v2/models/aws_cur_config_post_request.rb +98 -0
- data/lib/datadog_api_client/v2/models/aws_cur_config_post_request_attributes.rb +202 -0
- data/lib/datadog_api_client/v2/models/aws_cur_config_post_request_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/aws_cur_config_response.rb +80 -0
- data/lib/datadog_api_client/v2/models/aws_cur_config_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/aws_cur_configs_response.rb +82 -0
- data/lib/datadog_api_client/v2/models/aws_related_account.rb +129 -0
- data/lib/datadog_api_client/v2/models/aws_related_account_attributes.rb +90 -0
- data/lib/datadog_api_client/v2/models/aws_related_account_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/aws_related_accounts_response.rb +82 -0
- data/lib/datadog_api_client/v2/models/azure_uc_config.rb +378 -0
- data/lib/datadog_api_client/v2/models/azure_uc_config_pair.rb +129 -0
- data/lib/datadog_api_client/v2/models/azure_uc_config_pair_attributes.rb +110 -0
- data/lib/datadog_api_client/v2/models/azure_uc_config_pair_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/azure_uc_config_pairs_response.rb +80 -0
- data/lib/datadog_api_client/v2/models/azure_uc_config_patch_data.rb +119 -0
- data/lib/datadog_api_client/v2/models/azure_uc_config_patch_request.rb +98 -0
- data/lib/datadog_api_client/v2/models/azure_uc_config_patch_request_attributes.rb +98 -0
- data/lib/datadog_api_client/v2/models/azure_uc_config_patch_request_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/azure_uc_config_post_data.rb +119 -0
- data/lib/datadog_api_client/v2/models/azure_uc_config_post_request.rb +98 -0
- data/lib/datadog_api_client/v2/models/azure_uc_config_post_request_attributes.rb +192 -0
- data/lib/datadog_api_client/v2/models/azure_uc_config_post_request_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/azure_uc_configs_response.rb +82 -0
- data/lib/datadog_api_client/v2/models/bill_config.rb +161 -0
- data/lib/datadog_api_client/v2/models/ci_app_git_info.rb +2 -2
- data/lib/datadog_api_client/v2/models/cloud_cost_activity.rb +119 -0
- data/lib/datadog_api_client/v2/models/cloud_cost_activity_attributes.rb +98 -0
- data/lib/datadog_api_client/v2/models/cloud_cost_activity_response.rb +80 -0
- data/lib/datadog_api_client/v2/models/cloud_cost_activity_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/cloudflare_account_create_request_attributes.rb +28 -4
- data/lib/datadog_api_client/v2/models/cloudflare_account_response_attributes.rb +28 -4
- data/lib/datadog_api_client/v2/models/cloudflare_account_update_request_attributes.rb +28 -4
- data/lib/datadog_api_client/v2/models/create_open_api_response.rb +80 -0
- data/lib/datadog_api_client/v2/models/create_open_api_response_attributes.rb +82 -0
- data/lib/datadog_api_client/v2/models/create_open_api_response_data.rb +90 -0
- data/lib/datadog_api_client/v2/models/dora_deployment_request_attributes.rb +11 -1
- data/lib/datadog_api_client/v2/models/dora_git_info.rb +2 -2
- data/lib/datadog_api_client/v2/models/dora_incident_request_attributes.rb +11 -1
- data/lib/datadog_api_client/v2/models/gcpsts_service_account_attributes.rb +25 -5
- data/lib/datadog_api_client/v2/models/metric_payload.rb +1 -1
- data/lib/datadog_api_client/v2/models/open_api_endpoint.rb +90 -0
- data/lib/datadog_api_client/v2/models/open_api_file.rb +80 -0
- data/lib/datadog_api_client/v2/models/relationship_to_user_team_team.rb +98 -0
- data/lib/datadog_api_client/v2/models/relationship_to_user_team_team_data.rb +119 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_rule_options.rb +14 -4
- data/lib/datadog_api_client/v2/models/security_monitoring_rule_third_party_options.rb +114 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_rule_update_payload.rb +13 -1
- data/lib/datadog_api_client/v2/models/security_monitoring_standard_rule_create_payload.rb +13 -1
- data/lib/datadog_api_client/v2/models/security_monitoring_standard_rule_response.rb +13 -1
- data/lib/datadog_api_client/v2/models/security_monitoring_suppression.rb +100 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_suppression_attributes.rb +198 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_suppression_create_attributes.rb +181 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_suppression_create_data.rb +119 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_suppression_create_request.rb +98 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_suppression_response.rb +80 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_suppression_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_suppression_update_attributes.rb +166 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_suppression_update_data.rb +119 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_suppression_update_request.rb +98 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_suppressions_response.rb +82 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_third_party_root_query.rb +92 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_third_party_rule_case.rb +112 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_third_party_rule_case_create.rb +130 -0
- data/lib/datadog_api_client/v2/models/security_monitoring_user.rb +98 -0
- data/lib/datadog_api_client/v2/models/sensitive_data_scanner_included_keyword_configuration.rb +134 -0
- data/lib/datadog_api_client/v2/models/sensitive_data_scanner_rule_attributes.rb +46 -1
- data/lib/datadog_api_client/v2/models/sensitive_data_scanner_standard_pattern_attributes.rb +33 -1
- data/lib/datadog_api_client/v2/models/update_open_api_response.rb +80 -0
- data/lib/datadog_api_client/v2/models/update_open_api_response_attributes.rb +82 -0
- data/lib/datadog_api_client/v2/models/update_open_api_response_data.rb +90 -0
- data/lib/datadog_api_client/v2/models/user_team_attributes.rb +24 -1
- data/lib/datadog_api_client/v2/models/user_team_relationships.rb +11 -1
- data/lib/datadog_api_client/v2/models/user_team_team_type.rb +26 -0
- data/lib/datadog_api_client/version.rb +1 -1
- metadata +103 -3
- data/examples/v1/usage-metering/GetUsageLambda_3132428705.rb +0 -8
|
@@ -0,0 +1,98 @@
|
|
|
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
|
+
# A user.
|
|
21
|
+
class SecurityMonitoringUser
|
|
22
|
+
include BaseGenericModel
|
|
23
|
+
|
|
24
|
+
# The handle of the user.
|
|
25
|
+
attr_accessor :handle
|
|
26
|
+
|
|
27
|
+
# The name of the user.
|
|
28
|
+
attr_accessor :name
|
|
29
|
+
|
|
30
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
31
|
+
# @!visibility private
|
|
32
|
+
def self.attribute_map
|
|
33
|
+
{
|
|
34
|
+
:'handle' => :'handle',
|
|
35
|
+
:'name' => :'name'
|
|
36
|
+
}
|
|
37
|
+
end
|
|
38
|
+
|
|
39
|
+
# Attribute type mapping.
|
|
40
|
+
# @!visibility private
|
|
41
|
+
def self.openapi_types
|
|
42
|
+
{
|
|
43
|
+
:'handle' => :'String',
|
|
44
|
+
:'name' => :'String'
|
|
45
|
+
}
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
# List of attributes with nullable: true
|
|
49
|
+
# @!visibility private
|
|
50
|
+
def self.openapi_nullable
|
|
51
|
+
Set.new([
|
|
52
|
+
:'name',
|
|
53
|
+
])
|
|
54
|
+
end
|
|
55
|
+
|
|
56
|
+
# Initializes the object
|
|
57
|
+
# @param attributes [Hash] Model attributes in the form of hash
|
|
58
|
+
# @!visibility private
|
|
59
|
+
def initialize(attributes = {})
|
|
60
|
+
if (!attributes.is_a?(Hash))
|
|
61
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::SecurityMonitoringUser` initialize method"
|
|
62
|
+
end
|
|
63
|
+
|
|
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
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::SecurityMonitoringUser`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
|
68
|
+
end
|
|
69
|
+
h[k.to_sym] = v
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
if attributes.key?(:'handle')
|
|
73
|
+
self.handle = attributes[:'handle']
|
|
74
|
+
end
|
|
75
|
+
|
|
76
|
+
if attributes.key?(:'name')
|
|
77
|
+
self.name = attributes[:'name']
|
|
78
|
+
end
|
|
79
|
+
end
|
|
80
|
+
|
|
81
|
+
# Checks equality by comparing each attribute.
|
|
82
|
+
# @param o [Object] Object to be compared
|
|
83
|
+
# @!visibility private
|
|
84
|
+
def ==(o)
|
|
85
|
+
return true if self.equal?(o)
|
|
86
|
+
self.class == o.class &&
|
|
87
|
+
handle == o.handle &&
|
|
88
|
+
name == o.name
|
|
89
|
+
end
|
|
90
|
+
|
|
91
|
+
# Calculates hash code according to all attributes.
|
|
92
|
+
# @return [Integer] Hash code
|
|
93
|
+
# @!visibility private
|
|
94
|
+
def hash
|
|
95
|
+
[handle, name].hash
|
|
96
|
+
end
|
|
97
|
+
end
|
|
98
|
+
end
|
data/lib/datadog_api_client/v2/models/sensitive_data_scanner_included_keyword_configuration.rb
ADDED
|
@@ -0,0 +1,134 @@
|
|
|
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
|
+
# Object defining a set of keywords and a number of characters that help reduce noise.
|
|
21
|
+
# You can provide a list of keywords you would like to check within a defined proximity of the matching pattern.
|
|
22
|
+
# If any of the keywords are found within the proximity check, the match is kept.
|
|
23
|
+
# If none are found, the match is discarded.
|
|
24
|
+
class SensitiveDataScannerIncludedKeywordConfiguration
|
|
25
|
+
include BaseGenericModel
|
|
26
|
+
|
|
27
|
+
# The number of characters behind a match detected by Sensitive Data Scanner to look for the keywords defined.
|
|
28
|
+
# `character_count` should be greater than the maximum length of a keyword defined for a rule.
|
|
29
|
+
attr_reader :character_count
|
|
30
|
+
|
|
31
|
+
# Keyword list that will be checked during scanning in order to validate a match.
|
|
32
|
+
# The number of keywords in the list must be less than or equal to 30.
|
|
33
|
+
attr_reader :keywords
|
|
34
|
+
|
|
35
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
36
|
+
# @!visibility private
|
|
37
|
+
def self.attribute_map
|
|
38
|
+
{
|
|
39
|
+
:'character_count' => :'character_count',
|
|
40
|
+
:'keywords' => :'keywords'
|
|
41
|
+
}
|
|
42
|
+
end
|
|
43
|
+
|
|
44
|
+
# Attribute type mapping.
|
|
45
|
+
# @!visibility private
|
|
46
|
+
def self.openapi_types
|
|
47
|
+
{
|
|
48
|
+
:'character_count' => :'Integer',
|
|
49
|
+
:'keywords' => :'Array<String>'
|
|
50
|
+
}
|
|
51
|
+
end
|
|
52
|
+
|
|
53
|
+
# Initializes the object
|
|
54
|
+
# @param attributes [Hash] Model attributes in the form of hash
|
|
55
|
+
# @!visibility private
|
|
56
|
+
def initialize(attributes = {})
|
|
57
|
+
if (!attributes.is_a?(Hash))
|
|
58
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::SensitiveDataScannerIncludedKeywordConfiguration` initialize method"
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
62
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
63
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
64
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::SensitiveDataScannerIncludedKeywordConfiguration`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
|
65
|
+
end
|
|
66
|
+
h[k.to_sym] = v
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
if attributes.key?(:'character_count')
|
|
70
|
+
self.character_count = attributes[:'character_count']
|
|
71
|
+
end
|
|
72
|
+
|
|
73
|
+
if attributes.key?(:'keywords')
|
|
74
|
+
if (value = attributes[:'keywords']).is_a?(Array)
|
|
75
|
+
self.keywords = value
|
|
76
|
+
end
|
|
77
|
+
end
|
|
78
|
+
end
|
|
79
|
+
|
|
80
|
+
# Check to see if the all the properties in the model are valid
|
|
81
|
+
# @return true if the model is valid
|
|
82
|
+
# @!visibility private
|
|
83
|
+
def valid?
|
|
84
|
+
return false if @character_count.nil?
|
|
85
|
+
return false if @character_count > 50
|
|
86
|
+
return false if @character_count < 1
|
|
87
|
+
return false if @keywords.nil?
|
|
88
|
+
true
|
|
89
|
+
end
|
|
90
|
+
|
|
91
|
+
# Custom attribute writer method with validation
|
|
92
|
+
# @param character_count [Object] Object to be assigned
|
|
93
|
+
# @!visibility private
|
|
94
|
+
def character_count=(character_count)
|
|
95
|
+
if character_count.nil?
|
|
96
|
+
fail ArgumentError, 'invalid value for "character_count", character_count cannot be nil.'
|
|
97
|
+
end
|
|
98
|
+
if character_count > 50
|
|
99
|
+
fail ArgumentError, 'invalid value for "character_count", must be smaller than or equal to 50.'
|
|
100
|
+
end
|
|
101
|
+
if character_count < 1
|
|
102
|
+
fail ArgumentError, 'invalid value for "character_count", must be greater than or equal to 1.'
|
|
103
|
+
end
|
|
104
|
+
@character_count = character_count
|
|
105
|
+
end
|
|
106
|
+
|
|
107
|
+
# Custom attribute writer method with validation
|
|
108
|
+
# @param keywords [Object] Object to be assigned
|
|
109
|
+
# @!visibility private
|
|
110
|
+
def keywords=(keywords)
|
|
111
|
+
if keywords.nil?
|
|
112
|
+
fail ArgumentError, 'invalid value for "keywords", keywords cannot be nil.'
|
|
113
|
+
end
|
|
114
|
+
@keywords = keywords
|
|
115
|
+
end
|
|
116
|
+
|
|
117
|
+
# Checks equality by comparing each attribute.
|
|
118
|
+
# @param o [Object] Object to be compared
|
|
119
|
+
# @!visibility private
|
|
120
|
+
def ==(o)
|
|
121
|
+
return true if self.equal?(o)
|
|
122
|
+
self.class == o.class &&
|
|
123
|
+
character_count == o.character_count &&
|
|
124
|
+
keywords == o.keywords
|
|
125
|
+
end
|
|
126
|
+
|
|
127
|
+
# Calculates hash code according to all attributes.
|
|
128
|
+
# @return [Integer] Hash code
|
|
129
|
+
# @!visibility private
|
|
130
|
+
def hash
|
|
131
|
+
[character_count, keywords].hash
|
|
132
|
+
end
|
|
133
|
+
end
|
|
134
|
+
end
|
|
@@ -27,6 +27,12 @@ module DatadogAPIClient::V2
|
|
|
27
27
|
# Attributes excluded from the scan. If namespaces is provided, it has to be a sub-path of the namespaces array.
|
|
28
28
|
attr_accessor :excluded_namespaces
|
|
29
29
|
|
|
30
|
+
# Object defining a set of keywords and a number of characters that help reduce noise.
|
|
31
|
+
# You can provide a list of keywords you would like to check within a defined proximity of the matching pattern.
|
|
32
|
+
# If any of the keywords are found within the proximity check, the match is kept.
|
|
33
|
+
# If none are found, the match is discarded.
|
|
34
|
+
attr_accessor :included_keyword_configuration
|
|
35
|
+
|
|
30
36
|
# Whether or not the rule is enabled.
|
|
31
37
|
attr_accessor :is_enabled
|
|
32
38
|
|
|
@@ -40,6 +46,9 @@ module DatadogAPIClient::V2
|
|
|
40
46
|
# Not included if there is a relationship to a standard pattern.
|
|
41
47
|
attr_accessor :pattern
|
|
42
48
|
|
|
49
|
+
# Integer from 1 (high) to 5 (low) indicating rule issue severity.
|
|
50
|
+
attr_reader :priority
|
|
51
|
+
|
|
43
52
|
# List of tags.
|
|
44
53
|
attr_accessor :tags
|
|
45
54
|
|
|
@@ -52,10 +61,12 @@ module DatadogAPIClient::V2
|
|
|
52
61
|
{
|
|
53
62
|
:'description' => :'description',
|
|
54
63
|
:'excluded_namespaces' => :'excluded_namespaces',
|
|
64
|
+
:'included_keyword_configuration' => :'included_keyword_configuration',
|
|
55
65
|
:'is_enabled' => :'is_enabled',
|
|
56
66
|
:'name' => :'name',
|
|
57
67
|
:'namespaces' => :'namespaces',
|
|
58
68
|
:'pattern' => :'pattern',
|
|
69
|
+
:'priority' => :'priority',
|
|
59
70
|
:'tags' => :'tags',
|
|
60
71
|
:'text_replacement' => :'text_replacement'
|
|
61
72
|
}
|
|
@@ -67,10 +78,12 @@ module DatadogAPIClient::V2
|
|
|
67
78
|
{
|
|
68
79
|
:'description' => :'String',
|
|
69
80
|
:'excluded_namespaces' => :'Array<String>',
|
|
81
|
+
:'included_keyword_configuration' => :'SensitiveDataScannerIncludedKeywordConfiguration',
|
|
70
82
|
:'is_enabled' => :'Boolean',
|
|
71
83
|
:'name' => :'String',
|
|
72
84
|
:'namespaces' => :'Array<String>',
|
|
73
85
|
:'pattern' => :'String',
|
|
86
|
+
:'priority' => :'Integer',
|
|
74
87
|
:'tags' => :'Array<String>',
|
|
75
88
|
:'text_replacement' => :'SensitiveDataScannerTextReplacement'
|
|
76
89
|
}
|
|
@@ -102,6 +115,10 @@ module DatadogAPIClient::V2
|
|
|
102
115
|
end
|
|
103
116
|
end
|
|
104
117
|
|
|
118
|
+
if attributes.key?(:'included_keyword_configuration')
|
|
119
|
+
self.included_keyword_configuration = attributes[:'included_keyword_configuration']
|
|
120
|
+
end
|
|
121
|
+
|
|
105
122
|
if attributes.key?(:'is_enabled')
|
|
106
123
|
self.is_enabled = attributes[:'is_enabled']
|
|
107
124
|
end
|
|
@@ -120,6 +137,10 @@ module DatadogAPIClient::V2
|
|
|
120
137
|
self.pattern = attributes[:'pattern']
|
|
121
138
|
end
|
|
122
139
|
|
|
140
|
+
if attributes.key?(:'priority')
|
|
141
|
+
self.priority = attributes[:'priority']
|
|
142
|
+
end
|
|
143
|
+
|
|
123
144
|
if attributes.key?(:'tags')
|
|
124
145
|
if (value = attributes[:'tags']).is_a?(Array)
|
|
125
146
|
self.tags = value
|
|
@@ -131,6 +152,28 @@ module DatadogAPIClient::V2
|
|
|
131
152
|
end
|
|
132
153
|
end
|
|
133
154
|
|
|
155
|
+
# Check to see if the all the properties in the model are valid
|
|
156
|
+
# @return true if the model is valid
|
|
157
|
+
# @!visibility private
|
|
158
|
+
def valid?
|
|
159
|
+
return false if !@priority.nil? && @priority > 5
|
|
160
|
+
return false if !@priority.nil? && @priority < 1
|
|
161
|
+
true
|
|
162
|
+
end
|
|
163
|
+
|
|
164
|
+
# Custom attribute writer method with validation
|
|
165
|
+
# @param priority [Object] Object to be assigned
|
|
166
|
+
# @!visibility private
|
|
167
|
+
def priority=(priority)
|
|
168
|
+
if !priority.nil? && priority > 5
|
|
169
|
+
fail ArgumentError, 'invalid value for "priority", must be smaller than or equal to 5.'
|
|
170
|
+
end
|
|
171
|
+
if !priority.nil? && priority < 1
|
|
172
|
+
fail ArgumentError, 'invalid value for "priority", must be greater than or equal to 1.'
|
|
173
|
+
end
|
|
174
|
+
@priority = priority
|
|
175
|
+
end
|
|
176
|
+
|
|
134
177
|
# Checks equality by comparing each attribute.
|
|
135
178
|
# @param o [Object] Object to be compared
|
|
136
179
|
# @!visibility private
|
|
@@ -139,10 +182,12 @@ module DatadogAPIClient::V2
|
|
|
139
182
|
self.class == o.class &&
|
|
140
183
|
description == o.description &&
|
|
141
184
|
excluded_namespaces == o.excluded_namespaces &&
|
|
185
|
+
included_keyword_configuration == o.included_keyword_configuration &&
|
|
142
186
|
is_enabled == o.is_enabled &&
|
|
143
187
|
name == o.name &&
|
|
144
188
|
namespaces == o.namespaces &&
|
|
145
189
|
pattern == o.pattern &&
|
|
190
|
+
priority == o.priority &&
|
|
146
191
|
tags == o.tags &&
|
|
147
192
|
text_replacement == o.text_replacement
|
|
148
193
|
end
|
|
@@ -151,7 +196,7 @@ module DatadogAPIClient::V2
|
|
|
151
196
|
# @return [Integer] Hash code
|
|
152
197
|
# @!visibility private
|
|
153
198
|
def hash
|
|
154
|
-
[description, excluded_namespaces, is_enabled, name, namespaces, pattern, tags, text_replacement].hash
|
|
199
|
+
[description, excluded_namespaces, included_keyword_configuration, is_enabled, name, namespaces, pattern, priority, tags, text_replacement].hash
|
|
155
200
|
end
|
|
156
201
|
end
|
|
157
202
|
end
|
|
@@ -33,6 +33,9 @@ module DatadogAPIClient::V2
|
|
|
33
33
|
# Regex to match.
|
|
34
34
|
attr_accessor :pattern
|
|
35
35
|
|
|
36
|
+
# Integer from 1 (high) to 5 (low) indicating standard pattern issue severity.
|
|
37
|
+
attr_reader :priority
|
|
38
|
+
|
|
36
39
|
# List of tags.
|
|
37
40
|
attr_accessor :tags
|
|
38
41
|
|
|
@@ -44,6 +47,7 @@ module DatadogAPIClient::V2
|
|
|
44
47
|
:'included_keywords' => :'included_keywords',
|
|
45
48
|
:'name' => :'name',
|
|
46
49
|
:'pattern' => :'pattern',
|
|
50
|
+
:'priority' => :'priority',
|
|
47
51
|
:'tags' => :'tags'
|
|
48
52
|
}
|
|
49
53
|
end
|
|
@@ -56,6 +60,7 @@ module DatadogAPIClient::V2
|
|
|
56
60
|
:'included_keywords' => :'Array<String>',
|
|
57
61
|
:'name' => :'String',
|
|
58
62
|
:'pattern' => :'String',
|
|
63
|
+
:'priority' => :'Integer',
|
|
59
64
|
:'tags' => :'Array<String>'
|
|
60
65
|
}
|
|
61
66
|
end
|
|
@@ -94,6 +99,10 @@ module DatadogAPIClient::V2
|
|
|
94
99
|
self.pattern = attributes[:'pattern']
|
|
95
100
|
end
|
|
96
101
|
|
|
102
|
+
if attributes.key?(:'priority')
|
|
103
|
+
self.priority = attributes[:'priority']
|
|
104
|
+
end
|
|
105
|
+
|
|
97
106
|
if attributes.key?(:'tags')
|
|
98
107
|
if (value = attributes[:'tags']).is_a?(Array)
|
|
99
108
|
self.tags = value
|
|
@@ -101,6 +110,28 @@ module DatadogAPIClient::V2
|
|
|
101
110
|
end
|
|
102
111
|
end
|
|
103
112
|
|
|
113
|
+
# Check to see if the all the properties in the model are valid
|
|
114
|
+
# @return true if the model is valid
|
|
115
|
+
# @!visibility private
|
|
116
|
+
def valid?
|
|
117
|
+
return false if !@priority.nil? && @priority > 5
|
|
118
|
+
return false if !@priority.nil? && @priority < 1
|
|
119
|
+
true
|
|
120
|
+
end
|
|
121
|
+
|
|
122
|
+
# Custom attribute writer method with validation
|
|
123
|
+
# @param priority [Object] Object to be assigned
|
|
124
|
+
# @!visibility private
|
|
125
|
+
def priority=(priority)
|
|
126
|
+
if !priority.nil? && priority > 5
|
|
127
|
+
fail ArgumentError, 'invalid value for "priority", must be smaller than or equal to 5.'
|
|
128
|
+
end
|
|
129
|
+
if !priority.nil? && priority < 1
|
|
130
|
+
fail ArgumentError, 'invalid value for "priority", must be greater than or equal to 1.'
|
|
131
|
+
end
|
|
132
|
+
@priority = priority
|
|
133
|
+
end
|
|
134
|
+
|
|
104
135
|
# Checks equality by comparing each attribute.
|
|
105
136
|
# @param o [Object] Object to be compared
|
|
106
137
|
# @!visibility private
|
|
@@ -111,6 +142,7 @@ module DatadogAPIClient::V2
|
|
|
111
142
|
included_keywords == o.included_keywords &&
|
|
112
143
|
name == o.name &&
|
|
113
144
|
pattern == o.pattern &&
|
|
145
|
+
priority == o.priority &&
|
|
114
146
|
tags == o.tags
|
|
115
147
|
end
|
|
116
148
|
|
|
@@ -118,7 +150,7 @@ module DatadogAPIClient::V2
|
|
|
118
150
|
# @return [Integer] Hash code
|
|
119
151
|
# @!visibility private
|
|
120
152
|
def hash
|
|
121
|
-
[description, included_keywords, name, pattern, tags].hash
|
|
153
|
+
[description, included_keywords, name, pattern, priority, tags].hash
|
|
122
154
|
end
|
|
123
155
|
end
|
|
124
156
|
end
|
|
@@ -0,0 +1,80 @@
|
|
|
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
|
+
# Response for `UpdateOpenAPI`.
|
|
21
|
+
class UpdateOpenAPIResponse
|
|
22
|
+
include BaseGenericModel
|
|
23
|
+
|
|
24
|
+
# Data envelope for `UpdateOpenAPIResponse`.
|
|
25
|
+
attr_accessor :data
|
|
26
|
+
|
|
27
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
28
|
+
# @!visibility private
|
|
29
|
+
def self.attribute_map
|
|
30
|
+
{
|
|
31
|
+
:'data' => :'data'
|
|
32
|
+
}
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
# Attribute type mapping.
|
|
36
|
+
# @!visibility private
|
|
37
|
+
def self.openapi_types
|
|
38
|
+
{
|
|
39
|
+
:'data' => :'UpdateOpenAPIResponseData'
|
|
40
|
+
}
|
|
41
|
+
end
|
|
42
|
+
|
|
43
|
+
# Initializes the object
|
|
44
|
+
# @param attributes [Hash] Model attributes in the form of hash
|
|
45
|
+
# @!visibility private
|
|
46
|
+
def initialize(attributes = {})
|
|
47
|
+
if (!attributes.is_a?(Hash))
|
|
48
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::UpdateOpenAPIResponse` initialize method"
|
|
49
|
+
end
|
|
50
|
+
|
|
51
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
52
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
53
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
54
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::UpdateOpenAPIResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
|
55
|
+
end
|
|
56
|
+
h[k.to_sym] = v
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
if attributes.key?(:'data')
|
|
60
|
+
self.data = attributes[:'data']
|
|
61
|
+
end
|
|
62
|
+
end
|
|
63
|
+
|
|
64
|
+
# Checks equality by comparing each attribute.
|
|
65
|
+
# @param o [Object] Object to be compared
|
|
66
|
+
# @!visibility private
|
|
67
|
+
def ==(o)
|
|
68
|
+
return true if self.equal?(o)
|
|
69
|
+
self.class == o.class &&
|
|
70
|
+
data == o.data
|
|
71
|
+
end
|
|
72
|
+
|
|
73
|
+
# Calculates hash code according to all attributes.
|
|
74
|
+
# @return [Integer] Hash code
|
|
75
|
+
# @!visibility private
|
|
76
|
+
def hash
|
|
77
|
+
[data].hash
|
|
78
|
+
end
|
|
79
|
+
end
|
|
80
|
+
end
|
|
@@ -0,0 +1,82 @@
|
|
|
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 `UpdateOpenAPI`.
|
|
21
|
+
class UpdateOpenAPIResponseAttributes
|
|
22
|
+
include BaseGenericModel
|
|
23
|
+
|
|
24
|
+
# List of endpoints which couldn't be parsed.
|
|
25
|
+
attr_accessor :failed_endpoints
|
|
26
|
+
|
|
27
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
28
|
+
# @!visibility private
|
|
29
|
+
def self.attribute_map
|
|
30
|
+
{
|
|
31
|
+
:'failed_endpoints' => :'failed_endpoints'
|
|
32
|
+
}
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
# Attribute type mapping.
|
|
36
|
+
# @!visibility private
|
|
37
|
+
def self.openapi_types
|
|
38
|
+
{
|
|
39
|
+
:'failed_endpoints' => :'Array<OpenAPIEndpoint>'
|
|
40
|
+
}
|
|
41
|
+
end
|
|
42
|
+
|
|
43
|
+
# Initializes the object
|
|
44
|
+
# @param attributes [Hash] Model attributes in the form of hash
|
|
45
|
+
# @!visibility private
|
|
46
|
+
def initialize(attributes = {})
|
|
47
|
+
if (!attributes.is_a?(Hash))
|
|
48
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::UpdateOpenAPIResponseAttributes` initialize method"
|
|
49
|
+
end
|
|
50
|
+
|
|
51
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
52
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
53
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
54
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::UpdateOpenAPIResponseAttributes`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
|
55
|
+
end
|
|
56
|
+
h[k.to_sym] = v
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
if attributes.key?(:'failed_endpoints')
|
|
60
|
+
if (value = attributes[:'failed_endpoints']).is_a?(Array)
|
|
61
|
+
self.failed_endpoints = value
|
|
62
|
+
end
|
|
63
|
+
end
|
|
64
|
+
end
|
|
65
|
+
|
|
66
|
+
# Checks equality by comparing each attribute.
|
|
67
|
+
# @param o [Object] Object to be compared
|
|
68
|
+
# @!visibility private
|
|
69
|
+
def ==(o)
|
|
70
|
+
return true if self.equal?(o)
|
|
71
|
+
self.class == o.class &&
|
|
72
|
+
failed_endpoints == o.failed_endpoints
|
|
73
|
+
end
|
|
74
|
+
|
|
75
|
+
# Calculates hash code according to all attributes.
|
|
76
|
+
# @return [Integer] Hash code
|
|
77
|
+
# @!visibility private
|
|
78
|
+
def hash
|
|
79
|
+
[failed_endpoints].hash
|
|
80
|
+
end
|
|
81
|
+
end
|
|
82
|
+
end
|
|
@@ -0,0 +1,90 @@
|
|
|
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 envelope for `UpdateOpenAPIResponse`.
|
|
21
|
+
class UpdateOpenAPIResponseData
|
|
22
|
+
include BaseGenericModel
|
|
23
|
+
|
|
24
|
+
# Attributes for `UpdateOpenAPI`.
|
|
25
|
+
attr_accessor :attributes
|
|
26
|
+
|
|
27
|
+
# API identifier.
|
|
28
|
+
attr_accessor :id
|
|
29
|
+
|
|
30
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
31
|
+
# @!visibility private
|
|
32
|
+
def self.attribute_map
|
|
33
|
+
{
|
|
34
|
+
:'attributes' => :'attributes',
|
|
35
|
+
:'id' => :'id'
|
|
36
|
+
}
|
|
37
|
+
end
|
|
38
|
+
|
|
39
|
+
# Attribute type mapping.
|
|
40
|
+
# @!visibility private
|
|
41
|
+
def self.openapi_types
|
|
42
|
+
{
|
|
43
|
+
:'attributes' => :'UpdateOpenAPIResponseAttributes',
|
|
44
|
+
:'id' => :'UUID'
|
|
45
|
+
}
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
# Initializes the object
|
|
49
|
+
# @param attributes [Hash] Model attributes in the form of hash
|
|
50
|
+
# @!visibility private
|
|
51
|
+
def initialize(attributes = {})
|
|
52
|
+
if (!attributes.is_a?(Hash))
|
|
53
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::UpdateOpenAPIResponseData` initialize method"
|
|
54
|
+
end
|
|
55
|
+
|
|
56
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
57
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
58
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
59
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V2::UpdateOpenAPIResponseData`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
|
60
|
+
end
|
|
61
|
+
h[k.to_sym] = v
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
if attributes.key?(:'attributes')
|
|
65
|
+
self.attributes = attributes[:'attributes']
|
|
66
|
+
end
|
|
67
|
+
|
|
68
|
+
if attributes.key?(:'id')
|
|
69
|
+
self.id = attributes[:'id']
|
|
70
|
+
end
|
|
71
|
+
end
|
|
72
|
+
|
|
73
|
+
# Checks equality by comparing each attribute.
|
|
74
|
+
# @param o [Object] Object to be compared
|
|
75
|
+
# @!visibility private
|
|
76
|
+
def ==(o)
|
|
77
|
+
return true if self.equal?(o)
|
|
78
|
+
self.class == o.class &&
|
|
79
|
+
attributes == o.attributes &&
|
|
80
|
+
id == o.id
|
|
81
|
+
end
|
|
82
|
+
|
|
83
|
+
# Calculates hash code according to all attributes.
|
|
84
|
+
# @return [Integer] Hash code
|
|
85
|
+
# @!visibility private
|
|
86
|
+
def hash
|
|
87
|
+
[attributes, id].hash
|
|
88
|
+
end
|
|
89
|
+
end
|
|
90
|
+
end
|