JSON-file
Setup
public class SmtpEmailSettings
{
public string Host { get; set; }
public int Port { get; set; }
}{
"Host": "smtp.example.com",
"Port": 25
}services.AddConfiguration()
.AddJson<SmtpEmailSettings>("path_to_json_file");Last updated