First OAuth API stuff, needs more testing.