OpsCanary
observabilitygrafanaPractitioner

Automate Your Grafana Tasks: Save Time with Grafana Assistant

5 min read Grafana BlogReviewed for accuracy
Share
PractitionerHands-on experience recommended

In today's fast-paced environment, repetitive tasks can drain your time and energy. Grafana Assistant's automation feature addresses this issue by allowing you to schedule tasks that would otherwise require manual intervention. This means you can stop asking the same questions repeatedly and instead focus on analyzing the data that matters.

An automation consists of three main parts: what to run, when to run, and who can use it. You define what to run using a prompt or a skill invoked with a slash command. The scheduling can be set for regular intervals or left as manual-only execution. Visibility settings allow you to control who can access the automation, ensuring that sensitive tasks remain private if necessary. When the automation runs, it starts a new background conversation using your Grafana user identity, and the results are saved in the automation history for future reference.

To create an automation, navigate to Grafana Assistant, go to Settings, then Automations, and select New automation. You will need to provide a name, a prompt and/or skill, a schedule, and a visibility setting. This straightforward setup can significantly enhance your team's productivity. However, be mindful of the limitations; the official docs don't call out specific anti-patterns here. Use your judgment based on your scale and requirements.

Key takeaways

  • Define what to run using a prompt or skill invoked with a slash command.
  • Schedule automations for regular intervals or leave them as manual-only.
  • Control access with visibility settings to ensure sensitive tasks remain private.
  • Access automation history to revisit previous results and share insights.
  • Use infrastructure memory to enhance your automations with relevant service details.

Why it matters

Automating repetitive tasks in Grafana can drastically reduce the time spent on manual checks, allowing teams to respond to incidents faster and allocate resources more effectively. This leads to improved observability and operational efficiency.

Code examples

plaintext
/check-cart
plaintext
Summarize the current on-call state for the incoming engineer:
- Open IRM incidents and the last status update on each
- Alert notification failures or routing problems in the last 12h
- Review xyz-dashboard for any SLO burning faster than 2x over its short and long windows
- Recommend follow-ups, ranked by risk
plaintext
1Use infrastructure memory to produce
2a digest for the payment-service group.
3
4Include:
5- A link to the infrastructure memory, if available
6- The service overview and primary runtime or namespace details
7- Upstream and downstream dependencies
8- Key metrics, labels, and log sources Assistant would use
9  during an investigation
10- Any gaps, ambiguities, or inconsistencies with the team's
11  runbooks
12- Three concrete follow-ups for the on-call engineer

When NOT to use this

The official docs don't call out specific anti-patterns here. Use your judgment based on your scale and requirements.

Want the complete reference?

Read official docs

Test what you just learned

Quiz questions written from this article

Take the quiz →
DigitalOcean Serverless InferenceSponsor

OpenAI & Anthropic-compatible inference API — no GPU provisioning needed. 55+ models, pay-per-token with no minimums. VPC + zero data retention by default.

Try Serverless Inference →

Get the daily digest

One email. 5 articles. Every morning.

No spam. Unsubscribe anytime.