I am having an issue where nothing is put into the custom variables. Through trial and error running the commands in Powershell, I see that the commands that run CLI.exe give an error "Missing Pulseway execution cookie". I'm assuming there's something I'm missing? I was able to produce this error by adding -NoNewWindow to the end of the CLI.exe statements, otherwise it wouldn't report the error.
Ex. Start-Process -FilePath "C:\Program Files\Pulseway\CLI.exe" -ArgumentList ("setVariable recoverykey ""$recoverykey""") -Wait -NoNewWindow
So I figured out what caused this error, I have the Powershell User Impersonation enabled to a domain account. When I unchecked that box, everything worked.