Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Connect-PnPOnline https://yourtenant.sharepoint.com/sites/yoursite
# "testwebhook" is the name of our target list
Add-PnPWebhookSubscription -List testwebhook -NotificationUrl https://your-functions.azurewebsites.net/api/sample-webhook
# The command above outputs the following
# Id : 080e41c2-3c30-4c4d-8d1c-fa22249aedc0
# ClientState :
# ExpirationDateTime : 12-Mar-18 22:00:00
# NotificationUrl : https://your-functions.azurewebsites.net/api/sample-webhook
# Resource : 6efa3b51-f514-4b88-9117-3d158e3f8fe2
# We can also remove the subscription with the following Cmdlet
Remove-PnPWebhookSubscription -List testwebhook -Identity 080e41c2-3c30-4c4d-8d1c-fa22249aedc0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment