Move proxy responsibility solely to middleware