create-command

A guided command for creating a slash command, which is a reusable instruction started with a slash in Claude Code plugins.

In plain words
What is it for?
Use it to design commands for tasks such as creating features, scaffolding components, or running Git workflows.
Why use it?
It helps define the command's purpose, arguments, tool limits, context, and place in a larger workflow.

Command

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/crathgeb/claude-code-plugins/create-command
Clone the repo
git clone --depth 1 https://github.com/crathgeb/claude-code-plugins
Per session 10 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,327 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 $0.00010 $0.03327
Opus 5 $0.00005 $0.01664
Sonnet 5 $0.00002 $0.00665
Haiku 4.5 $0.00001 $0.00333

Measured yesterday against content hash 09b95af93b50, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

create-command 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 yesterday.

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.

plugins/plugin-builder/commands/create-command.md · 715 lines

How it starts

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

Slash Command Builder

You are an expert in building Claude Code slash commands. Guide users through creating well-structured, constrained commands that follow best practices.

User request: $ARGUMENTS


Phase 1: Command Requirements

Step 1.1: Gather Information

If not provided, ask:

Essential:

  • Command name? (use dash-case: create-feature, run-tests)
  • What does this command do? (one-sentence purpose)
  • What arguments does it accept?

Optional:

  • Should this command be constrained to specific tools? (e.g., only git commands)
  • Does this command need inline context? (e.g., !git status output)
  • Is this command part of a larger workflow?

Step 1.2: Analyze Similar Commands

Search for similar commands to learn patterns. Consider:

Workflow Commands (multi-phase processes):

  • feature-dev - 7-phase feature development
  • create-component - Component scaffolding
  • Pattern: Discovery ->†-> Planning ->†-> Approval ->†-> Implementation ->†-> Documentation

Git Commands (version control):

  • commit - Create commits with smart messages
  • commit-push-pr - Full workflow from commit to PR
  • clean_gone - Clean up deleted branches
  • Pattern: Git operations with strict tool constraints

Interactive Commands (user guidance):

  • new-sdk-app - Interactive app creation wizard
  • Pattern: Ask questions ->†-> Validate ->†-> Execute

Analysis Commands (code review):

  • Component verification, pattern checking
  • Pattern: Analyze -> Report findings -> Optional fixes

Describe 1-2 relevant examples.


Phase 2: Command Design

Step 2.1: Choose Command Pattern

Based on requirements, select a pattern:

Pattern A: Simple Command

  • Single-phase execution
  • Minimal user interaction
  • Example: Clean up branches, format code

Pattern B: Workflow Command

  • Multiple phases (Discovery -> Planning -> Execution)
  • User approval gates
  • Todo list tracking
  • Example: Feature development, component creation

Pattern C: Interactive Command

Read the full file on GitHub · 715 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. yesterday First seen · 715 lines · 10 tokens per session scan A 09b95af93b50

Subscribe to this mod's changes

create-command is a command published in the GitHub repository crathgeb/claude-code-plugins (2 stars, last pushed 10mo ago), licensed MIT. It adds 10 tokens to every session and 3,327 once invoked, about $0.0001 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-31.