function main(block) {
const CLANKER_DEPLOYMENT_EVENTS = [
{
address: '0x250c9FB2b411B48273f69879007803790A6AeA47',
signature:
'event TokenCreated(address tokenAddress, uint256 lpNftId, address deployer, string name, string symbol, uint256 supply, uint256 _supply, address lockerAddress)',
},
{
address: '0x9B84fcE5Dcd9a38d2D01d5D72373F6b6b067c3e1',
signature:
'event TokenCreated(address tokenAddress, uint256 lpNftId, address deployer, uint256 fid, string name, string symbol, uint256 supply, address lockerAddress, string castHash)',
},
{
address: '0x732560fa1d1A76350b1A500155BA978031B53833',
signature:
'event TokenCreated(address tokenAddress, uint256 positionId, address deployer, uint256 fid, string name, string symbol, uint256 supply, address lockerAddress, string castHash)',
},
{
address: '0x375C15db32D28cEcdcAB5C03Ab889bf15cbD2c5E',
signature:
'event TokenCreated(address tokenAddress, uint256 positionId, address deployer, uint256 fid, string name, string symbol, uint256 supply, string castHash)',
},
{
address: '0x2A787b2362021cC3eEa3C24C4748a6cD5B687382',
signature:
'event TokenCreated(address indexed tokenAddress,address indexed creatorAdmin, address indexed interfaceAdmin, address creatorRewardRecipient, address interfaceRewardRecipient, uint256 positionId, string name, string symbol, int24 startingTickIfToken0IsNewToken, string metadata, uint256 amountTokensBought, uint256 vaultDuration, uint8 vaultPercentage, address msgSender )',
},
];
const createdTokens = [];
for (const tx of block.transactions) {
if (!tx.receipt) continue;
for (const log of tx.receipt.logs) {
const decoded = utils.evmDecodeLog(log, CLANKER_DEPLOYMENT_EVENTS);
if (decoded) {
createdTokens.push({
__filter_key: log.address,
contract_address: decoded.tokenAddress,
fid: decoded.fid,
deployed_at: new Date(parseInt(block.timestamp) * 1000).toISOString(),
symbol: decoded.symbol,
cast_hash: decoded.castHash,
deployer_address: decoded.deployer || decoded.creatorAdmin,
});
}
}
}
return createdTokens;
}