sort_range
Sort a range of cells in a Google Sheet by a specific column, with ascending or descending order.
Instructions
Sort a range of cells by a column.
Args: spreadsheet_id: The ID of the spreadsheet sheet: Sheet/tab name range: A1 notation range to sort (e.g., 'A1:D100') sort_column: Column letter to sort by (e.g., 'B') order: 'ASCENDING' or 'DESCENDING'
Returns: Result of the sort operation
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"spreadsheet_id": "<spreadsheet_id>",
"sheet": "<sheet>",
"range": "<range>",
"sort_column": "<sort_column>"
},
"name": "sort_range"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| spreadsheet_id | Yes | ||
| sheet | Yes | ||
| range | Yes | ||
| sort_column | Yes | ||
| order | No | ASCENDING |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |