Skip to content

TG³ is a TooGoodToGo Telegram bot, notifying you about available favorite items

Notifications You must be signed in to change notification settings

LucasPlacentino/TG3

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 

Repository files navigation

TG³ [ 🚧 WIP 🚧 ]

A fork of LauPaSat-pl/TGTG notifications, and inspired by Der-Henning/tgtg and kacpi2442/am_bot

tgtg notifications tgtg notifications tgtg notifications

This runs 100% automatically on Github actions (not counting the set up), to check for your favourite TooGoodToGo bags and send you a Telegram message about it.

How to use

  1. Create a new Telegram bot using BotFather tutorial,
  2. Check your Telegram ID tutorial,
  3. Install the tgtg Python library
pip install tgtg
  1. Run
from tgtg import TgtgClient

client = TgtgClient(email="<your_email>")
credentials = client.get_credentials()

You should receive an email from TooGoodToGo. The client will wait until you validate the login by clicking the link inside the email.

Once you clicked the link, you will get credentials and be able to use them

print(credentials)
{
    'access_token': '<your_access_token>',
    'refresh_token': '<your_refresh_token>',
    'user_id': '<your_user_id>',
    'cookie': '<cookie>',
}
  1. Fork this repo,
  2. In your repo add secrets (tutorial) you got from earlier steps (TooGoodToGo and Telegram), you can check how to name them in notitications.yml file,
  3. Make sure it's up and running. (It's ok, if at least one of the TG³ notifications badges at the top is green)

About

TG³ is a TooGoodToGo Telegram bot, notifying you about available favorite items

Topics

Resources

Code of conduct

Security policy

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

Packages

No packages published

Languages

  • Python 100.0%