Skip to content
This repository has been archived by the owner on Jul 19, 2024. It is now read-only.

Matter Center Web API Documentation

Amitabh Mukherjee edited this page Mar 18, 2016 · 3 revisions

Matter Center new design document for service layer

The current Matter Center code (both UI and Web Services) will be re-factored using latest technologies and the new re-factored code will be designed in such a way that it is extensible for future business requirements. The current service code of Matter Center has been written using WCF and this will be re-factored using the ASP.NET WEB API framework. This document will cover the changes that are getting incorporated into this new re-factored code. The below image depicts the new architecture for the re-factored code.

Azure Active Directory (AAD)

  1. Matter Center application will leverage Azure Active Directory for authentication purposes.

  2. Matter Center service application will be created in Azure

  3. The Matter Center service application will be registered inside Azure Active Directory and proper permissions will be configured for the Matter Center service application to access “SharePoint Online” The following screenshot shows how to configure Matter Center service application to access “SharePoint Online”

  4. In the above image, Matter Center service application has been configured to have full control for all site collections

  5. The same process will be applied for the Matter Center UI application. The Matter Center UI will be configured to access Matter Center service application in the Azure Active Directory instead of SharePoint Online.

Security

As shown in the above image, the new authentication is based on Azure Active Directory (AAD).

  1. When the user makes any request to the Matter Center service application from Matter Center UI, the user will be authenticated using AAD.
  2. The AAD will send JWT authentication token (Bearer Token) to the UI and the UI will send that authentication token to the WEB API for each and every request.
  3. The Web API will use the JWT authentication token to make calls to SharePoint online.
  4. The Matter Center UI will be re-developed using AngularJS and adal.js and adal.angular.js libraries will be used for authenticating the users against AAD.

Web API

The new Web API will expose well defined end points for each Matter Center functionality that can be called from the front end applications, provided the front end application provides proper authentication token which the SharePoint application accepts

  1. https://serviceurl/api/matter
  2. https://serviceurl/api/document
  3. https://serviceurl/api/taxonomy
  4. https://serviceurl/api/user
  5. https://serviceurl/api/ondrive
  6. https://serviceurl/api/config
  7. https://serviceurl/api/shared

#Business Layer The Web Api service layer will internally call the business layer where the actual business logic related to each api will be implemented The business layer internally calls the data layer for persistence. #Models The models contain entities which are Data Transfer Objects (DTO’s) which contains properties (getters and setters) which will be used to transfer the data from the UI->Service->Business->Data Layer #Data layer The data layer consists of method which will make the actual call to SharePoint API for data persistence and for data retrieval.