Sha256: 9638b48722a8020dd1e30bf313693b0d20dcf9d7aab52577de98733c8e768e9e
Contents?: true
Size: 939 Bytes
Versions: 5
Compression:
Stored size: 939 Bytes
Contents
# Update an SLO correction returns "OK" response require "datadog_api_client" DatadogAPIClient::V2.configure do |config| config.unstable_operations[:update_slo_correction] = true end api_instance = DatadogAPIClient::V1::ServiceLevelObjectiveCorrectionsAPI.new # there is a valid "correction" for "slo" CORRECTION_DATA_ID = ENV["CORRECTION_DATA_ID"] body = DatadogAPIClient::V1::SLOCorrectionUpdateRequest.new({ data: DatadogAPIClient::V1::SLOCorrectionUpdateData.new({ attributes: DatadogAPIClient::V1::SLOCorrectionUpdateRequestAttributes.new({ category: DatadogAPIClient::V1::SLOCorrectionCategory::DEPLOYMENT, description: "Example-Update_an_SLO_correction_returns_OK_response", _end: (Time.now + 1 * 3600).to_i, start: Time.now.to_i, timezone: "UTC", }), type: DatadogAPIClient::V1::SLOCorrectionType::CORRECTION, }), }) p api_instance.update_slo_correction(CORRECTION_DATA_ID, body)
Version data entries
5 entries across 5 versions & 1 rubygems