# Claude Code

Anthropic's agentic command-line coding tool, deeply integrated with the terminal and your codebase.

Schema: 1.0 · Data: ee5de863c30bdbe4fe7dd3e07c7e22ea9bf4ab2248dbc7c35cdbf60bc28be1db

## Configuration

### MCP

Status: supported

Add MCP servers via claude mcp add or .mcp.json. Three scopes (local/project/user), stdio/HTTP/SSE/WebSocket transports, OAuth, and tool search.

- project: `.mcp.json` (json) — key: mcpServers
- global: `~/.claude.json` (json) — key: mcpServers — Local scope nests under projects.<path>.mcpServers; user scope is top-level.
- `type`: "stdio" | "http" | "sse" | "ws" — Transport type. 'streamable-http' is accepted as an alias for 'http'.
- `command`: string — Executable for a stdio server.
- `args`: string[] — Arguments for the stdio command.
- `env`: record<string, string> — Environment variables. Supports ${VAR} and ${VAR:-default} expansion.
- `url`: string — Endpoint for HTTP/SSE/WebSocket servers.
- `headers`: record<string, string> — Static HTTP headers (e.g. Authorization). Supports env expansion.
- `headersHelper`: string — Command that prints a JSON object of headers at connect time (dynamic auth).
- `oauth`: { clientId?, callbackPort?, scopes?, authServerMetadataUrl? } — OAuth configuration for remote servers.
- `timeout`: number — Per-server tool execution timeout in milliseconds.
- `alwaysLoad`: boolean — Exempt this server's tools from deferral so they load at session start.
- transports: stdio, http, sse, ws
- auth: oauth, headers, headersHelper
- Tools: supported
- Resources: supported — Reference with @server:protocol://resource/path.
- Prompts: supported — Exposed as /mcp__server__prompt commands.
- Roots: supported — Claude Code answers roots/list with the project directory.
- Elicitation: supported — Form and URL elicitation dialogs appear automatically.
- MCP approval uses permissions.allow in Claude settings, with mcp__<server> or mcp__<server>__<tool> rules; see https://code.claude.com/docs/en/permissions. add-mcp writes project approvals to .claude/settings.local.json and global approvals to ~/.claude/settings.json, separately from server definitions.
- Project scope uses .mcp.json (checked into version control, requires approval).
- Local and user scopes are stored in ~/.claude.json; type 'streamable-http' is an alias for 'http'.
- SSE transport is deprecated in favor of HTTP.

Project HTTP server (.mcp.json)
```json
{
  "mcpServers": {
    "api-server": {
      "type": "http",
      "url": "${API_BASE_URL:-https://api.example.com}/mcp",
      "headers": { "Authorization": "Bearer ${API_KEY}" }
    }
  }
}

```

Source: https://docs.claude.com/en/docs/claude-code/mcp
Checked: 2026-06-21

### Skills

Status: supported

SKILL.md skills with rich frontmatter, invoked with /name or loaded automatically by Claude. Custom commands are merged into skills.

- project: `.claude/skills/<name>/SKILL.md` (markdown)
- global: `~/.claude/skills/<name>/SKILL.md` (markdown) — Personal skills, available across all projects.
- `name`: string — Display name. Defaults to the directory name.
- `description`: string — What the skill does and when to use it. Recommended.
- `when_to_use`: string — Extra trigger context appended to description in the skill listing.
- `argument-hint`: string — Autocomplete hint for expected arguments.
- `arguments`: string | string[] — Named positional arguments for $name substitution.
- `disable-model-invocation`: boolean — When true, only the user can invoke (not Claude). Default false.
- `user-invocable`: boolean — When false, hide from the / menu (Claude-only). Default true.
- `allowed-tools`: string | string[] — Tools usable without approval while the skill is active.
- `disallowed-tools`: string | string[] — Tools removed from the pool while the skill is active.
- `model`: string — Model to use while the skill is active, or 'inherit'.
- `effort`: "low" | "medium" | "high" | "xhigh" | "max" — Effort level override while the skill is active.
- `context`: "fork" — Run the skill in a forked subagent context.
- `agent`: string — Subagent type to use when context: fork is set.
- `hooks`: object — Hooks scoped to the skill's lifecycle.
- `paths`: string | string[] — Glob patterns that limit when the skill auto-activates.
- `shell`: "bash" | "powershell" — Shell for inline !`command` blocks. Default bash.
- invocation: /skill-name, automatic
- Live change detection reloads SKILL.md edits within a session.
- Project skills load from .claude/skills/ up the directory tree and from nested dirs on demand.

