Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Commands

This page documents all commands that can be sent to the RPFM server. Each command is wrapped in a Message with a unique id.

Commands with no parameters are serialized as plain strings. Commands with parameters use the { "CommandName": params } format. See the serialization convention for details.

Most commands that operate on a specific pack take a pack_key string as their first parameter. The pack key is returned by OpenPackFiles or NewPack when you open or create a pack.


Lifecycle

Exit

Close the background thread. Do not use directly — the server manages this internally.

Response: None (breaks the server loop).

ClientDisconnecting

Signal that the client is intentionally disconnecting. Allows the server to clean up the session immediately.

Response: "Success"

{ "id": 1, "data": "ClientDisconnecting" }

PackFile Operations

NewPack

Create a new empty Pack.

Response: { String: string } — the assigned pack key.

{ "id": 1, "data": "NewPack" }

OpenPackFiles

Open one or more Pack files and merge them into the current session.

ParameterTypeDescription
pathsstring[]Filesystem paths to open

Response: { StringContainerInfo: [string, ContainerInfo] } — pack key and metadata.

{ "id": 1, "data": { "OpenPackFiles": ["/path/to/my_mod.pack"] } }

LoadAllCAPackFiles

Open all CA Pack files for the selected game as one merged Pack.

Response: { StringContainerInfo: [string, ContainerInfo] }

{ "id": 1, "data": "LoadAllCAPackFiles" }

ListOpenPacks

List all currently open packs with their keys and metadata.

Response: { VecStringContainerInfo: [string, ContainerInfo][] }

{ "id": 1, "data": "ListOpenPacks" }

ClosePack

Close a specific open Pack.

ParameterTypeDescription
pack_keystringPack to close

Response: "Success"

{ "id": 1, "data": { "ClosePack": "my_mod.pack" } }

CloseAllPacks

Close all currently open Packs.

Response: "Success"

{ "id": 1, "data": "CloseAllPacks" }

SavePack

Save a specific open Pack to disk.

ParameterTypeDescription
pack_keystringPack to save

Response: { ContainerInfo: ContainerInfo }

{ "id": 1, "data": { "SavePack": "my_mod.pack" } }

SavePackAs

Save a specific open Pack to a new path.

ParameterTypeDescription
pack_keystringPack to save
pathstringDestination path

Response: { ContainerInfo: ContainerInfo }

{ "id": 1, "data": { "SavePackAs": ["my_mod.pack", "/path/to/new_mod.pack"] } }

CleanAndSavePackAs

Clean a Pack from corrupted/undecoded files and save to disk. Only use if the Pack is otherwise unsaveable.

ParameterTypeDescription
pack_keystringPack to clean
pathstringDestination path

Response: { ContainerInfo: ContainerInfo }

{ "id": 1, "data": { "CleanAndSavePackAs": ["my_mod.pack", "/path/to/cleaned.pack"] } }

GetPackFileDataForTreeView

Get tree view data (container info and file list) for a specific pack.

ParameterTypeDescription
pack_keystringPack to query

Response: { ContainerInfoVecRFileInfo: [ContainerInfo, RFileInfo[]] }

{ "id": 1, "data": { "GetPackFileDataForTreeView": "my_mod.pack" } }

GetPackedFilesInfo

Get metadata for one or more packed files by path.

ParameterTypeDescription
pack_keystringPack to query
pathsstring[]Internal file paths

Response: { VecRFileInfo: RFileInfo[] }

{ "id": 1, "data": { "GetPackedFilesInfo": ["my_mod.pack", ["db/units_tables/data"]] } }

GetRFileInfo

Get the info of a single packed file.

ParameterTypeDescription
pack_keystringPack to query
pathstringInternal file path

Response: { OptionRFileInfo: RFileInfo | null }

{ "id": 1, "data": { "GetRFileInfo": ["my_mod.pack", "db/units_tables/data"] } }

GetPackFilePath

Get the filesystem path of a specific open Pack.

ParameterTypeDescription
pack_keystringPack to query

Response: { PathBuf: string }

GetPackFileName

Get the file name of a specific open Pack.

ParameterTypeDescription
pack_keystringPack to query

Response: { String: string }

SetPackFileType

