Astroport Documentation
website·Indexed 34 days ago
https://docs.astroport.fi/Documentation for Astroport, a next-generation Automated Market Maker (AMM) and DEX for the Cosmos ecosystem. Includes guides on swapping, providing liquidity in Passive Concentrated Liquidity (PCL) pools, bridging tokens via Wormhole and Injective, and technical specifications for smart contracts like the Astral Assembly.
What's inside Astroport
- ASTRO (on Terra 2) and ASTROC (on Terra Classic) are the native tokens of the Astroport ecosystem. They serve as the primary tools for coordinating and aligning incentives among stakeholders, allowing users and builders to own, control, operate, maintain, and update the Astroport smart contract system on their respective blockchains.
Overview of the Astroport Maker contract
The Maker contract is responsible for collecting a portion of Astroport's pair fees (defined by the factory'smaker_fee). These accrued fees are swapped into ASTRO and distributed to stakers and governance based on thegovernance_percentconfiguration.Overview of Emissions Voting with vxASTRO
The vxASTRO contract allows xASTRO token holders to lock their tokens to participate in Emissions Voting, which directs ASTRO emissions. vxASTRO holders can allocate their voting power to a maximum of five pools once per epoch. Once votes are cast, they cannot be changed until the next epoch.
Key characteristics of vxASTRO include:
- Non-Transferable: Tokens cannot be swapped or transferred between addresses.
- Governance: Holders retain their standard Astroport Governance voting power while tokens are locked.
- Emissions Interaction: The contract interacts with the Emissions Controller to update a user's contribution to Emissions Voting whenever their balance changes.
Overview of Astroport Stableswap Pools
Stableswap pools in Astroport use the 4A(Rx+Ry) + D formula to maintain a constant price ratio (∆x / ∆y = 1), making them ideal for assets that should maintain a stable peg.Overview of Astroport's role in the Cosmos ecosystem
Astroport is designed as a next-generation Automated Market Maker (AMM) serving as the underlying liquidity layer for the Cosmos ecosystem. Its primary objective is to provide deep liquidity pools and high trading volumes to support various DeFi primitives, including:
- Liquidity mining programs for new Cosmos tokens (including dual rewards).
- Price oracles and data for credit protocols (e.g., Mars Protocol).
- Infrastructure for index products and token baskets.
- Liquidity sourcing for wallets and trading aggregators.
- The base liquidity layer for yield farming protocols.
Overview of the Astroport Router contract
The Router contract facilitates multi-hop swaps for Cosmos native and CW20 tokens. It allows users to route trades through multiple pools to optimize for the best output.Mainnet Address: terra1j8hayvehh3yy02c2vtw5fdhz9f4drhtee8p5n5rguvg3nyd6m83qd2y90a Testnet Address: terra1na348k6rvwxje9jj6ftpsapfeyaejxjeq6tuzdmzysps20l6z23smnlv64
Overview of the Astroport Oracle contract
The Astroport Oracle contract is designed to calculate a 1-day Time-Weighted Average Price (TWAP) for xy=k Astroport pools.Overview of the Astroport Factory contract
The Factory contract creates and manages Astroport pair contracts and associated LP token contracts. It maintains a registry that serves as a directory for all pairs. Supported pair types include constant product (XYK) and stableswap, with the possibility for governance to add custom pool implementations.Overview of Passive Concentrated Liquidity (PCL) Pools
Astroport's Passive Concentrated Liquidity (PCL) pools automate the concentrated liquidity experience. Instead of requiring LPs to manually manage price ranges, liquidity is automatically concentrated around an internal oracle price, which is calculated as the moving average of recent trades in the pair.Overview of Astroport Staking
The staking contract enables ASTRO holders to stake their tokens to receive xASTRO. The amount of ASTRO that can be claimed upon unstaking increases over time as accrued fees from the Maker contract are swapped to ASTRO and distributed to stakers.Overview of the Native Coin Wrapper
The Native Coin Wrapper converts native coins into equivalent CosmWasm (CW20) tokens. This allows native coins to be used for deploying proxy rewards and connecting with reward generators within the Astroport ecosystem. Native coins are held in escrow by the contract while the equivalent CW20 tokens are minted. Users can later burn these CW20 tokens to release the original native coins from escrow.Overview of the Astral Assembly contract
The Astral Assembly contract enables xASTRO holders and Initial Astroport Builders to create and vote on on-chain proposals that can execute arbitrary logic.
Contract Addresses:
- Mainnet:
terra1k9j8rcyk87v5jvfla2m9wp200azegjz0eshl7n2pwv852a7ssceqsnn7pq - Testnet:
terra195m6n5xq4rkjy47fn5y3s08tfmj3ryknj55jqvgq2y55zul9myzsgy06hk
- Mainnet: