Command Creator Skill
Interactive wizard for creating new Claude Code custom slash commands. Guides you through naming, parameter design, behavior specification, and outputs a ready-to-use command markdown file.
Description
This skill walks you through creating a new Claude Code custom slash command. It handles the structure, formatting, and best practices so you get a production-quality command file that works immediately.
Instructions
When the user wants to create a new command, follow this guided workflow:
Step 1: Gather Requirements
Ask the user (or infer from context):
- What should the command do? (one-sentence description)
- What inputs does it need? (arguments, flags, file paths)
- What should it output? (files, terminal output, git actions)
- Any constraints? (language, framework, safety requirements)
Step 2: Generate the Command File
Structure the command markdown:
--- description: [One-line description for the command picker] argument: [Description of the $ARGUMENTS placeholder] --- ## Command `/command-name` ## Description [2-3 sentences explaining what the command does, when to use it] ## Behavior [Step-by-step instructions for Claude on how to execute this command] 1. **Step one** — What to do first 2. **Step two** — What to do next 3. **Step three** — How to finish ## Output Format [Description or template of expected output] ## Rules - Rule 1 - Rule 2 - Rule 3 ## Examples [Usage examples]
Step 3: Write the File
mkdir -p .claude/commands # Write to .claude/commands/{command-name}.md
Step 4: Verify
- Confirm the file was created
- Show the user how to invoke it:
/command-name [args] - Suggest testing it immediately
Rules
- Command names should use kebab-case:
my-commandnotmyCommand - Always include a
descriptionfrontmatter field for the command picker - Include
argumentfrontmatter only if the command accepts arguments - Use
$ARGUMENTSplaceholder in the body where user input should be inserted - Keep the behavior section specific and actionable — avoid vague instructions
- Include at least 2 examples showing different usage patterns
- Save to
.claude/commands/directory (create it if it does not exist) - For project-specific commands, use the project's
.claude/commands/directory - For global commands, use
~/.claude/commands/
Examples
User: Create a command that generates API route boilerplate Action: Ask for framework (Express/Fastify/etc), create command with templates for route, controller, validation, and tests
User: I want a /deploy command Action: Ask for deployment target, create command with build, test, and deploy steps
User: Make a command for database migrations Action: Create command that generates migration files with up/down functions, timestamps, and naming conventions
Reviews
No reviews yet. Be the first to review this template!
Similar Templates
Full-Stack Code Reviewer
Comprehensive code review skill that checks for security vulnerabilities, performance issues, accessibility, and best practices across frontend and backend code.
Test Suite Generator
Generates comprehensive test suites with unit tests, integration tests, and edge cases. Supports Jest, Vitest, Pytest, and Go testing.
Pro Architecture Workspace
Battle-tested skill for architectural, decision, making, framework. Includes structured workflows, validation checks, and reusable patterns for development.