Simplify the OAuth RP API to use promises. Tease out common code from fx-desktop and iframe channels into the postmessage_receiver channel.