Change the PFH type of a specific open Pack (e.g., Mod, Movie, Boot).

ParameterTypeDescription
pack_keystringPack to modify
typePFHFileTypeNew file type

Response: "Success"

ChangeIndexIncludesTimestamp

Toggle the “Index Includes Timestamp” flag for a specific pack.

ParameterTypeDescription
pack_keystringPack to modify
enabledbooleanNew flag value

Response: "Success"

ChangeCompressionFormat

Change the compression format of a specific open Pack.

ParameterTypeDescription
pack_keystringPack to modify
formatCompressionFormatNew format

Response: { CompressionFormat: CompressionFormat } — actual format set (may differ if unsupported).

OptimizePackFile

Run the optimizer over a specific open Pack.

ParameterTypeDescription
pack_keystringPack to optimize
optionsOptimizerOptionsOptimization config

Response: { HashSetStringHashSetString: [string[], string[]] } — deleted and added paths.

PatchSiegeAI

Patch Siege AI for Warhammer siege maps in a specific pack.

ParameterTypeDescription
pack_keystringPack to patch

Response: { StringVecContainerPath: [string, ContainerPath[]] }


Game Selection

GetGameSelected

Get the currently selected game key.

Response: { String: string }

{ "id": 1, "data": "GetGameSelected" }

SetGameSelected

Change the selected game. Optionally rebuilds dependencies.

ParameterTypeDescription
game_keystringGame identifier (e.g., "warhammer_3")
rebuildbooleanWhether to rebuild dependencies

Response: { CompressionFormatDependenciesInfo: [CompressionFormat, DependenciesInfo | null] }

{ "id": 1, "data": { "SetGameSelected": ["warhammer_3", true] } }

GenerateDependenciesCache

Generate the dependencies cache for the currently selected game.

Response: { DependenciesInfo: DependenciesInfo }

UpdateCurrentSchemaFromAssKit

Update the current schema with data from the game’s Assembly Kit.

Response: "Success"


PackedFile Operations

NewPackedFile

Create a new packed file inside a specific open Pack.

ParameterTypeDescription
pack_keystringTarget pack
pathstringInternal path for the file
specNewFileFile type specification

Response: "Success"

{ "id": 1, "data": { "NewPackedFile": ["my_mod.pack", "db/units_tables/data", { "DB": ["data", "units_tables", 4] }] } }

AddPackedFiles

Add files from the filesystem to a specific open Pack.

ParameterTypeDescription
pack_keystringTarget pack
source_pathsstring[]Filesystem paths to add
dest_pathsContainerPath[]Destination paths inside the pack
ignore_pathsstring[] or nullPaths to exclude (optional)

Response: { VecContainerPathOptionString: [ContainerPath[], string | null] } — added paths and optional error.

DecodePackedFile

Decode a packed file for display.

ParameterTypeDescription
pack_keystringPack containing the file
pathstringInternal path
sourceDataSourceData source to decode from

Response: Type-specific (e.g., { DBRFileInfo: [DB, RFileInfo] }, { TextRFileInfo: [Text, RFileInfo] }, "Unknown", etc.)

{ "id": 1, "data": { "DecodePackedFile": ["my_mod.pack", "db/units_tables/data", "PackFile"] } }

SavePackedFileFromView

Save an edited packed file back to the Pack.

ParameterTypeDescription
pack_keystringTarget pack
pathstringInternal path
dataRFileDecodedDecoded file content

Response: "Success"

DeletePackedFiles

Delete packed files from a specific open Pack.

ParameterTypeDescription
pack_keystringPack to modify
pathsContainerPath[]Paths to delete

Response: { VecContainerPath: ContainerPath[] } — deleted paths.

{ "id": 1, "data": { "DeletePackedFiles": ["my_mod.pack", [{ "File": "db/units_tables/data" }]] } }

ExtractPackedFiles

Extract packed files to the filesystem.

ParameterTypeDescription
pack_keystringPack to extract from
paths_by_sourceRecord<DataSource, ContainerPath[]>Files grouped by data source
dest_pathstringFilesystem destination
as_tsvbooleanExport tables as TSV

Response: { StringVecPathBuf: [string, string[]] }

{ "id": 1, "data": { "ExtractPackedFiles": ["my_mod.pack", { "PackFile": [{ "File": "db/units_tables/data" }] }, "/tmp/extract", false] } }

