Quantcast
Channel: THWACK: All Content - Orion SDK
Viewing all articles
Browse latest Browse all 2677

Clearing Alerts in Orion.AlertActive

$
0
0

Hey guys,

 

I'm trying to clear alerts in SWQL. My code is as follows:

 

public static bool Clear(IEnumerable<Alert> alerts)

        {

            var ids = alerts.Select(alert => alert.AlertObjectID).ToList();

 

 

            var body = JsonConvert.SerializeObject(ids);

 

 

            var postAlert = _Post(body, "Invoke/Orion.AlertActive/ClearAlert");

 

 

            if (false == postAlert.HasData) return false;

 

 

            return Convert.ToBoolean(postAlert.Data);

        }

 

I have a similar method to acknowledge alerts and it works fine with Invoke/Orion.AlertStatus/Acknowledge.

 

Why is clearing the alerts not working (getting 400 error)? I'm sending in an array of AlertObjectIDs?


Viewing all articles
Browse latest Browse all 2677

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>