# Generate custom report and automate sending using watcher

**URL:** <https://discuss.elastic.co/t/generate-custom-report-and-automate-sending-using-watcher/246973>\
**Category:** Kibana\
**Tags:** elastic-stack-alerting\
**Created:** [August 31, 2020, 2:50pm UTC](https://discuss.elastic.co/t/generate-custom-report-and-automate-sending-using-watcher/246973 "2020-08-31T14:50:16Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![vivekkarne](https://avatars.discourse-cdn.com/v4/letter/v/f08c70/32.png) [@vivekkarne](https://discuss.elastic.co/u/vivekkarne)\
**Post date:** [August 31, 2020, 2:50pm UTC](https://discuss.elastic.co/t/generate-custom-report-and-automate-sending-using-watcher/246973/1 "2020-08-31T14:50:17Z")

</div>

I have a saved search which when exported as csv from the discover page works fine, i then copy the url and create a watcher following to process here: [Automatically generate reports | Kibana Guide [master] | Elastic](https://www.elastic.co/guide/en/kibana/master/automating-report-generation.html)

But the watcher fails and we get an error:

> Watch[7849323b-dd39-45ef-813a-0468d92d8d5a] reporting[error\_report.csv] Error when polling pdf from host[[kibana-tsb.servicenow.net](http://kibana-tsb.servicenow.net)], port[443], method[POST], path[/api/reporting/generate/csv], status[500], body[{"message":"Reporting generation failed","reason":"Error: Expected \_scroll\_id in the following Elasticsearch response: {\"took\":1,\"timed\_out\":false,\"\_shards\":{\"total\":0,\"successful\":0,\"skipped\":0,\"failed\":0},\"\_clusters\":{\"total\":1,\"successful\":1,\"skipped\":0},\"hits\":{\"total\":{\"value\":0,\"relation\":\"eq\"},\"max\_score\":0,\"hits\":}}"}]"

Can anyone please help.

Regards,  
vivek.

---

<div class="post-metadata">

**Author:** ![markov00](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/markov00/32/33316_2.png) [@markov00](https://discuss.elastic.co/u/markov00)\
**Post date:** [August 31, 2020, 5:23pm UTC](https://discuss.elastic.co/t/generate-custom-report-and-automate-sending-using-watcher/246973/2 "2020-08-31T17:23:05Z")

</div>

Hi, seems that with the POST URL used, no document is found, please check the time range used by the POST URL to be sure that it reflects a valid interval with data.

cc @joelgriffith

---

<div class="post-metadata">

**Author:** ![vivekkarne](https://avatars.discourse-cdn.com/v4/letter/v/f08c70/32.png) [@vivekkarne](https://discuss.elastic.co/u/vivekkarne)\
**Post date:** [August 31, 2020, 5:44pm UTC](https://discuss.elastic.co/t/generate-custom-report-and-automate-sending-using-watcher/246973/3 "2020-08-31T17:44:19Z")

</div>

In the discover page with the same post url i am able to see hits markov, however now when i tried with a different user it just says:

> "reason": "Watch[37356167-fcab-433b-ae9f-8daf3c02442f] reporting[error\_report.csv] Error response when trying to trigger reporting generation host[[kibana-tsb.servicenow.net](http://kibana-tsb.servicenow.net)], port[443] method[POST], path[/api/reporting/generate/csv], status[500]"

Regards,  
Vivek.

---

<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:** [September 28, 2020, 5:44pm UTC](https://discuss.elastic.co/t/generate-custom-report-and-automate-sending-using-watcher/246973/4 "2020-09-28T17:44:22Z")

</div>

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