Creating Provider-Hosted App in Office 365 and Azure Using VS 2013: Part 3

In my previous article Creating Provider-Hosted App in Office 365 and Azure Using VS 2013: Part 2 you saw how to do the following procedure:

  1. Publish the web to Microsoft Azure Websites
  2. Register the App in Office 365
  3. Configure the app settings for Azure Website

In this article you will perform the following procedure:

  1. Publish the app.
  2. Upload the app file to the app catalog in Office 365.
  3. Add the app to the Office 365 site.

Publish the app

  1. In the Solution Explorer, expand MyFirstProvidedHostedApp and then right-click on AppManifest.xml. Click on View Code.



  2. AppManifest.xml will have the following metadata.



  3. Replace ~remoteAppUrl/ with the Azure website URL https://myfirstprovidedhostedapp.azurewebsites.net/ and replace ClientId with the Id that we generated previously. Ensure that the Azure Website URL has https.



  4. Save the AppManifest.xml file. In the Solution Explorer, right-click on the app project and then click on Publish.



  5. Click on the Package the app button.



  6. Enter the Azure website URL (https://myfirstprovidedhostedapp.azurewebsites.net/) and the client Id as shown below. Ensure the URL has https.



  7. Click on the Finish button.
  8. The folder that contains the app file will be opened.


Upload the app file to the app catalog in Office 365

  1. Log into the O365 App Catalog as an administrator (example: https://c986.sharepoint.com/sites/AppCatalog/).
  2. Click on the Apps for SharePoint link in the Quick Launch bar.



  3. Upload the app file.


Add the app to the Office 365 site
  1. Log into the O365 developer site as an administrator (example: https://c986.sharepoint.com/).
  2. Click on Site Contents in the Quick Launch bar.



  3. Click on add an app.



  4. Click on the From Your Organization link in the Quick Launch bar and you will be able to see the provider-hosted app that we created. Click on MyFirstProvidedHostedApp.



  5. Click on the Trust it button.



  6. The app will be installed successfully as shown below.



  7. Click on the app and it will be redirected to the Azure website as shown below.


Summary

Thus in this article series you saw how to create a Provider-Hosted app in Office 365 and Azure using Visual Studio 2013.

Reference

https://github.com/OfficeDev/TrainingContent/blob/master/O3651/O3651-7%20Setting%20up%20your%20Developer%20environment%20in%20Office%20365/Lab.md


Similar Articles