Edit Game Server File
mutate_gameserver_fileCreate, write, upload, rename, delete, move or copy a gameserver file or folder. write takes text; upload takes one binary file as contentBase64 (max. 2 MB, replaces an existing file, e.g. a DLL of a resource update; archives are not extracted). move/copy put entries into an existing destination folder and never overwrite. Destructive actions (write, upload, rename, delete, move) require confirm=true. Requires an active ZapX Pass (see server instructions).
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": {
"serviceId": "<serviceId>",
"action": "<action>"
},
"name": "mutate_gameserver_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | File or folder to act on (required except for move/copy given `paths`). For move/copy: the single entry to transfer. For upload: the full target path including the file name; missing parent folders are created. | |
| paths | No | move/copy: several entries to transfer at once (overrides path). | |
| scope | No | Without scope paths start at the server root (as `list_gameserver_files` without scope shows them); `config`/`active` resolve paths from the game data root; `savegame` additionally restricts to savegame paths. Read and write a file with the same scope. | |
| action | Yes | ||
| confirm | No | ||
| content | No | write/create_file: the text content. | |
| newName | No | ||
| serviceId | Yes | ID of the Gameserver: the "id" field from list_account_services or list_gameservers (e.g. "cmabc123..."). The numericId shown in the panel (e.g. "180") is accepted too. IDs of other service types do not work here. | |
| destination | No | move/copy: existing folder the entries go into, keeping their names. Nothing is overwritten: a taken name or a missing folder refuses the request. | |
| contentBase64 | No | upload: the file content base64 encoded (standard alphabet). For binary files such as DLLs, JARs or images that `write` cannot carry. One file per call, max. 2 MB decoded; an existing file at `path` is replaced. Archives are stored as they are, not extracted. | |
| expectedRevision | No | `revision` returned when the file was read. With action `write` the write is refused (409 file_changed) when the file changed since; re-read and retry. |