I wanted to create a working environment with the on-premises data gateway in combination with SharePoint 2019. The scenario I configured is a simple one as it only sends a mail when a new item has been added to a library in my SharePoint 2019 farm. This scenario would present more possibilities for customers who are using SharePoint on-premises and are looking for a Workflow or PowerApp solution without having to use for example SharePoint Designer.
This post will first describe the installation of the on-premises data gateway and then the creation of the Microsoft Flow using this gateway.
Installing the on-premises data gateway
Information can be found at https://docs.microsoft.com/en-us/power-bi/service-gateway-onprem and you can download the gateway using at https://go.microsoft.com/fwlink/?LinkID=820580&clcid=0x409.
I’ve downloaded the on-premises data gateway and started the installation on a server which also hosts my Azure AD Connect tool.
Everything was successful except the two server names and IP.
This can be at Microsoft’s end or at my end but I decided to not troubleshoot this as it has 31 successful server names.
Now go to https://flow.microsoft.com
Configuring Microsoft Flow Connections
The Gateway should be automatically created for your tenant where you only need to create a connection.
Please go to https://emea.flow.microsoft.com/en-us/pricing/ to verify the available plans and if you can add Gateway Connections as it does not work with the free version or E1 license.
Creating the Microsoft Flow
This “simple” scenario shows that you can communicate with your SharePoint On-Premises environment using the on-premises data gateway from Microsoft.
Microsoft Flows are being triggered by the On-Premises environment.
You can now build your complex workflows not using SharePoint Designer but using Microsoft Flow.
The logging from the on-premises data gateway also provides good information regarding your gateway.
I have verified the logs for my environment and can see that Microsoft Flow is actively polling my SharePoint on-premises library for new content.
DM.EnterpriseGateway Information: 0 : 2018-10-02T19:22:55.9955178Z DM.EnterpriseGateway 6d3ce9bd-66b1-4af9-8140-38d010ebc9a1 2e3ae2b3-44d1-49a1-89db-f33e83245d52 MGPP 983aa058-7427-4c1b-97d2-08090368600b 46EFAADE [DM.GatewayCore] Deserialized GatewayHttpWebRequest, executing
DM.EnterpriseGateway Information: 0 : 2018-10-02T19:22:55.9955178Z DM.EnterpriseGateway 4b2ee4e3-e434-4e4b-9f7e-f1e6c837a391 2e3ae2b3-44d1-49a1-89db-f33e83245d52 MWPR 983aa058-7427-4c1b-97d2-08090368600b 2BD360D1 [DM.GatewayCore] Processing http(s) request with URL: http://portal.sharepointfire.com//_api/web/GetFolderByServerRelativeUrl(@p)/Files?$filter=TimeCreated%20ge%20datetime’2018-10-02T19:00:09Z’&$orderby=TimeCreated,Name&@p=’%2fShared+Documents’
DM.EnterpriseGateway Information: 0 : 2018-10-02T19:22:55.9955178Z DM.EnterpriseGateway 4b2ee4e3-e434-4e4b-9f7e-f1e6c837a391 2e3ae2b3-44d1-49a1-89db-f33e83245d52 MWPR 983aa058-7427-4c1b-97d2-08090368600b BB3A41D3 [DM.GatewayCore] Processing https request
DM.EnterpriseGateway Information: 0 : 2018-10-02T19:22:55.9955178Z DM.EnterpriseGateway 4b2ee4e3-e434-4e4b-9f7e-f1e6c837a391 2e3ae2b3-44d1-49a1-89db-f33e83245d52 MWPR 983aa058-7427-4c1b-97d2-08090368600b DFE1F964 [DM.GatewayCore] Http(s) request with windows authentication