https://github.com/dev30na/daramet-donation-sync
افزونه درگاه پرداخت دونیت دارمت برای سایت و ربات تگرام با نصب اسان
https://github.com/dev30na/daramet-donation-sync
donation gateway-api mysql payment-gateway php telegrambot
Last synced: 28 days ago
JSON representation
افزونه درگاه پرداخت دونیت دارمت برای سایت و ربات تگرام با نصب اسان
- Host: GitHub
- URL: https://github.com/dev30na/daramet-donation-sync
- Owner: dev30na
- License: mit
- Created: 2025-07-04T22:20:30.000Z (10 months ago)
- Default Branch: main
- Last Pushed: 2025-07-29T21:01:24.000Z (10 months ago)
- Last Synced: 2025-07-29T21:55:32.288Z (10 months ago)
- Topics: donation, gateway-api, mysql, payment-gateway, php, telegrambot
- Language: PHP
- Homepage: https://daramet.com
- Size: 52.7 KB
- Stars: 7
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.en.md
- License: LICENSE
Awesome Lists containing this project
README
# 💸 Automated Donation Transactions with PHP + Telegram Bot
This PHP script helps you automatically fetch donation transactions from the Daramet API, store them in your database, and send notifications via a Telegram bot. It filters out duplicate transactions, updates user wallets, and converts amounts from Rial to Toman.
---
## 🎯 Features
* Direct connection to Daramet API
* Store donation data in MySQL
* Prevent duplicate entries
* Send notifications to Telegram (admin and user)
* Run via cron job every 5 minutes
* Amount conversion from Rial to Toman
* Increment user wallet balance by user ID
* IP-based access control (only server IP allowed)
* Bot extracts ID
* Site extracts email
---
## ⚙️ Quick Setup
Run the appropriate installer script with one of the following commands:
```bash
bash <(curl -sSL https://raw.githubusercontent.com/dev30na/daramet-donation-sync/main/install-web.sh)
```
> Advanced one-line installer for the **web** version
```bash
bash <(curl -sSL https://raw.githubusercontent.com/dev30na/daramet-donation-sync/main/install-bot.sh)
```
> Advanced one-line installer for the **Telegram bot** version
---
## 🧱 Database Table: `donation_logs`
Use this SQL to manually create the donation log table if needed:
```sql
CREATE TABLE IF NOT EXISTS donation_logs (
donate_id VARCHAR(255) PRIMARY KEY,
userid VARCHAR(255) NOT NULL,
amount INT NOT NULL,
created_at DATETIME NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
```
---
## 📬 Telegram Notifications (Bot Version Only)
If you provide your Telegram bot token and chat IDs, every new donation will be sent automatically to the admin and the donor. This helps you stay updated without logging into a control panel.
---
## 👤 Developer
> **Sina (dev30na)**
> [🌐 GitHub Profile](https://github.com/dev30na)
> Developed with ❤️