Assuming you have a way to trigger it, you can use @ogiewon 's code to Post to /hub/shutdown to port 8080