Get price

Get price on Compound

Ethereum
Ethereum
Base
Base

Reads onchain state

Ready to run on Base

Reads the price of an asset in a Compound market from the market's own feed. The action picks the base token's feed or the collateral asset's feed as appropriate and asks Comet for the price at its 8-decimal scale, so the number is exactly what the market uses to value collateral and debt. Reach for it to convert between token and dollar amounts inside the market's own accounting: sizing a collateral supply to a target capacity, or checking how far a position sits from its liquidation factor.

Plug lets you combine onchain actions like this one into a single transaction, without writing a smart contract. Use in App opens a new plug with this action already in it.

More plugs on Base

Earn yield on Base · 12 plugs

More on Compound · 20

On other protocols · 12