Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
64 changes: 64 additions & 0 deletions abi/folks_finance_loan_manager.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
[
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "bytes32",
"name": "loanId",
"type": "bytes32"
},
{
"indexed": false,
"internalType": "uint8",
"name": "poolId",
"type": "uint8"
},
{
"indexed": false,
"internalType": "uint256",
"name": "amount",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "fAmount",
"type": "uint256"
}
],
"name": "Deposit",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "bytes32",
"name": "loanId",
"type": "bytes32"
},
{
"indexed": false,
"internalType": "uint8",
"name": "poolId",
"type": "uint8"
},
{
"indexed": false,
"internalType": "uint256",
"name": "amount",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "fAmount",
"type": "uint256"
}
],
"name": "Withdraw",
"type": "event"
}
]
1 change: 1 addition & 0 deletions constants/chains.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,4 @@ class Chain(Enum):
SEPOLIA = "Sepolia"
TON = "Ton"
HYPEREVM = "HyperEVM"
AVALANCHE = "Avalanche"
22 changes: 22 additions & 0 deletions constants/folks_finance.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import json
from utils.web3_utils import w3_avalanche
from enum import Enum
from constants.integration_token import Token

with open("abi/folks_finance_loan_manager.json") as loan_manager_abi_file:
LOAN_MANAGER_ABI = json.load(loan_manager_abi_file)

LOAN_MANAGER_ADDRESS = w3_avalanche.to_checksum_address(
"0xF4c542518320F09943C35Db6773b2f9FeB2F847e"
)
LOAN_MANAGER_CONTRACT = w3_avalanche.eth.contract(
address=LOAN_MANAGER_ADDRESS,
abi=LOAN_MANAGER_ABI,
)

TOKEN_TO_POOL_IDS = {Token.USDE: 55, Token.SUSDE: 56}
STARTING_BLOCKS = {Token.USDE: 68784025, Token.SUSDE: 68784034}

LOAN_TO_ADDRESSES_INDEXER_URL = (
"https://indexer.xapp.folks.finance/partner/ethena/loans"
)
4 changes: 4 additions & 0 deletions constants/summary_columns.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,10 @@ class SummaryColumn(Enum):

THRUSTER_POOL_PTS = ("thruster_pool_pts", SummaryColumnType.ETHENA_PTS)

# Folks Finance
FOLKS_FINANCE_USDE_PTS = ("folks_finance_usde_pts", SummaryColumnType.ETHENA_PTS)
FOLKS_FINANCE_SUSDE_PTS = ("folks_finance_susde_pts", SummaryColumnType.ETHENA_PTS)

def __init__(self, column_name: str, col_type: SummaryColumnType):
self.column_name = column_name
self.col_type = col_type
Expand Down
Loading