ZIV LABS
Reference

AI coding agent extensions: skills, hooks, MCP servers and plugins

Skills, hooks, MCP servers and plugins are how a coding agent is extended, and most of them are files in a repository or a home folder that the agent reads at start-up. This page lists, for Claude Code and Codex, where each extension point is configured, what it can make run, and what the documentation says about approving it. It is a lookup page: it states what we read and observed, and it marks what we did not cover.

What we checked

ToolVersionSources
Claude Code2.1.325The MCP, Skills, Hooks and Plugins pages of the official documentation (re-read in full on November 15, 2026), claude mcp --help, claude plugin --help, and the runs in the MCP note and the file-access guide
Codex CLI0.167.0The official MCP, Skills, Hooks and Plugins pages (read November 15, 2026), codex --help, codex mcp --help, codex plugin --help

The first checks were done on October 22, 2026 (Claude Code 2.1.306, Codex CLI 0.163.0), and re-done on November 15, 2026 against the versions above, from the documentation and the help output only; the runs mentioned below are from October 22 and were not repeated, because they send prompts to the provider. On October 22 the Codex pages for skills and hooks were not found; on November 15 they were, so the Codex rows now follow the documentation. Gemini CLI is not covered here; see the permission reference.

1. The four extension points

Extension pointClaude CodeCodex CLI
SkillsA folder with a SKILL.md, in ~/.claude/skills/, in .claude/skills/ of a project, or inside a plugin. The description stays in context; the body loads when the skill runs.A folder with a SKILL.md (a name and a description are required). Codex looks in .agents/skills of the working directory, of each folder above it up to the repository root, and of the repository root; in $HOME/.agents/skills; in /etc/codex/skills; and in the skills bundled with Codex. It starts with each skill's name, description and path, and reads the full SKILL.md when it uses the skill.
HooksHandlers that run at lifecycle events such as PreToolUse. Defined in user, project or local settings, managed policy, plugins, and skill or subagent frontmatter. A handler can be a shell command, an HTTP endpoint, an MCP tool call, a prompt or a subagent.Command handlers at events such as PreToolUse, PostToolUse, UserPromptSubmit and Stop, defined in hooks.json or [hooks] tables in config.toml, in ~/.codex/ or a project .codex/, and bundled with plugins. A project's hooks load only when its .codex/ layer is trusted. A hook that is not managed by policy runs only after you review and trust its exact definition: trust is recorded against its hash, so a new or changed hook is skipped until trusted again (/hooks in the CLI). --dangerously-bypass-hook-trust runs enabled hooks without that trust for one invocation.
MCP serversScopes: local (default), project (.mcp.json at the repository root) and user. Added with claude mcp add.~/.codex/config.toml, or a project .codex/config.toml for trusted projects only. codex mcp lists, gets, adds and removes servers.
PluginsA directory that bundles skills, agents, hooks and MCP servers, installed from a marketplace or a folder, at user, project or local scope. claude plugin enables, disables and inspects them.A bundle that can include skills and MCP servers (and hooks, which go through the same trust review as other hooks). codex plugin adds, lists and removes plugins and manages marketplaces.

2. What each one can make run, and who approves it

ItemStatementHow we know
A project MCP server in Claude CodeAn interactive session asks before using it. In claude -p it loads without asking. claude mcp get and claude mcp list show an unapproved server as pending and do not connect. A repository cannot approve its own servers: enableAllProjectMcpServers committed in its .claude/settings.json is ignored until you trust the folder.Documentation; and in our runs a server started under claude -p and not under mcp get or mcp list
A skill's allowed-toolsThe listed tools run without a permission prompt during the turn in which the skill is invoked. It applies even in a claude -p run in a folder you have never trusted, so the documentation says to review the field in skills from a repository before you run Claude Code there. An organization can withhold it with allowManagedPermissionRulesOnly (2.1.282 or later).Documentation
A skill's shell injectionThe !`command` syntax runs a shell command before Claude sees the skill content. A setting, disableSkillShellExecution, blocks it for skills and custom commands from user, project, plugin and additional-directory sources; bundled and managed skills are not affected.Documentation
A hook in Claude CodeA PreToolUse hook can block a call, by exit code 2 or by printing a deny decision. With exit code 2, fields in the JSON cannot override the block. With any other non-zero exit code and valid JSON on stdout, the JSON decides by default, so a hook that fails with exit code 1 but prints an allow does not block; a hook set to onFailure: "block" (2.1.295 or later) blocks the action when it fails.Documentation; and a deny from a command hook worked under claude -p in our runs
A plugin in Claude CodeAn enabled plugin is part of every session: its skills and agents add their names and descriptions to the context, its MCP servers run, its hooks fire. What it runs, it runs as you.Documentation
An MCP server in CodexEach server can set how its tools are approved: auto, prompt, writes or approve, with a per-tool override. The page does not state the default.Documentation

3. Before you run an agent in a repository you did not write

  1. Look for the files that configure extensions: .mcp.json, .claude/ (settings, skills), .codex/ (config, hooks), .agents/skills/, and a plugin folder.
  2. Read any command, hook script and allowed-tools line as code you are about to run.
  3. For Claude Code, prefer claude mcp get and claude mcp list to look at servers, because they did not start an unapproved project server in our run.
  4. Remember that in a non-interactive run nobody can approve. Use a disposable environment for unfamiliar repositories.

What this page does not cover

  • Codex skills, hooks and plugins beyond the documentation: we did not install or run any of them.
  • Gemini CLI and other agents.
  • Subagents, slash commands and the Agent SDK, other than where the pages above mention them.
  • The interactive approval prompts. We ran only non-interactive commands.

References

Before you read

Related notes