Code Monkey home page Code Monkey logo

send-emails-with-amazon-ses's Introduction

AWS SES Email Sending Application

This application is designed to provide a seamless and comprehensive solution for sending and managing emails using Amazon Web Services (AWS) Simple Email Service (SES). It follows a structured pattern with handlers, services, and routes, allowing for flexibility and customization in email communications.

Table of Contents

Prerequisites

Before using this application, make sure you have the following prerequisites:

  • Node.js: Install Node.js from nodejs.org.

  • AWS SES Credentials: Obtain AWS SES credentials (Access Key ID and Secret Access Key) by setting up an AWS account and SES service. Ensure that your AWS credentials are correctly configured on your local machine. in the env file for security

  1. Clone this repository to your local machine:

    https://github.com/MbohBless/Send-Emails-with-amazon-ses.git
    next
    npm install
    next
    npm start 

Usage

Now that you have successfully installed and set up the application, you can use it for sending emails, managing templates, and more. Here are some common usage scenarios:

Send Custom Email

  • Endpoint: /send
  • HTTP Method: POST
  • Description: Sends a custom email using AWS SES.
  • Request Body: JSON object containing email details (e.g., recipient, subject, message).
  • Example Request:
{
    "recipient": "[email protected]",
    "subject": "Hello from AWS SES",
    "body": "This is a test email from AWS SES."
}

Send Template Email

  • Endpoint: /sendtemplate
  • HTTP Method: POST
  • Description: Sends an email using an email template stored in your application.
  • Request Body: JSON object containing template name and email details.
  • Example Request:
    {
      "templateName": "welcome",
      "to": "[email protected]",
    }

Generate Email Templates

  • Endpoint: /generateTemplates
  • HTTP Method: POST
  • Description: Generates email templates for use in the /sendtemplate endpoint.
  • Request Body: The Body in this case is usually empty and always need unless the services folder or the handler is is modified. in this case there are about 5 templates that i did create which can be modified to match the required context.

Retrieve Email Template

  • Endpoint: /template/:tempName

  • HTTP Method: GET

  • Description: Retrieves an email template by name.

  • Parameters:

    • tempName: The name of the template to retrieve.
  • Example Request: /template/welcome

  • Example Response: JSON object containing the template details.

    Delete Email Template

  • Endpoint: /template/:tempName

  • HTTP Method: DELETE

  • Description: Deletes an email template by name.

  • Parameters:

    • tempName: The name of the template to delete.
  • Example Request: /template/welcome

  • Example Response: HTTP status code indicating success or failure.

Contributing

Contributions to this project are welcome! If you have ideas for improvements or new features, please open an issue or submit a pull request and if you wish get to me on just do I am lazy working when no one shows their interest in my ideas Email: [email protected] ๐Ÿ˜๐Ÿ˜๐Ÿ˜.

send-emails-with-amazon-ses's People

Contributors

mbohbless avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.