KLAYswap
Search…
FactoryView
A viewer contract that allows sorted searching of various KLAYswap data.

Code

Github Link: (Will be updated after official launch)

Address

Contract adress after production is deployed (scope link)

Read-Only Functions

factory

  • The address of the factory contract

getPoolCount

1
function getPoolCount() public view returns (uint)
Copied!
  • Number of pool in Factory contract

getFixedData

1
function getFixedData(uint si, uint ei) public view
2
returns (address[] memory, address[] memory, address[] memory, uint[] memory)
Copied!
  • Get basic information from si index to ei index pools
  • request
    • si : from index of pool
    • ei : to index of pool
  • response
    • list1 : exchange contract address list
    • list2 : exchange tokenA address list
    • list3 : exchange tokenB address list
    • list4 : exchange fee list

getAmountData

1
function getAmountData(uint si, uint ei) public view
2
returns (uint[] memory, uint[] memory, uint[] memory)
Copied!
  • Get liquidity information from si index to ei index pools
  • request
    • si : from index of pool
    • ei : to index of pool
  • response
    • list1 : total supply LP token list
    • list2 : amount of tokenA in exchange list
    • list3 : amount of tokenB in exchange list

getMiningData

1
function getMiningData(uint si, uint ei) public view
2
returns (uint[] memory, uint[] memory, uint[] memory)
Copied!
  • Get mining information from si index to ei index pools
  • request
    • si : from index of pool
    • ei : to index of pool
  • response
    • list1 : exchanges miningIndex list
    • list2 : exchanges lastMined list
    • list3 : exchanges mining list

getUserData

1
function getUserData(address user, uint si, uint ei) public view
2
returns (uint[] memory, uint[] memory, uint[] memory)
Copied!
  • Get information of specific user from si index to ei index pools
  • request
    • user : request user address
    • si : from index of pool
    • ei : to index of pool
  • response
    • list1 : Exchange User's LP token amount list
    • list2 : Exchange User's claimed KSP amount list
    • list3 : Exchange User's last index list
Last modified 1yr ago