Doing any Panel operations from the command line is quite a trick. It’s been done, but it doesn’t seem very popular or easy to do.
I’m not even sure that parking a domain retains the original domain’s data should you want to go back. It’d be easier to write a script that renames your directory from “mydomain.com” to “mydomain.sav” and then rename a “mydomain.park” to “mydomain.com” and put your Parked page in the mydomain.park directory.
Out of curiosity, why do you want to do this?