kubb-expert

kubb-expert is an agent for Claude Code from kubb-labs/kubb. It costs 60 tokens per session (536 once invoked), scanned A, original, MIT.

A setup and maintenance specialist for Kubb, a tool that generates TypeScript code from an OpenAPI or Swagger API description.

In plain words
What is it for?
Adding Kubb to an application, validating an API specification, choosing generation plugins, and producing typed clients, framework code, schemas, mocks, or test handlers.
Why use it?
It removes the manual work of configuring generated types, API clients, validation schemas, and test helpers, while checking the API description first.

Agent for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the kubb plugin — 2 skills, 3 commands, 1 agent, 1 MCP server shipped together

About the project

Kubb is a modular code-generation framework that turns OpenAPI descriptions into type-safe TypeScript code, Zod schemas, and TanStack Query integrations. It is used by TypeScript developers to generate client code and related interfaces from API specifications. The catalogue contains extensions such as skills, commands, hooks, agents, and a plugin that support Kubb workflows.

kubb-labs/kubb · 1,791 stars · on GitHub · kubb.dev

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 agents/kubb-labs/kubb/kubb-expert
Clone the repo
git clone --depth 1 https://github.com/kubb-labs/kubb

Made for: Claude Code.

Or install kubb, the plugin that ships this one along with the rest of its 2 skills, 3 commands, 1 agent, 1 MCP server.

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 kubb-expert

README.md
[![agentmods](https://agentmods.dev/badge/agents/kubb-labs/kubb/kubb-expert.svg)](https://agentmods.dev/agents/kubb-labs/kubb/kubb-expert)
Your own site
<a href="https://agentmods.dev/agents/kubb-labs/kubb/kubb-expert"><img src="https://agentmods.dev/badge/agents/kubb-labs/kubb/kubb-expert.svg" alt="Measured on agentmods" height="20"></a>
Per session 60 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 536 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. 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.1 $0.00060 $0.00536
Opus 5 $0.00030 $0.00268
Sonnet 5 $0.00012 $0.00107
Haiku 4.5 $0.00006 $0.00054

Measured 6d ago against content hash 8adf6d611d76, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

kubb-expert scanned grade A with 0 findings 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 6d 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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

tools/claude/agents/kubb-expert.md · 38 lines

What it actually says

You set up Kubb in a consuming application: turning an OpenAPI/Swagger spec into TypeScript types, clients, framework hooks, Zod schemas and mocks. You are not working on the Kubb monorepo itself. You generate code for the user's project.

Drive Kubb through its CLI (kubb validate, kubb init, kubb generate) rather than reimplementing its behavior. Read the config skill for the config shape and the plugin catalog.

Approach:

  1. Find the spec (a local file or a URL) and the target output directory. Validate the spec with kubb validate <spec> before doing anything destructive.
  2. Decide which @kubb/plugin-* packages match what the user wants generated. Keep plugin-ts as the base, since the client, framework and MSW plugins need it. Add a client or framework plugin for data fetching (the framework plugins also pull in a client plugin like plugin-axios or plugin-fetch), plugin-zod for runtime validation, and plugin-faker with plugin-msw for tests (MSW needs faker). Check the plugin's docs page on kubb.dev for the full dependency list. There is no pluginOas, since the OpenAPI adapter is applied automatically.
  3. Scaffold with kubb init --input <spec> --output <dir> --plugins <list>, which writes kubb.config.ts and installs kubb plus the chosen packages. If a config already exists, edit it by hand instead. Keep each generated kind in its own output folder, and never point output at hand-written source.
  4. Run kubb generate, then typecheck the output and confirm the consumer can import it.

Guardrails:

  • Generated output is overwritten on every run. Fix the spec or the config, then regenerate. Do not hand-edit generated files.
  • Use kubb generate --verbose to diagnose missing or malformed output.
  • Report what was generated and how to use it. Do not guess at API shapes the spec does not define.
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. 6d ago First seen · 38 lines · 60 tokens per session scan A 8adf6d611d76

Subscribe to this mod's changes

kubb-expert is an agent published in the GitHub repository kubb-labs/kubb (1,791 stars, last pushed yesterday), licensed MIT. It adds 60 tokens to every session and 536 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other agents, from other repositories

merge-conflict-resolver

Use this agent when you encounter Git merge conflicts that need intelligent resolution, whether they are simple line-based conflicts, complex semantic conflicts involving behavioral changes, or structural conflicts from refactoring. This agent should be used proactively when merge operations fail due to conflicts, or…

module-federation/core · 0 tokens

workflow-debugger

Use this agent when you need to debug Output SDK workflows in local development. Invoke when workflows fail, return unexpected results, or you need to analyze execution traces to identify root causes.

growthxai/output · 40 tokens

frontend-dev

Frontend Developer (Aria Chen) - React, Next.js, TypeScript, accessibility, performance.

vibeeval/vibecosystem · 22 tokens

momentjs-exorcist

Use this agent when you need to migrate Moment.js code to date-fns (v3+) and date-fns-tz. This includes refactoring individual functions, entire files, or reviewing code for Moment.js usage that needs to be modernized. Examples of when to use this agent:\n\n \nContext: The user has written a new utility function using…

Badminton-Apps/badman · 414 tokens

code-reviewer

Multi-perspective code and plan reviewer. Use proactively before important commits or for PR reviews.

pablo-albaladejo/kaiord · 21 tokens

effect-architecture-reviewer

Reviews TypeScript system architecture to determine whether Effect (effect-ts) should be used, where it applies, and to what extent. Use when reviewing implementation plans, evaluating proposed architectures, or providing guidance to downstream implementation agents.

bengous/claude-code-plugins · 50 tokens