Events Authentication and Configuration
Establish a connection between VSM and Cloud Events.
Configuring the connection between the event and VSM execution





Request Examples
Creating a new event
Last updated
Was this helpful?
Was this helpful?
var sha256digest = CryptoJS.HmacSHA256(request.data, "the-secret-from-management-dashboard");
var base64sha256 = CryptoJS.enc.Base64.stringify( sha256digest);
postman.setEnvironmentVariable("hmac", base64sha256);{
"id": "0c29dar5-13er-4766-82f8-91e87a45ghy6",
"name": "devenv",
"values": [
{
"key": "src",
"value": "src_w34a44rft567",
"type": "default",
"enabled": true
},
{
"key": "secret",
"value": "<replace with secret from VSM->Admin->Events in Management Dashboard>",
"type": "secret",
"enabled": true
},
{
"key": "hmac",
"value": "",
"type": "any",
"enabled": true
}
],
"_postman_variable_scope": "environment",
"_postman_exported_at": "2023-04-19T07:26:28.294Z",
"_postman_exported_using": "Postman/10.10.4"
}
{
"info": {
"_postman_id": "d5ce7aff-7f71-4261-b369-7cd67813e878",
"name": "VSM Hello World",
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
"_exporter_id": "12223042"
},
"item": [
{
"name": "say-hello",
"event": [
{
"listen": "prerequest",
"script": {
"exec": [
"var sha256digest = CryptoJS.HmacSHA256(request.data, postman.getEnvironmentVariable(\"secret\"));",
"var base64sha256 = CryptoJS.enc.Base64.stringify( sha256digest);",
"postman.setEnvironmentVariable(\"hmac\", base64sha256);"
],
"type": "text/javascript"
}
}
],
"request": {
"method": "POST",
"header": [
{
"key": "ce-source",
"value": "postman",
"type": "text"
},
{
"key": "ce-type",
"value": "hello_world",
"type": "text"
},
{
"key": "ce-specversion",
"value": "1.0",
"type": "text"
},
{
"key": "ce-id",
"value": "{{$guid}}",
"type": "text"
},
{
"key": "x-emporix-hmac",
"value": "{{hmac}}",
"type": "text"
}
],
"body": {
"mode": "raw",
"raw": "{\n \"hello\" : \"world\"\n}",
"options": {
"raw": {
"language": "json"
}
}
},
"url": {
"raw": "https://signals.emporix.io/e/{{src}}",
"protocol": "https",
"host": [
"signals",
"emporix",
"io"
],
"path": [
"e",
"{{src}}"
]
}
},
"response": []
}
]
}