How to auto log every request in .NET Core WebAPI?
ActionFilter will work until you need to log only requests processed by MVC middleware (as controller actions). If you need logging for all incoming requests, then you need to use a middleware approach. Good visual explanation: Note that middleware order is important, and if your logging should be done at the start of pipeline execution, … Read more