You can use the command
sudo systemctl poweroff
Don't need to use sudo if running as a root. You can also specify reboot instead of poweroff
What is the right syntax to use a linux command from within a sketch that is in intel xdk (node.js)?
If you are using Node.js, the best way to use a system command (like poweroff, which is used to shut down the board) is to use Child Process. I suggest you to read Node's manual section for Child Process, there you should be able to get more information about how to achieve this.
Let me know if this information helps you.
I did end up getting the Intel Edison through using a Child Process.
Thanks for the help!
That's great to hear, I'm glad it's working. If you ever have any other doubts, please don't hesitate to come back to the community.