UniswapV2Factory

Unichain Browse chains

0x1f98400000000000000000000000000000000002

Solidity v0.5.16+commit.9c3226ce

🤖
Query this contract from your AI
Reference: 0x1f98400000000000000000000000000000000002
Sample prompt: "Tell me the current state of unichain/0x1f98400000000000000000000000000000000002"
No AI wired up yet? → mcp.smarts.md · Browse chains
Unichain is a docs-only chain on Smarts: source code and ABI are indexed, but live on-chain data (state, recent events, admin profile) is not currently available. AI agents can still query get_contract_info and get_contract_source via MCP.

Overview

Read Functions
5
Write Functions
3
Events
1

Read Functions

allPairs(uint256) view

Returns the pair contract address at the specified index in the factory's list.✨ AI

Parameters

Name Type Description
uint256

Returns

Name Type Description
address Pair contract address located at the provided index.✨ AI
allPairsLength() view

Return the total number of pair contracts created by this factory.✨ AI

Returns

Name Type Description
uint256 Total count of pair contracts (the length of the allPairs array).✨ AI
feeTo() view

Returns the address that currently receives protocol fees.✨ AI

Returns

Name Type Description
address The address designated to receive protocol fees (feeTo).✨ AI
feeToSetter() view

Returns the address that can change the protocol fee recipient.✨ AI

Returns

Name Type Description
address The address authorized to set the fee recipient (feeTo).✨ AI
getPair(address, address) view

Returns the pair contract address for the two token addresses, if it exists.✨ AI

Parameters

Name Type Description
address
address

Returns

Name Type Description
address Address of the pair contract for the token pair, or the zero address if no pair exists.✨ AI

Write Functions

createPair(tokenA: address, tokenB: address) nonpayable

Create a new pair contract for tokenA and tokenB and return its address.✨ AI

Parameters

Name Type Description
tokenA address Address of the first ERC-20 token.✨ AI
tokenB address Address of the second ERC-20 token.✨ AI

Returns

Name Type Description
pair address Address of the newly created pair contract.✨ AI
setFeeTo(_feeTo: address) nonpayable

Sets the address that receives protocol fees.✨ AI

Parameters

Name Type Description
_feeTo address Address that will receive protocol fees.✨ AI
setFeeToSetter(_feeToSetter: address) nonpayable

Set the address authorized to change the fee recipient.✨ AI

Parameters

Name Type Description
_feeToSetter address New address that can update the fee recipient (permissioned setter).✨ AI

Events

PairCreated(token0: address, token1: address, pair: address, uint256)
Name Type Indexed Description
token0 address
token1 address
pair address
uint256