Skip to content

About

🥫 🎫 Automatic coupon clipper for Safeway and other Albertsons brands' online "for U" coupons

Topics

Resources

Contributing

Stars

82 stars

Watchers

10 watching

Forks

Repository files navigation

safeway-coupons

Automatic coupon clipper for Safeway and other Albertsons brands' online "for U" coupons

License PyPI Python CI Coverage Renovate GitHub stars

safeway-coupons is a tool that will log in to an Albertsons brand store account (such as Safeway), and attempt to select all of the "for U" electronic coupons on the site so they don't have to each be clicked manually.

See the documentation site for full project details!

Supported store brands

The web sites for all Albertsons brands (including Safeway) use the same platform, so coupon clipping works the same way on each. safeway-coupons supports the following Albertsons brands:

Acme, Albertsons Market, Albertsons, Amigos, Andronico's, Balducci's, Carrs, Haggen, Jewel-Osco, Kings, Market Street, Pavilions, Randalls, Safeway, Shaw's, Star Market, Tom Thumb, United Supermarkets, Vons

Quick start

PyPI package

Ensure Google Chrome is installed.

Install with uv or pipx:

uv tool install safeway-coupons
pipx install safeway-coupons

Configure a store account (account-name is a label you choose, such as main or test):

safeway-coupons accounts add safeway account-name my.account.email@example.com

Sign in interactively, using a multi-factor authentication (MFA) code if prompted:

safeway-coupons --login-only

Clip all coupons:

safeway-coupons

Docker Compose

Set up Docker Compose using the sample compose.yaml.

Configure a store account (account-name is a label you choose, such as main or test):

docker compose run --rm safeway-coupons accounts add safeway account-name my.account.email@example.com

Sign in interactively, using a multi-factor authentication (MFA) code if prompted:

docker compose run --rm safeway-coupons --login-only

Start the service to clip coupons on a schedule:

docker compose up -d

When run with no arguments, the container runs the service to clip coupons on a schedule. To clip all coupons on demand, run with at least one argument (such as -n/--no-notify):

docker compose run --rm safeway-coupons --no-notify

Further information

See the documentation site for full project details!

Design notes

Google Chrome is used to complete the sign in process. To reduce how often sign in prompts for multi-factor authentication (MFA) verification codes, a persistent browser profile directory is created for each configured store account and is reused for logins with the same account.

Once a signed in session is established, coupon clipping is performed using HTTP requests via requests.

The store sign in page is protected by a web application firewall (WAF). Sign in may fail based on your IP's reputation, either by presenting an interactive challenge (such as a captcha) or denying sign in attempts altogether. safeway-coupons can't complete these interactive challenges.

License

Copyright (C) 2012 Stephen Kent and contributors

Licensed under the GNU General Public License v3.0 or later (GPL-3.0-or-later).

Project template

This project is based on and maintained with copier-project.

About

🥫 🎫 Automatic coupon clipper for Safeway and other Albertsons brands' online "for U" coupons

Topics

Resources

Contributing

Stars

82 stars

Watchers

10 watching

Forks

Releases

Packages

Used by

Contributors

Languages