skills/c0ntr0lledcha0s/building-commands/SKILL.md
Expert at creating and modifying Claude Code slash commands. Auto-invokes when the user wants to create, update, modify, enhance, validate, or standardize slash commands, or when modifying command YAML frontmatter fields (especially 'model', 'allowed-tools', 'description'), needs help designing command workflows, or wants to understand command arguments and parameters. Also auto-invokes proactively when Claude is about to write command files (*/commands/*.md), or implement tasks that involve creating slash command components.
npx skillsauth add aiskillstore/marketplace building-commandsInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
You are an expert at creating Claude Code slash commands. Slash commands are user-triggered workflows that provide parameterized, action-oriented functionality.
Use a COMMAND when:
Use a SKILL instead when:
Use an AGENT instead when:
.claude/commands/command-name.md~/.claude/commands/command-name.mdplugin-dir/commands/command-name.md.claude/commands/git/commit.md → /project:git:commitSingle Markdown file with YAML frontmatter and Markdown body.
---
description: Brief description of what the command does
---
---
description: Brief description of what the command does
allowed-tools: Read, Grep, Glob, Bash
argument-hint: [parameter-description]
---
---
description: Brief description of command functionality # Required
allowed-tools: Read, Write, Edit, Grep, Glob, Bash # Optional: Pre-approved tools
argument-hint: [filename] [options] # Optional: Parameter guide for users
model: claude-3-5-haiku-20241022 # Optional: Specific model (see warning below)
disable-model-invocation: false # Optional: Prevent auto-invocation
---
Commands support VERSION ALIASES or FULL IDs (but NOT short aliases):
---
description: Fast operation
model: claude-haiku-4-5 # ✅ Recommended - version alias (auto-updates)
---
---
description: Stable operation
model: claude-haiku-4-5-20251001 # ✅ Also valid - full ID (locked version)
---
DO NOT use SHORT ALIASES in commands (they cause API 404 errors):
model: haiku # ❌ WRONG - causes "model not found" error
model: sonnet # ❌ WRONG - causes "model not found" error
model: opus # ❌ WRONG - causes "model not found" error
Best Practice: Omit model field to inherit from conversation:
---
description: Inherits conversation model automatically
# No model field - will use whatever model the conversation uses
---
Model Format Options:
Short Aliases (❌ DON'T WORK in commands):
haiku, sonnet, opus - Only work in agentsVersion Aliases (✅ RECOMMENDED for commands):
claude-haiku-4-5 - Auto-updates to latest snapshotclaude-sonnet-4-5 - Auto-updates to latest snapshotclaude-opus-4-1 - Auto-updates to latest snapshotFull IDs with Dates (✅ STABLE for commands):
claude-haiku-4-5-20251001 - Locked to specific snapshotclaude-sonnet-4-5-20250929 - Locked to specific snapshotclaude-opus-4-1-20250805 - Locked to specific snapshotWhy the Difference?
haiku → claude-haiku-4-5-20251001)claude-* format)When to Specify Model:
Recommendation:
claude-haiku-4-5 (version alias)Finding Current Model IDs: Check Anthropic's model documentation for current versions.
The disable-model-invocation field prevents Claude from autonomously triggering the command via the SlashCommand tool.
---
description: Delete all test data from database
disable-model-invocation: true # ✅ Prevents accidental invocation by Claude
allowed-tools: Bash
---
When to Use:
Effect: Command still appears in /help and can be manually invoked by users, but Claude won't suggest or execute it automatically.
review-pr, run-tests, deploy-app)git/commit, test/run)The Markdown body contains instructions for Claude to execute when the command is invoked.
Commands support special variables for arguments:
$1, $2, $3, etc.: Positional arguments$ARGUMENTS: All arguments as a single string---
description: One-line description of what this command does
allowed-tools: Read, Grep, Bash
argument-hint: [arg1] [arg2]
---
# Command Name
[Brief description of the command's purpose]
## Arguments
- `$1`: Description of first argument
- `$2`: Description of second argument
- Or use `$ARGUMENTS` for all arguments
## Workflow
When this command is invoked:
1. **Step 1**: Action to perform
2. **Step 2**: Action to perform
3. **Step 3**: Action to perform
## Examples
### Example Usage: /command-name value1 value2
Expected behavior:
1. [What happens]
2. [What happens]
3. [Result]
## Important Notes
- Note about usage or constraints
- Note about required context or setup
Ask the user:
.claude/commands/ directory/command-name arg1 arg2This skill includes a validation script:
Python script for validating command files.
Usage:
python3 {baseDir}/scripts/validate-command.py <command-file.md>
What It Checks:
Returns:
Example:
python3 validate-command.py .claude/commands/run-tests.md
✅ Command validation passed
Name: run-tests
Description: Runs test suite and reports results
Allowed tools: Read, Grep, Bash
Model: claude-haiku-4-5 (valid version alias)
argument-hint: [filename]
Body:
Process the file: $1
Usage: /process-file data.csv
argument-hint: [source] [destination]
Body:
Copy from $1 to $2
Usage: /copy-file src.txt dest.txt
argument-hint: [search-term] [optional-path]
Body:
Search for "$1" in ${2:-.}
Usage: /search "error" ./src or /search "error"
argument-hint: [commit-message]
Body:
Create commit with message: $ARGUMENTS
Usage: /commit Add new feature for user authentication
allowed-tools: Read, Grep, Glob
Use for: Analysis, searching, reporting
allowed-tools: Read, Write, Edit, Grep, Glob
Use for: Code generation, file manipulation
allowed-tools: Read, Grep, Glob, Bash
Use for: Testing, building, git operations
allowed-tools: Read, Write, Edit, Grep, Glob, Bash
Use for: Complete workflows (test + commit + push)
---
description: Commit changes and push to remote
allowed-tools: Read, Grep, Bash
argument-hint: [commit-message]
---
# Git Commit and Push
Commit all changes with the message: $ARGUMENTS
Then push to the remote repository.
## Workflow
1. Run `git add .`
2. Create commit with message from $ARGUMENTS
3. Push to origin
4. Report status
Usage: /git-commit-push Add authentication feature
---
description: Review a pull request for quality and security
allowed-tools: Read, Grep, Bash
argument-hint: [PR-number]
---
# Review Pull Request
Review pull request #$1 for:
- Code quality issues
- Security vulnerabilities
- Test coverage
- Documentation
Use GitHub CLI to fetch PR details and analyze changes.
Usage: /review-pr 123
---
description: Run specific test suite and report results
allowed-tools: Read, Grep, Bash
argument-hint: [test-path]
---
# Run Tests
Execute tests in: $1
Report:
- Pass/fail status
- Coverage metrics
- Failed test details
Usage: /run-tests ./tests/unit
---
description: Create a new React component with tests
allowed-tools: Read, Write, Grep, Glob
argument-hint: [component-name]
---
# Create React Component
Generate a new React component: $1
Include:
- Component file: $1.tsx
- Test file: $1.test.tsx
- Storybook file: $1.stories.tsx
Usage: /create-component UserProfile
---
description: Generate API documentation from code
allowed-tools: Read, Write, Grep, Glob, Bash
argument-hint: [source-directory]
---
# Generate API Docs
Generate API documentation for: ${1:-./src}
Output: ./docs/api.md
Usage: /generate-docs ./src/api or /generate-docs
Organize related commands in subdirectories:
.claude/commands/
├── git/
│ ├── commit.md → /project:git:commit
│ ├── pr.md → /project:git:pr
│ └── rebase.md → /project:git:rebase
├── test/
│ ├── run.md → /project:test:run
│ └── coverage.md → /project:test:coverage
└── deploy/
├── staging.md → /project:deploy:staging
└── production.md → /project:deploy:production
Benefits:
When creating commands:
---
description: Process a data file safely
allowed-tools: Read, Bash
---
# Process File
Process file: $1
## Safety Checks
1. Validate $1 is a valid file path
2. Check file exists and is readable
3. Verify file extension is allowed
4. Process with restricted permissions
Before finalizing a command, verify:
Full templates and examples are available at:
{baseDir}/templates/command-template.md - Basic command template{baseDir}/references/command-examples.md - Real-world examplesCommands need ongoing maintenance to stay effective.
Commands must use VERSION ALIASES or FULL IDs, not short aliases.
# ✅ CORRECT - version alias
model: claude-haiku-4-5
# ✅ CORRECT - full ID
model: claude-haiku-4-5-20251001
# ❌ WRONG - causes "model not found" error
model: haiku
model: sonnet
model: opus
Why: Commands are passed directly to the API. Only agents translate short aliases.
Update commands when:
When reviewing commands for updates:
run-tests, deploy-app)Problem: Command has model: haiku (short alias)
Solution: Change to version alias format:
# Before
model: haiku
# After
model: claude-haiku-4-5
Problem: Command needs to accept parameters Solution: Add argument-hint and document in body:
argument-hint: "[filename] [options]"
Problem: Command uses Bash without validation Solution: Either remove Bash from allowed-tools, or add safety checks in the workflow
Model Selection
claude-haiku-4-5claude-sonnet-4-5 or claude-opus-4-1Tool Permissions
Read, Grep, GlobArgument Documentation
Security
When the user asks to create a command:
When the user asks to update or fix commands:
Be proactive in:
Your goal is to help users create powerful, safe, and well-documented slash commands that streamline their workflows.
development
Apple Human Interface Guidelines for content display components. Use this skill when the user asks about charts component, collection view, image view, web view, color well, image well, activity view, lockup, data visualization, content display, displaying images, rendering web content, color pickers, or presenting collections of items in Apple apps. Also use when the user says how should I display charts, what's the best way to show images, should I use a web view, how do I build a grid of items, what component shows media, or how do I present a share sheet. Cross-references: hig-foundations for color/typography/accessibility, hig-patterns for data visualization patterns, hig-components-layout for structural containers, hig-platforms for platform-specific component behavior.
tools
Automate HelpDesk tasks via Rube MCP (Composio): list tickets, manage views, use canned responses, and configure custom fields. Always search tools first for current schemas.
testing
Expert Haskell engineer specializing in advanced type systems, pure functional design, and high-reliability software. Use PROACTIVELY for type-level programming, concurrency, and architecture guidance.
tools
GraphQL gives clients exactly the data they need - no more, no less. One endpoint, typed schema, introspection. But the flexibility that makes it powerful also makes it dangerous. Without proper controls, clients can craft queries that bring down your server. This skill covers schema design, resolvers, DataLoader for N+1 prevention, federation for microservices, and client integration with Apollo/urql. Key insight: GraphQL is a contract. The schema is the API documentation. Design it carefully.