Getting NLog to send out JSON with proper headers?
Looking at the HttpNetworkSender
source, I don't see an obvious way to pass in a content type to the WebRequest
.
I think you will have to create a custom target based on the NetworkTarget
which uses a custom HttpNetworkSender
, and include config to set the content-type on the WebRequest
Appropriately.