imap-json-fetcher/README.md

32 lines
950 B
Markdown

# IMAP JSON Fetcher
## Setup
Before running the `imap-json-fetcher`, ensure that the following environment variables are set:
- `IMAP_HOST`: Your IMAP server address (e.g., `imap.example.com:993`).
- `IMAP_USERNAME`: Your email username.
- `IMAP_PASSWORD`: Your email password.
You can set these environment variables in a Unix-like terminal as follows:
```bash
export IMAP_HOST="your_imap_server_address"
export IMAP_USERNAME="your_username"
export IMAP_PASSWORD="your_password"
```
## Running the Script
To run the `imap-json-fetcher`, navigate to the `dist` directory where the binary is located, and use the following command:
```bash
./imap-json-fetcher
```
This assumes that you have already compiled the binary and placed it in the `dist` directory.
## Output
The `imap-json-fetcher` will listen for new emails and output the extracted email addresses in separate JSON files, one per email, named in the format `email-seqNum.json`.