Plenty of examples on how to do this with MVC and Startup.cs
How do I get the connection string from the appsettings.json inside the main program?
My code is f