You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
An open source component for sending and receiving [WebHooks](https://en.wikipedia.org/wiki/Webhook) on [elastic.io platform](https://www.elastic.io"elastic.io platform").
5
17
6
-
Before you can deploy any code into our system **you must be a registered elastic.io platform user**. Please see our home page at [https://www.elastic.io](https://www.elastic.io) to learn how.
7
-
8
18
## Credentials
9
19
Webhook component supports the following authorisation types:
10
20
***No Auth** - use this method to work with any open REST API
@@ -15,44 +25,62 @@ Webhook component supports the following authorisation types:
Simple webhook trigger which receives data as an input and starts the flow execution after this.
20
-
21
-
Receive trigger has 1 field: sample data field to define your incoming message.
28
+
### Receive
29
+
Simple webhook trigger which receives data as an input and starts the flow execution after this.
22
30
23
-
To use the Receive trigger for WebHook at elastic.io you would need to define the sample structure which would be used to send your data.
24
-
You are able to input your desired data structure either as JSON data, XML or as List of properties.
25
-
26
-
#### Sending JSON
27
-
Send WebHook using JSON data and Content-Type of `application/json` - in this case you just paste a sample of such JSON payload in the WebHook configuration window.
28
-
```json
31
+
#### Expected output metadata
32
+
[Output schema](lib/schemas/base64.out.json)
33
+
34
+
Example:
35
+
```metadata json
29
36
{
30
-
"foo" : "bar",
31
-
"myJSON" : "is the best!"
32
-
}
37
+
"recievedBody": "recievedBody",
38
+
"_query": {},
39
+
"_headers": {
40
+
"content-type": "application/json",
41
+
"accept": "*/*",
42
+
"accept-encoding": "gzip, deflate"
43
+
},
44
+
"_method": "POST",
45
+
"_url": "/hook/5d691738cb5a286adc1e68e2"
46
+
}
33
47
```
34
48
35
-
#### Receive. Config fields
36
-
***[required]** Payload. This is the place you define your incoming data.
37
-
Renders an input text area field to define a payload metadata for the WebHook component.
38
-
39
-
## Actions
40
-
### Send Data
41
-
Simply sends data it receives as an input to a URL provided.
42
-
43
-
WebHook action can also be used to troubleshoot many processes to see the outcome.
44
-
For example one could create Invoices (in Salesforce) to Webhook flow and configure the Webhook with a url created in https://webhook.site or with any similar services.
49
+
## Actions
50
+
### Send data
51
+
Simply sends data it receives as an input to a URL provided.
52
+
53
+
WebHook action can also be used to troubleshoot many processes to see the outcome.
54
+
For example one could create Invoices (in Salesforce) to Webhook flow and configure the Webhook with a url created in https://webhook.site or with any similar services.
45
55
46
-
#### Send Data. Config fields
47
-
***[required]****HTTP Verb**
48
-
***POST**. The WebHook component can POST information to preconfigured WebHook address. This action could be used for different purposes. For example WebHook can be used to inform your custom connector about an event which it waits to work.
49
-
***PUT**. The WebHook component can also PUT a specific preconfigured JSON into specific address where the process will not be handled by the server. For this reason the "Output JSON Sample" field can be used.
50
-
***[required]****URI**. This is the address to send WebHook.
51
-
***[not required]****Secret**. This is an optional field to authenticate WebHook POST. There maybe cases when a special password or a secret might be required. For example the WebHook address was generated explicitly with a password so that to prevent any third parties to use it. This could be your specific WebHook address that you use to send your Wordpress posts into your server.
56
+
#### List of Expected Config fields
57
+
***[required]****HTTP Verb**
58
+
***POST**. The WebHook component can POST information to preconfigured WebHook address. This action could be used for different purposes. For example WebHook can be used to inform your custom connector about an event which it waits to work.
59
+
***PUT**. The WebHook component can also PUT a specific preconfigured JSON into specific address where the process will not be handled by the server. For this reason the "Output JSON Sample" field can be used.
60
+
***[required]****URI**. This is the address to send WebHook.
61
+
***[not required]****Secret**. This is an optional field to authenticate WebHook POST. There maybe cases when a special password or a secret might be required. For example the WebHook address was generated explicitly with a password so that to prevent any third parties to use it. This could be your specific WebHook address that you use to send your Wordpress posts into your server.
62
+
63
+

52
64
53
-

65
+
#### Expected output metadata
66
+
[Output schema](lib/schemas/base64.out.json)
67
+
68
+
Example:
69
+
```metadata json
70
+
{
71
+
"recievedBody": "recievedBody",
72
+
"_query": {},
73
+
"_headers": {
74
+
"content-type": "application/json",
75
+
"accept": "*/*",
76
+
"accept-encoding": "gzip, deflate"
77
+
},
78
+
"_method": "POST",
79
+
"_url": "/hook/5d691738cb5a286adc1e68e2"
80
+
}
81
+
```
54
82
55
-
## Known Limitations
83
+
## Known limitations
56
84
57
85
1. Maximal possible size for an attachment is 10 MB.
58
86
2. Attachments mechanism does not work with [Local Agent Installation](https://support.elastic.io/support/solutions/articles/14000076461-announcing-the-local-agent-)
Copy file name to clipboardExpand all lines: component.json
+10-20Lines changed: 10 additions & 20 deletions
Original file line number
Diff line number
Diff line change
@@ -15,25 +15,18 @@
15
15
"triggers": {
16
16
"receive": {
17
17
"title": "Receive",
18
-
"description": "Receive trigger has 3 fields: the WebHook URL to send your data, HMAC to secure your WebHook and sample data field to define your incoming message.",
19
-
"main": "./receive.js",
20
-
"fields": {
21
-
"payload": {
22
-
"viewClass": "WebHookPayloadView",
23
-
"label": "Sample data",
24
-
"required": true,
25
-
"placeholder": "{ \"foo\" : \"bar\" }"
26
-
}
27
-
},
18
+
"description": "Simple webhook trigger which receives data as an input and starts the flow execution after this.",
0 commit comments