Install libnet-imap-simple-perl by entering the following commands in the terminal:
sudo apt update sudo apt install libnet-imap-simple-perl
Perl module to manage an IMAP account
Net::IMAP::Simple provides a simple way to access and manipulate information on Internet Message Access Protocol (IMAP) capable servers. The API is mostly equivalent to Net::POP3, with some additional extensions based on the other features supported in the IMAP standard. This module supports connections via SSL using IO::Socket::SSL (see libio-socket-ssl-perl), over IPv6 using IO::Socket::INET6 (see libio-socket-inet6-perl) and handling messages in various ways (delete or undelete, mark as read or unread, expunge, edit flags, and more).