http API: clean up var names