﻿---
title: stack kb alerting-v2 get-alerting-v2-execution-history-rules cli command
description: List rule executions Behaviour flags: --dry-run — validate all inputs and exit without performing any action 
url: https://www.elastic.co/elastic/docs-builder/docs/4075/reference/elastic-cli/cli/stack/kb/alerting-v2/get-alerting-v2-execution-history-rules
applies_to:
  - Elastic Cloud Serverless: Preview
  - Elastic Stack: Preview
---

# stack kb alerting-v2 get-alerting-v2-execution-history-rules cli command
<cli-modifiers>
</cli-modifiers>

```bash
elastic stack kb alerting-v2 get-alerting-v2-execution-history-rules \
  --sort <sort> \
  --sort-order <sort-order> \
  --page <page> \
  --per-page <per-page> \
  [options]
```

List rule executions
**Behaviour flags:**
`--dry-run` — validate all inputs and exit without performing any action

## Options

<definitions>
  <definition term="--sort enum required">
    Sort field. Defaults to started_at.
    **Values:** started_at, duration
  </definition>
  <definition term="--sort-order enum required">
    Sort direction.
    **Values:** asc, desc
  </definition>
  <definition term="--page number required">
    Page number.
  </definition>
  <definition term="--per-page number required">
    Number of results per page.
  </definition>
  <definition term="--rule-ids string[]">
    Rule id filter.
    **Repeatable:** pass `--rule-ids` multiple times to supply more than one value
  </definition>
  <definition term="--outcome string[]">
    Outcome filter.
    **Repeatable:** pass `--outcome` multiple times to supply more than one value
  </definition>
  <definition term="--from string">
    Inclusive ISO datetime lower bound on event.start.
  </definition>
  <definition term="--to string">
    Inclusive ISO datetime upper bound on event.start.
  </definition>
  <definition term="--input-file string">
    path to a JSON file to use as command input
  </definition>
  <definition term="--dry-run">
    validate all inputs and exit without performing any action (preview changes without applying them)
  </definition>
</definitions>


## Global Options

<definitions>
  <definition term="--json">
    output as JSON
  </definition>
</definitions>