cleaned up api and handler logic
tag 0.0.4