Connecting to Azure from SPFX in team - azure

I have followed this post to connect a spfx WebPart to Azure and it's working and it can get data from Azure.
Then I followed this post to get my spfx run in the MS Team. The issue is the web part can only connect when it's running in the sharepoint web page or team web page but can not connect to Azure when it's in the Team mobile app or SharePoint app.
The code is available here

Related

sharepoint add-in multi site installation

developing a provider hosted application where the application redirects to different pages of a web application hosted on an azure web site.
This web site also handles the app installed event.
The problem is that in the web.config of the site, we need to add a client ID and Password, but these (Client ID/Password) are automatically generated by the SharePoint Online app registration page, after we register the application on the SharePoint online site.
So if we install the app on this SPOnline Site , it works fine, but if we try to install it on another site, when it redirects to the azure web site page, we got an authentication error.
need to add a unique client ID and password to the azure web site so when the SharePoint app in being installed on any Client ‘s SharePoint site can be identified as safe, authenticated and well-functioning with the azure site.
In the current process, we have to create an azure web site for each SharePoint Site where the application is being installed
How is this done with SharePoint plugins? Does the provider have to generate the Id and secret on each SharePoint Site.
In the SharePoint web provider project code , I found something called HostedAppSigningKey and HostedAppName , but did not find any tutorial about that. Can these be used for a solution?
To support multiple environments you should generate a id/secret from the Microsoft Seller Dashboard (even if you don't plan to sell your add-in) and use one set for all the environments. You should not use the appregnew page.

How do I setup SharePoint 2013 (On Premise) for third party apps?

I have created a provider-hosted app which was developed and tested against SharePoint Online. I now want to install this on SharePoint 2013 On Premise.
It is my intention that, despite being a provider hosted app, I wish to host the app web in IIS on the SharePoint server (single farm not a cluster). I then intend to use a local URL for my App Web URL.
I understand the process of setting up an App Catalog (On SharePoint Online) as a repository for my App which in turn will enable users to add it to a site.
I have only been able to find a guide to setup On Premise SharePoint to allow users to use the SharePoint store but I only want to set it up for third party apps.
My question is do I need to go through all the steps in this link https://technet.microsoft.com/en-gb/library/fp161236.aspx even if I don't want/require store access? I don't not want to do more than necessary and I would prefer a simple solution for my clients.
I followed this guide https://technet.microsoft.com/en-gb/library/fp161234.aspx in the hope that creating the app catalog would be sufficient but I get the error "Sorry, apps are turned off. If you know who runs the server, tell them to enable apps."

Office 365 Provider Hosted app Deployment in Azure

I deployed Office 365 app into azure.. and it is working fine when i deploy with F5 in visual studio..
But the problem is that i am not able to visit app directly with link http://xyz.azurewebsites.net/ because it is a SharePoint app it requires {StandardTokens}.
I tried this but no luck..
When developing a provider hosted app in SharePoint, you need to access the app through SP, so your code will get the authentication token and execute all your code to retrieve data from SP through the API. You do not need to access the app through the URL. this is not the intent of provider hosted app. The provider hosted app gives you the flexibility to host your app outside the SP farm (which is in your case in Azure) and integrate properly with Azure AD for exchanging required token to develop against the SP API.
Check out this link that gives a step of step walkthrough for working with provider hosted apps: https://msdn.microsoft.com/en-us/library/office/fp142381.aspx
Hope this helps.

Create a DNN 7module with SharePoint 2013

I want to know if there are any projects that use DNN 7 to interact with SharePoint 2013. The SharePoint 2013 is a Provider hosted. For the setup, DNN would be installed on the same server as the App server and SharePoint 2013 on a separate server. Normally, I would create a SharePoint app that would be installed on the App server. I want to do the same using DNN as the framework with the module as the SharePoint App. Is this possible? I would assume so since SP2013 uses client model. Should I create the SharePoint App project and included it in my DNN project?
Thanks in advance.
You can embed SharePoint apps in DotNetNuke by making use of a html module that embeds your app in an iframe element. But since your apps can be hosted on any web hosting stack, you can even probably create a DotNetNuke module that is a Sharepoint app.
You will have to register your app with Azure ACS and with the App Management Service of the SharePoint farm or SharePoint Online tenancy, to be able to establish communication.
Then, to access Sharepoint, you will have to pass an access token in each HTTP request that you can obtain from Microsoft Azure Access Control Service.
More info here.

Provider-hosted apps and Atohosted apps for Office 365?

Can you use a Provider-hosted apps and an Autohosted apps for Office 365? How? You write server side code in them, so how can they work with Online?
You can use provider hosted apps and autohosted apps with SharePoint Online. They work because your server side code is not hosted on SharePoint - in case of Autohosted apps your code is hosted on Azure web site, in case of provider hosted some provider hosts it. So basically in your SharePoint site you have "link" wrapped in app package which points to external web site. External web site can use some features of SharePoint (for example get its data or use chrome control).

Resources