Fathom Protocol
  • Introduction
  • FXD Stablecoin
    • FXD Smart Contract Architecture
    • Minting and Burning Mechanisms with LTV Ratio
    • Soft-Pegging to the US Dollar
    • Opening and closing position flows
    • BookKeeping mechanism
      • Stablecoin Accounting
      • Collateral Accounting
    • Liquidation
      • Fixed Spread Liquidation Strategy
      • Liquidation process walk through
    • Emergency Shutdown
    • Maths for position safety
    • Fee structure
    • Risk Management
    • Interfaces
      • ProxyWalletRegistry
      • ProxyWallet
        • FathomStablecoinProxyActions
      • CollateralPoolConfig
      • BookKeeper
      • FXD
      • LiquidationEngine
      • FlashMintModule
      • PriceFeed
      • ShowStopper
      • StabilityFeeCollector
      • SystemDebtEngine
      • AdminControls
    • Deployments
      • XDC Network
    • User Guides
      • Open FXD position
      • Top Up FXD Position
      • Repay and close FXD position
    • Fathom Stablecoin Smart Contracts
    • Fathom Stablecoin Subgraph
  • Vaults
    • Key Features
    • Definitions
    • Architecture
    • Fees
    • Workflows
    • Vault Management
    • Strategy Creation
    • Interfaces
      • Factory
      • Vault
      • BaseStrategy
      • TokenizedStrategy
    • Deployments
      • XDC Network
    • User Guides
      • Deposit and Withdraw in Vault
    • Fathom Vaults Smart Contracts
    • Fathom Vaults Subgraph
  • Lending
    • Core Concepts
    • Protocol Mechanics
    • Architecture
    • Interfaces
      • FmToken
      • VariableDebtToken
      • StableDebtToken
      • L2Pool
      • PoolAddressesProvider
    • User Guides
      • Supply, Borrow, Repay and Withdraw Asset
    • Deployments
      • XDC Network
    • Fathom Lending Smart Contracts
    • Fathom Lending Subgraph
  • DEX
    • Core Concepts
    • Architecture
    • Interfaces
      • Factory
      • Pair
      • Router
    • User Guides
      • Providing Liquidity
      • Swapping Assets
    • Deployments
      • XDC Network
    • Fathom DEX Smart Contracts
    • Fathom DEX Subgraph
  • DAO
    • DAO Structure
    • Governance Process
    • Staking Process
    • Treasury Management
    • Risk Management and Security Measures
    • Contributing to Fathom DAO
    • Interfaces
      • FTHM
      • Staking
        • Vault
        • RewardsCalculator
        • vFTHM
      • Governance
        • TimelockController
    • Deployments
      • XDC Network
    • User Guides
      • Staking
      • Proposing
      • Voting
    • Fathom DAO Smart Contracts
    • Fathom DAO Subgraph
  • Whitepaper
    • Version 1.0
  • Resources
  • FXD Deployments
  • FTHM Deployments
  • Privacy Policy
  • Terms of Service
Powered by GitBook

Copyright© Fathom App 2024.

On this page

Was this helpful?

Export as PDF
  1. FXD Stablecoin
  2. Interfaces

LiquidationEngine

https://github.com/Into-the-Fathom/fathom-stablecoin-smart-contracts/blob/master/contracts/main/stablecoin-core/LiquidationEngine.sol

The LiquidationEngine contract manages all liquidations within the protocol, providing interfaces for liquidators to initiate the liquidation process for positions that are under-collateralized.

Functions

  • liquidate(bytes32 _collateralPoolId, address _positionAddress, uint256 _debtShareToBeLiquidated, uint256 _maxDebtShareToBeLiquidated, address _collateralRecipient, bytes calldata _data): Allows a whitelisted liquidator to initiate the liquidation of a position. It requires the ID of the collateral pool, the address of the position, the amount of debt to be liquidated, a maximum allowable debt amount for liquidation to manage slippage, the recipient of the collateral, and additional data for the liquidation process.

  • batchLiquidate(bytes32[] calldata _collateralPoolIds, address[] calldata _positionAddresses, uint256[] calldata _debtShareToBeLiquidateds, uint256[] calldata _maxDebtShareToBeLiquidateds, address[] calldata _collateralRecipients, bytes[] calldata datas): Facilitates the batch liquidation of multiple positions in a single transaction. This method enhances efficiency in handling liquidations at scale.

Events

  • LiquidationFail(bytes32 _collateralPoolId, address _positionAddress, address _liquidator, string reason): Emitted when a liquidation attempt fails. It provides details about the failed operation, including the collateral pool ID, position address, liquidator, and reason for failure.

PreviousFXDNextFlashMintModule

Last updated 11 months ago

Was this helpful?