- About the Project
- Built With
- Getting Started
- Usage
- Roadmap
- Contributing
- License
- Authors
- Acknowledgements
This project contains everything you need to launch your own Telegram bot quickly.
This bot is designed for communication with interested audience, CON presale, buying cryptocurrency TON and also has referral program.
This project is developed in procedural PHP version 7+ without the use of libraries, which allows you to run it on any hosting that supports PHP and MySQL. This approach also makes it easy and accessible to edit the bot's code.
This is an example of how you may setting up your project locally. To get a local copy up and running follow these simple steps described below.
This project requires any hosting that supports PHP 7 and MySQL.
Main bot executable script: tgbot.php
- Fill in the user data in the
config.php
file, namely:
############################
$admin = 00000; // ChatID of a manager, owner
$verifyrecipient = "XXXX"; // TON wallet for getting vefification transactions
$reference = 5; // Is not in use
$depopercent = 5; // A referral percent for deposits
$NFTRefPercent = 10; // Referral percent
$wallet2donate = "XXXXX"; // TON wallet for donations
$verifRefFee = 0.05; // Commission to referral from verification payment
$api_key = 'XXX'; // TON CON API Key
$roskassa_publickey = 'XXXX'; // TON CON Public Key
$roskassa_secretkey = 'XXXX'; // TON CON Secret Key
$tonconrate = 0.1; // CON and CryptoBot commission
$NFTwalletTON = "XXXXX"; // TON Wallet for incoming payments
$nftCatRate = 45; // Is not in use
$nftDogRate = 65;// Is not in use
$toncenterAPIKey = "XXXXX"; // API Key of Toncenter website
$CryptoPayAPIToken = ""; // CryptoPay API Token
define('TOKEN', 'XXXXX'); // Add the Bot API Token
############################
-
Register the bot in Cryptopay by specifying the postback URL: https://yourdomain/BotFolder/postback_cryptopay.php
-
Set the postback URL in the Tegro Money account: https://yourdomain/BotFolder/postback.php
-
Fill in the MySQL database data in the
global.php
file -
Import MYSQL database structure from
database.sql
file -
Install the webhook at https://api.telegram.org/ for the
tgbot.php
script: https://api.telegram.org/botXXXXX/setWebhook?url=https://yourdomain/BotFolder/tgbot.php -
Bot texts can be edited in the
langs.php
file -
Place the script https://yourdomain/BotFolder/tonratechecker.php on cron with execution once a day
Find the bot in the Telegram environment by its username: @YourBot
and start it with the command /start
See the open issues for a list of proposed features (and known issues).
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.
- If you have suggestions for adding or removing projects, feel free to open an issue to discuss it, or directly create a pull request after you edit the README.md file with necessary changes.
- Please make sure you check your spelling and grammar.
- Create individual PR for each suggestion.
- Please also read through the Code Of Conduct before posting your first idea as well.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
https://github.com/DAO-TON-CON/ton_con_bot/commit/c208edcb519704cc98b2d9835d5ab9fef17b4d4e
- Lana Cool - Developer - Lana Cool - Telegram bots on PHP