Edit runtime sandbox file
Replace occurrences of oldString with newString in a file in the workspace runtime sandbox, then push the change to the workspace’s default branch on GitHub. By default oldString must occur exactly once; pass replaceAll: true to replace every occurrence.
Documentation Index
Fetch the complete documentation index at: https://docs.getcargo.ai/llms.txt
Use this file to discover all available pages before exploring further.
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
Edit a file in the workspace runtime sandbox via string replacement, then push the change to the default branch.
Path of the file to edit, relative to the workspace working directory.
1The exact substring to replace. Must occur exactly once unless replaceAll is true.
1Replacement string. May be empty to delete the match. Must differ from oldString.
When true, replace every occurrence of oldString instead of requiring a single match.
Optional commit message override. Defaults to 'context(runtime): edit '.
1Response
Successful response

