public async Task <ActionResult <AlbumModel> > Post(int artistId, CreateAlbumRequestModel2 model) { var artist = await this.context.Artist.FindAsync(artistId); if (artist == null) { return(this.NotFound()); } var entity = model.MapAsNewEntity(artist); this.context.Album.Add(entity); await this.context.SaveChangesAsync(); return(this.CreatedAtAction("Get", new { artistId = artistId, Title = entity.Title }, entity.MapAsModel())); }