# Fathom Protocol

## Fathom Protocol

- [Introduction](https://docs.fathom.fi/introduction.md): Introduction to the Fathom Protocol
- [FXD Stablecoin](https://docs.fathom.fi/fxd-stablecoin.md): Introduction to Fathom's FXD Stablecoin
- [FXD Smart Contract Architecture](https://docs.fathom.fi/fxd-stablecoin/fxd-smart-contract-architecture.md)
- [Minting and Burning Mechanisms with LTV Ratio](https://docs.fathom.fi/fxd-stablecoin/minting-and-burning-mechanisms-with-ltv-ratio.md)
- [Soft-Pegging to the US Dollar](https://docs.fathom.fi/fxd-stablecoin/soft-pegging-to-the-us-dollar.md): Soft-Pegging of FXD's market price to $1 is done by arbitrageurs. This section explains FXD pegging mechanism.
- [Opening and closing position flows](https://docs.fathom.fi/fxd-stablecoin/opening-and-closing-position-flows.md)
- [BookKeeping mechanism](https://docs.fathom.fi/fxd-stablecoin/bookkeeping-mechanism.md): In Fathom's FXD stablecoin system, two important accounting mechanisms are central: stablecoin accounting and collateral accounting.
- [Stablecoin Accounting](https://docs.fathom.fi/fxd-stablecoin/bookkeeping-mechanism/stablecoin-accounting.md): This section provides a deep understanding of how the accounting of issued stablecoin is done in the BookKeeper contract.
- [Collateral Accounting](https://docs.fathom.fi/fxd-stablecoin/bookkeeping-mechanism/collateral-accounting.md): This section provides a deep understanding of how the accounting of collateral is done in the BookKeeper contract.
- [Liquidation](https://docs.fathom.fi/fxd-stablecoin/liquidation.md): High level explanation of liquidation process
- [Fixed Spread Liquidation Strategy](https://docs.fathom.fi/fxd-stablecoin/liquidation/fixed-spread-liquidation-strategy.md)
- [Liquidation process walk through](https://docs.fathom.fi/fxd-stablecoin/liquidation/liquidation-process-walk-through.md): This page provides a more detailed explanation of Fathom's FXD liquidation process
- [Emergency Shutdown](https://docs.fathom.fi/fxd-stablecoin/emergency-shutdown.md)
- [Maths for position safety](https://docs.fathom.fi/fxd-stablecoin/maths-for-position-safety.md): This section explains how the Fathom's FXD stablecoin position's safety is calculated.
- [Fee structure](https://docs.fathom.fi/fxd-stablecoin/fee-structure.md)
- [Risk Management](https://docs.fathom.fi/fxd-stablecoin/risk-management.md)
- [Interfaces](https://docs.fathom.fi/fxd-stablecoin/interfaces.md)
- [ProxyWalletRegistry](https://docs.fathom.fi/fxd-stablecoin/interfaces/proxywalletregistry.md): https://github.com/Into-the-Fathom/fathom-stablecoin-smart-contracts/blob/master/contracts/main/proxy-wallet/ProxyWalletRegistry.sol
- [ProxyWallet](https://docs.fathom.fi/fxd-stablecoin/interfaces/proxywallet.md): https://github.com/Into-the-Fathom/fathom-stablecoin-smart-contracts/blob/master/contracts/main/proxy-wallet/ProxyWallet.sol
- [FathomStablecoinProxyActions](https://docs.fathom.fi/fxd-stablecoin/interfaces/proxywallet/fathomstablecoinproxyactions.md): https://github.com/Into-the-Fathom/fathom-stablecoin-smart-contracts/blob/master/contracts/main/proxy-actions/FathomStablecoinProxyActions.sol
- [CollateralPoolConfig](https://docs.fathom.fi/fxd-stablecoin/interfaces/collateralpoolconfig.md): https://github.com/Into-the-Fathom/fathom-stablecoin-smart-contracts/blob/master/contracts/main/stablecoin-core/config/CollateralPoolConfig.sol
- [BookKeeper](https://docs.fathom.fi/fxd-stablecoin/interfaces/bookkeeper.md): https://github.com/Into-the-Fathom/fathom-stablecoin-smart-contracts/blob/master/contracts/main/stablecoin-core/BookKeeper.sol
- [FXD](https://docs.fathom.fi/fxd-stablecoin/interfaces/fxd.md): https://github.com/Into-the-Fathom/fathom-stablecoin-smart-contracts/blob/master/contracts/main/stablecoin-core/FathomStablecoin.sol
- [LiquidationEngine](https://docs.fathom.fi/fxd-stablecoin/interfaces/liquidationengine.md): https://github.com/Into-the-Fathom/fathom-stablecoin-smart-contracts/blob/master/contracts/main/stablecoin-core/LiquidationEngine.sol
- [FlashMintModule](https://docs.fathom.fi/fxd-stablecoin/interfaces/flashmintmodule.md): https://github.com/Into-the-Fathom/fathom-stablecoin-smart-contracts/blob/master/contracts/main/flash-mint/FlashMintModule.sol
- [PriceFeed](https://docs.fathom.fi/fxd-stablecoin/interfaces/pricefeed.md): https://github.com/Into-the-Fathom/fathom-stablecoin-smart-contracts/blob/master/contracts/main/price-feeders/CentralizedOraclePriceFeed.sol
- [ShowStopper](https://docs.fathom.fi/fxd-stablecoin/interfaces/showstopper.md): https://github.com/Into-the-Fathom/fathom-stablecoin-smart-contracts/blob/master/contracts/main/stablecoin-core/ShowStopper.sol
- [StabilityFeeCollector](https://docs.fathom.fi/fxd-stablecoin/interfaces/stabilityfeecollector.md): https://github.com/Into-the-Fathom/fathom-stablecoin-smart-contracts/blob/master/contracts/main/stablecoin-core/StabilityFeeCollector.sol
- [SystemDebtEngine](https://docs.fathom.fi/fxd-stablecoin/interfaces/systemdebtengine.md): https://github.com/Into-the-Fathom/fathom-stablecoin-smart-contracts/blob/master/contracts/main/stablecoin-core/SystemDebtEngine.sol
- [AdminControls](https://docs.fathom.fi/fxd-stablecoin/interfaces/admincontrols.md): https://github.com/Into-the-Fathom/fathom-stablecoin-smart-contracts/blob/master/contracts/main/stablecoin-core/AdminControls.sol
- [Deployments](https://docs.fathom.fi/fxd-stablecoin/deployments.md)
- [XDC Network](https://docs.fathom.fi/fxd-stablecoin/deployments/xdc-network.md): Addresses of deployed contract on XDC mainnet and Apothem testnet
- [User Guides](https://docs.fathom.fi/fxd-stablecoin/user-guides.md)
- [Open FXD position](https://docs.fathom.fi/fxd-stablecoin/user-guides/open-fxd-position.md)
- [Top Up FXD Position](https://docs.fathom.fi/fxd-stablecoin/user-guides/top-up-fxd-position.md)
- [Repay and close FXD position](https://docs.fathom.fi/fxd-stablecoin/user-guides/repay-and-close-fxd-position.md)
- [Vaults](https://docs.fathom.fi/vaults.md)
- [Key Features](https://docs.fathom.fi/vaults/key-features.md)
- [Definitions](https://docs.fathom.fi/vaults/definitions.md)
- [Architecture](https://docs.fathom.fi/vaults/architecture.md)
- [Fees](https://docs.fathom.fi/vaults/fees.md)
- [Workflows](https://docs.fathom.fi/vaults/workflows.md)
- [Vault Management](https://docs.fathom.fi/vaults/vault-management.md)
- [Strategy Creation](https://docs.fathom.fi/vaults/strategy-creation.md)
- [Interfaces](https://docs.fathom.fi/vaults/interfaces.md)
- [Factory](https://docs.fathom.fi/vaults/interfaces/factory.md): https://github.com/Into-the-Fathom/fathom-vaults-smart-contracts/blob/master/contracts/factory/packages/FactoryPackage.sol
- [Vault](https://docs.fathom.fi/vaults/interfaces/vault.md): https://github.com/Into-the-Fathom/fathom-vaults-smart-contracts/blob/master/contracts/vault/packages/VaultPackage.sol
- [BaseStrategy](https://docs.fathom.fi/vaults/interfaces/basestrategy.md): https://github.com/Into-the-Fathom/fathom-vaults-smart-contracts/blob/master/contracts/strategy/BaseStrategy.sol
- [TokenizedStrategy](https://docs.fathom.fi/vaults/interfaces/tokenizedstrategy.md): https://github.com/Into-the-Fathom/fathom-vaults-smart-contracts/blob/master/contracts/strategy/TokenizedStrategy.sol
- [Deployments](https://docs.fathom.fi/vaults/deployments.md)
- [XDC Network](https://docs.fathom.fi/vaults/deployments/xdc-network.md)
- [User Guides](https://docs.fathom.fi/vaults/user-guides.md)
- [Deposit and Withdraw in Vault](https://docs.fathom.fi/vaults/user-guides/deposit-and-withdraw-in-vault.md)
- [Lending](https://docs.fathom.fi/lending.md)
- [Core Concepts](https://docs.fathom.fi/lending/core-concepts.md)
- [Protocol Mechanics](https://docs.fathom.fi/lending/protocol-mechanics.md)
- [Architecture](https://docs.fathom.fi/lending/architecture.md)
- [Interfaces](https://docs.fathom.fi/lending/interfaces.md)
- [FmToken](https://docs.fathom.fi/lending/interfaces/fmtoken.md): https://github.com/Into-the-Fathom/fathom-lending-platform-smart-contracts/blob/master/contracts/protocol/tokenization/FmToken.sol
- [VariableDebtToken](https://docs.fathom.fi/lending/interfaces/variabledebttoken.md): https://github.com/Into-the-Fathom/fathom-lending-platform-smart-contracts/blob/master/contracts/protocol/tokenization/VariableDebtToken.sol
- [StableDebtToken](https://docs.fathom.fi/lending/interfaces/stabledebttoken.md): https://github.com/Into-the-Fathom/fathom-lending-platform-smart-contracts/blob/master/contracts/protocol/tokenization/StableDebtToken.sol
- [L2Pool](https://docs.fathom.fi/lending/interfaces/l2pool.md): https://github.com/Into-the-Fathom/fathom-lending-platform-smart-contracts/blob/master/contracts/protocol/pool/L2Pool.sol
- [PoolAddressesProvider](https://docs.fathom.fi/lending/interfaces/pooladdressesprovider.md): https://github.com/Into-the-Fathom/fathom-lending-platform-smart-contracts/blob/master/contracts/protocol/configuration/PoolAddressesProvider.sol
- [User Guides](https://docs.fathom.fi/lending/user-guides.md)
- [Supply, Borrow, Repay and Withdraw Asset](https://docs.fathom.fi/lending/user-guides/supply-borrow-repay-and-withdraw-asset.md)
- [Deployments](https://docs.fathom.fi/lending/deployments.md)
- [XDC Network](https://docs.fathom.fi/lending/deployments/xdc-network.md)
- [DEX](https://docs.fathom.fi/dex.md)
- [Core Concepts](https://docs.fathom.fi/dex/core-concepts.md)
- [Architecture](https://docs.fathom.fi/dex/architecture.md)
- [Interfaces](https://docs.fathom.fi/dex/interfaces.md)
- [Factory](https://docs.fathom.fi/dex/interfaces/factory.md): https://github.com/Into-the-Fathom/fathom-swap-smart-contracts/blob/master/contracts/core/UniswapV2Factory.sol
- [Pair](https://docs.fathom.fi/dex/interfaces/pair.md): https://github.com/Into-the-Fathom/fathom-swap-smart-contracts/blob/master/contracts/core/UniswapV2Pair.sol
- [Router](https://docs.fathom.fi/dex/interfaces/router.md): https://github.com/Into-the-Fathom/fathom-swap-smart-contracts/blob/master/contracts/periphery/UniswapV2Router02.sol
- [User Guides](https://docs.fathom.fi/dex/user-guides.md)
- [Providing Liquidity](https://docs.fathom.fi/dex/user-guides/providing-liquidity.md)
- [Swapping Assets](https://docs.fathom.fi/dex/user-guides/swapping-assets.md)
- [Deployments](https://docs.fathom.fi/dex/deployments.md)
- [XDC Network](https://docs.fathom.fi/dex/deployments/xdc-network.md)
- [DAO](https://docs.fathom.fi/dao.md)
- [DAO Structure](https://docs.fathom.fi/dao/dao-structure.md)
- [Governance Process](https://docs.fathom.fi/dao/governance-process.md)
- [Staking Process](https://docs.fathom.fi/dao/staking-process.md)
- [Treasury Management](https://docs.fathom.fi/dao/treasury-management.md)
- [Risk Management and Security Measures](https://docs.fathom.fi/dao/risk-management-and-security-measures.md)
- [Contributing to Fathom DAO](https://docs.fathom.fi/dao/contributing-to-fathom-dao.md)
- [Interfaces](https://docs.fathom.fi/dao/interfaces.md)
- [FTHM](https://docs.fathom.fi/dao/interfaces/fthm.md): https://github.com/Into-the-Fathom/fathom-dao-smart-contracts/blob/master/contracts/dao/tokens/MainToken.sol
- [Staking](https://docs.fathom.fi/dao/interfaces/staking.md)
- [Vault](https://docs.fathom.fi/dao/interfaces/staking/vault.md): https://github.com/Into-the-Fathom/fathom-dao-smart-contracts/blob/master/contracts/dao/staking/vault/packages/VaultPackage.sol
- [RewardsCalculator](https://docs.fathom.fi/dao/interfaces/staking/rewardscalculator.md): https://github.com/Into-the-Fathom/fathom-dao-smart-contracts/tree/master/contracts/dao/staking/packages
- [vFTHM](https://docs.fathom.fi/dao/interfaces/staking/vfthm.md): https://github.com/Into-the-Fathom/fathom-dao-smart-contracts/blob/master/contracts/dao/tokens/VMainToken.sol
- [Governance](https://docs.fathom.fi/dao/interfaces/governance.md): https://github.com/Into-the-Fathom/fathom-dao-smart-contracts/blob/master/contracts/dao/governance/MainTokenGovernor.sol
- [TimelockController](https://docs.fathom.fi/dao/interfaces/governance/timelockcontroller.md): https://github.com/Into-the-Fathom/fathom-dao-smart-contracts/blob/master/contracts/dao/governance/TimelockController.sol
- [Deployments](https://docs.fathom.fi/dao/deployments.md)
- [XDC Network](https://docs.fathom.fi/dao/deployments/xdc-network.md)
- [User Guides](https://docs.fathom.fi/dao/user-guides.md)
- [Staking](https://docs.fathom.fi/dao/user-guides/staking.md)
- [Proposing](https://docs.fathom.fi/dao/user-guides/proposing.md)
- [Voting](https://docs.fathom.fi/dao/user-guides/voting.md)
- [Whitepaper](https://docs.fathom.fi/whitepaper.md)
- [Version 1.0](https://docs.fathom.fi/whitepaper/version-1.0.md)
- [Resources](https://docs.fathom.fi/resources.md)
- [FXD Deployments](https://docs.fathom.fi/fxd-deployments.md)
- [FTHM Deployments](https://docs.fathom.fi/fthm-deployments.md)
- [Privacy Policy](https://docs.fathom.fi/privacy-policy.md): Last modified: April 9, 2024 https://gist.github.com/BaldyAsh/47a33c5e8005c05315cc8dfc9baa4c0e
- [Terms of Service](https://docs.fathom.fi/terms-of-service.md): Last modified: April 9, 2024 https://gist.github.com/BaldyAsh/9e1efbfd87fa87fd67091b5d45c481b3


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
This site has an agentic ask interface you may use to query the documentation dynamically by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.fathom.fi/index.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.
