Skip to main content
skill CX Codex

cli-policy-audit — Claude Code skill: audit logs and policies

Reads audit logs, access policies and telemetry from the Anthropic CLI. Useful when you need to filter events by type, user or time range.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add cheaper-inference/OmniRoute --skill cli-policy-audit -a claude-code
Open on GitHub

What cli-policy-audit does

The skill teaches your agent to drive the omniroute CLI. Through it you can read audit logs, search entries by query, export them to a file and pull stats for a period. A separate branch of commands covers access policies: list, create from a file, update, delete, import and export, plus policy evaluate to check a rule against an API key, action and resource.

Telemetry has its own set: a summary for a period with an optional comparison period, and an export to a chosen path. Request history comes from logs, which takes filters for level, status code, duration range, request id and more.

The tool has to be on your machine first — npm install -g omniroute, or run it as npx omniroute. omniroute --version confirms it. Several commands accept --base-url and --api-key, so they fail without a reachable instance.

What it helps with

  • read the audit log and filter events by source
  • find one user's entries within a time window
  • export audit records to a file in a given format
  • create or update an access policy from a file
  • check whether an action on a resource is allowed

Example prompts for the agent

  • Show the latest audit entries with omniroute audit tail
  • Search the audit log for yesterday's events and export them to a file
  • List the access policies and evaluate one of them

How to install cli-policy-audit

1Skills CLI (Vercel)

npx skills add cheaper-inference/OmniRoute --skill cli-policy-audit -a claude-code

2Manually: put the files in place

~/.claude/skills/cli-policy-audit/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/cli-policy-audit/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about cli-policy-audit

How do I install cli-policy-audit in Claude Code?

Run npx skills add cheaper-inference/OmniRoute --skill cli-policy-audit -a claude-code. The skill file lands at ~/.claude/skills/cli-policy-audit/SKILL.md.

What does cli-policy-audit do?

It gives the agent a set of omniroute commands for inspecting audit logs, managing access policies, reading telemetry and reviewing request history. Filters cover event type, user and time range.

What do I need before using the skill?

The omniroute CLI installed — globally with npm install -g omniroute or run via npx omniroute. Some commands also need --base-url and --api-key.

Source text

SKILL.md · MIT
---
name: cli-policy-audit
description: Inspect audit logs, manage access policies, view telemetry data, and review request history from the CLI. Filter by event type, user, or time range for compliance workflows.
---
<!-- generated by src/lib/agentSkills/generator.ts; manual edits will be overwritten -->

## Overview

Inspect audit logs, manage access policies, view telemetry data, and review request history from the CLI. Filter by event type, user, or time range for compliance workflows.

## Quick install

```bash
npm install -g omniroute   # or: npx omniroute
omniroute --version
```

## Subcommands

### `audit`

**Example:**

```bash
omniroute audit
```

### `audit tail`

**Flags:**

- `--source <s>`
- `--follow`
- `--limit <n>`

**Example:**

```bash
omniroute audit tail
```

### `audit search <query>`

**Flags:**

- `--source <s>`
- `--since <ts>`
- `--until <ts>`
- `--limit <n>`
- `--actor <id>`
- `--action <a>`

**Example:**

```bash
omniroute audit search <query>
```

### `audit export <file>`

**Flags:**

- `--source <s>`
- `--format <f>`
- `--since <ts>`
- `--until <ts>`

**Example:**

```bash
omniroute audit export <file>
```

### `audit stats`

**Flags:**

- `--source <s>`
- `--period <p>`

**Example:**

```bash
omniroute audit stats
```

### `audit get <id>`

**Flags:**

- `--source <s>`

**Example:**

```bash
omniroute audit get <id>
```

### `logs`

**Flags:**

- `--follow`
- `--filter <level>`
- `--lines <n>`
- `--timeout <ms>`
- `--base-url <url>`
- `--request-id <id>`
- `--api-key <key>`
- `--combo <name>`
- `--status <code>`
- `--duration-min <ms>`
- `--duration-max <ms>`
- `--export <path>`

**Example:**

```bash
omniroute logs
```

### `policy`

**Example:**

```bash
omniroute policy
```

### `policy list`

**Flags:**

- `--kind <k>`
- `--scope <s>`

**Example:**

```bash
omniroute policy list
```

### `policy get <id>`

**Example:**

```bash
omniroute policy get <id>
```

### `policy create`

**Flags:**

- `--file <path>`

**Example:**

```bash
omniroute policy create
```

### `policy update <id>`

**Flags:**

- `--file <path>`

**Example:**

```bash
omniroute policy update <id>
```

### `policy delete <id>`

**Flags:**

- `--yes`

**Example:**

```bash
omniroute policy delete <id>
```

### `policy evaluate`

**Flags:**

- `--api-key <k>`
- `--action <a>`
- `--resource <r>`
- `--context <json>`

**Example:**

```bash
omniroute policy evaluate
```

### `policy export <file>`

**Example:**

```bash
omniroute policy export <file>
```

### `policy import <file>`

**Flags:**

- `--overwrite`

**Example:**

```bash
omniroute policy import <file>
```

### `telemetry`

**Example:**

```bash
omniroute telemetry
```

### `telemetry summary`

**Flags:**

- `--period <p>`
- `--compare-to <p>`

**Example:**

```bash
omniroute telemetry summary
```

### `telemetry export`

**Flags:**

- `--out <path>`
- `--period <p>`

**Example:**

```bash
omniroute telemetry export
```

© cheaper-inference · MIT · cheaper-inference/OmniRoute

Similar skills

All skills for Agent setup: memory, context, orchestration →

From the same set45

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor