Skip to content

FileEditInput

Base classes

Name Children Inherits
dict
builtins
dict() -> new empty dictionary

⋔ Inheritance diagram

graph TD
  2095055822["input_types.FileEditInput"]
  2645524081["builtins.dict"]
  2751680898["builtins.object"]
  2645524081 --> 2095055822
  2751680898 --> 2645524081

🛈 DocStrings

Bases: TypedDict

Input for the Edit tool. Performs exact string replacements in files.

Source code in src/clawd_code_sdk/models/input_types.py
@_extra_allow
class FileEditInput(TypedDict):
    """Input for the Edit tool. Performs exact string replacements in files."""

    file_path: str
    """The absolute path to the file to modify."""
    old_string: str
    """The text to replace."""
    new_string: str
    """The text to replace it with (must be different from old_string)."""
    replace_all: NotRequired[bool]
    """Replace all occurrences of old_string (default false)."""

file_path instance-attribute

file_path: str

The absolute path to the file to modify.

new_string instance-attribute

new_string: str

The text to replace it with (must be different from old_string).

old_string instance-attribute

old_string: str

The text to replace.

replace_all instance-attribute

replace_all: NotRequired[bool]

Replace all occurrences of old_string (default false).

:fa-brands-github: Show source on GitHub