# create_directory

Create a directory within the project.

Agent View of the PolicyLayer registry record for `create_directory`. HTML page: https://policylayer.com/tools/54yyyu-code-mcp/create-directory

## Facts

- Tool: `create_directory`
- Server: Code (`54yyyu/code-mcp`) — https://policylayer.com/tools/54yyyu-code-mcp.md
- Homepage: https://github.com/54yyyu/code-mcp
- Risk category: Write (Medium risk)
- Registry record: grade F, identity unverified
- Server rate-limited: no
- Parameters: 0
- Recommended policy verdict: Rate-limited

## Example call (MCP tools/call, JSON-RPC 2.0)

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "create_directory",
    "arguments": {}
  }
}
```

## Why create_directory is rated Medium

Creating a directory is a write operation: it creates new state on disk. It is reversible (the directory can be deleted), so it does not qualify as Destructive. Severity is medium because an agent could create many directories or use paths to access unexpected locations, but the impact is limited compared to Execute or Destructive tools on this server. Confidence is high because the intent is unambiguous.

From the tool's own definition: "Tool description states 'Create a directory' — a reversible write operation that modifies the filesystem by adding a new directory."

## Use case

AI agents use create_directory to create or update resources in Code, usually the action step of a workflow, after the agent has gathered context. Every call changes real data in your Code environment.

## Recommended policy (PolicyLayer)

Verdict: **Rate-limited**. Enforced by the PolicyLayer MCP gateway (https://policylayer.com/mcp-gateway) before a call reaches Code:

```json
{
  "version": "1",
  "default": "deny",
  "tools": {
    "create_directory": {
      "limits": [
        {
          "counter": "create_directory_rate",
          "window": "minute",
          "max": 30,
          "scope": "grant"
        }
      ]
    }
  }
}
```

## Other tools on Code (8)

- `delete_path` — Destructive — https://policylayer.com/tools/54yyyu-code-mcp/delete-path.md
- `git_operation` — Execute — https://policylayer.com/tools/54yyyu-code-mcp/git-operation.md
- `run_command` — Execute — https://policylayer.com/tools/54yyyu-code-mcp/run-command.md
- `list_directory` — Read — https://policylayer.com/tools/54yyyu-code-mcp/list-directory.md
- `read_file` — Read — https://policylayer.com/tools/54yyyu-code-mcp/read-file.md
- `edit_block` — Write — https://policylayer.com/tools/54yyyu-code-mcp/edit-block.md
- `edit_file` — Write — https://policylayer.com/tools/54yyyu-code-mcp/edit-file.md
- `smart_edit` — Write — https://policylayer.com/tools/54yyyu-code-mcp/smart-edit.md

## For agents

This record is a snapshot. Live verdicts and the full registry:

- Check every server in your MCP config at once: `npx -y policylayer stack`
- Vet a server before you add it: install the mcp-precheck skill — `npx skills add https://policylayer.com` (skill text: https://policylayer.com/skill.md)
- Query the registry over MCP: endpoint `https://api.policylayer.com/mcp` — tools `check_mcp_server`, `check_mcp_stack`, `check_tool`, `search_registry`, `get_change_events`

---

Source: the PolicyLayer MCP registry — one continuously verified record per MCP server. Full record: https://policylayer.com/registry?q=54yyyu-code-mcp · API: https://policylayer.com/registry/api · Policy library: https://policylayer.com/policies/54yyyu-code-mcp
