The SIGNL4 webhook not only allows to send event data e.g. in JSON format. It can also accept images or sound attachments. This media data is encoded like email attachments and transmitted via HTTP POST in a multipart/forma-data content type.
Supported file formats
Attachment type | Supported file format(s) |
Image | png, tiff, tif, jpeg, jpg, gif, bmp |
Sound |
mp3, wav, aiff, m4a |
Text | txt |
Document |
|
Video |
mov, mp4 |
Each attachment may be max. 4MB in size.
How are parameter values transferred?
Parameter values within a multipart/formdata transfer are encoded as text attachments. The parameter name is the name of the attachment. The actual text is the value of the parameter.
The following example shows how the parameter values of an event are transmitted in JSON format in a multipart/form-data message:
{
"Title": "Critical production failure",
"Message": "Check line machine C immediately",
"Severity": "High",
"Business Details": {
"Impact": "Major",
"Scope": "Unlimited"
}
}
------RandomGeneratedBoundary
Content-Disposition: form-data; name="Title"
Critical production failure
------RandomGeneratedBoundary
Content-Disposition: form-data; name="Message"
Check line machine C immediately
------RandomGeneratedBoundary
Content-Disposition: form-data; name="Severity"
High
------RandomGeneratedBoundary
Content-Disposition: form-data; name="Business Details.Impact"
Major
------RandomGeneratedBoundary
Content-Disposition: form-data; name="Business Details.Scope"
Unlimited
------RandomGeneratedBoundary--
How are images, sound or documents transmitted?
Attachments in the previously mentioned file formats can be submitted as base64 encoded attachments:
------RandomGeneratedBoundary
Content-Disposition: form-data; name="Logo"; filename="S4_Icon_32.png"
Content-Type: image/png
Content-Transfer-Encoding: base64
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAAXNSR0IArs4c6QAAAARnQU1BAACx
jwv8YQUAAAAJcEhZcwAADsEAAA7BAbiRa+0AAASBSURBVEhL1ZVdaFxFFIDPmXvv7r13b/Yn2d2S
pEna1NY0tBF/qaAggi+l/kGliIKgPigqgqggIigiivTRVlBonxR81AQi9MGiIIgKjeBPbVDapEmz
2W6yu9m/+zeeuXd2s+luMELy4Mche+bOzDlnzpw5gf89SEi1jfATzYQK58Dpb6D/V250wBAUBBVB
Y6AypCFZ9zh3fCDxhC5XbhFkZCOEC9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yHqjTPF9t0m9iTo8Tv/7OpG96AZpLC/I+SZeYYl71EWDBQzr
uXk50cRdnqO6alloSdcUYXX6E79SlFsDypMfN/u6oDp1mtsNORe8OGoerc7fjkIvWeRuo0C1XLtw
HpO7WCzhLP5V/Pw979svxPbmAl7M13/9HvsGmR5z5i6unnnTv3BOmG8zIiURN8MoOvF9n5orcj8M
TX5dh3se9ykNmy4QYHJzB9tCs13vmHQt0+0EU4mYVHeGnU9Rx5dtFYB/AC0uoeMjRAaUAAAAAElF
TkSuQmCC
------RandomGeneratedBoundary--
Example event with parameter values, an image as well as position data
The following example transmits an incident with several parameter values, an image and position data, which could be sent from an IP camera to the webhook, for example:
POST https://connect.signl4.com/webhook/g93sdfm2843 HTTP/1.1
User-Agent: IPCamera
Host: connect.signl4.com
Content-Type: multipart/form-data; boundary=----RandomGeneratedBoundary
Content-Length: 2556
------RandomGeneratedBoundary
Content-Disposition: form-data; name="Title"
Critical production failure
------RandomGeneratedBoundary
Content-Disposition: form-data; name="Message"
Check line machine C immediately
------RandomGeneratedBoundary
Content-Disposition: form-data; name="Severity"
High
------RandomGeneratedBoundary
Content-Disposition: form-data; name="Business Details.Impact"
Major
------RandomGeneratedBoundary
Content-Disposition: form-data; name="Business Details.Scope"
Unlimited
------RandomGeneratedBoundary
Content-Disposition: form-data; name="X-S4-Location"
52.4354955,13.0540154
------RandomGeneratedBoundary
Content-Disposition: form-data; name="Logo"; filename="S4_Icon_32.png"
Content-Type: image/png
Content-Transfer-Encoding: base64
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAIAAAD8GO2jAAAAAXNSR0IArs4c6QAAAARnQU1BAACx
jwv8YQUAAAAJcEhZcwAADsEAAA7BAbiRa+0AAASBSURBVEhL1ZVdaFxFFIDPmXvv7r13b/Yn2d2S
pEna1NY0tBF/qaAggi+l/kGliIKgPigqgqggIigiivTRVlBonxR81AQi9MGiIIgKjeBPbVDapEmz
2W6yu9m/+zeeuXd2s+luMELy4Mche+bOzDlnzpw5g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FtBFJHn2lZJ3w1ap54gxQ5j5B8+IWWdcKP
xszHXhVF2YHsRRtBPnqrVJuoA6OgyHqjTPF9t0m9iTo8Tv/7OpG96AZpLC/I+SZeYYl71EWDBQzr
uXk50cRdnqO6alloSdcUYXX6E79SlFsDypMfN/u6oDp1mtsNORe8OGoerc7fjkIvWeRuo0C1XLtw
HpO7WCzhLP5V/Pw979svxPbmAl7M13/9HvsGmR5z5i6unnnTv3BOmG8zIiURN8MoOvF9n5orcj8M
TX5dh3se9ykNmy4QYHJzB9tCs13vmHQt0+0EU4mYVHeGnU9Rx5dtFYB/AC0uoeMjRAaUAAAAAElF
TkSuQmCC
------RandomGeneratedBoundary--
The resulting Signl details in the SIGNL4 web application look as follows:
Comments
0 comments
Please sign in to leave a comment.