# Kibana watcher ctx.payload.hits.hits is empty even though hits.total is a big number

**URL:** <https://discuss.elastic.co/t/kibana-watcher-ctx-payload-hits-hits-is-empty-even-though-hits-total-is-a-big-number/124654>\
**Category:** Elasticsearch\
**Tags:** elastic-stack-alerting\
**Created:** [March 19, 2018, 10:21pm UTC](https://discuss.elastic.co/t/kibana-watcher-ctx-payload-hits-hits-is-empty-even-though-hits-total-is-a-big-number/124654 "2018-03-19T22:21:34Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Preetiv](https://avatars.discourse-cdn.com/v4/letter/p/a698b9/32.png) [@Preetiv](https://discuss.elastic.co/u/Preetiv)\
**Post date:** [March 19, 2018, 10:21pm UTC](https://discuss.elastic.co/t/kibana-watcher-ctx-payload-hits-hits-is-empty-even-though-hits-total-is-a-big-number/124654/1 "2018-03-19T22:21:34Z")

</div>

A part of my watch is below. Why is hits.hits (array) empty when the hits.total is a big number?

```auto
      "type": "search",
      "status": "success",
      "payload": {
        "_shards": {
          "total": 1010,
          "failed": 0,
          "successful": 1010,
          "skipped": 1000
        },
        "hits": {
          "hits": [],
          "total": 1128278,
          "max_score": 0

```

I need to access the source field of the hits.hits.0 and it is coming out to be empty, for sure because hits.hits is itself empty. Why so?

---

<div class="post-metadata">

**Author:** ![Preetiv](https://avatars.discourse-cdn.com/v4/letter/p/a698b9/32.png) [@Preetiv](https://discuss.elastic.co/u/Preetiv)\
**Post date:** [March 19, 2018, 10:54pm UTC](https://discuss.elastic.co/t/kibana-watcher-ctx-payload-hits-hits-is-empty-even-though-hits-total-is-a-big-number/124654/2 "2018-03-19T22:54:41Z")

</div>

I found I had incorrectly set the 'size' of the 'body' to 0. Changed it to a number and it worked.  
Thanks!

---

<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:** [April 16, 2018, 10:54pm UTC](https://discuss.elastic.co/t/kibana-watcher-ctx-payload-hits-hits-is-empty-even-though-hits-total-is-a-big-number/124654/3 "2018-04-16T22:54:51Z")

</div>

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