Constructors

Properties

address?: string
addresses?: NetworkContracts
calculations: CalculationService
chainId: number
logLevel: LogLevel
provider: MulticallProvider
signer?: Signer
zeroXApiKey?: string

Methods

  • Claims testnet collateral to open positions on the testnet. This is for the tesnet only and will revert if called on mainnet.

    Parameters

    Returns Promise<TransactionStatus>

    Transaction status of the liquidate transaction

  • Parameters

    • Optional overrides: Overrides

      Current price read overrides

    Returns Promise<BigNumber>

    Current price registered with system oracle in Ether units

    Deprecated

    Use PriceService instead. Retrieve current price from oracle

  • Check how much collateral can be claimed from the surplus pool for a given account

    Parameters

    • account: string

      Address of the account to check

    • Optional overrides: Overrides

      Claim overrides

    Returns Promise<BigNumber>

    Amount of collateral that can be claimed in Ether units

  • Gives the address of the eBTC contract for the given chainId

    Parameters

    • chainId: number

      Chain ID of the network

    Returns undefined | NetworkContracts

    Addresses for the eBTC contracts

  • Retrieve the eBTC gas compensation

    Parameters

    • Optional overrides: Overrides

      eBTC gas compensation overrides

    Returns Promise<BigNumber>

    Amount required for deposit for gas compensation

  • Parameters

    • Optional overrides: Overrides

      Chainlink oracle overrides

    Returns Promise<BigNumber>

    Latest stETH/USD price in an 8 decimal BigNumber

    Deprecated

    Use PriceService instead. Get the latest stETH/USD price from the Chainlink oracle

  • Parameters

    Returns MulticallProvider

  • Returns Promise<BigNumber>

    Current share price of stEth in Ether units

    Deprecated

    Use PriceService instead. Returns the current share price of stEth

  • Check how much collateral can be claimed in the system as a whole

    Parameters

    • Optional overrides: Overrides

      Claim overrides

    Returns Promise<BigNumber>

    Amount of collateral that can be claimed in the system as a 18 decimal BigNumber

  • Returns true if the system is currently in recovery mode for the current price

    Parameters

    • Optional overrides: Overrides

      overrides

    Returns Promise<boolean>

    True if the system is in recovery mode

  • Prepare the SDK services for use.

    Returns Promise<void>

Generated using TypeDoc