RenamePackedFiles

Rename packed files in a specific Pack.

ParameterTypeDescription
pack_keystringPack to modify
renames[ContainerPath, ContainerPath][]Array of [old_path, new_path] pairs

Response: { VecContainerPathContainerPath: [ContainerPath, ContainerPath][] }

FolderExists

Check if a folder exists in a specific open Pack.

ParameterTypeDescription
pack_keystringPack to check
pathstringFolder path

Response: { Bool: boolean }

PackedFileExists

Check if a packed file exists in a specific open Pack.

ParameterTypeDescription
pack_keystringPack to check
pathstringFile path

Response: { Bool: boolean }

GetPackedFileRawData

Get the raw binary data of a packed file.

ParameterTypeDescription
pack_keystringPack to query
pathstringInternal file path

Response: { VecU8: number[] }

AddPackedFilesFromPackFile

Copy packed files from one Pack into another.

ParameterTypeDescription
target_keystringDestination pack key
source_keystringSource pack key
pathsContainerPath[]Paths to copy

Response: { VecContainerPath: ContainerPath[] }

AddPackedFilesFromPackFileToAnimpack

Copy packed files from the main Pack into an AnimPack.

ParameterTypeDescription
pack_keystringPack containing animpack
animpack_pathstringPath to the AnimPack
pathsContainerPath[]Paths to copy

Response: { VecContainerPath: ContainerPath[] }

AddPackedFilesFromAnimpack

Copy packed files from an AnimPack into the main Pack.

ParameterTypeDescription
pack_keystringTarget pack
sourceDataSourceData source
animpack_pathstringPath to the AnimPack
pathsContainerPath[]Paths to copy

Response: { VecContainerPath: ContainerPath[] }

DeleteFromAnimpack

Delete packed files from an AnimPack.

ParameterTypeDescription
pack_keystringPack containing animpack
animpack_pathstringPath to the AnimPack
pathsContainerPath[]Paths to delete

Response: "Success"

ImportDependenciesToOpenPackFile

Import files from dependencies into a specific open Pack.

ParameterTypeDescription
pack_keystringTarget pack
sourcesRecord<DataSource, ContainerPath[]>Files to import by source

Response: { VecContainerPathVecString: [ContainerPath[], string[]] } — added paths, failed paths.

SavePackedFilesToPackFileAndClean

Save packed files to a specific Pack and optionally run optimizer.

ParameterTypeDescription
pack_keystringTarget pack
filesRFile[]Files to save
optimizebooleanRun optimizer

Response: { VecContainerPathVecContainerPath: [ContainerPath[], ContainerPath[]] } — added and deleted paths.

GetPackedFilesNamesStartingWitPathFromAllSources

Get all file names under a path from all dependency sources.

ParameterTypeDescription
pathContainerPathPath prefix

Response: { HashMapDataSourceHashSetContainerPath: Record<DataSource, ContainerPath[]> }


Dependency Commands

RebuildDependencies

Rebuild the dependencies by combining deps from all open packs.

ParameterTypeDescription
rebuild_allbooleantrue = all dependencies, false = mod-specific

Response: { DependenciesInfo: DependenciesInfo }

{ "id": 1, "data": { "RebuildDependencies": true } }

IsThereADependencyDatabase

Check if a dependency database is loaded.

ParameterTypeDescription
require_asskitbooleanCheck that AssKit data is included

Response: { Bool: boolean }

GetTableListFromDependencyPackFile

Get all DB table names from dependency Pack files.

Response: { VecString: string[] }

GetCustomTableList

Get custom table names (start_pos_, twad_ prefixes) from the schema.

Response: { VecString: string[] }

LocalArtSetIds

Get local art set IDs from campaign_character_arts_tables in a specific pack.

ParameterTypeDescription
pack_keystringPack to query

Response: { HashSetString: string[] }

DependenciesArtSetIds

Get art set IDs from dependencies’ campaign_character_arts_tables.

Response: { HashSetString: string[] }

GetTableVersionFromDependencyPackFile

Get the version of a table from the dependency database.

ParameterTypeDescription
table_namestringTable to query

Response: { I32: number }

