import { Indexer } from "algosdk"; import { TealKeyValue } from "algosdk/dist/types/client/v2/algod/models/types"; import { DepositStakingInfo, DepositStakingProgramInfo, LoanInfo, LoanLocalState, OraclePrices, Pool, PoolManagerInfo, UserDepositStakingInfo, UserDepositStakingLocalState, UserLoanInfo } from "./types"; export declare function getEscrows(indexerClient: Indexer, userAddr: string, appId: number, addNotePrefix: string, removeNotePrefix: string): Promise>; /** * * Derives deposit staking local state from escrow account. * * @param state - escrow account local state * @param depositStakingAppId - deposit staking application to query about * @param escrowAddr - escrow address * @returns UserDepositStakingLocalState user deposit staking local state */ export declare function depositStakingLocalState(state: TealKeyValue[], depositStakingAppId: number, escrowAddr: string): UserDepositStakingLocalState; /** * * Derives deposit staking programs info from deposit staking info. * Use for advanced use cases where optimising number of network request. * * @param depositStakingInfo - deposit staking info which is returned by retrieveDepositStakingInfo function * @param poolManagerInfo - pool manager info which is returned by retrievePoolManagerInfo function * @param pools - pools in pool manager (either MainnetPools or TestnetPools) * @param oraclePrices - oracle prices which is returned by getOraclePrices function * @returns Promise deposit staking programs info */ export declare function depositStakingProgramsInfo(depositStakingInfo: DepositStakingInfo, poolManagerInfo: PoolManagerInfo, pools: Record, oraclePrices: OraclePrices): DepositStakingProgramInfo[]; /** * * Derives user loan info from escrow account. * Use for advanced use cases where optimising number of network request. * * @param localState - local state of escrow account * @param poolManagerInfo - pool manager info which is returned by retrievePoolManagerInfo function* * @param depositStakingProgramsInfo - deposit staking programs info which is returned by depositStakingProgramsInfo function * @returns Promise user loans info */ export declare function userDepositStakingInfo(localState: UserDepositStakingLocalState, poolManagerInfo: PoolManagerInfo, depositStakingProgramsInfo: DepositStakingProgramInfo[]): UserDepositStakingInfo; /** * * Derives loan local state from escrow account. * * @param state - escrow account local state * @param loanAppId - loan application to query about * @param escrowAddr - escrow address * @returns LoanLocalState loan local state */ export declare function loanLocalState(state: TealKeyValue[], loanAppId: number, escrowAddr: string): LoanLocalState; /** * * Derives user loan info from escrow account. * Use for advanced use cases where optimising number of network request. * * @param localState - local state of escrow account * @param poolManagerInfo - pool manager info which is returned by retrievePoolManagerInfo function * @param loanInfo - loan info which is returned by retrieveLoanInfo function * @param oraclePrices - oracle prices which is returned by getOraclePrices function * @returns Promise user loans info */ export declare function userLoanInfo(localState: LoanLocalState, poolManagerInfo: PoolManagerInfo, loanInfo: LoanInfo, oraclePrices: OraclePrices): UserLoanInfo; //# sourceMappingURL=utils.d.ts.map