# Action over webhook status

**URL:** <https://discuss.elastic.co/t/action-over-webhook-status/338055>\
**Category:** Kibana\
**Tags:** elastic-stack-monitoring, elastic-stack-alerting\
**Created:** [July 11, 2023, 5:36am UTC](https://discuss.elastic.co/t/action-over-webhook-status/338055 "2023-07-11T05:36:42Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ddoroshenko](https://avatars.discourse-cdn.com/v4/letter/d/b9e5f3/32.png) [@ddoroshenko](https://discuss.elastic.co/u/ddoroshenko)\
**Post date:** [July 11, 2023, 5:36am UTC](https://discuss.elastic.co/t/action-over-webhook-status/338055/1 "2023-07-11T05:36:43Z")

</div>

Hi,

I have a watcher with webhook action in it. Is it possible to make another action based on webhook response status? Something like that

```auto
actions: {
  webhook_action: {
    webhook: {
      scheme:
      host:
      port:
      ...
    }
  },
  action_on_webhook_response_status: {
    condition: {
      compare: {
        webhook_action.response.status: {
          gte: 400
        }
      }
    },
    email: {
      from:
      to:
      subject:
      body: {
        webhook_action failed
      }
    }
  }
}

```

---

<div class="post-metadata">

**Author:** ![tsullivan](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tsullivan/32/31077_2.png) [@tsullivan](https://discuss.elastic.co/u/tsullivan)\
**Post date:** [July 13, 2023, 12:02am UTC](https://discuss.elastic.co/t/action-over-webhook-status/338055/2 "2023-07-13T00:02:56Z")

</div>

I don't think it's possible to collect the response from the webhook that is called in the watch action. You might try asking in the Elasticsearch area of this forum: [https://discuss.elastic.co/c/elastic-stack/elasticsearch/6](https://discuss.elastic.co/c/elastic-stack/elasticsearch/6)

---

<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:** [August 10, 2023, 12:02am UTC](https://discuss.elastic.co/t/action-over-webhook-status/338055/3 "2023-08-10T00:02:58Z")

</div>

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