new-plugin

new-plugin is a command for coding agents from ch-bas/kibana-plugin-helper. It costs 29 tokens per session (2,149 once invoked), scanned C, original, MIT.

A command guide for creating a new Kibana plugin with its required folders, configuration files, and TypeScript setup. Kibana is Elastic's web interface for searching, analyzing, and monitoring data.

In plain words
What is it for?
Use it to scaffold a server-side, browser-side, or combined Kibana plugin inside the Kibana repository.
Why use it?
It avoids missing the files and directory location that Kibana's build tools require.

Command

Part of the kibana-plugin-helper plugin — 1 skill, 8 commands, 5 agents shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/ch-bas/kibana-plugin-helper/new-plugin
Clone the repo
git clone --depth 1 https://github.com/ch-bas/kibana-plugin-helper

Or install kibana-plugin-helper, the plugin that ships this one along with the rest of its 1 skill, 8 commands, 5 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for new-plugin

README.md
[![agentmods](https://agentmods.dev/badge/commands/ch-bas/kibana-plugin-helper/new-plugin.svg)](https://agentmods.dev/commands/ch-bas/kibana-plugin-helper/new-plugin)
Your own site
<a href="https://agentmods.dev/commands/ch-bas/kibana-plugin-helper/new-plugin"><img src="https://agentmods.dev/badge/commands/ch-bas/kibana-plugin-helper/new-plugin.svg" alt="Measured on agentmods" height="20"></a>
Per session 29 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,149 The whole file, excluding the scripts and references it only reads on demand.
Security scan C 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00029 $0.02149
Opus 5 $0.00015 $0.01074
Sonnet 5 $0.00006 $0.00430
Haiku 4.5 $0.00003 $0.00215

Measured 4d ago against content hash 23883ab70007, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade C, and why

new-plugin scanned grade C with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Recursive force deletehighDestructive command

rm -rf with a variable or a broad path is one typo away from removing the wrong tree.

rm -rf plugins/my_plugin
commands/new-plugin.md · 343 lines

How it starts

The opening of the file, as written. The whole thing — 343 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Create New Kibana Plugin

CRITICAL: Plugin Location

Kibana plugins MUST be created inside the Kibana repository in the plugins/ directory. They cannot be developed outside the Kibana repo — the build tools require access to Kibana's scripts.

kibana/                    <- Kibana repository root
├── plugins/               <- YOUR PLUGINS GO HERE
│   └── my_plugin/         <- Your plugin
├── scripts/               <- Build scripts (plugin-helpers)
├── src/
└── package.json

For the most reliable setup, use Kibana's official generator:

cd /path/to/kibana
node scripts/generate_plugin my_plugin_name

This creates a properly configured plugin with all necessary files.

Manual Creation (if generator unavailable)

Ask the user for:

  1. Plugin ID (snake_case, e.g., my_awesome_plugin)
  2. Display name (human-readable, e.g., "My Awesome Plugin")
  3. Description (one sentence)
  4. Plugin type: Server-side, Browser-side, or Both
  5. Include app in navigation? (yes/no)

Generated Structure

kibana/plugins/{plugin_id}/
├── kibana.jsonc              # Plugin manifest (Kibana 8.x uses .jsonc)
├── package.json              # NPM package (REQUIRED - specific format)
├── tsconfig.json             # TypeScript config
├── common/
│   └── index.ts
├── public/                   # Browser-side (if selected)
│   ├── index.ts
│   ├── plugin.ts
│   └── types.ts
└── server/                   # Server-side (if selected)
    ├── index.ts
    ├── plugin.ts
    ├── types.ts
    └── routes/
        └── index.ts

package.json Template (REQUIRED - EXACT FORMAT)

For Kibana 8.x+ — use this minimal format:

{
  "name": "{plugin_id}",
  "version": "1.0.0",
  "private": true
}

That's it! Modern Kibana 8.x plugins:

  • Use kibana.jsonc for all plugin metadata
  • Don't need scripts in package.json — run everything from Kibana root
  • Should NOT have "main", "kibana", or build scripts

Read the full file on GitHub · 343 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 343 lines · 29 tokens per session scan C 23883ab70007

Subscribe to this mod's changes

new-plugin is a command published in the GitHub repository ch-bas/kibana-plugin-helper (3 stars, last pushed 6mo ago), licensed MIT. It adds 29 tokens to every session and 2,149 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it C with 1 finding (recursive force delete). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.