Replaces all occurrences of a string in a file with a new string.
curl --request POST \
--url http://localhost:4242/{computer_name}/api/editor/str-replace \
--header 'Content-Type: application/json' \
--data '{
"new_str": "new text",
"old_str": "old text",
"path": "/path/to/file.txt"
}'
This response does not have an example.
Successfully replaced string
curl --request POST \
--url http://localhost:4242/{computer_name}/api/editor/str-replace \
--header 'Content-Type: application/json' \
--data '{
"new_str": "new text",
"old_str": "old text",
"path": "/path/to/file.txt"
}'
This response does not have an example.
Replaces all occurrences of a string in a file with a new string.
curl --request POST \
--url http://localhost:4242/{computer_name}/api/editor/str-replace \
--header 'Content-Type: application/json' \
--data '{
"new_str": "new text",
"old_str": "old text",
"path": "/path/to/file.txt"
}'
This response does not have an example.
Successfully replaced string
curl --request POST \
--url http://localhost:4242/{computer_name}/api/editor/str-replace \
--header 'Content-Type: application/json' \
--data '{
"new_str": "new text",
"old_str": "old text",
"path": "/path/to/file.txt"
}'
This response does not have an example.