Searcher Call Data
The _searcherCallData
argument of the FastLane Auction Handler's submitFlashBid
and submitFastBid
function should be the transaction data necessary for the searcher's smart contract (as specified by _searcherToAddress) to execute as intended.
The easiest way to get the correct _searcherCallData
is for the searcher to create a transaction directly to their own smart contract (as if FastLane didn't exist) and extract that transaction's 'data' value.
There are many approaches on how you want to use the _searcherCallData
and they're ultimately up to you.
Potential Approaches:
Use it to call another function inside your smart contract In this case
_searcherCallData
is an encoding ofyourFunction(yourParams)
that you most likely will call inside yourfastLaneCall
function withaddress(this).call(_searcherCallData)
Only some arguments to be decoded inside an internal function of your smart contract In this case
_searcherCallData
is an encoding ofparam1uint, param2string ..
and insidefastLaneCall
you will do_myInternalFunction(_searcherCallData)
and it's up to_myInternalFunction
to decode those back in usingabi.decode()
like(_param1, _param2) = abi.decode(_searcherCallData, (uint, string))
Example:
Then in your searcher contract you will be able to use it in the fastLaneCall(
If on the other hand
You just want to get access to params
Last updated