using System.Threading.Tasks;
public static async Task Main()
var testOptions = new TestOptions();
testOptions.GetMessageId = () => "Test";
var testOptions2 = new TestOptions();
Console.WriteLine(testOptions.GetMessageId());
if(testOptions2.GetMessageId != null)
Console.WriteLine(testOptions2.GetMessageId());
public Func<string> GetMessageId { get; set; }