Add Gmail API injection, provider presets, delivery method, and frontend wizard
- Add gmail_service.py with Gmail API users.messages.insert() for direct email injection - Add DeliveryMethod enum and GmailCredential model to database models - Add delivery_method field to MailAccount schema and model - Create providers.py endpoint with 12 provider presets (Gmail, GMX, WEB.DE, Outlook, Yahoo, AOL, T-Online, 1&1/IONOS, Freenet, Posteo, mail.de, iCloud) - Expand MailServerAutoDetect with 30+ domain mappings - Update Celery tasks to prefer Gmail API injection, with SMTP fallback - Add ProviderWizard.tsx frontend component for quick provider setup - Update AddMailAccountModal.tsx with wizard integration - Add Google API Python client libraries to requirements.txt - Add Gmail API config settings - Add unit tests for Gmail service and provider presets Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com> Agent-Logs-Url: https://github.com/christianlouis/pop_puller_to_gmail/sessions/de3ef930-a980-4958-8a9d-a2c802918e81
This commit is contained in:
@@ -395,6 +395,11 @@ class MailServerAutoDetect:
|
||||
"pop3_ssl": {"host": "pop.gmail.com", "port": 995},
|
||||
"imap_ssl": {"host": "imap.gmail.com", "port": 993},
|
||||
},
|
||||
"googlemail.com": {
|
||||
"name": "Gmail",
|
||||
"pop3_ssl": {"host": "pop.gmail.com", "port": 995},
|
||||
"imap_ssl": {"host": "imap.gmail.com", "port": 993},
|
||||
},
|
||||
"outlook.com": {
|
||||
"name": "Outlook.com",
|
||||
"pop3_ssl": {"host": "outlook.office365.com", "port": 995},
|
||||
@@ -405,6 +410,21 @@ class MailServerAutoDetect:
|
||||
"pop3_ssl": {"host": "outlook.office365.com", "port": 995},
|
||||
"imap_ssl": {"host": "outlook.office365.com", "port": 993},
|
||||
},
|
||||
"live.com": {
|
||||
"name": "Live",
|
||||
"pop3_ssl": {"host": "outlook.office365.com", "port": 995},
|
||||
"imap_ssl": {"host": "outlook.office365.com", "port": 993},
|
||||
},
|
||||
"msn.com": {
|
||||
"name": "MSN",
|
||||
"pop3_ssl": {"host": "outlook.office365.com", "port": 995},
|
||||
"imap_ssl": {"host": "outlook.office365.com", "port": 993},
|
||||
},
|
||||
"outlook.de": {
|
||||
"name": "Outlook.de",
|
||||
"pop3_ssl": {"host": "outlook.office365.com", "port": 995},
|
||||
"imap_ssl": {"host": "outlook.office365.com", "port": 993},
|
||||
},
|
||||
"gmx.com": {
|
||||
"name": "GMX",
|
||||
"pop3_ssl": {"host": "pop.gmx.com", "port": 995},
|
||||
@@ -415,6 +435,21 @@ class MailServerAutoDetect:
|
||||
"pop3_ssl": {"host": "pop.gmx.net", "port": 995},
|
||||
"imap_ssl": {"host": "imap.gmx.net", "port": 993},
|
||||
},
|
||||
"gmx.net": {
|
||||
"name": "GMX",
|
||||
"pop3_ssl": {"host": "pop.gmx.net", "port": 995},
|
||||
"imap_ssl": {"host": "imap.gmx.net", "port": 993},
|
||||
},
|
||||
"gmx.at": {
|
||||
"name": "GMX",
|
||||
"pop3_ssl": {"host": "pop.gmx.net", "port": 995},
|
||||
"imap_ssl": {"host": "imap.gmx.net", "port": 993},
|
||||
},
|
||||
"gmx.ch": {
|
||||
"name": "GMX",
|
||||
"pop3_ssl": {"host": "pop.gmx.net", "port": 995},
|
||||
"imap_ssl": {"host": "imap.gmx.net", "port": 993},
|
||||
},
|
||||
"web.de": {
|
||||
"name": "WEB.DE",
|
||||
"pop3_ssl": {"host": "pop3.web.de", "port": 995},
|
||||
@@ -422,14 +457,84 @@ class MailServerAutoDetect:
|
||||
},
|
||||
"t-online.de": {
|
||||
"name": "T-Online",
|
||||
"pop3_ssl": {"host": "pop.t-online.de", "port": 995},
|
||||
"imap_ssl": {"host": "imap.t-online.de", "port": 993},
|
||||
"pop3_ssl": {"host": "securepop.t-online.de", "port": 995},
|
||||
"imap_ssl": {"host": "secureimap.t-online.de", "port": 993},
|
||||
},
|
||||
"yahoo.com": {
|
||||
"name": "Yahoo",
|
||||
"pop3_ssl": {"host": "pop.mail.yahoo.com", "port": 995},
|
||||
"imap_ssl": {"host": "imap.mail.yahoo.com", "port": 993},
|
||||
},
|
||||
"yahoo.de": {
|
||||
"name": "Yahoo",
|
||||
"pop3_ssl": {"host": "pop.mail.yahoo.com", "port": 995},
|
||||
"imap_ssl": {"host": "imap.mail.yahoo.com", "port": 993},
|
||||
},
|
||||
"yahoo.co.uk": {
|
||||
"name": "Yahoo",
|
||||
"pop3_ssl": {"host": "pop.mail.yahoo.com", "port": 995},
|
||||
"imap_ssl": {"host": "imap.mail.yahoo.com", "port": 993},
|
||||
},
|
||||
"ymail.com": {
|
||||
"name": "Yahoo",
|
||||
"pop3_ssl": {"host": "pop.mail.yahoo.com", "port": 995},
|
||||
"imap_ssl": {"host": "imap.mail.yahoo.com", "port": 993},
|
||||
},
|
||||
"aol.com": {
|
||||
"name": "AOL",
|
||||
"pop3_ssl": {"host": "pop.aol.com", "port": 995},
|
||||
"imap_ssl": {"host": "imap.aol.com", "port": 993},
|
||||
},
|
||||
"aim.com": {
|
||||
"name": "AOL",
|
||||
"pop3_ssl": {"host": "pop.aol.com", "port": 995},
|
||||
"imap_ssl": {"host": "imap.aol.com", "port": 993},
|
||||
},
|
||||
"online.de": {
|
||||
"name": "1&1 / IONOS",
|
||||
"pop3_ssl": {"host": "pop.ionos.de", "port": 995},
|
||||
"imap_ssl": {"host": "imap.ionos.de", "port": 993},
|
||||
},
|
||||
"onlinehome.de": {
|
||||
"name": "1&1 / IONOS",
|
||||
"pop3_ssl": {"host": "pop.ionos.de", "port": 995},
|
||||
"imap_ssl": {"host": "imap.ionos.de", "port": 993},
|
||||
},
|
||||
"1und1.de": {
|
||||
"name": "1&1 / IONOS",
|
||||
"pop3_ssl": {"host": "pop.ionos.de", "port": 995},
|
||||
"imap_ssl": {"host": "imap.ionos.de", "port": 993},
|
||||
},
|
||||
"freenet.de": {
|
||||
"name": "Freenet",
|
||||
"pop3_ssl": {"host": "mx.freenet.de", "port": 995},
|
||||
"imap_ssl": {"host": "mx.freenet.de", "port": 993},
|
||||
},
|
||||
"posteo.de": {
|
||||
"name": "Posteo",
|
||||
"imap_ssl": {"host": "posteo.de", "port": 993},
|
||||
},
|
||||
"posteo.net": {
|
||||
"name": "Posteo",
|
||||
"imap_ssl": {"host": "posteo.de", "port": 993},
|
||||
},
|
||||
"icloud.com": {
|
||||
"name": "iCloud",
|
||||
"imap_ssl": {"host": "imap.mail.me.com", "port": 993},
|
||||
},
|
||||
"me.com": {
|
||||
"name": "iCloud",
|
||||
"imap_ssl": {"host": "imap.mail.me.com", "port": 993},
|
||||
},
|
||||
"mac.com": {
|
||||
"name": "iCloud",
|
||||
"imap_ssl": {"host": "imap.mail.me.com", "port": 993},
|
||||
},
|
||||
"mail.de": {
|
||||
"name": "mail.de",
|
||||
"pop3_ssl": {"host": "pop.mail.de", "port": 995},
|
||||
"imap_ssl": {"host": "imap.mail.de", "port": 993},
|
||||
},
|
||||
}
|
||||
|
||||
@classmethod
|
||||
|
||||
Reference in New Issue
Block a user