setting up automapper .net core code example
Example 1: install automapper asp.net core mvc
Install-Package AutoMapper.Extensions.Microsoft.DependencyInjection -Version 7.0.0
Example 2: automapper dependency injection
services.AddAutoMapper(typeof(ProfileTypeFromAssembly1), typeof(ProfileTypeFromAssembly2) /*, ...*/);