See mineflayer
sudo npm install -g archerbot
archerbot
You can optionally pass in --host
and --port
if you are connecting to a
server other than localhost, and you can pass in --username
and --password
if you are connecting to a server that is in online mode.