Questions tagged [arbitrage]
The arbitrage tag has no usage guidance.
40
questions
0
votes
0
answers
13
views
Is it possible to import foundry anvil in rust?
I successfully installed and used anvil from the wsl shell.
I have some rust code, where i want to import foundry anvil instead of running from shell, cause i want to be able to control it from the ...
0
votes
1
answer
40
views
pancakeswap v2 flash loan arbitrage real output amount is not as expected
when i monitor a profitable trade. The difference in profit calculated by my own method and the result of getAmoutsOut is not significant. Before sending the transaction, I would use the getAmoutsOut ...
0
votes
1
answer
12
views
flashloan-arbitrage: ENS error
I am trying to write a flashloan trading arbitrage bot as my first project but I keep on hitting the same error and I can not seem to fix it. Can anyone help me? My code's repo is here: https://github....
1
vote
1
answer
109
views
Flashloan + flashbot
Can i use both flashloan and MEV builder in one transaction? Means borrowing from flashloan, then building my transaction in MEV builder (to prevent sandwich attack )?
If it is possible, can anyone ...
0
votes
0
answers
20
views
How is exchange rate calculated on DEX platforms like uniswap and sushiswap?
I started getting into the crypto scene and I read about liquidity pools but I am not sure how to get exchange rates into my javascript code, I looked for API's and SDK's but couldn't find any for the ...
0
votes
0
answers
20
views
An example of arbitrage opportunity when LPs deposit assets in a pool
I am studying about automated market making (Uniswap version x*y=k) for the first time and now I'm currently looking at liquidity pools.
Actually, I want to understand how the ratio of tokens' value ...
1
vote
1
answer
44
views
flash loan arbitrage vs flash loan attack
What is the difference between a flash loan arbitrage and a flash loan attack? If I somehow find an opportunity to make a 1000% profit which crashes one or more token, will it be considered an attack? ...
0
votes
0
answers
53
views
Execution Error - ERC20: Transfer Amount Exceeds Balance in Ethereum Smart Contract
I'm encountering a perplexing issue while working on an Ethereum smart contract. It seems to be a parameter related error, but I haven't been able to rectify it. The following error message is ...
0
votes
1
answer
73
views
I JUST RECENTLY TRIED A FRONT RUNNING BOT AS WELL [duplicate]
TOOK .51ETH FROM ME NOW HES ASKING FOR ANOTHER.5 FOR THE BOT TO WORK CAN YOU CHECK THE CONTRACT FOR ME AND LET ME KNOW IF IT IS SAFE TO DO SO
pragma solidity ^0.6.6;
// Import Libraries Migrator/...
0
votes
0
answers
16
views
How to decode orca.so api response
I'm building my arbitrage bot with orca.so, when I try to fetch the price via their api this is the response:
{
"jsonrpc": "2.0",
"result": {
"...
0
votes
0
answers
29
views
In "simple-arbitrage" code, where does the abi.ts come from? Is this hand written or this is from uniswap provided info?
Where does this abi.ts come from?
I was comparing it with Uniswap code here:
but they don't look the same. Thanks
0
votes
1
answer
85
views
Profit or just waste of time?
I have some questions that I hope will be answered here I posted this question on twitter as well but with no response, I am a newcomer in the world of crypto and decentralized exchanges and Flash-...
0
votes
2
answers
129
views
Is profitable direct arbitrage impossible with getAmountsOut?
I’ve run the math on a uniswap v2 arbitrage trade that looks more or less like this:
1) Buy X amount of token1 with Y amount of token0 on Uniswap
2) Sell equivalent amount of token1 in exchange for ...
1
vote
1
answer
911
views
Flash Loan Arbitrage Bot
I'm design an Arbitrage bot, and I wanted it to grab the funds from a flash loan.
How would you implement this?
1
vote
0
answers
43
views
How can I get a sense of slippage before committing to the transaction?
Of course, as we all know, determining slippage for a certainty is impossible. I've done my best in my code to reduce my impact on slippage, finding the largest amount across the two pools in my ...
1
vote
0
answers
250
views
Uniswap V2 getAmountOut arbitrage calculation
I'm trying to learn more about arbitrage bots and it seems I'm stuck on profit calculation.
Lets say I have two different routers - Uniswap V2 and Sushiswap
To calculate possible arbitrage I use ...
0
votes
0
answers
100
views
I am wondering what address do you use to call flashloan?
I am using this address to call flashloan 0x65aFADD39029741B3b8f0756952C74678c9cEC93 but I get Gas estimation failed error please let me know if you use another address and successfully call the ...
1
vote
2
answers
499
views
"Error: Transaction has been reverted by the EVM" <- don’t even know where to start
So, first off, I have checked every single question on this topic, and it seems to come down to the particulars of the code. I can't find a throughline for any of them.
That said, I have a bot that ...
1
vote
0
answers
53
views
hardhat script giving this error when ran
Please, I need help clearing this.
root@DESKTOP-O7HMHFH:/mnt/c/pr0/projects/arbitrage/comp# npx hardhat run scripts/manipulate.js --network localhost
Beginning Swap...
Input Token: COMP
Output Token:...
0
votes
4
answers
190
views
Flash loan basics
hello everyone pls i've been trying to write some solidity code for flash loans , im kind of new to it , i would like to know after testing and deploying your smart contract with a test net without ...
1
vote
1
answer
533
views
Triangular Arbitrage or multiple swap arbitrage
Is it posible to develop a bot with a multiple step arbitrage? like 5 swaps and above? trying my hands on triangular arbitrage with bots on dexes, able to run a binary arbitrage. can i get a sample ...
0
votes
0
answers
627
views
Formula For Calculating Optimal Input for Arbitrage Transaction
I have the following code which calculates the maximum order quantity permissible given a price impact of i, which I wrote based on this explanation of price impact:
https://dailydefi.org/articles/...
0
votes
0
answers
83
views
Assistance in Web3.py Arbitrage Calculating
Hey I was looking for a prototype on getting this task done in web 3.py
lets say the list of dex are: uniswap v2 & v3 and sushiswap
and the list of coins are: USDC/USDT/DAI
#3.Calculate each DEX's ...
0
votes
0
answers
120
views
Flashloan smart contract examples
Are there any complete examples of flashloan smart contracts that include a swapping arbitrage function and show how to enter the loan amount. Thanks in advance.
0
votes
2
answers
589
views
How to search for arbitrage opportunities?
Noticed some arbitrageurs playing around.
For example, this tx (swap BUSD for ETH https://bscscan.com/tx/0xdebf81a126249386d15ae003006f7b7862087aecf3ef9775a5f1d0bae10e6047) opened an arbitrage ...
1
vote
1
answer
307
views
Problem running arbitrage flashloan test app in JS [closed]
I´ve created a JS script to test arbitrage flashloan with Ethereum blockchain. When I attempt to run this code sample directly under the Truffle command line and run the uniswapFactory.getPair(...
0
votes
1
answer
111
views
Transaction failing but I'm unsure why
I am attempting to create a test arbitrage bot on the Goerli testnet.
Here is my smart contract which should perform a swap from Uniswap to Sushiswap :
pragma solidity =0.6.6;
import './...
2
votes
1
answer
209
views
Work out Eth price from getAmountsIn method
I am attempting to create a test arbitrage bot using Uniswap & SushiSwap.
I can successfully get the amount of X tokens I would get for 1 WETH on both dexes. For example:
Uniswap: WETH / USDT ...
3
votes
1
answer
567
views
How are arbitrage bots so fast?
I built a system to monitor token prices on a given EVM blockchain. I monitor the token prices on several decentralized exchanges (DEX) by looking at the reserves of tokens for pairs of tokens.
To ...
0
votes
1
answer
250
views
Flashloan Arbitrage error 'SafeERC20: low-level call failed'
So I finally am almost finished with my flashloan arbitrage how ever when I run it I get this error
'SafeERC20: low-level call failed'
here is my contract code
// SPDX-License-Identifier: MIT
pragma ...
1
vote
0
answers
693
views
Hardhat throwing 'missing revert data in call exception; Transaction reverted without a reason string'
After installing Hardhat's npm package latest version following this brief guide and setting up my first 'sample project', i tried to create a script and deploy a contract on the BSC mainnet. I edited ...
1
vote
1
answer
65
views
Make sure transaction will be in block x
I am currently building a frontrunning bot for the Binance Smart Chain.
The problem: Sometimes my transaction is getting into the block I want, sometimes I miss the block by some ms I guess
My ...
0
votes
2
answers
6k
views
How to fix PancakeLibrary: INSUFFICIENT_INPUT_AMOUNT?
I'm trying to make a multiple swap function in my smart contract using solidity. For example we want to swap BNB->BUSD->USDT->ADA->BNB. The contract interacts with PancakeSwap. I deployed ...
0
votes
1
answer
52
views
Are liquidity pool prices consistent in the same token pairs, between fee-designated pools in Uniswap v3?
In Uniswap v3, you can have up to three fee-designated pools (0.05%, 0.30% or 1.00%) per token pair.
Do the token prices remain exactly the same across these pools or are there discrepancies across ...
2
votes
0
answers
129
views
Any public contracts / dApps that can execute multiswap?
Are there any smart contracts on ETH mainnet that can be used to execute e.g. arbitrage swap on single call? E.g. USDC -> DAI -> WETH -> USDC?
Or actually I'm more interested doing round-trip ...
2
votes
1
answer
465
views
Why I need smart contract for arbitrage
To make arbitrage between two defis why i need a smart contract? web3py or web3js can interact with defi smart contracts. A script can monitor price difference and if find arbitrage opportunity script ...
1
vote
1
answer
212
views
How haven't flash loans completly destabilized the ethereum blockchain?
Now bare with me here, I might have kinda misunderstood what a flashloan actually is. Internet tells me that it's a type of uncollaterized lending, where a smart contract takes money out of a pool, ...
0
votes
2
answers
348
views
Solidity Expected '(' but got identifier
So I am working on a flash loan arbitrage in solidity and was coding the arbitrage logic when I got hit with
Expected '(' but got identifier
here is the code for the arbitrage
function startArbitrage(
...
0
votes
1
answer
317
views
MEV explore flashbots
What's the exact definition of Outlier MEV txs currently in review on Flashbot's MEV-explore dashboard?
Does it mean that the transactions there are currently under review and the profit (MEV Tx ...
1
vote
0
answers
329
views
Is there any trick (besides high gas fee) to get transactions included in the next Polygon block?
I recognize some arbitrage opportunities on the Polygon network and tend to include my transactions in the next block. Since Polygon's transaction time is too low, I know that I have to do it quickly ...