I'd suggest that you start by taking a look at some Python scripts for sending email. The basics aren't too bad. There are a lot of canned scripts to include images and attachments.
Then you get one set up to work as you want. Get it set up so that Panorama can send it for you- without modifications. Once that much is working, you can start inserting Panorama variables to replace the parts that you want to have change with each message.
It is some work to do it, but I had never touched Python before I decided to pursue it. I learned through trial and error to modify the canned scripts. Now I have some fairly elaborate procedures reliably sending out one or sometimes hundreds of indiviualized emails at a time.
Mine have reached the point of using so many variables that it would be more work to explain what they represent than is reasonable. But - at the end of this message is my basic Python test script. The defining of the variables is omitted in the example, but must be accomplished before having Panorama run it. Most should be clear enough. If not, ask me. You could just as easily load data from fields in their place.
I send authenticated email, as do most of my clients, so it does require the same settings as Apple Mail and such. Here's are how I set several of them up as preferences:
Here's an example of an email sent from a Panorama database with a deliberately large photograph embedded:
Local lvResult, lvName, lvToEmail, lvFromEmail, lvReplyEmail, lvSubject, lvMessage, lvUser, lvPassword, lvAuthentication, lvSMTP, lvPort, lvSSL, lvTLS
from email.MIMEText import MIMEText
strTo = $«lvToEmail»$
strFrom = $«lvFromEmail»$
strCC = ""
strError = ""
msg = MIMEText($«lvMessage»$)
msg['Subject'] = $«lvSubject»$
msg['From'] = $«lvFromEmail»$
msg['Reply-to'] = $«lvReplyEmail»$
msg['To'] = $«lvToEmail»$
smtp = smtplib.SMTP|||
+?(lvSSL ≠ "","_SSL","")+|||($«lvSMTP»$, $«lvPort»$)
smtp.sendmail(strFrom, strTo, msg.as_string())