Giter Site home page Giter Site logo

himacharan128 / gmailautoresponder Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 10.77 MB

A Node.js based app that is able to respond to emails sent to Gmail mailbox while we’re out on a vacation.

Home Page: https://youtu.be/5RH4BimvuF8?si=mSwqNV3fTpVmRzsG

JavaScript 100.00%

gmailautoresponder's Introduction

AutoResponder for Gmail

This Node.js application automatically responds to unreplied emails in your Gmail inbox while you're on vacation.

Introduction

This Node.js application uses the Gmail API to check for new emails in your Gmail inbox, identify unreplied emails, and automatically respond with a predefined message. It also adds a label to the email and moves it to the labeled category. The application repeats this process in random intervals, simulating a vacation auto-responder.

Prerequisites

Before using this application, ensure you have the following:

Installation

  1. Clone this repository to your local machine:

      git clone https://github.com/himacharan128/gmailAutoResponder.git
      cd gmailAutoResponder
  2. Install dependencies:

      npm install
  3. Configure Gmail API:

  • Enable the Gmail API and download the credentials.json file from the Google Cloud Console.
  • Save the credentials.json file in the project directory.
  1. Create userSecret.json: Create a userSecret.json file in the project directory with the following structure:
      {
     "installed": {
       "client_id": "<YOUR_CLIENT_ID>",
       "client_secret": "<YOUR_CLIENT_SECRET>",
       "redirect_uris": ["urn:ietf:wg:oauth:2.0:oob", "http://localhost"]
       }
     }

Usage

Run the application with the following command:

  npm start

Visit http://localhost:8080 in your browser to authenticate and start the auto-responder.

Configuration

Adjust the following variables in app.js to customize the behavior:

  • LabelName: The label name for auto-replied emails.
  • SCOPES: Gmail API scopes for authentication.

File Structure

  • app.js: Main application file with the server setup and Gmail API integration.
  • gmailFunctions.js: Module containing functions for interacting with the Gmail API.
  • userSecret.json: JSON file containing your OAuth 2.0 client credentials.

Notes

  • The app processes unreplied emails at random intervals to simulate a real-time vacation response.
  • Auto-reply message content can be customized in the sendAutoReply function.

gmailautoresponder's People

Contributors

himacharan128 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.