Ironed out a bugs and made lock and unlock work with the new api.  Bot shouldn't be any buggier than the browser bot was before...