Skip to main content

send mails from az

Project description

AzMailer

Introduction

AzMailer is a Python class designed to facilitate sending emails using Azure Communication Services.

Inspired by the Azure Communication Services documentation here, AzMailer simplifies the process of sending emails by providing an easy-to-use interface for constructing and sending email messages.

Installation

To install azmailer, simply use pip:

pip install azmailer

Usage Example

To use the AzMailer class, follow these steps:

  1. Initialize the AzMailer object with the Azure Communication Service connection string and sender's email address:

    mailer = AzMailer(AZURE_CONNECTION_STRING, SENDER_EMAIL_ADDRESS)
    
  2. Construct an email message using the construct_message() method:

    email_message = mailer.construct_message(
        subject="Your Email Subject",
        content="Your Email Content",
        to_addresses=["recipient1@example.com", "recipient2@example.com"],
        attachments=["/path/to/file1", "/path/to/file2"]
    )
    
  3. Send the email message using the send_email() method:

    mailer.send_email(email_message)
    

Documentation

The Sphinx-generated documentation for azmailer can be found here.

Contribution

Feel free to contribute by submitting issues here.

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

azmailer-1.0.1-py3-none-any.whl (5.8 kB view details)

Uploaded Python 3

File details

Details for the file azmailer-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: azmailer-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 5.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.12.0

File hashes

Hashes for azmailer-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e24bf33f6ef7e4b7f91bf3c3c7df084a1c9a56540bcd3a0697c24efc28edcfff
MD5 a882b2b9f53245a58b85d38b411f431f
BLAKE2b-256 af9f9824ac0b387765225378f02a030977fc783821421cc31a1061667b6611a2

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