GetTableDefinitionFromDependencyPackFile

Get the definition of a table from the dependency database.

ParameterTypeDescription
table_namestringTable to query

Response: { Definition: Definition }

MergeFiles

Merge multiple compatible tables into one.

ParameterTypeDescription
pack_keystringPack containing the files
pathsContainerPath[]Files to merge
merged_pathstringDestination path for result
delete_sourcesbooleanDelete source files after

Response: { String: string } — merged path.

UpdateTable

Update a table to a newer schema version.

ParameterTypeDescription
pack_keystringPack containing table
pathContainerPathTable path

Response: { I32I32VecStringVecString: [old_ver, new_ver, deleted_fields, added_fields] }

GetDependencyPackFilesList

Get the list of Pack files marked as dependencies of a specific Pack.

ParameterTypeDescription
pack_keystringPack to query

Response: { VecBoolString: [boolean, string][] }[enabled, pack_name] pairs.

SetDependencyPackFilesList

Set the list of Pack files marked as dependencies.

ParameterTypeDescription
pack_keystringPack to modify
deps[boolean, string][][enabled, pack_name] pairs

Response: "Success"

GetRFilesFromAllSources

Get packed files from all known sources.

ParameterTypeDescription
pathsContainerPath[]Paths to retrieve
lowercasebooleanNormalize paths to lowercase

Response: { HashMapDataSourceHashMapStringRFile: Record<DataSource, Record<string, RFile>> }


Search Commands

GlobalSearch

Perform a global search across a specific pack.

ParameterTypeDescription
pack_keystringPack to search
configGlobalSearchSearch configuration

Response: { GlobalSearchVecRFileInfo: [GlobalSearch, RFileInfo[]] }

{
  "id": 1,
  "data": {
    "GlobalSearch": ["my_mod.pack", {
      "pattern": "cavalry",
      "replace_text": "",
      "case_sensitive": false,
      "use_regex": false,
      "source": "Pack",
      "search_on": { "db": true, "loc": true, "text": true },
      "matches": {},
      "game_key": "warhammer_3"
    }]
  }
}

GlobalSearchReplaceMatches

Replace specific matches in a global search.

ParameterTypeDescription
pack_keystringPack to modify
configGlobalSearchSearch config
matchesMatchHolder[]Matches to replace

Response: { GlobalSearchVecRFileInfo: [GlobalSearch, RFileInfo[]] }

GlobalSearchReplaceAll

Replace all matches in a global search.

ParameterTypeDescription
pack_keystringPack to modify
configGlobalSearchSearch config

Response: { GlobalSearchVecRFileInfo: [GlobalSearch, RFileInfo[]] }

GetReferenceDataFromDefinition

Get reference data for columns in a table definition.

ParameterTypeDescription
pack_keystringPack to query
table_namestringName of the table
definitionDefinitionTable definition
force_localbooleanForce regeneration from local

Response: { HashMapI32TableReferences: Record<number, TableReferences> }

SearchReferences

Find all references to a value across tables in a specific pack.

ParameterTypeDescription
pack_keystringPack to search
table_columnsRecord<string, string[]>Map of table name to column names
search_valuestringValue to search for

Response: { VecDataSourceStringStringUsizeUsize: [DataSource, string, string, number, number][] }


GoToDefinition

Go to the definition of a table reference.

ParameterTypeDescription
pack_keystringPack to search
table_namestringTable name
column_namestringColumn name
valuesstring[]Values to search for

Response: { DataSourceStringUsizeUsize: [DataSource, string, number, number] }

GoToLoc

Navigate to a loc key’s location.

ParameterTypeDescription
pack_keystringPack to search
loc_keystringLoc key to find

Response: { DataSourceStringUsizeUsize: [DataSource, string, number, number] }

GetSourceDataFromLocKey

Get the source data (table, column, values) of a loc key.

ParameterTypeDescription
pack_keystringPack to search
loc_keystringLoc key to look up

Response: { OptionStringStringVecString: [string, string, string[]] | null }


Cascade Edition

CascadeEdition

Trigger a cascade edition on all referenced data in a specific pack.

ParameterTypeDescription
pack_keystringPack to modify
tablestringTable name
definitionDefinitionTable definition
changes[Field, string, string][][field, old_value, new_value] tuples

