An open API service indexing awesome lists of open source software.

https://github.com/liddiard/flight-deal-alerts

Posts flight deals from The Flight Deal's RSS feed to a Slack channel. Not affiliated with The Flight Deal.
https://github.com/liddiard/flight-deal-alerts

alerting flights slack

Last synced: 8 days ago
JSON representation

Posts flight deals from The Flight Deal's RSS feed to a Slack channel. Not affiliated with The Flight Deal.

Awesome Lists containing this project

README

          

# ✈️🔔 Flight deal alerts for Slack

Make automated posts like this to a Slack channel:

Screenshot 2023-05-23 at 13 01 27

## Setup and usage

### With Docker (recommended)

From the top level of the repo, run:

```bash
touch lastChecked
cp .env.example .env
```

In the .env file, fill in the `SLACK_WEBHOOK_URL` environment variable ([get one here](https://api.slack.com/messaging/webhooks)). If desired, you may also change the city following [instructions below](#change-city). Then, run:

```bash
docker compose up -d
```

That's it!

### Without Docker

1. Install: `npm i`
2. Follow [instructions here](https://api.slack.com/messaging/webhooks) to get a Slack "app" and webhook URL.
2. Run the script (manually): `SLACK_WEBHOOK_URL= FLIGHT_DEAL_CITY="New York City" node index.js`

You probably want to set up the script to run automatically using cron with a frequency of every hour or less.

## Change city

You can change the city by examining the RSS feed for supported cities and updating the `FLIGHT_DEAL_CITY` environment variable.