# Kibana Alerts to index is giving me a JSON with key/value instead of just the value

**URL:** <https://discuss.elastic.co/t/kibana-alerts-to-index-is-giving-me-a-json-with-key-value-instead-of-just-the-value/374385>\
**Category:** Kibana\
**Created:** [February 11, 2025, 8:49pm UTC](https://discuss.elastic.co/t/kibana-alerts-to-index-is-giving-me-a-json-with-key-value-instead-of-just-the-value/374385 "2025-02-11T20:49:16Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ElasticLiver](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/elasticliver/32/64869_2.png) [@ElasticLiver](https://discuss.elastic.co/u/ElasticLiver)\
**Post date:** [February 11, 2025, 8:49pm UTC](https://discuss.elastic.co/t/kibana-alerts-to-index-is-giving-me-a-json-with-key-value-instead-of-just-the-value/374385/1 "2025-02-11T20:49:16Z")

</div>

Kibana version 8.17.0

Hi, I set up an index to store the alerts, Im using metric threshold and when I use the variable {{context.metric}} y get a JSON instead of just the value of the metric:

`{"condition0":"gcp.compute.instance.cpu.usage.pct"}`

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/c/f/cf83309a6417765f486c968b9118c285e738f8be.png)

Is this the normal behavior? or I am doing something wrong?

this is my document:

{  
"dataset": "gcp.compute",  
"fuente": "{{context.group}}",  
"razon": "{{context.reason}}",  
"metrica": "{{context.metric}}",  
"estado": "{{context.alertState}}",  
"@timestamp": "{{context.timestamp}}",  
"ctx\_cloud": "{{context.cloud}}",  
"ctx\_host": "{{context.host}}"  
}
