-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
GITBOOK-5: change request with no subject merged in GitBook
- Loading branch information
1 parent
14dd392
commit 23c1046
Showing
7 changed files
with
94 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# What is an Event Notification? | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
--- | ||
layout: | ||
title: | ||
visible: true | ||
description: | ||
visible: false | ||
tableOfContents: | ||
visible: false | ||
outline: | ||
visible: true | ||
pagination: | ||
visible: true | ||
--- | ||
|
||
# What is a Sender of Webhooks? | ||
|
||
Considering the overall network of communications, where Webhooks are messages exchanged between two applications, a Webhook Sender is an application that sends these messages to another application (or to a multitude of applications). | ||
|
||
In real life, you might consider the _Sender_ as the postman delivering a letter or a package to the destination, ensuring the address is correct and exists, that the postbox can hold the shipment, eventually coming back more than once at the address (if the recipient is not at home), accepting the signature, etc. | ||
|
||
As much as a postman wouldn't care if the letter or package was in delivery because of an agreement between the recipient and an organization, the same way a Webhook Sender doesn't have to necessarily require the knowledge that an application is expecting the message it is sending (this would be a [Webhook Subscription](webook-subscription.md)). | ||
|
||
### The Delivery Destination | ||
|
||
A Sender requires the specification of a Destination, to be able to attempt the delivery of Webhooks, which is like a postal address, following the example above. | ||
|
||
In most cases, this is simply a URL (_Universal Resource Locator_), that can be reached by an HTTP request, but in some scenarios, this can be enriched with further information instructing the sender on the behavior to have with it, when attempting to deliver a package (for example, we inform the sender to leave the package to our neighbor, if we are not at home, or to try reaching us only on Thursdays, etc.). | ||
|
||
Such destination-specific instructions would act as an exception to the regular behavior of the sender, which is described below. | ||
|
||
### The Sender Behavior | ||
|
||
When sending a Webhook to another party, the application sending messages should ensure that the destination is reachable, the message is well-formatted, its delivery is retried (in case of failures), and the integrity of the content is assured. | ||
|
||
This is done by a configured behavior, that typically provides the following elements of configuration | ||
|
||
<table><thead><tr><th width="209.5">Attribute</th><th>Description</th></tr></thead><tbody><tr><td><strong>Content Type</strong></td><td>The specification of the format of the contents of the Webhook message (eg. <em>JSON</em>, <em>XML</em>, <em>Form-Encoded</em>)</td></tr><tr><td><strong>Retry Strategy</strong></td><td>The methodology to deliver the message (eg. <em>Circuit Breaker,</em> <em>Exponential Backoff</em>, <em>Timeout</em>, etc.), and the configurations of retries (eg. <em>a maximum number of retries</em>, <em>delays between attempts</em>, etc.)</td></tr><tr><td><strong>Signature Method</strong></td><td>A methodology used to sign the Webhook payloads, so that the the receiver can ensure their integrity</td></tr><tr><td><strong>Context</strong></td><td>The set of contextual information informing the receiver of the origination of the Webhook (eg. <em>the machine name</em>, <em>the application type</em>, etc.)</td></tr></tbody></table> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# What is a Receiver of Webhooks? | ||
|
||
As we have cleared out before, Webhooks are messages that inform an application of the occurrence of an event in a system: as such we consider the context of communications, where there are two (or more) parties sending and receiving messages between each other. | ||
|
||
In a specular way to the definition of the Webhook Sender, of which we made an analogy with a postman delivering a letter or a package, the Webhook Receiver can be considered the recipient (a person or a company), that physically receives the deliverable. | ||
|
||
Considering the real-life scenario of delivery of letters or packages, we all can be receivers, if we provide a postbox with our name on it, that we make available for postmen to access.  | ||
|
||
In some special cases of secure shipments, we might also be requested to sign a receipt to ensure that the packages or envelopes were actually delivered. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters