interfaces in python hide all the details moreoverthe scripts we've begun writing even hide the python interfaces and provide higher-level interactive tools both the popmail and smtpmail scripts provide portable email tools but aren' quite what we' expect in terms of usability these days later in this we'll use what we've seen thus far to implement more interactiveconsole-based mail tool in the next we'll also code tkinter email guiand then we'll go on to build web-based interface in later all of these toolsthoughvary primarily in terms of user interface onlyeach ultimately employs the python mail transfer modules we've met here to transfer mail message text over the internet with sockets before we move onone more smtp notejust as for reading mailwe can use the python interactive prompt as our email sending clienttooif we type calls manually the followingfor examplesends message through my isp' smtp server to two recipient addresses assumed to be part of mail listc:\pp \internet\emailpython from smtplib import smtp conn smtp('smtpout secureserver net'conn sendmail'pp @learning-python com'true sender ['lutz@rmi net''pp @learning-python com']true recipients """frompp @learning-python com tomaillist subjecttest interactive smtplib testing """{conn quit(quit(requireddate added ( 'closing connection good bye 'we'll verify receipt of this message in later email client programthe "torecipient shows up as "maillistin email clients-- completely valid use case for header manipulation in factyou can achieve the same effect with the smtpmail-noto script by separating recipient addresses at the "to?prompt with semicolon ( lutz@rmi netpp @learning-python comand typing the email list' name in the "to:header line mail clients that support mailing lists automate such steps sending mail interactively this way is bit tricky to get rightthough--header lines are governed by standardsthe blank line after the subject line is required and significantfor instanceand date is omitted altogether (one is added for usfurthermoremail formatting gets much more complex as we start writing messages with attachments in practicethe email package in the standard library is generally used to construct emailsbefore shipping them off with smtplib the package lets us build mails by assigning headers and attaching and possibly encoding partsand creates correctly formatted mail text to learn howlet' move on to the next section client-side scripting