Skip to content

Instantly share code, notes, and snippets.

@sedouard
Last active August 29, 2015 14:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sedouard/4362b0e809cee4fa4669 to your computer and use it in GitHub Desktop.
Save sedouard/4362b0e809cee4fa4669 to your computer and use it in GitHub Desktop.
Example of oauth AndContinue for Windows Phone 8.1 (javascript)
try{
//Windows 8/8.1
Windows.Security.Authentication.Web.WebAuthenticationBroker
.authenticateAsync(Windows.Security.Authentication.Web.WebAuthenticationOptions.default, startURI, endURI)
.then(function(result){
console.log('handle your provider specific token inside ' + result.responseData);
}, function(error){
console.error(error);
});
}
catch(err)
{
//Windows Phone 8.1 will throw a Not Implemented exception when you call authenticateAsync. Use authenticateAndContinue instead
//continuation is handled in the acivation handler
Windows.Security.Authentication.Web.WebAuthenticationBroker.authenticateAndContinue(startURI, endURI);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment