def __init__(self, **kwargs):
<EOL>self.__api_key = None<EOL>self.__sender = None<EOL>self.__reply_to = None<EOL>self.__to = None<EOL>self.__cc = None<EOL>self.__bcc = None<EOL>self.__subject = None<EOL>self.__tag = None<EOL>self.__html_body = None<EOL>self.__text_body = None<EOL>self.__track_opens = False<EOL>self.__custom_headers = {}<EOL>self.__attachments = []<EOL>self.__message_id = None<EOL>self.__metadata = {}<EOL>self.__template_id = None<EOL>self.__template_model = None<EOL>acceptable_keys = (<EOL>'<STR_LIT>',<EOL>'<STR_LIT>',<EOL>'<STR_LIT>',<EOL>'<STR_LIT:to>', '<STR_LIT>',  <EOL>'<STR_LIT>',<EOL>'<STR_LIT>',<EOL>'<STR_LIT>',<EOL>'<STR_LIT>',<EOL>'<STR_LIT>',<EOL>'<STR_LIT>',<EOL>'<STR_LIT>',<EOL>'<STR_LIT>',<EOL>'<STR_LIT>',<EOL>'<STR_LIT>',<EOL>'<STR_LIT>',<EOL>'<STR_LIT>'<EOL>)<EOL>for key in kwargs:<EOL><INDENT>if key in acceptable_keys:<EOL><INDENT>if key == '<STR_LIT>':<EOL><INDENT>setattr(self, '<STR_LIT:to>', kwargs[key])<EOL><DEDENT>else:<EOL><INDENT>setattr(self, key, kwargs[key])<EOL><DEDENT><DEDENT><DEDENT>self.__user_agent = '<STR_LIT>' % ('<STR_LIT:_>'.join([str(var) for var in sys.version_info]), __version__)<EOL>try:<EOL><INDENT>from django import VERSION<EOL>from django.conf import settings as django_settings<EOL>self.__user_agent = '<STR_LIT>' % (self.__user_agent, '<STR_LIT:_>'.join([str(var) for var in VERSION]))<EOL>if not self.__api_key and hasattr(django_settings, '<STR_LIT>'):<EOL><INDENT>self.__api_key = django_settings.POSTMARK_API_KEY<EOL><DEDENT>if not self.__sender and hasattr(django_settings, '<STR_LIT>'):<EOL><INDENT>self.__sender = django_settings.POSTMARK_SENDER<EOL><DEDENT>if not self.__track_opens and hasattr(django_settings, '<STR_LIT>'):<EOL><INDENT>self.__track_opens = django_settings.POSTMARK_TRACK_OPENS<EOL><DEDENT><DEDENT>except ImportError:<EOL><INDENT>pass<EOL><DEDENT>
Keyword arguments are:
api_key:        Your Postmark server API key
sender:         Who the email is coming from, in either
                "name@email.com" or "First Last <name@email.com>" format
to:             Who to send the email to, in either
                "name@email.com" or "First Last <name@email.com>" format
                Can be multiple values separated by commas (limit 20)
cc:             Who to copy the email to, in either
                "name@email.com" or "First Last <name@email.com>" format
                Can be multiple values separated by commas (limit 20)
bcc:            Who to blind copy the email to, in either
                "name@email.com" or "First Last <name@email.com>" format
                Can be multiple values separated by commas (limit 20)
subject:        Subject of the email, ignored if using Postmark templates
tag:            Use for adding categorizations to your email
html_body:      Email message in HTML
text_body:      Email message in plain text
track_opens:    Whether or not to track if emails were opened or not
custom_headers: A dictionary of key-value pairs of custom headers.
attachments:    A list of tuples or email.mime.base.MIMEBase objects describing attachments.
metadata:       A dictionary of key-value pairs of custom metadata. Keys and values can only be strings or ints.
template_id:    id of Postmark template. See: https://postmarkapp.com/blog/special-delivery-postmark-templates
template_model: a dictionary containing the values to be loaded into the template