scott-778 / coinmarketcap-sniper-bot Goto Github PK
View Code? Open in Web Editor NEWSniper bot to buy new tokens listed on Coinmarketcap.
License: MIT License
Sniper bot to buy new tokens listed on Coinmarketcap.
License: MIT License
Allow the user to choose a limit on the liquidity amount that the bot should snipe. High liquidity tends to move less with CMC listings, whereas low liquidity moves a lot, quickly. It's listed in the Telegram group that the bot funnels information from.
Example: if (tokenLiquidity < 250){
buy code//
One doubt where to change no. Of tokens to buy.
As I want to run it in VPS continuously so it needs to run continuously. Buying continuously and selling continuously till I stop the bot
Transaction Hash. Bought for 0.02 BNB but reflected only $ 0.55 in the balance please clarify.
0x4b9d0ef2a4ddcf990cb164ed0a46f7b762c77b394b62bbc6c0fd5af8fa8f01d6
Buy tax sell tax option separately also from to option also will be helpful. Like tax limit for buy 1% and sell tax 10% separate option for buy and sell would be more specfic targets can be achieved.
From to option like 1 to 3% buy tax and sell option from 1 to 20 separate feature may give option
Sir, On running the Bot this message was thrown pls clarify
....
async function checkForProfit(token) {
var sellAttempts = 0;
token.contract.on("Transfer", async (from, to, value, event) => {
const takeLoss = (parseFloat(token.investmentAmount) * (token.stopLossMultiplier - token.tokenSellTax / 100)).toFixed(18).toString();
const takeProfit = (parseFloat(token.investmentAmount) * (token.profitMultiplier + token.tokenSellTax / 100)).toFixed(18).toString();
const tokenName = await token.contract.name();
let bal = await token.contract.balanceOf(addresses.recipient);
const amount = await pancakeRouter.getAmountsOut(bal, token.sellPath);
const profitDesired = ethers.utils.parseUnits(takeProfit);
const stopLoss = ethers.utils.parseUnits(takeLoss);
let currentValue;
if (token.sellPath.length == 3) {
currentValue = amount[2];
} else {
currentValue = amount[1];
}
console.log('--- ', tokenName, '--- Current Value in BNB:', ethers.utils.formatUnits(currentValue), '--- Profit At:', ethers.utils.formatUnits(profitDesired), '--- Stop Loss At:', ethers.utils.formatUnits(stopLoss), '\n');
if (currentValue.gte(profitDesired)) {
if (buyCount <= numberOfTokensToBuy && !token.didSell && token.didBuy && sellAttempts == 0) {
sellAttempts++;
console.log("Selling", tokenName, "now profit target reached", "\n");
sell(token, true);
token.contract.removeAllListeners();
}
}
if (currentValue.lte(stopLoss)) {
if (buyCount <= numberOfTokensToBuy && !token.didSell && token.didBuy && sellAttempts == 0) {
sellAttempts++;
console.log("Selling", tokenName, "now stoploss reached", "\n");
sell(token, false);
token.contract.removeAllListeners();
}
}
});
}
[Running] node "c:\Users\x\cmcBot.js"
�[33m[2022-01-17T05:05:06.149Z] [INFO] - [Running gramJS version 2.4.1]�[0m
�[33m[2022-01-17T05:05:06.164Z] [INFO] - [Connecting to 149.154.167.91:80/TCPFull...]�[0m
�[33m[2022-01-17T05:05:08.136Z] [INFO] - [Connection to 149.154.167.91:80/TCPFull complete!]�[0m
? xxxxxxxxxxxxxxxx �[14D�[14C
Hello again, I think I got a bit further with your help already, but the bot did not do its job when a new cmc listing was released.
Line 84 was left unedited. However on the line 98 I wrote if(msg.includes('COINMARKETCAP || COINGECKO') && msg.includes('BNB'))
I would like to snipe cg and cmc.
thank you
Below Bug pops in the cmd please address
SyntaxError: Unexpected token { in JSON at position 251
at JSON.parse ()
at F:\BOT 08.03.2022\coinmarketcap-sniperbot-main\cmcBot.js:255:26
Describe the bug
After the purchase and approval of the token, the bot stops with an error. When executing a script in VS Code, an error appears:
"token[buycount - 1].checkProfit();
^
ReferenceError: buycount is not defined
at approve"
Can we make it work in any telegram channel specified if it do pls guide to how to do, thanks
Instead giving inputs everything we restart any option to give defined inputs so no need to give inputs everything we restart for low liquidity etc and even custom strategy
Is it possible to disable selling with const autosell false?
My investment amount was 160BUSD. It autosold in less than a minute for 156 Busd. I didn´t change the 90% stop loss limit; const stopLossXAmount = 0.90 The slippage was
1% buy
4% sell
--- Current Value in BUSD: 104435.611949807707733547 --- Profit At: 256.0 --- Stop Loss At: 128.0
Selling token profit target reached
selling tokens
--- Current Value in BUSD: 160.356854316344451995 --- Profit At: 256.0 --- Stop Loss At: 128.0
--- Current Value in BUSD: 160.356854316344451995 --- Profit At: 256.0 --- Stop Loss At: 128.0
--- Current Value in BUSD: 105088.926272523279600518 --- Profit At: 256.0 --- Stop Loss At: 128.0
--- Current Value in BUSD: 104439.212941291430615152 --- Profit At: 256.0 --- Stop Loss At: 128.0
--- Current Value in BUSD: 104439.212941291430615152 --- Profit At: 256.0 --- Stop Loss At: 128.0
--- Current Value in BUSD: 160.351264703788449887 --- Profit At: 256.0 --- Stop Loss At: 128.0
How can I have this actually selling at 0.9x? Or did the bot somehow think the token was bad?
Additional context
If the bot takes data from Telegram to calculate profit and loss when selling 'Slippage: хх% (sell)', then this will be an accurate and correct calculation.
Is it possible to replace the value maxTax with slipSell in the code and did it work correctly?
before:
const takeProfit = (profitXAmount + maxTax / 100) * 100;
const takeLoss = (stopLossXAmount - maxTax / 100) * 100;
after:
const takeProfit = (profitXAmount + slipSell / 100) * 100;
const takeLoss = (stopLossXAmount - slipSell / 100) * 100;
I am a beginner, Although its for the CMC call still i included my channel where i will post new coins about to be launched where it can await for the liquidity and buy the token feature would be helpful along with the existing features. here our bot is fully used to me. So we can use the bot for the launch of coins too
if system restarts or power shutdown on restart only approve and sell would be helpful for your consideration
Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
Describe the solution you'd like
A clear and concise description of what you want to happen.
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Additional context
Add any other context about the feature request here.
Can I use the key to generate the wallet instead? Because most addresses are small
node:internal/modules/cjs/loader:936
throw err;
^
Error: Cannot find module 'telegram'
Require stack:
[Done] exited with code=1 in 19.92 seconds
This is what happens when running the code.
I have written the required data at the lines 19, 20, 25, 27, 28, 30, 51 and 77-79
Could you help me set this running properly?
I really appreciate your work.
Thank you
Marketcap option from to will be additional help to filter right coins
Same like liquidity filter from to option if Marketcap filter given along with existing options would be promising
Nowadays bsc transaction fails many times.Bsc transaction failed when bot try selling after hitting the stop loss but failed, then Bot left that trade which results further loss may impact more % loss. Need to try again till the transaction success. Likewise buy transaction may also fail till sucess get token it should try again.
maxBuyTax: 10, instead upto option 10%, if it from maxBuyTax: 3 to maxBuyTax: 11 this option of from to would be great
maxSellTax: 10, instead upto option 10 % , Eg: if it from maxSellTax: 3 to maxSellTax: 11, this option of from to would be great
As 1% to 3% were not success most of the time as per I watched the new listing
If Buy Tax and Sell Tax function separately given, It will be helpful individuals strategy they can flexibly change the tax limitation to their
threshold.
Is it possible to buy with BUSD instead of BNB? I just want to know if I have to accept the price fluctuations of bnb or not.
Thank you
MarketCap filter can be used to enter in to trade as high market cap tokens were not moving much as existing holders were dumping to buy again in the lower price so entry can be limited to right value marketcap which will appreciate price.
I have 0.11 bnb on my wallet, but i just wanna buy 0.02bnb token, i check manual the gas and fee, it's actually enough, but when i try to buy. It also fail every single transaction because not enough bnb in wallet.
reason: 'processing response error',
code: 'SERVER_ERROR',
body: '{"jsonrpc":"2.0","id":53,"error":{"code":-32000,"message":"insufficient funds for gas * price + value"}}\n',
As its reconnecting 5 times after its disconnected which results in missing few listing when unnoticed So kindly fix it reconnecting issues or how to avoid reconnecting issue.
I've only changed the info that was necessary on the file in the comments, and ran it through node. It came up with the "Uncaught SyntaxError: Unexpected token ':'" error. I tried to look through the code and couldn't find the issue, ran it through VB for debug and still have the issue but it's not highlighted under any specific line as an error.
Just want know weather this feature included as its already closed by you 3 days before. Today it checked and this feature not working
Before Buying it needs to search the telegram channel for the contract. If it found the contract before then no buy if first time new message then buy.
Eg. Before it may got listed in coinjecko if so need not buy on the coinmarketcap bot
Like if it listed in cmc then not to buy for coingecko bot
With this filter sure it's complete, really it's good find to get more sucess
History from telegram can be loaded for 30 days and no repeat of token buy. Like if listed previously in cg then no buy in listing with cmc bot should not buy. Like if already listed in cmc then no buy in listing with cg bot should not buy.
Please comment if additional clarity on my request required.
recipient: '' // Your wallet address
over here do i put my bnb smart chain wallet address?
edit: also do you know if this works for trust wallet?
Before Buying it needs to search the telegram channel for the contract. If it found the contract before then no buy if first time new message then buy.
Eg. Before it may got listed in coinjecko if so need not buy on the coinmarketcap bot
Like if it listed in cmc then not to buy for coingecko bot
With this filter sure it's complete, really it's good find to get more sucess
Where is the Channel specified?
For me the bot just gives out random adresses that are not in the cmc group...
Setting Marketcap limits can give higher hands. Like setting low liquidity 1 to 150. Same in marketcap user can give his input - as liquidity is low but marketcap is higher before launch price maybe $1 on launch it may be in 3 $ so any time the marketcap can be brought down. So limiting the marketcap with liquidity gives additional confirmation
Describe the bug
A clear and concise description of what the bug is.
To Reproduce
Steps to reproduce the behavior:
Additional context
Add any other context about the problem here.
No Screenshots Please
As it buy both coingecko and cmc listing if it already pop message in coingecko price moved then again if it listed in cmc bot should not buy it feature is good. As price moves only any one listing. If bot checks for 3 days history if already listed it should not buy that token option would be good. Or any solution is good
Auto sell on reaching 60% and buy only below 10% tax functions possible would be good
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.