write_html_file
Creates or overwrites an HTML tool file under resources/html/, auto-injects the design-system baseline, and returns validation results to guide edits without manual base CSS.
Instructions
Create or overwrite one file inside an HTML tool folder (paths under resources/html/ only; tool.meta.json, tool.settings.json and tool_registry.json are managed and refused). HTML files get the design-system baseline auto-injected — never write base CSS yourself. The result includes a validation summary; if validation.issues is empty, do not read the file back. Use replace_in_html_file for targeted edits.
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": {
"workspacePath": "<workspacePath>",
"filePath": "<filePath>",
"content": "<content>"
},
"name": "write_html_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| content | Yes | Full file content to write | |
| filePath | Yes | File path relative to the workspace root (e.g. "resources/html/my-tool/index.html") | |
| workspacePath | Yes | Absolute path to the workspace directory |