Inspiration

I have a passion for using Web Services as I hope to venture into SEO, Email Marketing, Website Hosting and Creation soon as a hobby startup.

What it does

MailTime allows you to send mass emails email delivery system whether it is for your daily routines or mass marketing. Its interface is so simplistic and intuitive, which allows for fast and smooth delivery without the need for intensive hardware or complex instructions.

How I built it

This program is built with Sparkposts API and the use of python and GUI supported by tkinter.

Challenges I ran into

My biggest challenge was using outdated GUI, Tkinter, but the result was satisfying as it's very compact and minimal. I ran into a problem with Alexa, after setting up Lambda and re-coding to suit Alexa's voice control features, I ran into a problem when AWS requires approval of using Skills, which I have not acquired as of right now.

Accomplishments that I'm proud of

This is one of the first applications that I jumped fully into with no experience with API, but understood it as I read the Github Documentation and ended with a viable product.

What I learned

API's use, Python Zipping, DNS Servers, Alexa's.

What's next for MailTime

Implementing Marketing Technology into the simple app that will help businesses with low marketing budgets.

import time
from Tkinter import *
import tkMessageBox
import tkSimpleDialog
from sparkpost import SparkPost


try:
    # Python2
    import Tkinter as tk
except ImportError:
    # Python3
    import tkinter as tk

sp = SparkPost('11b7251ce8bc90a0344d03bda3c8646e8c858792')

