Added RESTful interface, needs work on the examples