oauth - Oauth2.0 authentication Google Adsense -


i trying authenticate using oauth2. earlier implementations using oauth2draft10 since deprecated now, wanted move oauth2.0 http://www.proksi.us/browse.php?u=oi8vy29kzs5nb29nbguuy29tl3avz29vz2xllwfwas1qyxzhlwnsawvudc93awtpl09bdxromg%3d%3d&b=143

mine installed application , following http://www.proksi.us/browse.php?u=oi8vy29kzs5nb29nbguuy29tl3avz29vz2xllwfwas1qyxzhlwnsawvudc93awtpl09bdxromg%3d%3d&b=143#installed_applications

but facing problem while calling authorize() method here, not through verificationcodereceiver.

any or guide can through wrong or missing..?

resolved ..:)

no need verificationcodereceiver.

 public static credential authorize() throws exception {         // load client secrets         googleclientsecrets clientsecrets = googleclientsecrets.load(             json_factory, adsensesample.class.getresourceasstream("/client_secrets.json"));           // set file credential store         file jsonfile = new file("/adsense.json");           filecredentialstore credentialstore = new filecredentialstore(jsonfile, json_factory);          // set authorization code flow         googleauthorizationcodeflow flow = new googleauthorizationcodeflow.builder(             http_transport, json_factory, clientsecrets,             collections.singleton(adsensescopes.adsense_readonly)).setcredentialstore(             credentialstore).build();         // authorize         return new authorizationcodeinstalledapp(flow, new localserverreceiver()).authorize("user");       } 

thanks..:)


Comments

Popular posts from this blog

get url and add instance to a model with prefilled foreign key :django admin -

css - Make div keyboard-scrollable in jQuery Mobile? -

android - Keyboard hides my half of edit-text and button below it even in scroll view -