public void TriggerMethod(MyModel m) { _logger.LogDebug("SecondClass Write a debug message with property {Property}!", Property); _myInterface.TestMethod(_myInterface.Model); var i = _provider.GetService <MyInterface>(); i.TestMethod(m); _logger.LogInformation("SecondClass Write a info message with Interface Model {@Model}!", _myInterface.Model); var d = _provider.GetRequiredService <SecondClass>(); d.GetMyInterface.TestMethod(new MyModel() { MyString = "Test" }); }