Response: { VecContainerPathVecRFileInfo: [ContainerPath[], RFileInfo[]] }


Video Commands

SetVideoFormat

Change the format of a ca_vp8 video packed file.

ParameterTypeDescription
pack_keystringPack containing file
pathstringInternal file path
formatSupportedFormatsTarget video format

Response: "Success"


Schema Commands

SaveSchema

Save a schema to disk.

ParameterTypeDescription
schemaSchemaComplete schema to save

Response: "Success"

CleanCache

Encode and clean the internal cache for specified paths.

ParameterTypeDescription
pack_keystringPack to clean
pathsContainerPath[]Paths to process

Response: "Success"

IsSchemaLoaded

Check if a schema is loaded in memory.

Response: { Bool: boolean }

Schema

Get the currently loaded schema.

Response: { Schema: Schema }

DefinitionsByTableName

Get all definitions (all versions) for a table name.

ParameterTypeDescription
table_namestringTable to query

Response: { VecDefinition: Definition[] }

DefinitionByTableNameAndVersion

Get a specific definition by table name and version.

ParameterTypeDescription
table_namestringTable name
versionnumberVersion number

Response: { Definition: Definition }

DeleteDefinition

Delete a definition by table name and version.

ParameterTypeDescription
table_namestringTable name
versionnumberVersion number

Response: "Success"

ReferencingColumnsForDefinition

Get columns from other tables that reference a given table/definition.

ParameterTypeDescription
table_namestringReferenced table
definitionDefinitionTable definition

Response: { HashMapStringHashMapStringVecString: Record<string, Record<string, string[]>> }

FieldsProcessed

Get the processed fields from a definition (bitwise expansion, enum conversion, colour merging applied).

ParameterTypeDescription
definitionDefinitionDefinition to process

Response: { VecField: Field[] }


TSV Commands

ExportTSV

Export a table as a TSV file.

ParameterTypeDescription
pack_keystringPack containing table
pathstringInternal table path
deststringFilesystem output path
sourceDataSourceData source

Response: "Success"

ImportTSV

Import a TSV file as a table.

ParameterTypeDescription
pack_keystringTarget pack
pathstringInternal destination path
tsv_pathstringFilesystem TSV path

Response: { RFileDecoded: RFileDecoded }


External Program Commands

OpenContainingFolder

Open the folder containing a specific open Pack in the file manager.

ParameterTypeDescription
pack_keystringPack whose folder to open

Response: "Success"

OpenPackedFileInExternalProgram

Open a packed file in an external program.

ParameterTypeDescription
pack_keystringPack containing file
sourceDataSourceData source
pathContainerPathFile path

Response: { PathBuf: string } — extracted temporary path.

SavePackedFileFromExternalView

Save a packed file that was edited in an external program.

ParameterTypeDescription
pack_keystringTarget pack
pathstringInternal path
ext_pathstringExternal file path

Response: "Success"


Diagnostics Commands

DiagnosticsCheck

Run a full diagnostics check over the open packs.

ParameterTypeDescription
pack_keysstring[]Pack keys to check
check_akbooleanCheck AssKit-only references

Response: { Diagnostics: Diagnostics }

DiagnosticsUpdate

Run a partial diagnostics update on specific paths.

ParameterTypeDescription
diagnosticsDiagnosticsExisting diagnostics state
pathsContainerPath[]Paths to re-check
check_akbooleanCheck AssKit-only references

Response: { Diagnostics: Diagnostics }

AddLineToPackIgnoredDiagnostics

Add a line to a specific pack’s ignored diagnostics list.

ParameterTypeDescription
pack_keystringPack to modify
linestringDiagnostic key to ignore

Response: "Success"


Pack Settings Commands

GetPackSettings

Get the settings of a specific open Pack.

ParameterTypeDescription
pack_keystringPack to query

Response: { PackSettings: PackSettings }

SetPackSettings

Set the settings of a specific open Pack.

ParameterTypeDescription
pack_keystringPack to modify
settingsPackSettingsNew settings

Response: "Success"


Notes Commands

NotesForPath

Get all notes under a given path in a specific pack.

ParameterTypeDescription
pack_keystringPack to query
pathstringPath prefix

