0

In our project we need to download some data from Add-in Web. And it brings some problems.

For example, user have to be logged in on both domains. If user is logged in on your website http://mywebsite.sharepoint.com and there is a REST call to http://mywebsite-e72bc262fda58e.sharepoint.com/YourAddInName/_api/web/lists made by JS, this call will get 302 response with redirect to login page. So user must open http://mywebsite-e72bc262fda58e.sharepoint.com/YourAddInName/ first, complete the authentication and only after that you can use REST calls to http://mywebsite-e72bc262fda58e.sharepoint.com/YourAddInName from Host Web.

To workaround this problem we send REST request to Add-in Web using same domain: http://mywebsite.sharepoint.com/YourAddInName/_api/web/lists It works well, but the question we have - how reliable is this way? Is it something officially declared or it may change any moment?

  • 1
    Good question. Got her looking for information like this, In my case, because I have two developers: UI and "SpDataServices" in a TSVC. They have to work in splitted repositories due to SPO testing landscape, So I have one UI add-in and a Angular $emit scopes dataservice, so UI must consume data from Angular.... – egidiocs Mar 22 '16 at 1:47
  • @egidiocs If you like this question you can vote it up, maybe it will receive more attention then. – Serhiy Mar 22 '16 at 6:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.