Commit 8067ca0
Changed function invokeWebhook to allow for additional settings (#487)
* Changed function invokeWebhook to allow for additional settings
The invokeWebhook function was changed so that the following settings can be used in the settings.json file:
webhook_type - set the name of the entity that contains the type (defaults to type)
webhook_data - set the name of the entity that contains the data (defaults to data)
webhook_header_name - add a header (for instance for authorization) (defaults to none)
webhook_header_contents - set the contents of the additional header.
The reason for this change is that I want to point this webhook to Splunk. Splunk requires an event entity in the payload in stead of a data entity and the type entity is unknown as well. In addition, authentication is done through the header "Authentication".
I have programmed it such that it is backwards compatible with the previous version.
* Changed new property and variable names to camelCase1 parent a1817a1 commit 8067ca0
1 file changed
+16
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
113 | 113 | | |
114 | 114 | | |
115 | 115 | | |
| 116 | + | |
| 117 | + | |
116 | 118 | | |
117 | 119 | | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
118 | 123 | | |
119 | | - | |
120 | | - | |
| 124 | + | |
| 125 | + | |
121 | 126 | | |
122 | 127 | | |
123 | 128 | | |
124 | 129 | | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
125 | 138 | | |
126 | 139 | | |
127 | 140 | | |
128 | | - | |
129 | | - | |
130 | | - | |
131 | | - | |
| 141 | + | |
132 | 142 | | |
133 | 143 | | |
134 | 144 | | |
| |||
0 commit comments