examples/authorize: Remove useless imports/dependencies; write auth JSON to proper stream.