refactor python interface
refactor rest class
remove javascript method