We have a service we host ourselves (on Azure) that accesses Office 365 via CSOM. We'd like to access a user's site on their behalf without previously installing an app on their site collection.

Is this possible using OAuth, or by any means that doesn't require asking for the user's login details?

3 Answers 3


Having learned a fair bit about OAuth in Office 365 since I posted the question, I can now answer myself:

No, you cannot use OAuth without an app.

However, in on-premise solutions you can set up a High Trust server to communicate without having to use OAuth at all.


I think this answers your question.

MSDN - Tips and FAQs: OAuth and remote apps for SharePoint 2013

Get tips and answers to some FAQs for a app for SharePoint that runs in a remote web application and communicates back to SharePoint 2013.

  • The first FAQ on that page is how to retrieve app registration information, so I'm guessing it covers registered apps.
    – Stu Pegg
    Jul 31, 2013 at 10:59

It can be done (I just finished doing it, it works fine) -

You can read about in more detail in my blog here - https://medium.com/@yash_agarwal2/performing-oauth-and-rest-calls-with-sharepoint-online-without-creating-an-add-in-677e15c8d6ab#.6pf4wp83b

High level overview -

1) Get client id and secret by registering yourself here - https://sellerdashboard.microsoft.com/Registration

2) Then follow this link - https://msdn.microsoft.com/en-us/library/office/jj687470.aspx (This has a step by step process on how to do this at the end of the article, you will need client id and secret from first step)

More information here -

https://msdn.microsoft.com/en-us/library/office/dn790707.aspx#Flows (search for authentication code flow)



Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.