From 19ba8d148936758fa486724c7fd56905ba30f322 Mon Sep 17 00:00:00 2001 From: dwalasek <138129050+dwalasek@users.noreply.github.com> Date: Wed, 10 Jul 2024 14:17:00 +0200 Subject: [PATCH] detector: extend detector create model with detectorOrigin and parentDetectorId fields (#219) --- detector/model_create_detector_request.go | 4 ++++ detector/model_validate_detector_request_model.go | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/detector/model_create_detector_request.go b/detector/model_create_detector_request.go index 80dce65..ad56ba0 100644 --- a/detector/model_create_detector_request.go +++ b/detector/model_create_detector_request.go @@ -35,4 +35,8 @@ type CreateUpdateDetectorRequest struct { Teams []string `json:"teams"` // Options that control the appearance of a detector in the SignalFx web UI. VisualizationOptions *Visualization `json:"visualizationOptions,omitempty"` + // ID of the parent detector from which this detector is customized and created. This property is required for detectors with detectorOrigin of type AutoDetectCustomization. + ParentDetectorId string `json:"parentDetectorId,omitempty"` + // Indicates how a detector was created. The possible values are: Standard, AutoDetect, AutoDetectCustomization.You can only use Standard or AutoDetectCustomization to create custom detectors. + DetectorOrigin string `json:"detectorOrigin,omitempty"` } diff --git a/detector/model_validate_detector_request_model.go b/detector/model_validate_detector_request_model.go index 9a4644c..daf6fdd 100644 --- a/detector/model_validate_detector_request_model.go +++ b/detector/model_validate_detector_request_model.go @@ -34,4 +34,8 @@ type ValidateDetectorRequestModel struct { Teams []string `json:"teams,omitempty"` // Options that control the appearance of a detector in the SignalFx web UI. Each element in the array is a 'Visualization'. VisualizationOptions []Visualization `json:"visualizationOptions,omitempty"` + // ID of the parent detector from which this detector is customized and created. This property is required for detectors with detectorOrigin of type AutoDetectCustomization. + ParentDetectorId string `json:"parentDetectorId,omitempty"` + // Indicates how a detector was created. The possible values are: Standard, AutoDetect, AutoDetectCustomization.You can only use Standard or AutoDetectCustomization to create custom detectors. + DetectorOrigin string `json:"detectorOrigin,omitempty"` }