get_file_content
Retrieves the full file content from a codebase, optionally verifying the file belongs to a specified project before reading. Returns the content as a string.
Instructions
Return the full content of a given file path.
Args:
path: File path to read
project: When supplied, validates that the path belongs to this project
before reading. Raises an error if the path is not indexed.
Returns:
File content as string
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"path": "<path>"
},
"name": "get_file_content"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | ||
| project | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |