This repository is designed to send emails using SendGrid based on a list of email addresses provided in a CSV file. The email content is generated from an HTML template.
- Node.js installed on your machine
- A SendGrid account and API key
-
Clone the repository:
git clone https://github.com/yourusername/urbe-mails.git cd urbe-mails
-
Install the dependencies:
npm install
-
Create a
.env
file in the root directory of the project and add your SendGrid API key:SENDGRID_API_KEY=your_sendgrid_api_key
-
Prepare your
emails.csv
file in the root directory. The CSV file should have the following structure: -
Prepare your
template.html
file in the root directory. This file will be used as the HTML template for the emails.
To send the emails, run the following command:
npm run start
or
node index.js