Changed app to use bottle's json request handling.