Response: { VecNote: Note[] }

AddNote

Add a note to a specific pack.

ParameterTypeDescription
pack_keystringTarget pack
noteNoteNote to add

Response: { Note: Note }

DeleteNote

Delete a note from a specific pack.

ParameterTypeDescription
pack_keystringPack to modify
pathstringNote path
note_idnumberNote ID

Response: "Success"


Schema Patch Commands

SaveLocalSchemaPatch

Save local schema patches to disk.

ParameterTypeDescription
patchesRecord<string, DefinitionPatch>Table name to patches

Response: "Success"

RemoveLocalSchemaPatchesForTable

Remove all local schema patches for a table.

ParameterTypeDescription
table_namestringTable name

Response: "Success"

RemoveLocalSchemaPatchesForTableAndField

Remove local schema patches for a specific field in a table.

ParameterTypeDescription
table_namestringTable name
field_namestringField name

Response: "Success"

ImportSchemaPatch

Import schema patches into local patches.

ParameterTypeDescription
patchesRecord<string, DefinitionPatch>Table name to patches

Response: "Success"


Loc Generation Commands

GenerateMissingLocData

Generate all missing loc entries for a specific open Pack.

ParameterTypeDescription
pack_keystringPack to generate for

Response: { VecContainerPath: ContainerPath[] }


Update Commands

CheckUpdates

Check if there is an RPFM update available.

Response: { APIResponse: APIResponse }

CheckSchemaUpdates

Check if there is a schema update available.

Response: { APIResponseGit: GitResponse }

UpdateSchemas

Download and apply schema updates.

Response: "Success"

UpdateMainProgram

Update RPFM to the latest version.

Response: "Success"

CheckLuaAutogenUpdates

Check for updates on the tw_autogen repository.

Response: { APIResponseGit: GitResponse }

UpdateLuaAutogen

Update the tw_autogen repository.

Response: "Success"

CheckEmpireAndNapoleonAKUpdates

Check for updates on the old Assembly Kit files repository.

Response: { APIResponseGit: GitResponse }

UpdateEmpireAndNapoleonAK

Update the old Assembly Kit files repository.

Response: "Success"

CheckTranslationsUpdates

Check for translation updates.

Response: { APIResponseGit: GitResponse }

UpdateTranslations

Update the translations repository.

Response: "Success"


MyMod Commands

InitializeMyModFolder

Initialize a MyMod folder structure.

ParameterTypeDescription
mod_namestringName of the mod
game_keystringTarget game
sublimebooleanCreate Sublime Text project
vscodebooleanCreate VS Code project
gitignorestring or nullGitignore content (null = no git)

Response: { PathBuf: string } — path to the new pack.

LiveExport

Live-export a specific Pack to the game’s data folder.

ParameterTypeDescription
pack_keystringPack to export

Response: "Success"


Translation Commands

GetPackTranslation

Get pack translation data for a language from a specific pack.

ParameterTypeDescription
pack_keystringPack to query
languagestringLanguage code

Response: { PackTranslation: PackTranslation }


Starpos Commands

BuildStarpos

Build starpos (pre-processing step) for a specific pack.

ParameterTypeDescription
pack_keystringTarget pack
campaign_idstringCampaign identifier
process_hlp_spdbooleanProcess HLP/SPD data

Response: "Success"

BuildStarposPost

Build starpos (post-processing step) for a specific pack.

ParameterTypeDescription
pack_keystringTarget pack
campaign_idstringCampaign identifier
process_hlp_spdbooleanProcess HLP/SPD data

Response: { VecContainerPath: ContainerPath[] }

BuildStarposCleanup

Clean up starpos temporary files for a specific pack.

ParameterTypeDescription
pack_keystringTarget pack
campaign_idstringCampaign identifier
process_hlp_spdbooleanProcess HLP/SPD data

Response: "Success"

BuildStarposGetCampaingIds

Get campaign IDs available for starpos building from a specific pack.

ParameterTypeDescription
pack_keystringPack to query

Response: { HashSetString: string[] }

BuildStarposCheckVictoryConditions

Check if victory conditions file exists in a specific pack.

ParameterTypeDescription
pack_keystringPack to check

Response: "Success"


Animation Commands

UpdateAnimIds