email = ''
name = ''
addressBookName = ['Naseem Raad','Lena Ngungu','Kai Fleisehman','Kunwar Dev']
addressBookEmail = ['nzraad@gmail.com', 'lenangungu@hotmail.co.uk', 'kaifleischmans@gmail.com', 'kunwardev94@gmail.com']
def select():
    sf = var.get()
    if sf == 'Party Time':
        email = tkSimpleDialog.askstring("Enter Email", "Email")
        name = tkSimpleDialog.askstring("Enter Name", "Name")

        response = sp.transmissions.send(
        recipients=[
            email
        ],
        cc=['carboncopy@example.com'],
        bcc=['blindcarboncopy@example.com'],
        html='<p>HELLO {{name}}, WE ARE HAVING A BACKYARD BIRTHDAY PARTY FOR FRANCISCO, NOVEMBER 15TH, AT 7PM, 65 HIGH PARK AVENUE,RSVP AT 123852963</p>',
        text="",
        from_email='Naseem Raad <postmaster@64stacks.com>',
        subject="Let's Party!",
        description='contrived example',
        custom_headers={
            'X-CUSTOM-HEADER': 'foo bar'
        },
        track_opens=True,
        track_clicks=True,
        attachments=[
        ],
        campaign='sdk example',
        metadata={
            'key': 'value',
            'arbitrary': 'values'
        },
        substitution_data={
            'name': name
        },
        reply_to='no-reply@sparkpostmail.com'
        )
        print("Delivered")
    elif sf == 'Business Message':
        email = tkSimpleDialog.askstring("Enter Email", "Email")
        name = tkSimpleDialog.askstring("Enter Name", "Name")

        response = sp.transmissions.send(
        recipients=[
            email
        ],
        cc=['carboncopy@example.com'],
        bcc=['blindcarboncopy@example.com'],
        html='<p>HELLO {{name}}, WE ARE HAVING A BACKYARD BIRTHDAY PARTY FOR FRANCISCO, NOVEMBER 15TH, AT 7PM, 65 HIGH PARK AVENUE,RSVP AT 123852963</p>',
        text="",
        from_email='Naseem Raad <postmaster@64stacks.com>',
        subject="Let's Party!",
        description='contrived example',
        custom_headers={
            'X-CUSTOM-HEADER': 'foo bar'
        },
        track_opens=True,
        track_clicks=True,
        attachments=[
        ],
        campaign='sdk example',
        metadata={
            'key': 'value',
            'arbitrary': 'values'
        },
        substitution_data={
            'name': name
        },
        reply_to='no-reply@sparkpostmail.com'
        )
        print("Delivered")
    elif sf == 'Remind Me':
        email = tkSimpleDialog.askstring("Enter Email", "Email")
        name = tkSimpleDialog.askstring("Enter Name", "Name")

        response = sp.transmissions.send(
        recipients=[
            email
        ],
        cc=['carboncopy@example.com'],
        bcc=['blindcarboncopy@example.com'],
        html='<p>HELLO {{name}}, WE ARE HAVING A BACKYARD BIRTHDAY PARTY FOR FRANCISCO, NOVEMBER 15TH, AT 7PM, 65 HIGH PARK AVENUE,RSVP AT 123852963</p>',
        text="",
        from_email='Naseem Raad <postmaster@64stacks.com>',
        subject="Let's Party!",
        description='contrived example',
        custom_headers={
            'X-CUSTOM-HEADER': 'foo bar'
        },
        track_opens=True,
        track_clicks=True,
        attachments=[
        ],
        campaign='sdk example',
        metadata={
            'key': 'value',
            'arbitrary': 'values'
        },
        substitution_data={
            'name': name
        },
        reply_to='no-reply@sparkpostmail.com'
        )
        print("Delivered")
    elif sf == 'Study Group':
        email = tkSimpleDialog.askstring("Enter Email", "Email")
        name = tkSimpleDialog.askstring("Enter Name", "Name")

        response = sp.transmissions.send(
        recipients=[
            email
        ],
        cc=['carboncopy@example.com'],
        bcc=['blindcarboncopy@example.com'],
        html='<p>HELLO {{name}}, WE ARE HAVING A BACKYARD BIRTHDAY PARTY FOR FRANCISCO, NOVEMBER 15TH, AT 7PM, 65 HIGH PARK AVENUE,RSVP AT 123852963</p>',
        text="",
        from_email='Naseem Raad <postmaster@64stacks.com>',
        subject="Let's Party!",
        description='contrived example',
        custom_headers={
            'X-CUSTOM-HEADER': 'foo bar'
        },
        track_opens=True,
        track_clicks=True,
        attachments=[
        ],
        campaign='sdk example',
        metadata={
            'key': 'value',
            'arbitrary': 'values'
        },
        substitution_data={
            'name': name
        },
        reply_to='no-reply@sparkpostmail.com'
        )
        print("Delivered")
    elif sf == 'Send to Address Book':
        for name, email in zip(addressBookName, addressBookEmail):
            response = sp.transmissions.send(
            recipients=[
                email
            ],
            cc=['carboncopy@example.com'],
            bcc=['blindcarboncopy@example.com'],
            html='<p>HELLO {{name}}, WE ARE HAVING A BACKYARD BIRTHDAY PARTY FOR FRANCISCO, NOVEMBER 15TH, AT 7PM, 65 HIGH PARK AVENUE,RSVP AT 123852963</p>',
            text="",
            from_email='Naseem Raad <postmaster@64stacks.com>',
            subject="Let's Party!",
            description='contrived example',
            custom_headers={
                'X-CUSTOM-HEADER': 'foo bar'
            },
            track_opens=True,
            track_clicks=True,
            attachments=[
            ],
            campaign='sdk example',
            metadata={
                'key': 'value',
                'arbitrary': 'values'
            },
            substitution_data={
                'name': name
            },
            reply_to='no-reply@sparkpostmail.com'
            )
            print("Delivered")
    else:
        label1.configure(text='Invalid Choice')



root = tk.Tk()
llabel = StringVar()
ment = StringVar()


# use width x height + x_offset + y_offset (no spaces!)
root.geometry("%dx%d+%d+%d" % (330, 80, 200, 150))
root.title("MailTime")

var = tk.StringVar(root)
# initial value
var.set('-- Select --')

choices = ['Party Time', 'Business Message', 'Remind Me', 'Study Group','Send to Address Book']
option = tk.OptionMenu(root, var, *choices)
option.pack(side='left', padx=10, pady=10)
button = tk.Button(root, text="Let's Get Emailing", command=select)
label1 = Label(root, text="Welcome")
label1.pack(side='bottom', pady=10)
button.pack(side='left', padx=20)



root.mainloop()

Built With

Share this project:

Updates