Skip to main content

A package with a function for sending emails easily using sendgrid.

Project description

psusannx_email

A package that allows emails to be sent through a python function using Sendgrid, provided a valid Sendgrid API Key is passed as an argument to the function (sendgrid_api_key).

The docs for using Sendgrid with python can be found here.

This package was created to be used as a subpackage in a wider project - PSUSANNX.

Package Functions

  • send_email()

Installation

pip install psusannx-email

Usage

# Import the function from the package
from psusannx_email import send_email

# Get some info about the function
help(send_email) 

Now use the function to send an email.

# Send a test email from your own personal email (once you have a sendgrid api key)
send_email(
    subject="Test email using the psusannx_email package", 
    body="This is a test email.\n\nThanks.",
    from_email="<your-email>",
    recipients=["<recipient-1>", "<recipient-2>"],
    sendgrid_api_key="<verified-sendgrid-api-key>"
)

Notes

  • The package is quite restricted in what it can do, but it only needs to do things that are required by the parent project so there won't be much development.
  • A new feature that will be added is the ability to send emails where the body is html, rather than just plain text.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

psusannx_email-0.1.4.tar.gz (3.4 kB view details)

Uploaded Source

Built Distribution

psusannx_email-0.1.4-py3-none-any.whl (3.7 kB view details)

Uploaded Python 3

File details

Details for the file psusannx_email-0.1.4.tar.gz.

File metadata

  • Download URL: psusannx_email-0.1.4.tar.gz
  • Upload date:
  • Size: 3.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for psusannx_email-0.1.4.tar.gz
Algorithm Hash digest
SHA256 acbd8c2bb4855c114d608cfdcce0efddc8633c51de385b8097c5dce71405c550
MD5 ac81c9062e08b01b7a827818533fa4e0
BLAKE2b-256 d1397c779d7602823f87979607b016b9b73fb94f1f17da897504f151d4eaf4b0

See more details on using hashes here.

File details

Details for the file psusannx_email-0.1.4-py3-none-any.whl.

File metadata

File hashes

Hashes for psusannx_email-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 b894818537ad9838ccbd3f8daa2ccf297ebf5cc79c57f5790f132180eaf2ccf6
MD5 9e0a931e87bdefa461ab11024679f985
BLAKE2b-256 2e0acb2020e43c46e2b18ff7e6e53b5c9af865c231eee1efe5f93ed2f079d2e2

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page