Documentation Index
Fetch the complete documentation index at: https://docs.relace.ai/llms.txt
Use this file to discover all available pages before exploring further.
Path Parameters
Path to the file within the repository (URL encoded)
Request Body
The request body should contain the raw file content as binary data. Set the Content-Type header to application/octet-stream.
Response
Returns HTTP status 201 Created on success.
The repository ID that was updated
Commit hash for the updated repo head
Array of file paths that were modified
curl -X PUT https://api.relace.run/v1/repo/3fa85f64-5717-4562-b3fc-2c963f66afa6/file/src/main.py \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/octet-stream" \
--data-binary "def main():
print('Hello World!')
if __name__ == '__main__':
main()"
{
"repo_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"repo_head": "abc123def456789",
"changed_files": ["src/main.py"]
}