Certopolis

Claude Certified Architect – Foundations

Claude Code skills and slash commands: SKILL.md

A skill is a folder with a SKILL.md file; the folder name becomes a slash command, so .claude/skills/deploy/SKILL.md gives you /deploy. Custom commands in .claude/commands/ have been merged into skills and still work, and Claude can also load a skill on its own based on its description.

Where skills live

Personal skills go in ~/.claude/skills/<name>/SKILL.md and work in all your projects on that machine. Project skills go in .claude/skills/<name>/SKILL.md and reach the team when committed. Enterprise skills are deployed through managed settings. Plugin skills are namespaced as /plugin-name:skill-name.

When names collide, enterprise overrides personal and personal overrides project. If a skill and a .claude/commands/ file share a name, the skill wins.

Frontmatter that controls invocation

The description says what the skill does and when to use it. Descriptions are always in context, and Claude uses them to decide when to load the full SKILL.md. Put the key use case first, because description plus when_to_use is cut at 1,536 characters in the listing.

Set disable-model-invocation: true for a workflow only you should start, such as a deploy. Set user-invocable: false to hide a background-knowledge skill from the / menu while Claude can still load it. allowed-tools lets listed tools run without a permission prompt during the turn that invokes the skill, model picks the model for the skill, and context: fork runs it in a subagent.

Arguments, scripts and live context

$ARGUMENTS expands to everything typed after the command. $ARGUMENTS[N] or $N picks one argument by 0-based index, so in /migrate-component SearchBar JavaScript TypeScript the target language is $2. Named arguments declared in arguments become $name.

${CLAUDE_SKILL_DIR} is the folder holding SKILL.md. Use it in both the body and an allowed-tools rule, such as Bash(${CLAUDE_SKILL_DIR}/scripts/render.sh *), and a bundled script runs without a prompt wherever the skill is installed.

An exclamation mark followed by a command in backticks, such as a git diff HEAD line, runs before the skill is sent to Claude and is replaced by the command's output. If that command fails, the whole invocation aborts. Keep SKILL.md under 500 lines and move long reference material into supporting files that load only when needed.

Where the exam catches people

  • Positional arguments are 0-based: $1 is the second argument, not the first.
  • Automatic loading depends on description, not on the folder name.
  • user-invocable: false hides a skill from the menu but does not stop Claude loading it; disable-model-invocation: true is the setting that stops Claude.
  • Supporting files are not loaded with SKILL.md; Claude reads them only when the body points to them and the task needs them.

Written from Anthropic's documentation

Try 3 questions on this

Pick an answer to see why each option is right or wrong.

  1. You wrote .claude/skills/api-conventions/SKILL.md for your team's endpoint patterns, and it does the right thing when you type /api-conventions. You would rather not have to remember it: when a teammate asks Claude to add an endpoint, Claude should reach for the skill on its own. What change would most effectively get Claude to load it unprompted?

    Right. In the game that’s Renown for your Claude Code Configuration and Workflows building.

    Not that one: C is right. In the game your Claude Code Configuration and Workflows building would lose a little Renown, and this question would come back later.

    Show the full explanation and doc quotes

    If omitted, uses the first paragraph of markdown content.' The docs add that the combined description and when_to_use text is truncated at 1,536 characters in the listing, so the key use case belongs first.

    Written from code.claude.com/docs/en/skills.md

  2. Your /migrate-component skill takes a component name, a source language and a target language, so you invoke it as /migrate-component SearchBar JavaScript TypeScript. You are now writing the line in the skill body that has to name the target language. Which approach should you take?

    Right. In the game that’s Renown for your Claude Code Configuration and Workflows building.

    Not that one: A is right. In the game your Claude Code Configuration and Workflows building would lose a little Renown, and this question would come back later.

  3. Your /render-chart skill ships a helper script inside its own directory, and the body tells Claude to run it. Some teammates keep the skill under their home directory and others commit it to the repository, so its absolute path differs everywhere and every run stops for a Bash approval. What's the most effective way to pre-approve that script?

    Right. In the game that’s Renown for your Claude Code Configuration and Workflows building.

    Not that one: B is right. In the game your Claude Code Configuration and Workflows building would lose a little Renown, and this question would come back later.