10 Replies Latest reply on Sep 7, 2017 1:28 PM by tmarndt1

    Clearing Alerts in Orion.AlertActive


      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?