{"id":19605236,"url":"https://github.com/macket/telegramblackbot","last_synced_at":"2026-03-04T12:32:33.757Z","repository":{"id":101868930,"uuid":"328928781","full_name":"Macket/TelegramBlackBot","owner":"Macket","description":"Telegram bot for grid trading on waves.exchange","archived":false,"fork":false,"pushed_at":"2021-01-15T08:45:37.000Z","size":369,"stargazers_count":4,"open_issues_count":1,"forks_count":3,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-04-05T02:33:32.866Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Macket.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":"2021-01-12T09:03:55.000Z","updated_at":"2024-01-19T10:27:58.000Z","dependencies_parsed_at":null,"dependency_job_id":"e5c7064c-111a-4465-83c3-6a133c9483dc","html_url":"https://github.com/Macket/TelegramBlackBot","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Macket%2FTelegramBlackBot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Macket%2FTelegramBlackBot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Macket%2FTelegramBlackBot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Macket%2FTelegramBlackBot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Macket","download_url":"https://codeload.github.com/Macket/TelegramBlackBot/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251196166,"owners_count":21550914,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":[],"created_at":"2024-11-11T09:42:02.842Z","updated_at":"2025-04-27T19:32:47.320Z","avatar_url":"https://github.com/Macket.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# TelegramBlackBot\n\nTelegramBlackBot (based on [BlackBot](https://github.com/Macket/BlackBot)) implements grid trading strategy with Telegram interface. It can work with any assets pair on the Waves DEX.\n\nGrid trading doesn’t care about which way the market’s going — in fact, as a profitable strategy it works best in ranging markets. The strategy places a ladder of sells at regular intervals above market price, and another ladder of buys beneath it. If a sell is filled, those funds are used to place a buy just beneath that sell. Thus you can think of the grid as a series of pairs of buys/sells stretching up and down the price chart, with either the buy or sell in each pair always active.\n\nFor example, let’s say the last price is 2000 satoshis you’ve got sells laddered up at 2100, 2200, 2300… If the price hits 2100, you immediately use those funds to place a new buy at 2000. If it drops to 2000 again, you buy back the Incent you sold at 2100. If it rises further, you sell at 2200 and open a buy at 2100. Whichever way the price moves, you’re providing depth — buffering the market and smoothing out any peaks and troughs. Additionally, if you open and then close a trade within a tranche (e.g. you sell at 2200, then buy back at 2100) then you make a small profit.\n\n## Getting Started\n\nTelegramBlackBot requires Python 3.7 and packages specified in ```requirements.txt```.\n\nYou can install them with\n\n```\npip install -r requirements.txt\n```\n\nBefore you start TelegramBlackBot it is necessary to create ```.env``` file:\n\n```\ntouch .env\n```\n\nand fill in this file according to the example below:\n\n```\nTELEGRAM_BOT_TOKEN = XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX\nUSER_ID = XXXXXXXXXXX\n\nNODE = http://nodes.wavesnodes.com\nNETWORK = mainnet\nMATCHER = https://matcher.waves.exchange\nORDER_FEE = 300000\nORDER_LIFETIME = 86400\n\nPRIVATE_KEY = XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX\n\nAMOUNT_ASSET = WAVES\nPRICE_ASSET = DG2xFkPdDwKUoBkzGAhQtLpSGzfXLiCYPEzeKH2Ad24p\n```\n\n```TELEGRAM_BOT_TOKEN``` is the token got from [BotFather](https://t.me/BotFather)\n\n```USER_ID``` is the telegram id of the account which will interact with bot (other users will be ignored)\n\n```NODE``` is the address of the fullnode\n\n```NETWORK``` can be either 'mainnet' or 'testnet'\n\n```MATCHER``` is the matcher address\n\n```ORDER_FEE``` is the fee to place buy and sell orders\n\n```ORDER_LIFETIME``` is the maximum life time (in seconds) for an open order\n\n```PRIVATE_KEY``` is the private key of the trading account\n\n```AMOUNT_ASSET``` and ```PRICE_ASSET``` are the IDs of the traded assets pair\n\n\n\nThen you can start TelegramBlackBot with this command:\n\n```\npython main.py\n```\n\n## Setting grid\n\nOnce TelegramBlackBot is started you should go to Telegram, open the bot and send ```/start``` command:\n\n![start](https://raw.githubusercontent.com/Macket/TelegramBlackBot/master/img/readme/1_start.png)\n\nThen you can choose ```ASK```, ```BID``` or ```LAST``` as base price (grid will be created around this price) or set it ```Manually```. After that configure other parameters:\n\n![configure](https://raw.githubusercontent.com/Macket/TelegramBlackBot/master/img/readme/2_configure.png)\n\nCheck them:\n\n![check](https://raw.githubusercontent.com/Macket/TelegramBlackBot/master/img/readme/3_check.png)\n\nAnd set grid:\n\n![grid](https://raw.githubusercontent.com/Macket/TelegramBlackBot/master/img/readme/4_grid.png)\n\nWhen one of the orders is filled bot will automatically place the new opposite order and you will receive a notification about that:\n\n![order_filled](https://raw.githubusercontent.com/Macket/TelegramBlackBot/master/img/readme/5_order_filled.png)\n\nIf you want to reset grid, just send ```/start``` command again and set new parameters.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmacket%2Ftelegramblackbot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmacket%2Ftelegramblackbot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmacket%2Ftelegramblackbot/lists"}