read_file
Access and retrieve the content of any file within size limits using the MCP Python Interpreter. Specify the file path and optional size cap to safely read and return the data.
Instructions
Read the content of any file, with size limits for safety.
Args:
file_path: Path to the file (relative to working directory or absolute)
max_size_kb: Maximum file size to read in KB (default: 1024)
Returns:
str: File content or an error message
Input Schema
Name | Required | Description | Default |
---|---|---|---|
file_path | Yes | ||
max_size_kb | No |
Input Schema (JSON Schema)
{
"properties": {
"file_path": {
"title": "File Path",
"type": "string"
},
"max_size_kb": {
"default": 1024,
"title": "Max Size Kb",
"type": "integer"
}
},
"required": [
"file_path"
],
"title": "read_fileArguments",
"type": "object"
}