LogoLogo
  • Introduction
  • App
    • How to
      • Connect a wallet
      • Swap
      • Approve Spending
      • Open a Long Position
      • Open a Short Position
      • Withdraw Funds
      • Add Funds
      • Close Position
      • Increase Leverage
      • Pay Off Debt
      • Deposit Liquidity
      • Withdraw Liquidity
      • Add Liquidity
    • Smart contract addresses
      • Arbitrum
      • Blast
    • FAQ
  • Protocol mechanics
    • Providing Liquidity
    • Trading
    • Marginly MAX leverage specifics
  • Protocol architecture
    • Overview
    • Pools
      • Pool variables
      • Pool parameters
      • User positions
      • User actions
      • Pool Factory API
      • Pool API
    • TWAP oracle
    • Loan pricing
    • Errors
    • Marginly SDK
  • Router
    • Router architecture
    • Adapters
      • ApeSwapAdapter
      • BalancerAdapter
      • CamelotAdapter
      • KyberSwapClassicAdapter
      • KyberSwapElasticAdapter
      • UniswapV2Adapter
      • UniswapV3Adapter
      • WooFiAdapter
  • Risk Management
    • Risk Management Overview
    • Keeper service and smart contract description
    • Keeper contract architecture
    • Liquidations and Deleveraging
    • Volatility as risk proxy
    • Insurance pool
    • Shutdown mode
  • Economics
    • Marginly economics
  • Future plans
    • Beyond Marginly v1
    • Some ideas for Marginly v2
  • Trading Contest FAQ
  • Github
  • Audit
Powered by GitBook
On this page
  1. Router

Adapters

AdapterActions

addPools

function addPools(struct PoolInput[] pools) external

Add pools to router adapter storage. Allowed only for MarginlyPoolAdmin owner

Parameters

Name
Type
Description

pools

struct PoolInput[]

New pool parameters

transferRouterAdapterOwnership

function transferRouterAdapterOwnership(uint256 dexIdx, address to) external

Set a new owner of a Marginly router adapter contract. Allowed only for MarginlyPoolAdmin owner

Parameters

Name
Type
Description

dexIdx

uint256

Index of a dex

to

address

Address of a new Marginly router adapter owner

acceptRouterAdapterOwnership

function acceptRouterAdapterOwnership(uint256 dexIdx) external

Accepts ownership of adapter. Needed for new pools addition

Parameters

Name
Type
Description

dexIdx

uint256

Index of a dex

PreviousRouter architectureNextApeSwapAdapter

Last updated 1 year ago