implemented RESTful routing in /lights