cURL
curl --request POST \ --url http://localhost:4444/v1/workspace/read-source-code \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data ' { "path": "src/main.py", "range": "<unknown>" } '
{ "source_code": "<string>" }
Returns the contents of the specified file.
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Bearer <token>
<token>
Path to the file, relative to the workspace root
"src/main.py"
Optional range within the file to read
Show child attributes
Source code retrieved successfully