azure mobile services - How to get user information when authenticating with OneDrive SDK -


i building azure app service has both windows desktop (not uwp) , ios clients. want use microsoft account authentication authenticate users.

as result of previous question here can authenticate users using onedrive sdk have fallen @ next hurdle. 1 drive sdk not appear provide access user details such given name , email address.

please can point me in direction of example or instructions authenticating user old school desktop application allow them access azure app service using microsoft account (not azure ad) provide client access email address , not use depreciated technology.

after authentication via easy auth, can acquire user information me endpoint(https://{yoursitename}/.auth/me) invoking api code below:

var result =await client.invokeapiasync("/.auth/me"); 

and acquire email, need wl.emails scope when authenticate onedrive sdk. , after can given-name , emails me endpoint like:

string email=(string)result[0].selecttoken("$.user_claims[?(@.typ == 'http://schemas.xmlsoap.org/ws/2005/05/identity/claims/emailaddress')]")["val"]  string givenname=(string)result[0].selecttoken("$.user_claims[?(@.typ == 'http://schemas.xmlsoap.org/ws/2005/05/identity/claims/givenname')]")["val"] 

Comments

Popular posts from this blog

resizing Telegram inline keyboard -

command line - How can a Python program background itself? -

php - "cURL error 28: Resolving timed out" on Wordpress on Azure App Service on Linux -