Restful api engine with sinatra