﻿---
title: stack kb alerting post-alerting-rule-rule-id-alert-alert-id-snooze cli command
description: Snooze an alert Behaviour flags: --dry-run — validate all inputs and exit without performing any action 
url: https://www.elastic.co/elastic/docs-builder/docs/4097/reference/elastic-cli/cli/stack/kb/alerting/post-alerting-rule-rule-id-alert-alert-id-snooze
applies_to:
  - Elastic Cloud Serverless: Preview
  - Elastic Stack: Preview
---

# stack kb alerting post-alerting-rule-rule-id-alert-alert-id-snooze cli command
<cli-modifiers>
</cli-modifiers>

```bash
elastic stack kb alerting post-alerting-rule-rule-id-alert-alert-id-snooze \
  --rule-id <rule-id> \
  --alert-id <alert-id> \
  [options]
```

Snooze an alert
**Behaviour flags:**
`--dry-run` — validate all inputs and exit without performing any action

## Options

<definitions>
  <definition term="--rule-id string required">
    The identifier for the rule.
  </definition>
  <definition term="--alert-id string required">
    The identifier for the alert.
  </definition>
  <definition term="--validate-alerts-existence">
    Set to `true` to validate that the specified alert exists. If a `400` error is returned, the specified alert does not exist. Defaults to `true`.
  </definition>
  <definition term="--condition-operator enum">
    Logical operator applied to the conditions array. "any" expires the snooze when at least one condition is met; "all" requires every condition to be met. When conditions are provided but this field is omitted, defaults to "any".
    **Values:** any, all
  </definition>
  <definition term="--conditions string[]">
    One or more conditions that, when met, automatically expire the snooze. Supported types: `field_change`, `severity_change`, `severity_equals`.
    **Repeatable:** pass `--conditions` multiple times to supply more than one value
  </definition>
  <definition term="--expires-at string">
    The datetime at which the snooze expires, in ISO 8601 format (`YYYY-MM-DDTHH:mm:ss.sssZ`). When omitted, the snooze persists indefinitely unless manually removed or a defined condition is met.
  </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>