Bubble
Bubble

Plug · Acts onchain

Surfaces a value as an output of this plug. The value is echoed into a dedicated slot and declared as the program's return: what a caller composing this plug through Use reads back. It is the inverse of Take. Reach for it to return a computed amount, a position id, or a boolean from a reusable plug, so the plug that uses it can coil the result into its own next step.

Get Chainlink Token Value (USD)

plug
math
5actions
  1. 1·Take

    Opening with a declared parameter, token is left for the caller to supply at execution time, naming the asset to be valued.

  2. 2·Take

    A second parameter, amount, is declared as caller-supplied, giving the quantity that the price will be applied to.

  3. 3·Use

    Composing the Get Chainlink Price (USD) plug pulls its price-reading logic into this one, returning the token's USD rate.

  4. 4·Calculate

    Multiplying the composed price by amount converts the supplied quantity into its USD value.

  5. 5·Bubble

    Surfacing that product returns the computed USD value as the output of this plug.

Take
Take
Use where
tokenis
Calculate
Bubble
  • Get Chainlink Token Value (USD)

    plug
    math
  • Get Chainlink Price (USD)

    plug
    chainlink
  • Transfer Token on a Schedule

    plug
    evm
    time
  • Expected Amount to Minimum Received

    plug
    math
    values
  • Approve Spending

    plug
    evm
  • Unwrap WETH to ETH

    evm
    plug
  • Wrap ETH to WETH

    evm
    plug
  • Get Simple Moving Average

    plug
    time
    chainlink
  • Get Weight Target

    plug
    values
    math
  • Get Price Running Total

    plug
    values
    math
  • Get Token Target

    plug
    database
    evm
  • Get Total Holdings Value

    plug
    evm
    boolean
  • Get Target Balance

    plug
    math
    evm
  • Get Holding Value

    plug
    evm
    math
  • Swap at Floor

    plug
    evm
    values
  • Morpho: Check Refinancing Constraints

    plug
    morpho
    evm
  • Morpho: Check Market Liquidity Vs. Required Amount

    plug
    evm
  • Morpho: Check Health Factor Vs. Min Threshold

    plug
    evm
  • Morpho: Find Borrow Rate Delta

    plug
    morpho
    evm
  • Morpho: Check Borrow Rate Delta Vs. Min Threshold

    plug
    evm
    boolean
  • Check Required Amount

    plug
    math
    evm
  • Morpho: Get Market Liquidity

    plug
    morpho
    math
  • Check Minimum Threshold

    plug
    boolean
    evm
  • Morpho: Get Borrow APR

    plug
    values
    math
  • Find Value Delta

    plug
    boolean
    evm
  • Morpho: Get Health Factor

    plug
    boolean
    evm
  • Morpho: Collateral Value to Borrow Capacity

    plug
    math
    evm
  • Morpho: Collateral Amount to Collateral Value

    plug
    math
  • Morpho: Borrow Shares to Borrow Assets

    plug
    math
    evm
  • Value to Token Amount

    plug
    aave
    math
  • Target Debt to Debt Delta

    plug
    aave
    boolean