read_file
Retrieve the contents of a text file from an Overleaf project. Large files are truncated unless the full flag is set, and the response indicates if truncation occurred.
Instructions
Read a text file from an Overleaf project.
Files over 100000 characters are truncated unless full=True, and the response sets truncated=true. write_file refuses to replace a file that was only read in part, because the unseen tail would be lost.
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": {
"project": "<project>",
"path": "<path>"
},
"name": "read_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| full | No | Return the whole file instead of the first 100000 characters. Needed before write_file can replace a large file; prefer edit_file for a targeted change. | |
| path | Yes | Path inside the project, e.g. main.tex | |
| project | Yes | Project id (24-char hex) or exact name |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||