Skip to content

nandweza/contact-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CONTACT API

The Contact API is a backend server that enables visitors to send emails through a contact form on my portfolio website. It uses Node.js, Express, and Nodemailer. The API handles the contact form submissions and forwards the emails to my Gmail account.

Features

  • Simple contact form to collect name, email, subject, and message.
  • Forwarding of contact information emails to my Gmail account.

Requirements

To run the Contact API, you need the following software installed on your machine:

  • Node.js (version 14 or later)
  • npm (Node Package Manager)

Installation

  1. Clone the repository to your local machine:

    git clone https://github.com/your_username/contact-api.git
    
    
    
  2. Navigate to the project directory:

    cd contact-api
    
    
  3. Install the dependencies:

    npm install
    
    
  4. Configure the Email Account:

    • Create .env file,
    • Save the email credentials and app-specific password in .env with your Gmail account details.
  5. Start the server:

     npm start
    
    

Lessons Learned

  • Practiced designing RESTful APIs with Express.
  • Gained experience with form validation and error handling.
  • Learned how to structure backend projects for scalability.

Contribution

Contributions to this project are welcome! If you find any issues or have suggestions for improvements, feel free to open an issue or submit a pull request.

License

MIT License – free to use and adapt.

About

API for handling messages from form then send them to my email

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published