run_vpk_pack
Packs a staging directory into an addon VPK with the game's vpk.exe, writes the addon manifest if missing, then verifies the archive's entry list against the staging tree to catch dropped files.
Instructions
Packs a staging directory into an addon VPK with the game's own vpk.exe. The directory is packed root-relative, so addoninfo.txt, missions/, maps/ and materials/vgui/maps/ end up where the game expects them. addoninfo writes the manifest first when the directory has none. Afterwards the archive is read back through the sidecar and its entry list is compared with the staging tree: a pack that silently dropped a file is the failure this check exists for.
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": {
"dir": "<dir>"
},
"name": "run_vpk_pack"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| dir | Yes | Staging directory containing addoninfo.txt and the addon's tree. | |
| out | No | Destination .vpk. Defaults to <parent>/<directory name>.vpk. | |
| confirm | No | ||
| addoninfo | No | Write addoninfo.txt into the staging directory first. | |
| overwrite | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| vpk | Yes | ||
| bytes | Yes | ||
| entries | Yes | ||
| staging | Yes | ||
| verified | Yes | ||
| entryCount | Yes | ||
| addoninfoWritten | Yes |