find_and_replace_doc
Locate and substitute specific text within a Google Doc. Specify user email, document ID, and text to find and replace. Optionally match case for precise adjustments. Returns replacement count for confirmation.
Instructions
Finds and replaces text throughout a Google Doc.
Args: user_google_email: User's Google email address document_id: ID of the document to update find_text: Text to search for replace_text: Text to replace with match_case: Whether to match case exactly
Returns: str: Confirmation message with replacement count
Input Schema
Name | Required | Description | Default |
---|---|---|---|
document_id | Yes | ||
find_text | Yes | ||
match_case | No | ||
replace_text | Yes | ||
user_google_email | Yes |
Input Schema (JSON Schema)
{
"properties": {
"document_id": {
"title": "Document Id",
"type": "string"
},
"find_text": {
"title": "Find Text",
"type": "string"
},
"match_case": {
"default": false,
"title": "Match Case",
"type": "boolean"
},
"replace_text": {
"title": "Replace Text",
"type": "string"
},
"user_google_email": {
"title": "User Google Email",
"type": "string"
}
},
"required": [
"user_google_email",
"document_id",
"find_text",
"replace_text"
],
"type": "object"
}