API - Post Notification Policies and roule group

  • What Grafana version and what operating system are you using?

9.4.7

  • What are you trying to achieve?
    Create a policie and a rule group using API
    Create a rule group inside a the /api/v1/provisioning/alert-rules with a customized interval ( defaul is 1 m)

  • How are you trying to achieve it?

Follow the documentation, using the rest APIs.

  • What happened?

Did not find on the docs the post route for Notification policies.
For the rule group after the creation of a rule I need to use the put inside the new rule group to change the interval ( is that the correct approach? seems wrong to me)

  • What did you expect to happen?

Expect to be able to create a policie using API. I’m creating a web site were I will create the alerts. I need to create everything using APIs. The rules works well, also the contact points but without a policie I cannot connect both.

Create a rule and define the interval for the rule group