Webhooks for Azure Functions

"Simplicity is a great virtue but it requires hard work to achieve it and education to appreciate it. And to make matters worse: complexity sells better"
- Edsger Dijkstra

This chapter illustrates the use of Webhook, even binding Webhook as the output in the Azure Function. It illustrates events with simple example. We will focus on topics such as the following:

  • Creating JavaScript functions triggered by Webhook
  • Using a Webhook with an Azure Function
  • Using an event with an Azure Function

Let's start with an introduction to Webhook before using it in our functions.

So, what is a Webhook? Webhooks are user-defined HTTP callbacks. They are usually triggered by some event, such as pushing code to a repository or a comment being posted to a blog. A web application implementing Webhooks will POST a message to a URL when certain things happen. Sometimes people call Webhooks reverse APIs, but perhaps more accurately a Webhook lets you skip a step. With most APIs, there's a request followed by a response. No request is required for a Webhook, it just sends the data when it's available.

Let's start with a simple example.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.118.141.27