Junos Space 14.x and higher already have the functionality to shutdown or reboot multiple devices at a scheduled time.
From within the Device Management view, select the devices that you wish to schedule, then select Actions | Device Operations | Reboot Devices
In the dialog box displayed, expand the "options" and select the checkbox "Power off", optionally enter an appropriate message, then select "Schedule at a later time" and select the appropriate time for the task to be executed.
http://www.juniper.net/techpubs/en_US/junos-space15.1/platform/topics/task/operational/devices-rebooting.html
You could still go the SLAX route and avoid having to deploy a script on each device, as you can have SLAX scripts executed locally on Junos Space and they can then go and "talk to" the selected devices. This is an approach that I had used prior to the current reboot/power-off functionality being added. I still have some scripts that are being used for multi-re chassis (MX960 etc) where a user might want to just reboot one of the RE's rather than both etc.
Of course there are a multitude of different approaches for off-box scripts Python/PyEz/SpaceEz/Ansible/Perl/Ruby etc. etc.
Regards,
Andy