# Send json data with escape character

**URL:** <https://discuss.elastic.co/t/send-json-data-with-escape-character/317041>\
**Category:** Elasticsearch\
**Created:** [October 19, 2022, 5:50pm UTC](https://discuss.elastic.co/t/send-json-data-with-escape-character/317041 "2022-10-19T17:50:50Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Pratik1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/pratik1/32/110450_2.png) [@Pratik1](https://discuss.elastic.co/u/Pratik1)\
**Post date:** [October 19, 2022, 5:50pm UTC](https://discuss.elastic.co/t/send-json-data-with-escape-character/317041/1 "2022-10-19T17:50:51Z")

</div>

I am using Kapacitor to send alerts via post method to elasticsearch. However, I was unable to do, so to debug further I was using a local django application to read the post response. By using alert template I am able to get the data in desired format:  
`{"\"id\": \"4g-alert\",\"time\": \"2022-10-19 13:30:01 +0000 UTC\",\"tag1\": \"0005B951C718_10213\",\"KPI_Name\": \"KPI_name,\"KPI_value\": \"0\",\"Level\": CRITICAL,\"previousLevel\": CRITICAL\""}`

However the kapacitor alert is adding '' as escape character, when I tried to send the same json using curl command it worked. Any way to remove the slash() or any other solution for this.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [November 16, 2022, 5:51pm UTC](https://discuss.elastic.co/t/send-json-data-with-escape-character/317041/2 "2022-11-16T17:51:00Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
