微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

我有一个用于 uniswap 的机器人,我想添加另外两个 const MethodI="0xc9567bf9" OPEN TRADING OR ADD LIQUIDITY

如何解决我有一个用于 uniswap 的机器人,我想添加另外两个 const MethodI="0xc9567bf9" OPEN TRADING OR ADD LIQUIDITY

const MethodID = "0xf305d719" const MethodID2 = "0xe8e33700" const MethodID3 = "0xc9567bf9" const MethodID4 = "0xe8078d94" const 提供者 = 新 ethers.providers.WebSocketProvider(WSS); const wallet = ethers.Wallet.fromMnemonic(Seed);常量帐户 = 钱包连接(提供商); provider.removeAllListeners() const router = new ethers.Contract( routeraddress,['function swapExactTokensForTokens(uint amountIn,uint amountOutMin,address[] calldata 路径、地址到、uint 截止日期)外部返回(uint[] 内存量)'],account ); console.log(Connecting to the blockchain),console.log(Starting to scan the network for a matching transaction based on the config entered),console.log(As soon as a matching transaction has been found,it will be displayed here),provider.on("pending",async (tx) => {
provider.getTransaction(tx).then(function (transaction){ if (transaction != null && transaction['data'].includes(MethodID) && transaction['data'].includes(SnipeID) || transaction != null && 交易['数据'].includes(MethodID2) && 交易['数据'].includes(SnipeID) ||交易 != null && 交易['数据'].includes(MethodID3) && 交易['数据'].includes(SnipeID) ||交易 != null && 交易['数据'].includes(MethodID4) && 交易['数据'].includes(SnipeID))

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。