Update animation IDs with an offset in a specific pack.

ParameterTypeDescription
pack_keystringPack to modify
starting_idnumberStarting ID
offsetnumberID offset

Response: { VecContainerPath: ContainerPath[] }

GetAnimPathsBySkeletonName

Get animation paths by skeleton name.

ParameterTypeDescription
skeleton_namestringSkeleton name

Response: { HashSetString: string[] }


Table Commands

GetTablesFromDependencies

Get tables from dependencies by table name.

ParameterTypeDescription
table_namestringTable to query

Response: { VecRFile: RFile[] }

GetTablesByTableName

Get table paths by table name from a specific Pack.

ParameterTypeDescription
pack_keystringPack to query
table_namestringTable name

Response: { VecString: string[] }

AddKeysToKeyDeletes

Add keys to the key_deletes table in a specific pack.

ParameterTypeDescription
pack_keystringTarget pack
table_file_namestringTable file name
key_table_namestringKey table name
keysstring[]Keys to add

Response: { OptionContainerPath: ContainerPath | null }


Map Packing Commands

PackMap

Pack map tiles into a specific Pack.

ParameterTypeDescription
pack_keystringTarget pack
tile_mapsstring[]Tile map paths
tiles[string, string][][tile_path, tile_name] pairs

Response: { VecContainerPathVecContainerPath: [ContainerPath[], ContainerPath[]] } — added and deleted paths.


3D Export Commands

ExportRigidToGltf

Export a RigidModel to glTF format.

ParameterTypeDescription
modelRigidModelModel to export
output_pathstringOutput file path

Response: "Success"


Settings Commands

Settings Getters

All settings getters take a single key string parameter and return the value in a typed wrapper:

CommandResponse Type
SettingsGetBool{ Bool: boolean }
SettingsGetI32{ I32: number }
SettingsGetF32{ F32: number }
SettingsGetString{ String: string }
SettingsGetPathBuf{ PathBuf: string }
SettingsGetVecString{ VecString: string[] }
SettingsGetVecRaw{ VecU8: number[] }
{ "id": 1, "data": { "SettingsGetString": "game_selected" } }

SettingsGetAll

Get all settings at once (batch loading). Much more efficient than individual calls.

Response: { SettingsAll: [Record<string, boolean>, Record<string, number>, Record<string, number>, Record<string, string>] } — bool, i32, f32, and string settings.

{ "id": 1, "data": "SettingsGetAll" }

Settings Setters

All settings setters take a [key, value] tuple and return "Success":

CommandValue Type
SettingsSetBoolboolean
SettingsSetI32number
SettingsSetF32number
SettingsSetStringstring
SettingsSetPathBufstring
SettingsSetVecStringstring[]
SettingsSetVecRawnumber[]
{ "id": 1, "data": { "SettingsSetString": ["game_selected", "warhammer_3"] } }

SettingsClearPath

Clear a specific config path entry.

ParameterTypeDescription
pathstringPath to clear

Response: "Success"


Path Commands

These commands return filesystem paths used by RPFM. All respond with { PathBuf: string }:

CommandDescription
ConfigPathConfig directory path
AssemblyKitPathAssembly Kit path for current game
BackupAutosavePathBackup autosave directory
OldAkDataPathOld AK data directory
SchemasPathSchemas directory
TableProfilesPathTable profiles directory
TranslationsLocalPathTranslations local directory
DependenciesCachePathDependencies cache directory
{ "id": 1, "data": "SchemasPath" }

Settings Backup Commands

BackupSettings

Backup current settings to memory (for restore on cancel).

Response: "Success"

ClearSettings

Clear all settings and reset to defaults.

Response: "Success"

RestoreBackupSettings

Restore settings from the in-memory backup.

Response: "Success"

OptimizerOptions

Get the optimizer options configuration.

Response: { OptimizerOptions: OptimizerOptions }


Debug Commands

GetMissingDefinitions

Export missing table definitions from a specific pack to a file (for debugging/development).

ParameterTypeDescription
pack_keystringPack to export from

Response: "Success"


Autosave Commands

TriggerBackupAutosave

Trigger an autosave backup of a specific Pack.

ParameterTypeDescription
pack_keystringPack to back up

Response: "Success"