Enable rule API

edit

Refer to alerting API.