feat: add dual-engine email service with aliyun smtp and resend routing
Route Chinese domains (edu.cn, qq.com, 163.com, etc.) via Aliyun SMTP and international addresses via Resend API. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -16,6 +16,25 @@ type Config struct {
|
||||
Mathpix MathpixConfig `mapstructure:"mathpix"`
|
||||
BaiduOCR BaiduOCRConfig `mapstructure:"baidu_ocr"`
|
||||
Google GoogleOAuthConfig `mapstructure:"google"`
|
||||
Email EmailConfig `mapstructure:"email"`
|
||||
}
|
||||
|
||||
type EmailConfig struct {
|
||||
FromName string `mapstructure:"from_name"`
|
||||
FromAddr string `mapstructure:"from_addr"`
|
||||
AliyunSMTP AliyunSMTPConfig `mapstructure:"aliyun_smtp"`
|
||||
Resend ResendEmailConfig `mapstructure:"resend"`
|
||||
}
|
||||
|
||||
type AliyunSMTPConfig struct {
|
||||
Host string `mapstructure:"host"`
|
||||
Port int `mapstructure:"port"`
|
||||
Username string `mapstructure:"username"`
|
||||
Password string `mapstructure:"password"`
|
||||
}
|
||||
|
||||
type ResendEmailConfig struct {
|
||||
APIKey string `mapstructure:"api_key"`
|
||||
}
|
||||
|
||||
type BaiduOCRConfig struct {
|
||||
|
||||
Reference in New Issue
Block a user