Is there a way to get/update the default alert profile for sensors

Solved
gdgudmundson
Here to help

Is there a way to get/update the default alert profile for sensors

If I make the call to https://api.meraki.com/api/v1/networks/:networkId/sensor/alerts/profiles it does not return the default profile.

 

Thanks,

 

Gordon

1 Accepted Solution
gdgudmundson
Here to help

Thanks for the clarification! 

 

Actually, it does appear you can change the default sensor profile settings for a network via the get/update network alerts settings. The settings such as sensorDown, sensorBatteryPercentage etc are returned in the get and I assume you can update the same via the update.

View solution in original post

10 Replies 10
Inderdeep
Kind of a big deal
Kind of a big deal

Did you check this https://community.meraki.com/t5/Feature-Announcements/MT-New-Sensor-Status-Alert-Profile/ba-p/122394 

Regards/Inder
Cisco IT Blogs awarded in 2020 & 2021
www.thenetworkdna.com
gdgudmundson
Here to help

I am wanting to manage it via the API

alemabrahao
Kind of a big deal
Kind of a big deal

Yes, there is a way to get and update the default alert profile for sensors in the Meraki API.

 

The default alert profile is applied automatically to all sensors and only allows the user to toggle the alerts on/off and configure recipients.

 

To get the default alert profile, navigate to Sensors > Overview > Alert Profiles, select Edit on the Sensor status alerts profile.

 

To update the default alert profile, you can use the updateNetworkSensorAlertsProfile endpoint in the Meraki Dashboard API. You might want to first read the current alerts for the network using the get-network-alerts-settings endpoint, and then use the update-network-alerts-settings endpoint to update the alerts after adding the one you want.

 

Note that the default profile might not be returned when you make a call to https://api.meraki.com/api/v1/networks/:networkId/sensor/alerts/profiles as it is treated differently and applied to all sensors automatically.

 

I am not a Cisco Meraki employee. My suggestions are based on documentation of Meraki best practices and day-to-day experience.

Please, if this post was useful, leave your kudos and mark it as solved.
gdgudmundson
Here to help

OK. I see where you can use get/update network alerts settings endpoint. Just to be clear, the default alert profile is applied automatically to all sensors in the network or in the org? Also, I don't see how you could use the updateNetworkSensorAlertsProfile endpoint. It needs a profile ID and the put data doesn't line up with the settings in the default profile.

alemabrahao
Kind of a big deal
Kind of a big deal

The default alert profile is applied automatically to all sensors in the network, not the organization.

 

You're correct about the updateNetworkSensorAlertsProfile endpoint, It requires a profile ID, which the default profile does not have since it's applied automatically to all sensors. I apologize for the confusion.

 

The updateNetworkSensorAlertsProfile endpoint is used to update custom alert profiles, not the default profile.

 

For the default profile, you can only toggle the alerts on/off and configure recipients. These settings can be accessed and modified via the Meraki Dashboard, under Sensors > Overview > Alert Profiles, by selecting Edit on the Sensor status alerts profile. Unfortunately, these settings cannot be accessed or modified via the API.

 

I am not a Cisco Meraki employee. My suggestions are based on documentation of Meraki best practices and day-to-day experience.

Please, if this post was useful, leave your kudos and mark it as solved.
gdgudmundson
Here to help

Thanks for the clarification! 

 

Actually, it does appear you can change the default sensor profile settings for a network via the get/update network alerts settings. The settings such as sensorDown, sensorBatteryPercentage etc are returned in the get and I assume you can update the same via the update.

Ryan_Miles
Meraki Employee
Meraki Employee

I'd never looked it up, but yeah it's weird the default sensor alert profile lives under Sensors in dashboard. But for the API it lives under network wide alerts. Odd.

Ryan

If you found this post helpful, please give it Kudos. If my answer solves your problem please click Accept as Solution so others can benefit from it.
gdgudmundson
Here to help

One final comment on this thread is it appears that you cannot enable/disable any of the alerts including the default sensor alerts if the network is bound to a template.

BDillon
Here to help

Does this include trying to update the profiles using API and Postaman etc?

Ryan_Miles
Meraki Employee
Meraki Employee

Maybe this has changed over time, not sure. Anyhow you can edit Sensor profiles including the Default profile for template bound networks.

 

Sensor Alerts have always existed at the network level for template bound networks. The config doesn't live under the template.

Ryan

If you found this post helpful, please give it Kudos. If my answer solves your problem please click Accept as Solution so others can benefit from it.
Get notified when there are additional replies to this discussion.