With webhooks, SharePoint has a new notification capability that makes it easier for developers to respond and react to content updates in SharePoint, within their organization. With these notifications, developers can build their own document processing steps or downstream communications.
Since Microsoft last announced SharePoint Webhooks in Developer Preview in September, they worked to improve their Webhooks service and infrastructure – but the APIs and calling patterns remain fundamentally the same. Microsoft now announces that SharePoint Webhooks are Generally Available, meaning that developers can use webhooks within SharePoint sites in multitenant Office 365, and run their own webhook-consuming applications and services in production.
For developers, webhooks are based on a defacto-standard around notifications between web services, and wherever possible Microsoft has patterned SharePoint webhooks to feel consistent with webhooks they may have used them elsewhere. Webhooks also respect the security permissions present in a SharePoint tenancy, ensuring that administrators have full control of their content. Developers can find an end-to-end overview of and getting started with webhooks via the documentation.
More specifically, within SharePoint Online in Office 365, many item or document events can be tracked using webhooks. Developers can call a simple REST-based APIs to register their webhook with SharePoint, signing up for one or more actions in SharePoint such as ItemAdded, ItemUpdated, ItemDeleted and more. As changes happen in SharePoint, calls are made to the developers’ service, and they can then react to those changes with code. Webhooks also work well with services built using recently-released Azure technologies, such as Azure Functions. All told, with the webhooks/Azure Functions combination, it’s never been simpler to set up a lightweight service that reacts to changes in SharePoint.
In future updates, Microsoft is expecting to continue to expand the set of behaviors one can hook into within SharePoint, using Webhooks as the underlying technology.
Building processes in an organization frequently starts or ends when users update a document or change its properties (e.g., marking a document as approved), so strong notification mechanisms — webhooks — for developers are key to robust support for processes and end-user notifications.