batch – Is it possible to insert a system command into a runOnce registry key/value?

For context, I have a script that runs a procedure, then reboots the computer, after reboot one directory needs to be recursively removed.

Is this possible to do by using a “built-in” Windows 10 command, by calling directly or inline, as a registry value in runOnce registry key pair?