build_hwpx
Generate HWPX files from templates, overriding header styles and section content via XML to produce a validated archive.
Instructions
Build an HWPX file from a template and optional XML overrides.
Workflow:
Start from the base template skeleton.
Optionally overlay a document-type template (gonmun/report/minutes).
Optionally override header.xml (styles) and/or section0.xml (body).
Pack as a valid HWPX archive and validate.
When a user provides a reference HWPX, first call analyze_hwpx() and extract_hwpx_xml() to get the header/section XML, then write a new section0.xml with only the required text changes, and pass it here.
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": {
"output_hwpx": "<output_hwpx>"
},
"name": "build_hwpx"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | No | Document title written into content.hpf metadata. | |
| creator | No | Document creator written into content.hpf metadata. | |
| template | No | Document type template — one of: gonmun, report, minutes. Leave empty for plain base template. | |
| header_xml | No | Absolute path to a custom header.xml file (styles). Leave empty to use the template's default header. | |
| output_hwpx | Yes | Absolute path for the output .hwpx file. | |
| section_xml | No | Absolute path to a custom section0.xml file (body content). Leave empty to use the template's default section. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |