add json handler and test
refactoring
update README