diff --git a/projects/navi/abis/sui/0x81be491340a6964eb9903141c3068db55704b5892072eb9e372cc98f4b04639c.json b/projects/navi/abis/sui/0x81be491340a6964eb9903141c3068db55704b5892072eb9e372cc98f4b04639c.json deleted file mode 100644 index c501037e..00000000 --- a/projects/navi/abis/sui/0x81be491340a6964eb9903141c3068db55704b5892072eb9e372cc98f4b04639c.json +++ /dev/null @@ -1,5429 +0,0 @@ -{ - "calculator": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "calculator", - "friends": [], - "structs": {}, - "exposedFunctions": { - "caculate_utilization": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256" - ] - }, - "calculate_amount": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - "U256", - "U8" - ], - "return": [ - "U256" - ] - }, - "calculate_borrow_rate": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256" - ] - }, - "calculate_compounded_interest": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "calculate_linear_interest": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "calculate_supply_rate": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [ - "U256" - ] - }, - "calculate_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - "U256", - "U8" - ], - "return": [ - "U256" - ] - } - } - }, - "dynamic_calculator": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "dynamic_calculator", - "friends": [], - "structs": {}, - "exposedFunctions": { - "calculate_current_index": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256", - "U256" - ] - }, - "dynamic_caculate_utilization": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_calculate_apy": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U8", - "U64", - "U64", - "Bool" - ], - "return": [ - "U256", - "U256" - ] - }, - "dynamic_calculate_borrow_rate": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_calculate_supply_rate": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256", - "U256", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_health_factor": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "Address", - "U8", - "U64", - "U64", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_liquidation_threshold": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - "Address", - "U8", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_user_collateral_balance": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_user_collateral_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_user_health_collateral_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address", - "U8", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_user_health_loan_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address", - "U8", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_user_loan_balance": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_user_loan_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - } - } - }, - "incentive": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "incentive", - "friends": [ - { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "lending" - } - ], - "structs": { - "Incentive": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - }, - { - "name": "creator", - "type": "Address" - }, - { - "name": "owners", - "type": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "U256", - "Bool" - ] - } - } - }, - { - "name": "admins", - "type": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "U256", - "Bool" - ] - } - } - }, - { - "name": "pools", - "type": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "U8", - { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "PoolInfo", - "typeArguments": [] - } - } - ] - } - } - }, - { - "name": "assets", - "type": { - "Vector": "U8" - } - } - ] - }, - "IncentiveAdminCap": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - } - ] - }, - "IncentiveBal": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [ - { - "constraints": { - "abilities": [] - }, - "isPhantom": true - } - ], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - }, - { - "name": "asset", - "type": "U8" - }, - { - "name": "current_idx", - "type": "U64" - }, - { - "name": "distributed_amount", - "type": "U256" - }, - { - "name": "balance", - "type": { - "Struct": { - "address": "0x2", - "module": "balance", - "name": "Balance", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - } - ] - }, - "IncentiveOwnerCap": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - } - ] - }, - "PoolAdminSetting": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "sender", - "type": "Address" - }, - { - "name": "admin", - "type": "U256" - }, - { - "name": "value", - "type": "Bool" - } - ] - }, - "PoolInfo": { - "abilities": { - "abilities": [ - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": "U8" - }, - { - "name": "last_update_time", - "type": "U64" - }, - { - "name": "coin_types", - "type": { - "Vector": { - "Struct": { - "address": "0x1", - "module": "ascii", - "name": "String", - "typeArguments": [] - } - } - } - }, - { - "name": "start_times", - "type": { - "Vector": "U64" - } - }, - { - "name": "end_times", - "type": { - "Vector": "U64" - } - }, - { - "name": "total_supplys", - "type": { - "Vector": "U256" - } - }, - { - "name": "rates", - "type": { - "Vector": "U256" - } - }, - { - "name": "index_rewards", - "type": { - "Vector": "U256" - } - }, - { - "name": "index_rewards_paids", - "type": { - "Vector": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "Address", - "U256" - ] - } - } - } - }, - { - "name": "user_acc_rewards", - "type": { - "Vector": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "Address", - "U256" - ] - } - } - } - }, - { - "name": "user_acc_rewards_paids", - "type": { - "Vector": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "Address", - "U256" - ] - } - } - } - }, - { - "name": "oracle_ids", - "type": { - "Vector": "U8" - } - } - ] - }, - "PoolOwnerSetting": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "sender", - "type": "Address" - }, - { - "name": "owner", - "type": "U256" - }, - { - "name": "value", - "type": "Bool" - } - ] - } - }, - "exposedFunctions": { - "add_pool": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - "U8", - "U64", - "U64", - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - }, - "U64", - "U8", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "claim_reward": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "IncentiveBal", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "create_and_transfer_ownership": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "Address", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "earned": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - { - "Vector": { - "Struct": { - "address": "0x1", - "module": "ascii", - "name": "String", - "typeArguments": [] - } - } - }, - { - "Vector": "U256" - }, - { - "Vector": "U8" - } - ] - }, - "get_pool_count": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U64" - ] - }, - "get_pool_info": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - "U8", - "U64" - ], - "return": [ - "U64", - "U64", - "U256", - "U8" - ] - }, - "set_admin": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - "U256", - "Bool", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "set_owner": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - "U256", - "Bool", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "update_reward": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [] - } - } - }, - "lending": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "lending", - "friends": [], - "structs": { - "BorrowEvent": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "reserve", - "type": "U8" - }, - { - "name": "sender", - "type": "Address" - }, - { - "name": "amount", - "type": "U64" - } - ] - }, - "DepositEvent": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "reserve", - "type": "U8" - }, - { - "name": "sender", - "type": "Address" - }, - { - "name": "amount", - "type": "U64" - } - ] - }, - "LiquidationCallEvent": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "reserve", - "type": "U8" - }, - { - "name": "sender", - "type": "Address" - }, - { - "name": "liquidate_user", - "type": "Address" - }, - { - "name": "liquidate_amount", - "type": "U64" - } - ] - }, - "RepayEvent": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "reserve", - "type": "U8" - }, - { - "name": "sender", - "type": "Address" - }, - { - "name": "amount", - "type": "U64" - } - ] - }, - "WithdrawEvent": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "reserve", - "type": "U8" - }, - { - "name": "sender", - "type": "Address" - }, - { - "name": "to", - "type": "Address" - }, - { - "name": "amount", - "type": "U64" - } - ] - } - }, - "exposedFunctions": { - "borrow": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U8", - "U64", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "deposit": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U8", - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - }, - "U64", - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "liquidation_call": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - }, - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U8", - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 1 - } - ] - } - } - }, - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - }, - "Address", - "U64", - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "repay": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U8", - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - }, - "U64", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "withdraw": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U8", - "U64", - "Address", - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - } - } - }, - "logic": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "logic", - "friends": [ - { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "lending" - } - ], - "structs": {}, - "exposedFunctions": { - "calculate_avg_ltv": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address" - ], - "return": [ - "U256" - ] - }, - "calculate_avg_threshold": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address" - ], - "return": [ - "U256" - ] - }, - "dynamic_liquidation_threshold": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - "Address" - ], - "return": [ - "U256" - ] - }, - "execute_borrow": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [] - }, - "execute_deposit": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [] - }, - "execute_liquidate": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - }, - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address", - "U8", - "U8", - "U256" - ], - "return": [ - "U256", - "U256", - "U256" - ] - }, - "execute_repay": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [ - "U256" - ] - }, - "execute_withdraw": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [ - "U64" - ] - }, - "is_collateral": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - "Bool" - ] - }, - "is_health": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address" - ], - "return": [ - "Bool" - ] - }, - "is_loan": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - "Bool" - ] - }, - "user_collateral_balance": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - "U256" - ] - }, - "user_collateral_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - "U256" - ] - }, - "user_health_collateral_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address" - ], - "return": [ - "U256" - ] - }, - "user_health_factor": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - "Address" - ], - "return": [ - "U256" - ] - }, - "user_health_factor_batch": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "Vector": "Address" - } - ], - "return": [ - { - "Vector": "U256" - } - ] - }, - "user_health_loan_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address" - ], - "return": [ - "U256" - ] - }, - "user_loan_balance": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - "U256" - ] - }, - "user_loan_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - "U256" - ] - } - } - }, - "pool": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "pool", - "friends": [ - { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "lending" - }, - { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "storage" - } - ], - "structs": { - "Pool": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [ - { - "constraints": { - "abilities": [] - }, - "isPhantom": true - } - ], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - }, - { - "name": "balance", - "type": { - "Struct": { - "address": "0x2", - "module": "balance", - "name": "Balance", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - { - "name": "treasury_balance", - "type": { - "Struct": { - "address": "0x2", - "module": "balance", - "name": "Balance", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - { - "name": "decimal", - "type": "U8" - } - ] - }, - "PoolAdminCap": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - }, - { - "name": "creator", - "type": "Address" - } - ] - }, - "PoolBalanceRegister": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "sender", - "type": "Address" - }, - { - "name": "amount", - "type": "U64" - }, - { - "name": "new_amount", - "type": "U64" - }, - { - "name": "pool", - "type": { - "Struct": { - "address": "0x1", - "module": "ascii", - "name": "String", - "typeArguments": [] - } - } - } - ] - }, - "PoolCreate": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "creator", - "type": "Address" - } - ] - }, - "PoolDeposit": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "sender", - "type": "Address" - }, - { - "name": "amount", - "type": "U64" - }, - { - "name": "pool", - "type": { - "Struct": { - "address": "0x1", - "module": "ascii", - "name": "String", - "typeArguments": [] - } - } - } - ] - }, - "PoolWithdraw": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "sender", - "type": "Address" - }, - { - "name": "recipient", - "type": "Address" - }, - { - "name": "amount", - "type": "U64" - }, - { - "name": "pool", - "type": { - "Struct": { - "address": "0x1", - "module": "ascii", - "name": "String", - "typeArguments": [] - } - } - } - ] - } - }, - "exposedFunctions": { - "convert_amount": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U64", - "U8", - "U8" - ], - "return": [ - "U64" - ] - }, - "create_pool": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "PoolAdminCap", - "typeArguments": [] - } - } - }, - "U8", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "deposit": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - }, - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "deposit_treasury": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U64" - ], - "return": [] - }, - "get_coin_decimal": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - } - ], - "return": [ - "U8" - ] - }, - "normal_amount": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U64" - ], - "return": [ - "U64" - ] - }, - "unnormal_amount": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U64" - ], - "return": [ - "U64" - ] - }, - "withdraw": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U64", - "Address", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "withdraw_reserve_balance": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "PoolAdminCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U64", - "Address", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "withdraw_treasury": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "PoolAdminCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U64", - "Address", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - } - } - }, - "ray_math": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "ray_math", - "friends": [], - "structs": {}, - "exposedFunctions": { - "half_ray": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [], - "return": [ - "U256" - ] - }, - "half_wad": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [], - "return": [ - "U256" - ] - }, - "ray": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [], - "return": [ - "U256" - ] - }, - "ray_div": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "ray_mul": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "ray_to_wad": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256" - ], - "return": [ - "U256" - ] - }, - "wad": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [], - "return": [ - "U256" - ] - }, - "wad_div": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "wad_mul": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "wad_to_ray": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256" - ], - "return": [ - "U256" - ] - } - } - }, - "safe_math": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "safe_math", - "friends": [], - "structs": {}, - "exposedFunctions": { - "add": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "div": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "min": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "mod": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "mul": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "sub": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - } - } - }, - "storage": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "storage", - "friends": [ - { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "logic" - } - ], - "structs": { - "BorrowRateFactors": { - "abilities": { - "abilities": [ - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "base_rate", - "type": "U256" - }, - { - "name": "multiplier", - "type": "U256" - }, - { - "name": "jump_rate_multiplier", - "type": "U256" - }, - { - "name": "reserve_factor", - "type": "U256" - }, - { - "name": "optimal_utilization", - "type": "U256" - } - ] - }, - "LiquidationFactors": { - "abilities": { - "abilities": [ - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "ratio", - "type": "U256" - }, - { - "name": "bonus", - "type": "U256" - }, - { - "name": "threshold", - "type": "U256" - } - ] - }, - "OwnerCap": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - } - ] - }, - "Paused": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "paused", - "type": "Bool" - } - ] - }, - "ReserveConfigurationMap": { - "abilities": { - "abilities": [ - "Copy", - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "data", - "type": "U256" - } - ] - }, - "ReserveData": { - "abilities": { - "abilities": [ - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": "U8" - }, - { - "name": "oracle_id", - "type": "U8" - }, - { - "name": "coin_type", - "type": { - "Struct": { - "address": "0x1", - "module": "ascii", - "name": "String", - "typeArguments": [] - } - } - }, - { - "name": "is_isolated", - "type": "Bool" - }, - { - "name": "supply_cap_ceiling", - "type": "U256" - }, - { - "name": "borrow_cap_ceiling", - "type": "U256" - }, - { - "name": "current_supply_rate", - "type": "U256" - }, - { - "name": "current_borrow_rate", - "type": "U256" - }, - { - "name": "current_supply_index", - "type": "U256" - }, - { - "name": "current_borrow_index", - "type": "U256" - }, - { - "name": "supply_balance", - "type": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "TokenBalance", - "typeArguments": [] - } - } - }, - { - "name": "borrow_balance", - "type": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "TokenBalance", - "typeArguments": [] - } - } - }, - { - "name": "last_update_timestamp", - "type": "U64" - }, - { - "name": "ltv", - "type": "U256" - }, - { - "name": "treasury_factor", - "type": "U256" - }, - { - "name": "treasury_balance", - "type": "U256" - }, - { - "name": "borrow_rate_factors", - "type": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "BorrowRateFactors", - "typeArguments": [] - } - } - }, - { - "name": "liquidation_factors", - "type": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "LiquidationFactors", - "typeArguments": [] - } - } - }, - { - "name": "reserve_field_a", - "type": "U256" - }, - { - "name": "reserve_field_b", - "type": "U256" - }, - { - "name": "reserve_field_c", - "type": "U256" - } - ] - }, - "Storage": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - }, - { - "name": "version", - "type": "U64" - }, - { - "name": "paused", - "type": "Bool" - }, - { - "name": "reserves", - "type": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "U8", - { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "ReserveData", - "typeArguments": [] - } - } - ] - } - } - }, - { - "name": "reserves_count", - "type": "U8" - }, - { - "name": "users", - "type": { - "Vector": "Address" - } - }, - { - "name": "user_info", - "type": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "Address", - { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "UserInfo", - "typeArguments": [] - } - } - ] - } - } - } - ] - }, - "StorageAdminCap": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - } - ] - }, - "StorageConfiguratorSetting": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "sender", - "type": "Address" - }, - { - "name": "configurator", - "type": "Address" - }, - { - "name": "value", - "type": "Bool" - } - ] - }, - "TokenBalance": { - "abilities": { - "abilities": [ - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "user_state", - "type": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "Address", - "U256" - ] - } - } - }, - { - "name": "total_supply", - "type": "U256" - } - ] - }, - "UserConfigurationMap": { - "abilities": { - "abilities": [ - "Copy", - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "data", - "type": "U256" - } - ] - }, - "UserInfo": { - "abilities": { - "abilities": [ - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "collaterals", - "type": { - "Vector": "U8" - } - }, - { - "name": "loans", - "type": { - "Vector": "U8" - } - } - ] - } - }, - "exposedFunctions": { - "decrease_borrow_balance": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [] - }, - "decrease_supply_balance": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [] - }, - "destory_user": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "StorageAdminCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "get_asset_ltv": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256" - ] - }, - "get_borrow_cap_ceiling_ratio": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256" - ] - }, - "get_borrow_rate_factors": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256", - "U256", - "U256", - "U256", - "U256" - ] - }, - "get_coin_type": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - { - "Struct": { - "address": "0x1", - "module": "ascii", - "name": "String", - "typeArguments": [] - } - } - ] - }, - "get_current_rate": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256", - "U256" - ] - }, - "get_index": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256", - "U256" - ] - }, - "get_last_update_timestamp": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U64" - ] - }, - "get_liquidation_factors": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256", - "U256", - "U256" - ] - }, - "get_oracle_id": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U8" - ] - }, - "get_reserve_for_testing": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "ReserveData", - "typeArguments": [] - } - } - } - ] - }, - "get_reserves_count": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - } - ], - "return": [ - "U8" - ] - }, - "get_supply_cap_ceiling": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256" - ] - }, - "get_total_supply": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256", - "U256" - ] - }, - "get_treasury_balance": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256" - ] - }, - "get_treasury_factor": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256" - ] - }, - "get_user_assets": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address" - ], - "return": [ - { - "Vector": "U8" - }, - { - "Vector": "U8" - } - ] - }, - "get_user_balance": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - "U256", - "U256" - ] - }, - "increase_balance_for_pool": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256", - "U256" - ], - "return": [] - }, - "increase_borrow_balance": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [] - }, - "increase_supply_balance": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [] - }, - "increase_treasury_balance": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "init_reserve": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "StorageAdminCap", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "PoolAdminCap", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Bool", - "U256", - "U256", - "U256", - "U256", - "U256", - "U256", - "U256", - "U256", - "U256", - "U256", - "U256", - "U256", - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "CoinMetadata", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "pause": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - } - ], - "return": [ - "Bool" - ] - }, - "remove_user_collaterals": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [] - }, - "remove_user_loans": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [] - }, - "reserve_validation": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "set_base_rate": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_borrow_cap": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_jump_rate_multiplier": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_liquidation_bonus": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_liquidation_ratio": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_liquidation_threshold": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_ltv": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_multiplier": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_optimal_utilization": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_pause": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Bool" - ], - "return": [] - }, - "set_reserve_factor": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_supply_cap": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_treasury_factor": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "update_interest_rate": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256", - "U256" - ], - "return": [] - }, - "update_state": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256", - "U256", - "U64", - "U256" - ], - "return": [] - }, - "update_user_collaterals": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [] - }, - "update_user_loans": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [] - }, - "version_migrate": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "StorageAdminCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "withdraw_treasury": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "StorageAdminCap", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "PoolAdminCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U64", - "Address", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - } - } - }, - "utils": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "utils", - "friends": [], - "structs": {}, - "exposedFunctions": { - "split_coin": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - }, - "U64", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [ - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - ] - }, - "split_coin_to_balance": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - }, - "U64", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [ - { - "Struct": { - "address": "0x2", - "module": "balance", - "name": "Balance", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - ] - } - } - }, - "validation": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "validation", - "friends": [], - "structs": {}, - "exposedFunctions": { - "validate_borrow": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "validate_deposit": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "validate_liquidate": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - }, - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U8", - "U256" - ], - "return": [] - }, - "validate_repay": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "validate_withdraw": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - } - } - } -} \ No newline at end of file diff --git a/projects/navi/abis/sui/0xd92bc457b42d48924087ea3f22d35fd2fe9afdf5bdfe38cc51c0f14f3282f6d5.json b/projects/navi/abis/sui/0xd92bc457b42d48924087ea3f22d35fd2fe9afdf5bdfe38cc51c0f14f3282f6d5.json deleted file mode 100644 index beff51d8..00000000 --- a/projects/navi/abis/sui/0xd92bc457b42d48924087ea3f22d35fd2fe9afdf5bdfe38cc51c0f14f3282f6d5.json +++ /dev/null @@ -1,5209 +0,0 @@ -{ - "calculator": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "calculator", - "friends": [], - "structs": {}, - "exposedFunctions": { - "caculate_utilization": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256" - ] - }, - "calculate_amount": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - "U256", - "U8" - ], - "return": [ - "U256" - ] - }, - "calculate_borrow_rate": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256" - ] - }, - "calculate_compounded_interest": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "calculate_linear_interest": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "calculate_supply_rate": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [ - "U256" - ] - }, - "calculate_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - "U256", - "U8" - ], - "return": [ - "U256" - ] - } - } - }, - "dynamic_calculator": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "dynamic_calculator", - "friends": [], - "structs": {}, - "exposedFunctions": { - "calculate_current_index": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256", - "U256" - ] - }, - "dynamic_caculate_utilization": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_calculate_apy": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U8", - "U64", - "U64", - "Bool" - ], - "return": [ - "U256", - "U256" - ] - }, - "dynamic_calculate_borrow_rate": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_calculate_supply_rate": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256", - "U256", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_health_factor": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "Address", - "U8", - "U64", - "U64", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_liquidation_threshold": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - "Address", - "U8", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_user_collateral_balance": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_user_collateral_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_user_health_collateral_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address", - "U8", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_user_health_loan_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address", - "U8", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_user_loan_balance": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - }, - "dynamic_user_loan_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256", - "Bool" - ], - "return": [ - "U256" - ] - } - } - }, - "incentive": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "incentive", - "friends": [ - { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "lending" - } - ], - "structs": { - "Incentive": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - }, - { - "name": "creator", - "type": "Address" - }, - { - "name": "owners", - "type": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "U256", - "Bool" - ] - } - } - }, - { - "name": "admins", - "type": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "U256", - "Bool" - ] - } - } - }, - { - "name": "pools", - "type": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "U8", - { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "PoolInfo", - "typeArguments": [] - } - } - ] - } - } - }, - { - "name": "assets", - "type": { - "Vector": "U8" - } - } - ] - }, - "IncentiveBal": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [ - { - "constraints": { - "abilities": [] - }, - "isPhantom": true - } - ], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - }, - { - "name": "asset", - "type": "U8" - }, - { - "name": "current_idx", - "type": "U64" - }, - { - "name": "distributed_amount", - "type": "U256" - }, - { - "name": "balance", - "type": { - "Struct": { - "address": "0x2", - "module": "balance", - "name": "Balance", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - } - ] - }, - "PoolAdminSetting": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "sender", - "type": "Address" - }, - { - "name": "admin", - "type": "U256" - }, - { - "name": "value", - "type": "Bool" - } - ] - }, - "PoolInfo": { - "abilities": { - "abilities": [ - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": "U8" - }, - { - "name": "last_update_time", - "type": "U64" - }, - { - "name": "coin_types", - "type": { - "Vector": { - "Struct": { - "address": "0x1", - "module": "ascii", - "name": "String", - "typeArguments": [] - } - } - } - }, - { - "name": "start_times", - "type": { - "Vector": "U64" - } - }, - { - "name": "end_times", - "type": { - "Vector": "U64" - } - }, - { - "name": "total_supplys", - "type": { - "Vector": "U256" - } - }, - { - "name": "rates", - "type": { - "Vector": "U256" - } - }, - { - "name": "index_rewards", - "type": { - "Vector": "U256" - } - }, - { - "name": "index_rewards_paids", - "type": { - "Vector": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "Address", - "U256" - ] - } - } - } - }, - { - "name": "user_acc_rewards", - "type": { - "Vector": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "Address", - "U256" - ] - } - } - } - }, - { - "name": "user_acc_rewards_paids", - "type": { - "Vector": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "Address", - "U256" - ] - } - } - } - }, - { - "name": "oracle_ids", - "type": { - "Vector": "U8" - } - } - ] - }, - "PoolOwnerSetting": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "sender", - "type": "Address" - }, - { - "name": "owner", - "type": "U256" - }, - { - "name": "value", - "type": "Bool" - } - ] - } - }, - "exposedFunctions": { - "add_pool": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - "U8", - "U64", - "U64", - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - }, - "U64", - "U8", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "claim_reward": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "IncentiveBal", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "earned": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - { - "Vector": { - "Struct": { - "address": "0x1", - "module": "ascii", - "name": "String", - "typeArguments": [] - } - } - }, - { - "Vector": "U256" - }, - { - "Vector": "U8" - } - ] - }, - "get_pool_count": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U64" - ] - }, - "get_pool_info": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - "U8", - "U64" - ], - "return": [ - "U64", - "U64", - "U256", - "U8" - ] - }, - "set_admin": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - "U256", - "Bool", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "set_owner": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - "U256", - "Bool", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "update_reward": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [] - } - } - }, - "lending": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "lending", - "friends": [], - "structs": { - "BorrowEvent": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "reserve", - "type": "U8" - }, - { - "name": "sender", - "type": "Address" - }, - { - "name": "amount", - "type": "U64" - } - ] - }, - "DepositEvent": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "reserve", - "type": "U8" - }, - { - "name": "sender", - "type": "Address" - }, - { - "name": "amount", - "type": "U64" - } - ] - }, - "LiquidationCallEvent": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "reserve", - "type": "U8" - }, - { - "name": "sender", - "type": "Address" - }, - { - "name": "liquidate_user", - "type": "Address" - }, - { - "name": "liquidate_amount", - "type": "U64" - } - ] - }, - "RepayEvent": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "reserve", - "type": "U8" - }, - { - "name": "sender", - "type": "Address" - }, - { - "name": "amount", - "type": "U64" - } - ] - }, - "WithdrawEvent": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "reserve", - "type": "U8" - }, - { - "name": "sender", - "type": "Address" - }, - { - "name": "to", - "type": "Address" - }, - { - "name": "amount", - "type": "U64" - } - ] - } - }, - "exposedFunctions": { - "borrow": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U8", - "U64", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "deposit": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U8", - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - }, - "U64", - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "liquidation_call": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - }, - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U8", - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 1 - } - ] - } - } - }, - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - }, - "Address", - "U64", - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "repay": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U8", - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - }, - "U64", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "withdraw": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U8", - "U64", - "Address", - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "incentive", - "name": "Incentive", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - } - } - }, - "logic": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "logic", - "friends": [ - { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "lending" - } - ], - "structs": {}, - "exposedFunctions": { - "dynamic_liquidation_threshold": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - "Address" - ], - "return": [ - "U256" - ] - }, - "execute_borrow": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [] - }, - "execute_deposit": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [] - }, - "execute_liquidate": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - }, - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address", - "U8", - "U8", - "U256" - ], - "return": [ - "U256", - "U256", - "U256" - ] - }, - "execute_repay": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [ - "U256" - ] - }, - "execute_withdraw": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [ - "U64" - ] - }, - "is_collateral": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - "Bool" - ] - }, - "is_health": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address" - ], - "return": [ - "Bool" - ] - }, - "is_loan": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - "Bool" - ] - }, - "user_collateral_balance": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - "U256" - ] - }, - "user_collateral_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - "U256" - ] - }, - "user_health_collateral_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address" - ], - "return": [ - "U256" - ] - }, - "user_health_factor": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - "Address" - ], - "return": [ - "U256" - ] - }, - "user_health_loan_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address" - ], - "return": [ - "U256" - ] - }, - "user_loan_balance": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - "U256" - ] - }, - "user_loan_value": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f", - "module": "oracle", - "name": "PriceOracle", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - "U256" - ] - } - } - }, - "pool": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "pool", - "friends": [ - { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "lending" - }, - { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "storage" - } - ], - "structs": { - "Pool": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [ - { - "constraints": { - "abilities": [] - }, - "isPhantom": true - } - ], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - }, - { - "name": "balance", - "type": { - "Struct": { - "address": "0x2", - "module": "balance", - "name": "Balance", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - { - "name": "treasury_balance", - "type": { - "Struct": { - "address": "0x2", - "module": "balance", - "name": "Balance", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - { - "name": "decimal", - "type": "U8" - } - ] - }, - "PoolAdminCap": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - }, - { - "name": "creator", - "type": "Address" - } - ] - }, - "PoolBalanceRegister": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "sender", - "type": "Address" - }, - { - "name": "amount", - "type": "U64" - }, - { - "name": "new_amount", - "type": "U64" - }, - { - "name": "pool", - "type": { - "Struct": { - "address": "0x1", - "module": "ascii", - "name": "String", - "typeArguments": [] - } - } - } - ] - }, - "PoolCreate": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "creator", - "type": "Address" - } - ] - }, - "PoolDeposit": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "sender", - "type": "Address" - }, - { - "name": "amount", - "type": "U64" - }, - { - "name": "pool", - "type": { - "Struct": { - "address": "0x1", - "module": "ascii", - "name": "String", - "typeArguments": [] - } - } - } - ] - }, - "PoolWithdraw": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "sender", - "type": "Address" - }, - { - "name": "recipient", - "type": "Address" - }, - { - "name": "amount", - "type": "U64" - }, - { - "name": "pool", - "type": { - "Struct": { - "address": "0x1", - "module": "ascii", - "name": "String", - "typeArguments": [] - } - } - } - ] - } - }, - "exposedFunctions": { - "convert_amount": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U64", - "U8", - "U8" - ], - "return": [ - "U64" - ] - }, - "create_pool": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "PoolAdminCap", - "typeArguments": [] - } - } - }, - "U8", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "deposit": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - }, - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "deposit_treasury": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U64" - ], - "return": [] - }, - "get_coin_decimal": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - } - ], - "return": [ - "U8" - ] - }, - "normal_amount": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U64" - ], - "return": [ - "U64" - ] - }, - "unnormal_amount": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U64" - ], - "return": [ - "U64" - ] - }, - "withdraw": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U64", - "Address", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "withdraw_reserve_balance": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "PoolAdminCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U64", - "Address", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "withdraw_treasury": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "PoolAdminCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U64", - "Address", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - } - } - }, - "ray_math": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "ray_math", - "friends": [], - "structs": {}, - "exposedFunctions": { - "half_ray": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [], - "return": [ - "U256" - ] - }, - "half_wad": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [], - "return": [ - "U256" - ] - }, - "ray": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [], - "return": [ - "U256" - ] - }, - "ray_div": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "ray_mul": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "ray_to_wad": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256" - ], - "return": [ - "U256" - ] - }, - "wad": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [], - "return": [ - "U256" - ] - }, - "wad_div": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "wad_mul": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "wad_to_ray": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256" - ], - "return": [ - "U256" - ] - } - } - }, - "safe_math": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "safe_math", - "friends": [], - "structs": {}, - "exposedFunctions": { - "add": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "div": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "min": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "mod": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "mul": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - }, - "sub": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - "U256", - "U256" - ], - "return": [ - "U256" - ] - } - } - }, - "storage": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "storage", - "friends": [ - { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "logic" - } - ], - "structs": { - "BorrowRateFactors": { - "abilities": { - "abilities": [ - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "base_rate", - "type": "U256" - }, - { - "name": "multiplier", - "type": "U256" - }, - { - "name": "jump_rate_multiplier", - "type": "U256" - }, - { - "name": "reserve_factor", - "type": "U256" - }, - { - "name": "optimal_utilization", - "type": "U256" - } - ] - }, - "LiquidationFactors": { - "abilities": { - "abilities": [ - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "ratio", - "type": "U256" - }, - { - "name": "bonus", - "type": "U256" - }, - { - "name": "threshold", - "type": "U256" - } - ] - }, - "OwnerCap": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - } - ] - }, - "Paused": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "paused", - "type": "Bool" - } - ] - }, - "ReserveConfigurationMap": { - "abilities": { - "abilities": [ - "Copy", - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "data", - "type": "U256" - } - ] - }, - "ReserveData": { - "abilities": { - "abilities": [ - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": "U8" - }, - { - "name": "oracle_id", - "type": "U8" - }, - { - "name": "coin_type", - "type": { - "Struct": { - "address": "0x1", - "module": "ascii", - "name": "String", - "typeArguments": [] - } - } - }, - { - "name": "is_isolated", - "type": "Bool" - }, - { - "name": "supply_cap_ceiling", - "type": "U256" - }, - { - "name": "borrow_cap_ceiling", - "type": "U256" - }, - { - "name": "current_supply_rate", - "type": "U256" - }, - { - "name": "current_borrow_rate", - "type": "U256" - }, - { - "name": "current_supply_index", - "type": "U256" - }, - { - "name": "current_borrow_index", - "type": "U256" - }, - { - "name": "supply_balance", - "type": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "TokenBalance", - "typeArguments": [] - } - } - }, - { - "name": "borrow_balance", - "type": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "TokenBalance", - "typeArguments": [] - } - } - }, - { - "name": "last_update_timestamp", - "type": "U64" - }, - { - "name": "ltv", - "type": "U256" - }, - { - "name": "treasury_factor", - "type": "U256" - }, - { - "name": "treasury_balance", - "type": "U256" - }, - { - "name": "borrow_rate_factors", - "type": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "BorrowRateFactors", - "typeArguments": [] - } - } - }, - { - "name": "liquidation_factors", - "type": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "LiquidationFactors", - "typeArguments": [] - } - } - }, - { - "name": "reserve_field_a", - "type": "U256" - }, - { - "name": "reserve_field_b", - "type": "U256" - }, - { - "name": "reserve_field_c", - "type": "U256" - } - ] - }, - "Storage": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - }, - { - "name": "version", - "type": "U64" - }, - { - "name": "paused", - "type": "Bool" - }, - { - "name": "reserves", - "type": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "U8", - { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "ReserveData", - "typeArguments": [] - } - } - ] - } - } - }, - { - "name": "reserves_count", - "type": "U8" - }, - { - "name": "users", - "type": { - "Vector": "Address" - } - }, - { - "name": "user_info", - "type": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "Address", - { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "UserInfo", - "typeArguments": [] - } - } - ] - } - } - } - ] - }, - "StorageAdminCap": { - "abilities": { - "abilities": [ - "Store", - "Key" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "id", - "type": { - "Struct": { - "address": "0x2", - "module": "object", - "name": "UID", - "typeArguments": [] - } - } - } - ] - }, - "StorageConfiguratorSetting": { - "abilities": { - "abilities": [ - "Copy", - "Drop" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "sender", - "type": "Address" - }, - { - "name": "configurator", - "type": "Address" - }, - { - "name": "value", - "type": "Bool" - } - ] - }, - "TokenBalance": { - "abilities": { - "abilities": [ - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "user_state", - "type": { - "Struct": { - "address": "0x2", - "module": "table", - "name": "Table", - "typeArguments": [ - "Address", - "U256" - ] - } - } - }, - { - "name": "total_supply", - "type": "U256" - } - ] - }, - "UserConfigurationMap": { - "abilities": { - "abilities": [ - "Copy", - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "data", - "type": "U256" - } - ] - }, - "UserInfo": { - "abilities": { - "abilities": [ - "Store" - ] - }, - "typeParameters": [], - "fields": [ - { - "name": "collaterals", - "type": { - "Vector": "U8" - } - }, - { - "name": "loans", - "type": { - "Vector": "U8" - } - } - ] - } - }, - "exposedFunctions": { - "decrease_borrow_balance": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [] - }, - "decrease_supply_balance": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [] - }, - "destory_user": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "StorageAdminCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "get_asset_ltv": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256" - ] - }, - "get_borrow_cap_ceiling_ratio": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256" - ] - }, - "get_borrow_rate_factors": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256", - "U256", - "U256", - "U256", - "U256" - ] - }, - "get_coin_type": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - { - "Struct": { - "address": "0x1", - "module": "ascii", - "name": "String", - "typeArguments": [] - } - } - ] - }, - "get_current_rate": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256", - "U256" - ] - }, - "get_index": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256", - "U256" - ] - }, - "get_last_update_timestamp": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U64" - ] - }, - "get_liquidation_factors": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256", - "U256", - "U256" - ] - }, - "get_oracle_id": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U8" - ] - }, - "get_reserves_count": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - } - ], - "return": [ - "U8" - ] - }, - "get_supply_cap_ceiling": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256" - ] - }, - "get_total_supply": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256", - "U256" - ] - }, - "get_treasury_balance": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256" - ] - }, - "get_treasury_factor": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8" - ], - "return": [ - "U256" - ] - }, - "get_user_assets": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Address" - ], - "return": [ - { - "Vector": "U8" - }, - { - "Vector": "U8" - } - ] - }, - "get_user_balance": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [ - "U256", - "U256" - ] - }, - "increase_balance_for_pool": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256", - "U256" - ], - "return": [] - }, - "increase_borrow_balance": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [] - }, - "increase_supply_balance": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address", - "U256" - ], - "return": [] - }, - "increase_treasury_balance": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "init_reserve": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "StorageAdminCap", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "PoolAdminCap", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "clock", - "name": "Clock", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Bool", - "U256", - "U256", - "U256", - "U256", - "U256", - "U256", - "U256", - "U256", - "U256", - "U256", - "U256", - "U256", - { - "Reference": { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "CoinMetadata", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "pause": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - } - ], - "return": [ - "Bool" - ] - }, - "remove_user_collaterals": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [] - }, - "remove_user_loans": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [] - }, - "reserve_validation": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "set_base_rate": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_borrow_cap": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_jump_rate_multiplier": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_liquidation_bonus": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_liquidation_ratio": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_liquidation_threshold": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_ltv": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_multiplier": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_optimal_utilization": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_pause": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "Bool" - ], - "return": [] - }, - "set_reserve_factor": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_supply_cap": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "set_treasury_factor": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "OwnerCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "update_interest_rate": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256", - "U256" - ], - "return": [] - }, - "update_state": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256", - "U256", - "U64", - "U256" - ], - "return": [] - }, - "update_user_collaterals": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [] - }, - "update_user_loans": { - "visibility": "Friend", - "isEntry": false, - "typeParameters": [], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "Address" - ], - "return": [] - }, - "version_migrate": { - "visibility": "Public", - "isEntry": true, - "typeParameters": [], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "StorageAdminCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - } - ], - "return": [] - }, - "withdraw_treasury": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "StorageAdminCap", - "typeArguments": [] - } - } - }, - { - "Reference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "PoolAdminCap", - "typeArguments": [] - } - } - }, - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "pool", - "name": "Pool", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - }, - "U64", - "Address", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [] - } - } - }, - "utils": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "utils", - "friends": [], - "structs": {}, - "exposedFunctions": { - "split_coin": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - }, - "U64", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [ - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - ] - }, - "split_coin_to_balance": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "Struct": { - "address": "0x2", - "module": "coin", - "name": "Coin", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - }, - "U64", - { - "MutableReference": { - "Struct": { - "address": "0x2", - "module": "tx_context", - "name": "TxContext", - "typeArguments": [] - } - } - } - ], - "return": [ - { - "Struct": { - "address": "0x2", - "module": "balance", - "name": "Balance", - "typeArguments": [ - { - "TypeParameter": 0 - } - ] - } - } - ] - } - } - }, - "validation": { - "fileFormatVersion": 6, - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "name": "validation", - "friends": [], - "structs": {}, - "exposedFunctions": { - "validate_borrow": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "validate_deposit": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "validate_liquidate": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - }, - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U8", - "U256" - ], - "return": [] - }, - "validate_repay": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - }, - "validate_withdraw": { - "visibility": "Public", - "isEntry": false, - "typeParameters": [ - { - "abilities": [] - } - ], - "parameters": [ - { - "MutableReference": { - "Struct": { - "address": "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca", - "module": "storage", - "name": "Storage", - "typeArguments": [] - } - } - }, - "U8", - "U256" - ], - "return": [] - } - } - } -} \ No newline at end of file diff --git a/projects/navi/package.json b/projects/navi/package.json index 19c5cec7..3ab221e7 100644 --- a/projects/navi/package.json +++ b/projects/navi/package.json @@ -1,7 +1,7 @@ { "name": "navi", "private": true, - "version": "1.0.0", + "version": "2.26.0", "type": "module", "scripts": { "test": "sentio test", diff --git a/projects/navi/sentio.yaml b/projects/navi/sentio.yaml index bdcdc09c..cfd9ce9d 100644 --- a/projects/navi/sentio.yaml +++ b/projects/navi/sentio.yaml @@ -1,7 +1,11 @@ -project: navi/navi +project: navi/naviproduction contracts: - chain: sui_mainnet address: "0xe17e8d461129585fdd83dd891b1b5858f51984acbb308daa7ad8627c13f31c9d" + - chain: sui_testnet + address: "0x8ba6cdd02f5d1b9ff9970690681c21957d9a6a6fbb74546b2f0cfb16dbff4c25" + - chain: sui_testnet + address: "0x6850914af4d097f53be63182675334fb41a6782e4e702a5d605a61969750e777" - chain: sui_mainnet address: "0xccdf4385016f20c784e68376359ddc2f6a9e050ec431ca5c85f1bc81024d4427" - chain: sui_mainnet @@ -11,22 +15,4 @@ contracts: - chain: sui_mainnet address: "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca" - chain: sui_mainnet - address: "0xe17e8d461129585fdd83dd891b1b5858f51984acbb308daa7ad8627c13f31c9d" - - chain: sui_mainnet - address: "0xccdf4385016f20c784e68376359ddc2f6a9e050ec431ca5c85f1bc81024d4427" - - chain: sui_mainnet - address: "0xda691d321641786d758d7435d0e230a7125777566c75b34c5742591163a252c3" - - chain: sui_mainnet - address: "0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f" - - chain: sui_mainnet - - address: "0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca" - - chain: sui_mainnet - address: "0xe66f07e2a8d9cf793da1e0bca98ff312b3ffba57228d97cf23a0613fddf31b65" - - chain: sui_mainnet - - address: "0x81be491340a6964eb9903141c3068db55704b5892072eb9e372cc98f4b04639c" - - chain: sui_mainnet - - address: "0xd92bc457b42d48924087ea3f22d35fd2fe9afdf5bdfe38cc51c0f14f3282f6d5" \ No newline at end of file diff --git a/projects/navi/src/mainnet/interfaces.ts b/projects/navi/src/mainnet/interfaces.ts new file mode 100644 index 00000000..1e3de9d5 --- /dev/null +++ b/projects/navi/src/mainnet/interfaces.ts @@ -0,0 +1,3 @@ +export interface CoinMap { + [key: string]: string; +} diff --git a/projects/navi/src/mainnet/main.ts b/projects/navi/src/mainnet/main.ts index 79e9a53a..570df7de 100644 --- a/projects/navi/src/mainnet/main.ts +++ b/projects/navi/src/mainnet/main.ts @@ -2,7 +2,7 @@ import { SuiContext, SuiObjectContext, } from "@sentio/sdk/sui" -import { lending } from "../types/sui/0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca.js"; +import { incentive_v2, lending } from "../types/sui/0xe66f07e2a8d9cf793da1e0bca98ff312b3ffba57228d97cf23a0613fddf31b65.js"; import { token } from "@sentio/sdk/utils" import { ProtocolProcessor } from "./storage.js"; import { PoolProcessor } from "./pool.js"; @@ -24,11 +24,8 @@ export const getOrCreateCoin = async function (ctx: SuiContext | SuiObjectContex export async function buildCoinInfo(ctx: SuiContext | SuiObjectContext, coinAddress: string): Promise { const metadata = await ctx.client.getCoinMetadata({ coinType: coinAddress }) - //@ts-ignore const symbol = metadata.symbol - //@ts-ignore const decimal = metadata.decimals - //@ts-ignore const name = metadata.name console.log(`build coin metadata ${symbol} ${decimal} ${name}`) return { @@ -53,7 +50,10 @@ async function onEvent(event: LendingEvent, ctx: SuiContext) { 0: "0x0000000000000000000000000000000000000000000000000000000000000002::sui::SUI", 1: "0x5d4b302506645c37ff133b98c4b50a5ae14841659738d6d733d59d0d217a93bf::coin::COIN", 2: "0xc060006111016b8a020ad5b33834984a437aaa7d3c74c18e09a95d48aceab08c::coin::COIN", - 3: "0xaf8cd5edc19c4512f4259f0bee101a40d41ebed738ade5874359610ef8eeced5::coin::COIN" + 3: "0xaf8cd5edc19c4512f4259f0bee101a40d41ebed738ade5874359610ef8eeced5::coin::COIN", + 4: "0x06864a6f921804860930db6ddbe2e16acdf8504495ea7481637a1c8b9a8fe54b::cetus::CETUS", + 5: "0x549e8b69270defbfafd4f94e17ec44cdbdd99820b33bda2278dea3b9a32d3f55::cert::CERT", + 6: "0xbde4ba4c2e274a60ce15c1cfff9e5c42e41654ac8b6d906a57efa4bd3c29f47d::hasui::HASUI" } const coinAddress = Coins[reserve] // const coinAddress = event.data_decoded.pool; @@ -78,7 +78,6 @@ async function onLiquidationEvent(event: lending.LiquidationCallEventInstance, c const liquidation_amount = event.data_decoded.liquidate_amount const liquidate_user = event.data_decoded.liquidate_user const reserve = event.data_decoded.reserve - const typeArray = event.type.split("::") const type = typeArray[typeArray.length - 1] @@ -94,20 +93,40 @@ async function onLiquidationEvent(event: lending.LiquidationCallEventInstance, c } -import { lending as lending2 } from "../types/sui/0xe17e8d461129585fdd83dd891b1b5858f51984acbb308daa7ad8627c13f31c9d.js" -// import { lending as lending } from "../types/sui/0xccdf4385016f20c784e68376359ddc2f6a9e050ec431ca5c85f1bc81024d4427.js" -// import { lending as lending2 } from "../types/sui/0xda691d321641786d758d7435d0e230a7125777566c75b34c5742591163a252c3.js" -// import { lending as lending2 } from "../types/sui/0xca441b44943c16be0e6e23c5a955bb971537ea3289ae8016fbf33fffe1fd210f.js" -import { lending as lending3 } from "../types/sui/0xd899cf7d2b5db716bd2cf55599fb0d5ee38a3061e7b6bb6eebf73fa5bc4c81ca.js" -import { lending as lending4 } from "../types/sui/0xe66f07e2a8d9cf793da1e0bca98ff312b3ffba57228d97cf23a0613fddf31b65.js" -import { lending as lending5 } from "../types/sui/0x81be491340a6964eb9903141c3068db55704b5892072eb9e372cc98f4b04639c.js" -import { lending as lending6 } from "../types/sui/0xd92bc457b42d48924087ea3f22d35fd2fe9afdf5bdfe38cc51c0f14f3282f6d5.js" - -for (const l of [lending, lending2, lending3, lending4, lending5, lending6]) { - l.bind() - .onEventBorrowEvent(onEvent) - .onEventDepositEvent(onEvent) - .onEventRepayEvent(onEvent) - .onEventWithdrawEvent(onEvent) - .onEventLiquidationCallEvent(onLiquidationEvent) +async function onRewardsClaimedEvent(event: incentive_v2.RewardsClaimedInstance, ctx: SuiContext) { + + //TODO 需要改为动态 + const Coins: any = { + 0: "0x0000000000000000000000000000000000000000000000000000000000000002::sui::SUI", + 1: "0x5d4b302506645c37ff133b98c4b50a5ae14841659738d6d733d59d0d217a93bf::coin::COIN", + 2: "0xc060006111016b8a020ad5b33834984a437aaa7d3c74c18e09a95d48aceab08c::coin::COIN", + 3: "0xaf8cd5edc19c4512f4259f0bee101a40d41ebed738ade5874359610ef8eeced5::coin::COIN" + } + const coinAddress = Coins[0] + const coinDecimal = getOrCreateCoin(ctx, coinAddress) + const amount = scaleDown(event.data_decoded.amount, (await coinDecimal).decimal) + const pool = event.data_decoded.pool + const sender = event.data_decoded.sender + + const typeArray = event.type.split("::") + const type = typeArray[typeArray.length - 1] + + ctx.eventLogger.emit("UserInteraction", { + distinctId: sender, + sender, + amount, + pool, + type, + env: "mainnet" + }) } + + +lending.bind() + .onEventBorrowEvent(onEvent) + .onEventDepositEvent(onEvent) + .onEventRepayEvent(onEvent) + .onEventWithdrawEvent(onEvent) + .onEventLiquidationCallEvent(onLiquidationEvent) +incentive_v2.bind() + .onEventRewardsClaimed(onRewardsClaimedEvent) \ No newline at end of file diff --git a/projects/navi/src/mainnet/pool.ts b/projects/navi/src/mainnet/pool.ts index 4b0a03a3..962491e5 100644 --- a/projects/navi/src/mainnet/pool.ts +++ b/projects/navi/src/mainnet/pool.ts @@ -8,6 +8,10 @@ const pools = [ "0xa02a98f9c88db51c6f5efaaf2261c81f34dd56d86073387e0ef1805ca22e39c8", // Treasury Pool For USDC "0x0e060c3b5b8de00fb50511b7a45188c8e34b6995c01f69d98ea5a466fe10d103", // Treasury Pool For USDT "0x71b9f6e822c48ce827bceadce82201d6a7559f7b0350ed1daa1dc2ba3ac41b56", // Treasury Pool For WETH + "0x3c376f857ec4247b8ee456c1db19e9c74e0154d4876915e54221b5052d5b1e2e", //Treasury Pool For CETUS + "0x9790c2c272e15b6bf9b341eb531ef16bcc8ed2b20dfda25d060bf47f5dd88d01", // Treasury Pool For VoloSui + "0x6fd9cb6ebd76bc80340a9443d72ea0ae282ee20e2fd7544f6ffcd2c070d9557a", //Treasury Pool For haSui + ] export function PoolProcessor() { @@ -20,11 +24,9 @@ export function PoolProcessor() { const type = String(self.type); const coin_type = SymbolMatcher(type); const coin_symbol = COIN_MAP[coin_type]; - //@ts-ignore - const decimal = self.fields.decimal - //@ts-ignore + + const decimal = self.fields.decimal; const balance = BigDecimal(self.fields.balance).div(Math.pow(10, decimal)); - //@ts-ignore const treasuryBalance = BigDecimal(self.fields.treasury_balance).div(Math.pow(10, decimal)); //TODO diff --git a/projects/navi/src/mainnet/reward.pool.ts b/projects/navi/src/mainnet/reward.pool.ts new file mode 100644 index 00000000..718dba2b --- /dev/null +++ b/projects/navi/src/mainnet/reward.pool.ts @@ -0,0 +1,40 @@ +import { SuiObjectProcessor } from "@sentio/sdk/sui" +import { ChainId } from "@sentio/chain" +import { BigDecimal } from "@sentio/sdk" +import { COIN_MAP, SymbolMatcher } from "./utils.js"; + +const rewardPools = [ + "0x9180e0b8758f4b03f74fa3fa1350ae023af88bc2b5b347352a298b8ad547b7f5", // Reward Pool For SUI + "0x6c5d1f05ca6794ff24ea6bd5e1ee93ecae82b65e7f4361aa0a2d5f8b985b6639", // Reward Pool For USDC + "0x8d146663da3afc111f8e7dd197591c01a950049ed552f940bc20927411072ca2", // Reward Pool For SUI + "0x595c64e52d44ddac6e84fa55ddec7b993526ca73ea8df1f0887a05307ce09435", // Reward Pool For USDC +] + +export function PoolProcessor() { + for (let pool of rewardPools) { + SuiObjectProcessor.bind({ + objectId: pool, + network: ChainId.SUI_MAINNET, + startCheckpoint: 7800000n + }).onTimeInterval(async (self, data, ctx) => { + //TODO: find out the token type + const type = String(self.type); + const coin_type = SymbolMatcher(type); + const coin_symbol = COIN_MAP[coin_type]; + + const decimal = self.fields.decimal; + const distributedAmountForRewardPool = BigDecimal(self.fields.distributed_amount).div(Math.pow(10, decimal)); + const balanceForRewardPool = BigDecimal(self.fields.balance).div(Math.pow(10, decimal)); + const assetForRewardPool = self.fields.asset; + const currentIdxForRewardPool = self.fields.current_idx; + + + //TODO: + ctx.meter.Gauge("distributedAmountForRewardPool").record(distributedAmountForRewardPool, { env: "mainnet", type, coin_type, coin_symbol }); + ctx.meter.Gauge("balanceForRewardPool").record(balanceForRewardPool, { env: "mainnet", type, coin_type, coin_symbol }); + ctx.meter.Gauge("assetForRewardPool").record(assetForRewardPool, { env: "mainnet", type, coin_type, coin_symbol }); + ctx.meter.Gauge("currentIdxForRewardPool").record(currentIdxForRewardPool, { env: "mainnet", type, coin_type, coin_symbol }); + + }) + } +} diff --git a/projects/navi/src/mainnet/storage.ts b/projects/navi/src/mainnet/storage.ts index 3cec829d..544da3a0 100644 --- a/projects/navi/src/mainnet/storage.ts +++ b/projects/navi/src/mainnet/storage.ts @@ -8,6 +8,9 @@ const reserves = [ "0xeb3903f7748ace73429bd52a70fff278aac1725d3b58afa781f25ce3450ac203", // Reserve For USDC "0xb8c5eab02a0202f638958cc79a69a2d30055565caad1684b3c8bbca3bddcb322", // Reserve For USDT "0xafecf4b57899d377cc8c9de75854c68925d9f512d0c47150ca52a0d3a442b735", // Reserve For WETH + "0x66a807c06212537fe46aa6719a00e4fa1e85a932d0b53ce7c4b1041983645133", // Reserve For CETUS + "0xd4fd7e094af9819b06ea3136c13a6ae8da184016b78cf19773ac26d2095793e2", // Reserve For VoloSui + "0x0c9f7a6ca561dc566bd75744bcc71a6af1dc3caf7bd32c099cd640bb5f3bb0e3", // Reserve For haSUI ] export function ProtocolProcessor() { @@ -19,31 +22,23 @@ export function ProtocolProcessor() { startCheckpoint: 7800000n }).onTimeInterval(async (self, _, ctx) => { try { - //@ts-ignore const type = String(self.fields.value.fields.coin_type) - //@ts-ignore const id = String(self.fields.value.fields.id) - //@ts-ignore const ltv = BigDecimal(self.fields.value.fields.ltv).div(Math.pow(10, DECIMAL_RAY)) const coin_symbol = COIN[i] - //@ts-ignore + const totalSupply = BigDecimal(self.fields.value.fields.supply_balance.fields.total_supply).div(Math.pow(10, DEFAULT_COIN_DECIMAL)) - //@ts-ignore const totalBorrow = BigDecimal(self.fields.value.fields.borrow_balance.fields.total_supply).div(Math.pow(10, DEFAULT_COIN_DECIMAL)) - //@ts-ignore + const currentSupplyIndex = BigDecimal(self.fields.value.fields.current_supply_index).div(Math.pow(10, DECIMAL_RAY)) - //@ts-ignore const currentBorrowIndex = BigDecimal(self.fields.value.fields.current_borrow_index).div(Math.pow(10, DECIMAL_RAY)) //add - //@ts-ignore const supplyCapCelling = BigDecimal(self.fields.value.fields.supply_cap_ceiling).div(Math.pow(10, DECIMAL_RAY)) - //@ts-ignore const borrowCapCeiling = BigDecimal(self.fields.value.fields.borrow_cap_ceiling).div(Math.pow(10, DECIMAL_RAY)) - //@ts-ignore + const treasuryBalance = BigDecimal(self.fields.value.fields.treasury_balance).div(Math.pow(10, DEFAULT_COIN_DECIMAL)) - //@ts-ignore + const currentBorrowRate = BigDecimal(self.fields.value.fields.current_borrow_rate).div(Math.pow(10, DECIMAL_RAY)) - //@ts-ignore const currentSupplyRate = BigDecimal(self.fields.value.fields.current_supply_rate).div(Math.pow(10, DECIMAL_RAY)) // const supply rate diff --git a/projects/navi/src/mainnet/utils.ts b/projects/navi/src/mainnet/utils.ts index 181d09ba..e30db871 100644 --- a/projects/navi/src/mainnet/utils.ts +++ b/projects/navi/src/mainnet/utils.ts @@ -1,6 +1,6 @@ import { CoinMap } from "./interfaces.js"; -export const COIN = ["SUI", "USDC", "USDT", "WETH"]; +export const COIN = ["SUI", "USDC", "USDT", "WETH", "CETUS","VoloSui","HASUI"]; export const DECIMAL_RAY = 27; export const DEFAULT_COIN_DECIMAL = 9; @@ -14,6 +14,12 @@ export const COIN_MAP: CoinMap = { "USDT", "0xaf8cd5edc19c4512f4259f0bee101a40d41ebed738ade5874359610ef8eeced5::coin::COIN": "WETH", + "0x06864a6f921804860930db6ddbe2e16acdf8504495ea7481637a1c8b9a8fe54b::cetus::CETUS": + "CETUS", + "0x549e8b69270defbfafd4f94e17ec44cdbdd99820b33bda2278dea3b9a32d3f55::cert::CERT": + "VoloSui", + "0xbde4ba4c2e274a60ce15c1cfff9e5c42e41654ac8b6d906a57efa4bd3c29f47d::hasui::HASUI": + "HASUI" }; export function SymbolMatcher(objectType: string) { diff --git a/projects/navi/src/processor.test.ts b/projects/navi/src/processor.test.ts new file mode 100644 index 00000000..a1a779a3 --- /dev/null +++ b/projects/navi/src/processor.test.ts @@ -0,0 +1,28 @@ +import { TestProcessorServer, firstCounterValue } from '@sentio/sdk/testing' +import { mockTransferLog } from '@sentio/sdk/eth/builtin/erc20' + +describe('Test Processor', () => { + const service = new TestProcessorServer(() => import('./processor.js')) + + beforeAll(async () => { + await service.start() + }) + + test('has valid config', async () => { + const config = await service.getConfig({}) + expect(config.contractConfigs.length > 0).toBeTruthy() + }) + + test('check transfer event handling', async () => { + const resp = await service.eth.testLog( + mockTransferLog('0x1e4ede388cbc9f4b5c79681b7f94d36a11abebc9', { + from: '0x0000000000000000000000000000000000000000', + to: '0xb329e39ebefd16f40d38f07643652ce17ca5bac1', + value: 10n ** 18n * 10n, + }) + ) + + const tokenCounter = firstCounterValue(resp.result, 'token') + expect(tokenCounter).toEqual(10n) + }) +}) diff --git a/projects/navi/src/processor.ts b/projects/navi/src/processor.ts index b9943a06..159575ef 100644 --- a/projects/navi/src/processor.ts +++ b/projects/navi/src/processor.ts @@ -1 +1,2 @@ -import "./mainnet/main" \ No newline at end of file +import "./mainnet/main.js" +import "./testnet.js" \ No newline at end of file diff --git a/projects/navi/src/testnet.ts b/projects/navi/src/testnet.ts new file mode 100644 index 00000000..31725975 --- /dev/null +++ b/projects/navi/src/testnet.ts @@ -0,0 +1,61 @@ +// // import { pool, pool_factory } from "./types/sui/turbos.js"; +// import { SuiObjectProcessor, SuiContext, SuiObjectContext, SuiObjectProcessorTemplate } from "@sentio/sdk/sui" +// // import * as constant from './constant-turbos.js' +// import { ChainId } from "@sentio/chain" +// import { BUILTIN_TYPES } from "@sentio/sdk/move" +// import { Gauge, scaleDown } from "@sentio/sdk"; +// import { pool } from "./types/sui/testnet/0x8ba6cdd02f5d1b9ff9970690681c21957d9a6a6fbb74546b2f0cfb16dbff4c25.js" +// import { lending as lendingTestnet } from "./types/sui/testnet/0x8ba6cdd02f5d1b9ff9970690681c21957d9a6a6fbb74546b2f0cfb16dbff4c25.js"; +// import { lending } from "./types/sui/0xe17e8d461129585fdd83dd891b1b5858f51984acbb308daa7ad8627c13f31c9d.js"; + +// import { storage } from "./types/sui/testnet/0x6850914af4d097f53be63182675334fb41a6782e4e702a5d605a61969750e777.js"; + +// import { dynamic_field } from "@sentio/sdk/sui/builtin/0x2"; +// import { getOrCreateCoin } from "./mainnet/main.js"; + +// export type LendingEvent = lending.BorrowEventInstance | lending.DepositEventInstance | lending.WithdrawEventInstance | lending.RepayEventInstance + +// // SuiObjectProcessor.bind({ +// // objectId: "0x5d137ca143af1366db782327d957d8e2afbf10c17b9d45e0f46111e6bcc4e805", +// // network: ChainId.SUI_TESTNET, +// // startCheckpoint: 3150000n +// // }).onTimeInterval(async (self, _, ctx) => { + +// // // const typeDescriptor = dynamic_field.Field.type(BUILTIN_TYPES.U8_TYPE, storage.ReserveData.type()) + +// // // const v = await ctx.coder.decodedType(self, typeDescriptor) +// // // if (v) { +// // try { +// // const totalSupply = Number(self.fields.value.fields.supply_balance.fields.total_supply) +// // ctx.meter.Gauge("total_supply").record(totalSupply) +// // } catch(e) { +// // console.log(e) +// // console.log(JSON.stringify(self)) +// // } +// // }) + +// async function onEvent(event: LendingEvent, ctx: SuiContext) { +// const sender = event.data_decoded.sender +// const reserve = event.data_decoded.reserve + +// const typeArray = event.type.split("::") +// const type = typeArray[typeArray.length - 1] + +// const coinDecimal = getOrCreateCoin(ctx,type) +// const amount = scaleDown(event.data_decoded.amount, (await coinDecimal).decimal) + +// ctx.eventLogger.emit("UserInteraction", { +// distinctId: sender, +// sender, +// amount, +// reserve, +// type, +// env: "testnet" +// }) +// } + +// lendingTestnet.bind() +// .onEventBorrowEvent(onEvent) +// .onEventDepositEvent(onEvent) +// .onEventRepayEvent(onEvent) +// .onEventWithdrawEvent(onEvent) \ No newline at end of file diff --git a/projects/navi/tsconfig.json b/projects/navi/tsconfig.json index 03c7d8c7..8fc700b4 100644 --- a/projects/navi/tsconfig.json +++ b/projects/navi/tsconfig.json @@ -7,7 +7,7 @@ "esModuleInterop": true, "noImplicitReturns": true, "noImplicitAny": true, - "module": "esnext", + "module": "nodenext", "moduleResolution": "nodenext", "strictNullChecks": true, "stripInternal": true,