Giter Club home page Giter Club logo

amex-alerts's Introduction

amex-alerts

This quick script, designed to be run as a cron, checks the balances on your American Express rewards programmes (e.g. Membership Rewards or Avios) and alerts you to their balance each day.

With backend storage based on Redis, this script will provide you with a popup each day of your balance and how it has changed.

This is based on my amex gem which uses a non-public American Express API to view your account.

Screenshot

Requirements

  • An American Express account (it might have to be a UK one, I'm not sure)
  • Redis installed on your machine
  • Mac OS X with Notification Centre support

Usage

  • Set the amex_username and amex_password environmental variables with your American Express online services username and password respectively (you can do this inline when executing the script)
  • Execute alerts.rb with Ruby
ruby alerts.rb
amex_username=chuck_norris amex_password=roundhouse ruby alerts.rb
  • On first run, you'll just get a popup notifying you that you have a balance on each of your American Express reward programmes (if you have multiple cards on your account, you'll get an alert for each)
  • On susbsequent runs:
  • If your balance has changed, you'll be told the change and your new balance
  • If there's no change, you'll just be shown your balance

Running as a cron

The best way to use this is to set it up as a cron job to be run each day at a time when you're likely to be using your computer.

For instance, to set it to run a midday every day:

editor=my_favourite_editor crontab -e
0 12  * * * amex_username=chuck_norris amex_password=roundhouse ruby /path/to/alerts.rb

Now, save the file and it'll be added as a cron. To check it's there, just run crontab -l.

amex-alerts's People

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.