sort_data
Sort arrays of values or objects by a specified key in ascending or descending order.
Instructions
Sort an array of values or objects.
Parameters:
data — JSON array to sort.
key — Sort key for objects. Empty for value arrays.
order — 'asc' (default) or 'desc'.
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": {
"data": "<data>"
},
"name": "sort_data"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | Yes | ||
| key | No | ||
| order | No | asc |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |