---
title: "ktm incidents counter"
description: "Use the ktm incidents counter command to quickly retrieve critical, warning, and closed incident counts for any operator."
sidebarTitle: "counter"
lastUpdated: "2026-09-23"
---

> **For AI agents:** the complete documentation index is at [llms.txt](/llms.txt). Append `.md` to any page URL for its markdown version.

{/* GENERATED FILE: do not edit by hand. Regenerate with: node scripts/generate.mjs */}

Get incident counts: critical, warning, closed

## Usage

```bash
ktm incidents counter [flags]
```

## Examples

```bash
# Get incident counts for an operator
ktm incidents counter --operator my-operator

# Get counts for a specific alert
ktm incidents counter --operator my-operator --alert-id 42

# Get counts for the last 7 days
ktm incidents counter --operator my-operator --created-after 2026-03-12T00:00:00Z
```

## Flags

| Flag | Type | Default | Description |
| --- | --- | --- | --- |
| `--alert-id` | string |  | Comma-separated alert definition IDs |
| `--closed-after` | string |  | Filter incidents closed after this ISO datetime |
| `--closed-before` | string |  | Filter incidents closed before this ISO datetime |
| `--created-after` | string |  | Filter incidents created after this ISO datetime |
| `--created-before` | string |  | Filter incidents created before this ISO datetime |
| `--operator` | string |  | Operator slug (required) |
| `--status` | string |  | Filter by status: OPEN, CLOSED, MANUALLY_CLOSED, CHANGED, DEACTIVATED |

## Details

Get a quick summary of incident counts grouped by severity.

Returns three numbers: critical, warning, and closed incident counts.
Accepts the same filters as 'incidents list' to scope the counts.

## Related

- [`ktm incidents`](/cli/commands/incidents)
- [`ktm incidents list`](/cli/commands/incidents/list)

<Note>
  Global flags (`--output`, `--debug`, `--host`, …) apply to every command. See the [command reference overview](/cli/commands/overview).
</Note>

## What's next?

<Columns cols={2}>
  <Card title="All commands" icon="terminal" href="/cli/commands/overview">
    Browse the full CLI reference.
  </Card>
  <Card title="Get started" icon="rocket" href="/cli/getting-started">
    Install the CLI and authenticate.
  </Card>
</Columns>
