Helllo guys i have a Ms teams webhook that receives these notification, my issue is some fields i expect to see in the alert are not being populated … i tried message.fields.RequestId message.RequestId still not populated.
Sample of Message
{
“RequestPath”: “/api/v1/business/owner”,
“Scheme”: “http”,
“ContentType”: “application/json; charset=utf-8; x-api-version=1”,
“gl2_remote_ip”: “1.1.1.1”,
“logger”: “Microsoft.AspNetCore.Hosting.Diagnostics”,
“gl2_remote_port”: 56042,
“source”: “my.Api”,
“ElapsedMilliseconds”: 2897.1303,
“machine_name”: “my-apis”,
“gl2_source_input”: “6633718f75795570f901fbc4e”,
“StatusCode”: 200,
“ConnectionId”: “0HN7KQ0U5V2M6”,
“gl2_source_node”: “47917e09-1e22-4adb-b5af-d9bee4713562”,
“Protocol”: “HTTP/1.1”,
“timestamp”: “2024-10-25T12:38:20.630Z”,
“Path”: “/api/v1/business/owner”,
“gl2_accounted_message_size”: 749,
“RequestId”: “0HN7KQ0U5V2M6:00000001”,
“level”: 6,
“QueryString”: “?sessionId=OWNERSHIPDETAILS”,
“streams”: [
“000000000000000000000001”
],
“gl2_message_id”: “01JB1TYN6P0N7NNCRJ126C0KY8”,
“Host”: “localhost:4342”,
“Method”: “POST”,
“message”: “Request finished HTTP/1.1 POST http://localhost:4342/api/v1/owner?sessionId=OWNERSHIPDETAILS - 200 - application/json;+charset=utf-8;+x-api-version=1 2897.1303ms”,
“event_id”: 2,
“Environment”: “Production”,
“_id”: “0463759c-92ce-11ef-8ae7-0242ac120004”,
“facility”: “my.Api”
}
Snip of my notification
${if backlog}
<b>--- [Last messages accounting for this alert:] --- </b>
${foreach backlog message}
<p><code>${message.timestamp} :: ${message.source} :: ${message.message} ::
<b>RequestId</b>:: ${message.fields.RequestId}:: ${message.id}<b>Exception</b> :: ${message.fields.exception}</code></p>
${end}${end}
I am unable to get the value of this ${message.fields.RequestId} thou its in my message field
GraylogVersion : Graylog 5.1.4
OS:Linux