format_code
Format code to follow language-specific style guides by specifying programming language and indentation preferences for consistent, readable code.
Instructions
Provides formatted version of code following language-specific style guides.
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": {
"code": "<code>",
"language": "<language>"
},
"name": "format_code"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | Yes | The code to format | |
| language | Yes | Programming language | |
| indent | No | Indentation size (default: 2 for JS, 4 for Python) |