secit-pl / imap-bundle

Simple php-imap integration for Symfony
MIT License
66 stars 19 forks source link

Examples with popular email programs #42

Open tacman opened 1 month ago

tacman commented 1 month ago

I keep trying with gmail and zohomail but can't connect. Either I have to enable something on the providers, or I'm not configuring this right. Any suggestions? An example with gmail (without the password, of course) would be helpful. And even recommendations of an email provider, I need to receive some emails will need to set up a new account for this anyway.

Thanks.

imap:
    connections:
       gmail:
         imap_path: "{imap.gmail.com:993}INBOX"
         username: "tacman@gmail.com"
         password: "<password>"

      zoho:
            imap_path: "{imappro.zoho.com:993}INBOX"
            username: "museado@zohomail.com"
            password: "<password>"
            attachments_dir: "%kernel.project_dir%/var/imap/attachments"
            create_attachments_dir_if_not_exists: true # default true
            created_attachments_dir_permissions: 777 # default 770
            server_encoding: "UTF-8"

+------------+-----------------------------------------------------------+-----------------------------+----------------------+---------+ | Connection | Connect Result | Mailbox | Username | Enabled | +------------+-----------------------------------------------------------+-----------------------------+----------------------+---------+ | zoho | FAILED: [CLOSED] IMAP connection broken (server response) | {imappro.zoho.com:993}INBOX | museado@zohomail.com | YES | +------------+-----------------------------------------------------------+-----------------------------+----------------------+---------+ Total connections: 1

tacman commented 1 month ago

I was able to get it to work with gmail by changing the config and signing up for an app password:

      gmail:
        imap_path: "{imap.gmail.com:993/imap/ssl}INBOX"
        username: "tacman@gmail.com"
        password: "<app-password>"
secit-pl commented 2 weeks ago

Feel free to contribute and add the examples to the documentation :)