ASP.NET Core API Starter Project — Structured Logging using Serilog

Shawn Shi
4 min readSep 13, 2020

Every software engineer probably can agree that a good logging system makes life much easier. Logging is just essential for monitoring, troubleshooting and debugging. This article will demonstrate how to use a well-known logging provider, Serilog, in a new ASP.NET Core 3.1 API project.

If you want to dive straight into the code, please check out the barebone GitHub repository, or a fully implemented API project Clean Architecture with partitioned repository pattern using Azure Cosmos DB.

--

--

Shawn Shi

Senior Software Engineer at Microsoft. Ex-Machine Learning Engineer. When I am not building applications, I am playing with my kids or outside rock climbing!