I found no direct documentation but got some information from the method documentation of the NextProcess class method in %SYS.ProcessQuery:

https://docs.intersystems.com/iris20243/csp/documatic/%25CSP.Documatic.c...

So, it seems passing an argument works like $order on the list of running processes with the caveat a halted process is treated like $zjob("") and returns the first process id in the list. I think this will do the trick, thanks Alice!

It sounds like what you want is to use XMLNIL. This will export null object Properties as  xsi:nil="true". Then on import the default behavior is to set such a valued Property to be a new instance of that object with no Properties set. See Handling Empty Strings and Null Values | Projecting Objects to XML | InterSystems IRIS Data Platform 2024.3
for more information.

One way I can think of is to get the name of each config item that is enabled via an SQL query such as:
SELECT Name, ClassName FROM Ens_Config.Item WHERE Production = '<production name>' and Enabled = 1

Then for each of these call ##class(Ens.Director).EnableConfigItem("<production name>||<config item name>|<config item class name>", 0)

I am not sure of any method to do it all at once.

I really enjoy taking things apart and breaking them down into basic components to see how they work. I found it useful to insert break statements in a confusing piece of code and run it from terminal (can also use the ObjectScript debugger from VS Code with breakpoints). Then I could write out the values at each break and reverse-engineer what the command/method must do. I also really enjoy the ability to drill down into the code and read the definition of a method. If you are curious how any method works you can just Ctrl+Click from VS Code to go to that method's definition(Ctrl+Shift+G from Studio).

If this was tied to your Windows password and you recently changed it then you may need to change the credentials for the service.

Try searching for "Services" in the windows search box and open the app. Then find the service associated with this instance (I think it would be InterSystems IRIS Controller for LATEST) and open properties and go to log on tab. Change the credentials here to match your OS credentials and then try starting your instance. Hope that helps!