Solution
The easiest way to do this is with the the Offline Mode API Tool located here: C:\Program Files (x86)\National Instruments\Shared\OfflineMode\NationalInstruments.Semiconductor.OfflineModeAPITool.exe
You can call this tool from the command line and pass either of the following arguments:
For example, to use the offline config file from the Accelerometer example, the call would look like this: .\NationalInstruments.Semiconductor.OfflineModeAPITool.exe /enter "C:\Users\Public\Documents\National Instruments\TestStand 2021 (64-bit)\Examples\NI_SemiconductorModule\Accelerometer\LabVIEW\OfflineModeSystemConfigurationForAccelerometerExample.offlinecfg"
Note that the /leave option does not require a path to an offline config file.
To automate this from TestStand, the Call Executable step type is the right approach. That step type is effectively the same as using a command prompt, and there is a way to pass command line arguments to the executable.