Task skill (manual invocation)
```markdown
---
name: deploy
description: Deploy the application to production
disable-model-invocation: true
allowed-tools: Bash(git add *) Bash(git commit *)
---

Deploy $ARGUMENTS to production:
1. Run the test suite
2. Build and push

```

Source: https://docs.claude.com/en/docs/claude-code/skills
Checked: 2026-06-21

### Rules

Status: supported

CLAUDE.md memory files (project/user/managed) plus modular .claude/rules/*.md with optional path scoping. Auto memory accumulates learnings.

- project: `CLAUDE.md` (markdown) — Also reads ./.claude/CLAUDE.md. CLAUDE.local.md for gitignored personal notes.
- project: `.claude/rules/*.md` (markdown) — Modular topic rules; recursive. Path-scope with the paths frontmatter field.
- global: `~/.claude/CLAUDE.md` (markdown) — Personal instructions for all projects. ~/.claude/rules/*.md also supported.
- enterprise: `/Library/Application Support/ClaudeCode/CLAUDE.md` (markdown) — Managed policy (macOS). Linux/WSL: /etc/claude-code/CLAUDE.md; Windows: C:\Program Files\ClaudeCode\CLAUDE.md.
- `paths`: string | string[] — Glob patterns; a rule file applies only when matching files are in context.
- Claude Code reads CLAUDE.md, not AGENTS.md. Import an existing AGENTS.md with @AGENTS.md inside CLAUDE.md.
- Auto memory is stored per repo in ~/.claude/projects/<project>/memory/MEMORY.md.
- Use @path/to/file imports (max depth 4) to compose instructions.

Path-scoped rule
```markdown
---
paths:
  - "src/api/**/*.ts"
---

# API Development Rules
- All API endpoints must include input validation
- Use the standard error response format

```

Source: https://docs.claude.com/en/docs/claude-code/memory
Checked: 2026-06-21

### Hooks

Status: supported

Shell commands that fire on lifecycle events, configured in settings.json under the hooks key (or scoped to a skill/subagent).

- project: `.claude/settings.json` (json) — key: hooks
- global: `~/.claude/settings.json` (json) — key: hooks
- `matcher`: string — Pattern matched against tool name (for PreToolUse/PostToolUse) to scope the hook.
- `hooks[].type`: "command" — Hook handler type.
- `hooks[].command`: string — Shell command to run. Receives event JSON on stdin.
- `hooks[].timeout`: number — Optional timeout in seconds for the hook command.
- events: PreToolUse, PostToolUse, UserPromptSubmit, Notification, Stop, SubagentStop, SessionStart, SessionEnd, PreCompact, Elicitation, InstructionsLoaded

Format TypeScript after edits
```json
{
  "hooks": {
    "PostToolUse": [
      {
        "matcher": "Edit|Write",
        "hooks": [{ "type": "command", "command": "prettier --write \"$CLAUDE_FILE_PATHS\"" }]
      }
    ]
  }
}

