title: Serilog - dotnet core JSON file format
body: <p>Our dotnet core application is using serilog to spit out log files in json format which we use beats/logstash/ES to process. </p>
  
  <p>It's by default using a messageTemplate field which uses paramters and stores the values elsewhere like below with {ConnectionId}. </p>
  
  <p>Is there a way that it will have a field with the actual message? 
  For example: "Connection id 0HLDSOA7JG3GS sending FIN."</p>
  
  <pre><code> {
           "source" =&gt; "/var/log/myapp/myapp-api-logs                                                                                                /myapp-staging-api-logs-20180518.log",
             "json" =&gt; {
                "Properties" =&gt; {
                "ConnectionId" =&gt; "0HLDSOA7JG3GS"                                                                                                ,
                     "EventId" =&gt; {
                   "Id" =&gt; 7
               },
               "SourceContext" =&gt; "Microsoft.AspN                                                                                                etCore.Server.Kestrel.Transport.Libuv"
           },
                     "Level" =&gt; "Debug",
                 "Timestamp" =&gt; "2018-05-18T16:23                                                                                                :40.5286099+03:00",
           "MessageTemplate" =&gt; "Connection id \"                                                                                                {ConnectionId}\" sending FIN.",
                   "message" =&gt; ""
       },
             "beat" =&gt; {
           "hostname" =&gt; "33eb9c70141c",
               "name" =&gt; "33eb9c70141c",
            "version" =&gt; "6.2.4"
       },
       "@timestamp" =&gt; 2018-05-18T13:23:43.999Z,
       "prospector" =&gt; {
           "type" =&gt; "log"
       },
           "offset" =&gt; 55337,
           "fields" =&gt; {
              "appenv" =&gt; "staging",
           "appsource" =&gt; "myapp-staging-api-logs"
       },
         "@version" =&gt; "1",
             "host" =&gt; "33eb9c70141c",
             "tags" =&gt; [
           [0] "beats_input_raw_event"
       ]
   }
  </code></pre>