format_cells
Apply formatting to Excel cells, including font styles, colors, alignment, borders, and number formats, for both live workbooks and .xlsx files without Excel.
Instructions
Apply formatting to cells. Use "workbook" for live Excel, or "path" for a .xlsx file on disk (no Excel needed, preserves images/charts). Options: bold, italic, underline, fontSize, fontName, fontColor, backgroundColor, textAlign (left/center/right), verticalAlign (top/middle/bottom), numberFormat, wrapText, borders ({top/bottom/left/right/inside/outside: {style, color}}).
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": {
"range": "<range>",
"format": "<format>"
},
"name": "format_cells"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| workbook | No | Open workbook name (live Excel) | |
| path | No | File path to .xlsx (no Excel needed) | |
| range | Yes | Cell range (e.g. "A1:C3") | |
| format | Yes | Formatting options | |
| sheet | No | Sheet name (default: active sheet) |