```

Source: https://docs.claude.com/en/docs/claude-code/hooks
Checked: 2026-06-21

### Commands

Status: supported

Custom slash commands as markdown files. Merged into Skills — a command and a skill of the same name behave identically; skills add supporting files and auto-invocation.

- project: `.claude/commands/<name>.md` (markdown)
- global: `~/.claude/commands/<name>.md` (markdown)
- `description`: string — What the command does.
- `argument-hint`: string — Autocomplete hint for expected arguments.
- `allowed-tools`: string | string[] — Tools the command may use without approval.
- `model`: string — Model override while the command runs.
- invocation: /command-name
- .claude/commands/<name>.md creates /<name> and supports the same frontmatter as skills.
- Skills are recommended for new workflows since they support supporting files and model invocation.
Source: https://docs.claude.com/en/docs/claude-code/slash-commands
Checked: 2026-06-21

### Settings

Status: supported

Hierarchical settings.json controls permissions, environment, hooks, model, and skill behavior across user, project, local, and managed scopes.

- project: `.claude/settings.json` (json) — Shared project settings (checked in).
- project: `.claude/settings.local.json` (json) — Personal project settings (gitignored).
- global: `~/.claude/settings.json` (json) — User settings for all projects.
- enterprise: `managed-settings.json` (json) — Managed policy settings deployed by IT/DevOps.
- `permissions`: { allow?: string[], deny?: string[], ask?: string[], additionalDirectories?: string[] } — Allow/deny/ask rules governing tool and command use.
- `env`: record<string, string> — Environment variables applied to every session.
- `hooks`: object — Lifecycle hook configuration (see Hooks).
- `model`: string — Default model for sessions.
- `disableBundledSkills`: boolean — Disable the built-in bundled skills (/code-review, /debug, etc.).
- `skillOverrides`: record<string, "on" | "name-only" | "user-invocable-only" | "off"> — Override skill visibility without editing SKILL.md frontmatter.
- `autoMemoryEnabled`: boolean — Toggle auto memory. Default true.
- `claudeMd`: string — Managed CLAUDE.md content (managed/policy scope only).
Source: https://docs.claude.com/en/docs/claude-code/settings
Checked: 2026-06-21

## Search, browser & identification

### Claude Code / built-in WebFetch / fetch

Tool: claude-web-fetch (built-in)

- Documentation snapshot checked September 6, 2026; exact version range not specified.
- Applies to WebFetch, not shell commands or installed MCP tools.

- Explicit Markdown preference: Yes (documented; checked 2026-09-06). The request Accept header prefers Markdown over HTML.
  Source: [Claude Code tool reference](https://code.claude.com/docs/en/tools-reference) — WebFetch and WebSearch tool behavior
- User-Agent: Claude-User prefix (documented; checked 2026-09-06). The documentation specifies the prefix, not a complete versioned UA string.
  Source: [Claude Code tool reference](https://code.claude.com/docs/en/tools-reference) — WebFetch and WebSearch tool behavior
- Redirects: Separate fetch for cross-host redirects (documented; checked 2026-09-06). WebFetch returns the original and target URLs for a subsequent fetch.
  Source: [Claude Code tool reference](https://code.claude.com/docs/en/tools-reference) — WebFetch and WebSearch tool behavior
- Accept header: Unknown (unknown). Not established by the reviewed official documentation.
- Custom headers: Unknown (unknown). Not established by the reviewed official documentation.
- Browser engine: Unknown (unknown). Not established by the reviewed official documentation.
- JavaScript execution: Unknown (unknown). Not established by the reviewed official documentation.
- Identification: user-agent product-token Claude-User; tool: Claude user retrieval. Claude-User is shared with other Claude retrieval contexts; this does not uniquely identify Claude Code. User-Agent is spoofable.

### Claude Code / built-in WebSearch / search

Tool: claude-web-search (built-in)

- Documentation snapshot checked September 6, 2026; platform availability varies.

- Provider: Anthropic search backend (documented; checked 2026-09-06). The built-in backend is not configurable; alternatives can be installed through MCP.
  Source: [Claude Code tool reference](https://code.claude.com/docs/en/tools-reference) — WebFetch and WebSearch tool behavior
- Tool output: Result titles and URLs (documented; checked 2026-09-06). Search does not fetch the result pages; WebFetch is a separate operation.
  Source: [Claude Code tool reference](https://code.claude.com/docs/en/tools-reference) — WebFetch and WebSearch tool behavior
- Accept header: Unknown (unknown). Not established by the reviewed official documentation.
- Explicit Markdown preference: Unknown (unknown). Not established by the reviewed official documentation.
- User-Agent: Unknown (unknown). Not established by the reviewed official documentation.
