add Sinatra and client-server logic