Refactor OAuth XHR post flows (gaye)