{"id":22792893,"url":"https://github.com/quaddarv1ne/telegramstarsbot","last_synced_at":"2026-01-23T20:41:23.619Z","repository":{"id":255385460,"uuid":"849445263","full_name":"QuadDarv1ne/TelegramStarsBot","owner":"QuadDarv1ne","description":"TelegramStarsBot is a Telegram bot that allows users to purchase images using Telegram Stars (XTR), an internal currency. This bot demonstrates how to integrate Telegram’s internal currency into a bot and handle payments","archived":false,"fork":false,"pushed_at":"2024-08-29T15:58:31.000Z","size":175,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-13T13:54:58.282Z","etag":null,"topics":["api","maestro7it","maximdupley","payment","payments","quadd4rv1n7","stars","telegram","telegram-bot"],"latest_commit_sha":null,"homepage":"https://stepik.org/users/150943726/teach","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/QuadDarv1ne.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-29T15:54:31.000Z","updated_at":"2024-09-27T12:43:02.000Z","dependencies_parsed_at":null,"dependency_job_id":"a5708775-f945-4d40-8be9-bb67d7150fea","html_url":"https://github.com/QuadDarv1ne/TelegramStarsBot","commit_stats":null,"previous_names":["quaddarv1ne/telegramstarsbot"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/QuadDarv1ne/TelegramStarsBot","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/QuadDarv1ne%2FTelegramStarsBot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/QuadDarv1ne%2FTelegramStarsBot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/QuadDarv1ne%2FTelegramStarsBot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/QuadDarv1ne%2FTelegramStarsBot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/QuadDarv1ne","download_url":"https://codeload.github.com/QuadDarv1ne/TelegramStarsBot/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/QuadDarv1ne%2FTelegramStarsBot/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28699717,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-23T17:25:48.045Z","status":"ssl_error","status_checked_at":"2026-01-23T17:25:47.153Z","response_time":59,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api","maestro7it","maximdupley","payment","payments","quadd4rv1n7","stars","telegram","telegram-bot"],"created_at":"2024-12-12T03:17:05.488Z","updated_at":"2026-01-23T20:41:23.600Z","avatar_url":"https://github.com/QuadDarv1ne.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# TelegramStarsBot\n\n![telegram_stars.jpg](img/telegram_stars.jpg)\n\n**TelegramStarsBot** is a Telegram bot that allows users to purchase images using Telegram Stars (XTR), an internal currency. This bot demonstrates how to integrate Telegram’s internal currency into a bot and handle payments.\n\n## Project Structure\n\n- **bot.py**: The main file containing the bot's logic.\n- **config.py**: Configuration file for storing environment variables.\n- **database.py**: Module for interacting with the SQLite database.\n- **.env**: File for storing environment variables (should be added to `.gitignore`).\n\n## Installation\n\n1. Clone the repository:\n\n    ```bash\n    git clone https://github.com/QuadDarv1ne/TelegramStarsBot/\n    cd TelegramStarsBot\n    ```\n\n2. Install dependencies:\n\n    ```bash\n    pip install -r requirements.txt\n    ```\n\n3. Rename `exmpl.env` to `.env` and add the following lines:\n\n    ```env\n    TOKEN='your_bot_token'\n    DATABASE='payments.db'\n    ```\n\n## Usage\n\n1. **Run the bot:**\n\n    Execute the command:\n\n    ```bash\n    python bot.py\n    ```\n\n2. **Functionality:**\n\n    - `/start`: Sends a welcome message with a button to purchase an image.\n    - **\"Buy Image\" Button**: Sends an invoice to the user for payment.\n    - **Successful Payment Handling**: After a successful payment, the bot sends the image and saves payment information to the database.\n    - `/paysupport`: Informs users about the no-refund policy and provides support contact information for any questions.\n\n## Files\n\n- **bot.py**: Contains the core bot code, including command and payment handlers.\n- **config.py**: Loads environment variables and provides them for use in other modules.\n- **database.py**: Contains functions for initializing the database and saving payment information.\n- **.env**: Secret data (should be created).\n\n## Notes\n\n- Make sure to add the `.env` file to `.gitignore` to avoid accidentally publishing sensitive information.\n\n## License\n\nThis project is provided \"as is,\" with no warranties. You are free to use and modify it as you see fit.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fquaddarv1ne%2Ftelegramstarsbot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fquaddarv1ne%2Ftelegramstarsbot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fquaddarv1ne%2Ftelegramstarsbot/lists"}