> Agent-readable docs index: /llms.txt. Download /docs.zip to grep all markdown files locally.

---
title: "readCodeFile"
sidebarTitle: "readCodeFile"
description: "Read the content of a code file by its ID. Available code files are listed in getProjectXml. Returns the current content, name, path, and available exports of the code file."
tag: "TOOL"
tagColor: "purple"
gridGap: 30
---

<Aside full>
  <RequestExample>
    ```json lines=false
    {
      "method": "tools/call",
      "params": {
        "name": "readCodeFile",
        "arguments": {
          "codeFileId": "string"
        }
      }
    }
    ```
  </RequestExample>
</Aside>

<MCPTool {...{"name":"readCodeFile","description":"Read the content of a code file by its ID. Available code files are listed in getProjectXml.\n\nReturns the current content, name, path, and available exports of the code file.","inputSchema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"codeFileId":{"type":"string","description":"The ID of the code file to read"}},"required":["codeFileId"],"additionalProperties":false},"annotations":{"readOnlyHint":true}}} />
