public static void Main()
var config = new MapperConfiguration(cfg =>
cfg.CreateMap<ReservationSource, ReservationDestination>()
.ForMember(dest => dest.ReturnTravelD, opt => opt.MapFrom(src => src.ReturnTravelS))
.ForMember(dest => dest.TowardsTravelD, opt => opt.MapFrom(src => src.TowardsTravelS));
cfg.CreateMap<TravelS, TravelD>();
var mapper = config.CreateMapper();
var source = new ReservationSource
ReservationNumber = "9821",
ReturnTravelS = new TravelS
TowardsTravelS = new TravelS
var destination = mapper.Map<ReservationDestination>(source);
Console.WriteLine(JsonSerializer.Serialize(destination));
public class ReservationSource
public string ReservationNumber
public TravelS TowardsTravelS
public TravelS ReturnTravelS
public class ReservationDestination
public string ReservationNumber
public TravelD TowardsTravelD
public TravelD ReturnTravelD