protect_range
Restrict editing permissions on a specified range or entire sheet in Google Sheets, with options for warning-only protection and editor exceptions.
Instructions
Protect a range (or the whole sheet) from editing.
Args: spreadsheet_id_or_url: Full Sheets URL or bare spreadsheet ID. sheet: Sheet name OR gid string. range: Bare A1 range to protect. None = whole sheet. description: Label shown in the Sheets UI. warning_only: Show a warning instead of blocking edits. editors: Email addresses still allowed to edit (ignored when warning_only). dry_run: If true, return the execution plan without changing anything.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| range | No | ||
| sheet | Yes | ||
| dry_run | No | ||
| editors | No | ||
| description | No | ||
| warning_only | No | ||
| spreadsheet_id_or_url | Yes |