Getting Alias name of the query that trigered the alarm?

So i have these two queries, with data coming from an influx database.


And I also have two alerts for both of them:

I want to send the alias name of the query that triggered the alert.

I am running v7.5.4

have you reviewed the templating documentation for legacy alerting?