Showing posts with label webhook. Show all posts
Showing posts with label webhook. Show all posts

Tuesday 18 February 2020

Retrieve Office365 People data on MS Team Channels via Outgoing Webhook and Azure App Service

Here, let us see how office 365 people information can be integrated into Microsoft Teams, with the help of outgoing webhooks on Teams. The use case is to pull the people present at a location, on posting a message to a service from Microsoft Teams.  

This could be easily achieved with the help of outgoing webhook feature under teams. The webhook has to interact with a service to get data processed based on data posted. 

Why Outgoing Webhook?: The outgoing webhook is used here instead of incoming webhook, since the data needs to be retrieved only when it is required.

No BOT Framework, only Azure App Service: This article helps us to understand creating outgoing webhook services for Microsoft Teams, without creating BOT service/app. Here the intent of service is clear, so we are not leveraging the BOT framework, instead hosting a simple service with Azure web app. From azure web app, the people data is being pulled from Azure AD with the help of Microsoft Graph API.


Create an outgoing webhook for a Microsoft Team 


Locate a team under Microsoft Teams, and navigate to manage team. Under App, in the bottom right corner, you will find an outgoing webhook link. From the link, create a webhook.  

Outgoing Webhook creation on Teams
Outgoing Webhook creation on Teams

Friday 16 March 2018

Building SharePoint Webhook Services with Serverless Architecture

Before looking out at the implementation of webhook models in SharePoint, here let us look at how Serverless web hooks concept can be feasible.

What is Serverless architecture? It allows us to build the required services, without the need of servers. Some Azure services like Azure functions helps building such Serverless models.

The components like webhook service, storage queues, web jobs and SQL database are hosted on Azure. The following picture depicts the Serverless webhooks process, with the help of Serverless components. The components present on the Azure box, depicts serverless architecture model.

Serverless Architecture for SharePoint Webhook Services
Serverless Architecture for SharePoint Webhook Services

Saturday 10 March 2018

Processing Events from SharePoint Webhook Services

Let us theoretically look how the event changes are retrieved from the storage queues, processed and stored on to the logs like SharePoint history lists.

In the previous post, you have seen how to subscribe to the event changes on SharePoint online and how the events are stored on the storage queue. Here, you could see how the events stored can be processed.

Process Data from the Queue - Web Jobs


If we closely look in the previous post, SharePoint service has sent few details to the notification service when the event change had happened on SharePoint. In the details, you can only see what has changed at high level. That is, which list has changes. It doesn’t define, what are the changes.
Event Change Details
Event Change Details

Wednesday 7 March 2018

Working with SharePoint Events using Webhooks

Introduction


In this post, let us look in detail on webhooks functionality. At a high level, there are two independent steps to work with Webhooks.
  • Subscribing to the SharePoint events (remote events)
  • Processing Events.
Note: In the recent SharePoint Saturday Event at Chennai, I have explored on using Serverless Webhooks. For the benefits of larger audience, I am writing down as a technical post in detail with explanations.

Subscribing to the SharePoint Events


SharePoint by default provides the subscription mechanism for event changes. For now, only item level changes can be tracked, that on SharePoint online platform.

Tuesday 6 February 2018

Introduction to SharePoint Webhooks

What is Webhook?


Web hook is a general concept for http based events, which will provide remote event mechanisms.

Say for example, you have a built a custom application separately which has some specific product related content. Whenever there is a data change on the product repository, your data on the custom application should also be updated. For this scenario, will you be keep on checking the product repository for the changes? The answer should be No. Instead of your application keep on poll the product for changes, product should notify or push the changes to your application.

What is SharePoint Webhook?


Previously for working with event based processes, we were using the server side event receivers and remote events receivers. Such processes can be replaced with the webhooks.

Tuesday 14 November 2017

Using Webhooks for Posting SharePoint Items into MS Teams with Flows

In my previous post, you would have seen posting the items into Microsoft Teams Channels as conversations using Microsoft Flows. The respective channels will be chosen by selecting the Teams service in the flow configurations.

In this post, let us try to achieve similar kind of functionality, but with a little different approach. As we are all aware that Microsoft Teams will support incoming webhook requests, let us try configuring the webhook URLs.


Webhook:


What is webhook? The external system which posts messages whenever data is available using the endpoint APIs.


How the webhook will help in Microsoft Teams? Take for an example, you are using Teams as a collaboration platform. You need to post data from multiple systems to the team channels for better collaboration. The webhook URL can be generated for a channel and can be shared with other external systems. Whenever the external system has the data for posting, the data will be sent to the teams using the API generated.