Morpho: Find Borrow Rate Delta
0x484428507A212cA56D71baa27Ca6089a6dB63a88

What this does

This plug reads the borrow rates of two Morpho Blue markets, converts each to an APR, and computes which APR is higher along with the difference between them. It asks the caller for two parameters, current_market and target_market. It runs on demand and outputs the current_apr_is_higher flag and the apr_delta value. Comparing these rates by hand or from a stale reading risks acting on an APR gap that no longer reflects the live markets.

Actions · 11

  • Get borrow rate
    Get borrow rate of
    Reads a Morpho Blue market's current borrow rate as a per-second rate and an APY.
  • Use
    Use where
    borrow_rate_per_secondis
    Composes another plug inside this one.
  • Set
    Set to
    Assigns a value to a named variable that later steps reference.
  • Get borrow rate
    Get borrow rate of
    Reads a Morpho Blue market's current borrow rate as a per-second rate and an APY.
  • Use
    Use where
    borrow_rate_per_secondis
    Composes another plug inside this one.
  • Set
    Set to
    Assigns a value to a named variable that later steps reference.
  • Use
    Use where
    value_1is
    value_2is
    Composes another plug inside this one.
  • Set
    Set to
    Assigns a value to a named variable that later steps reference.
  • Set
    Set to
    Assigns a value to a named variable that later steps reference.
  • Bubble
    Bubble
    Surfaces a value as an output of this plug.
  • Bubble
    Bubble
    Surfaces a value as an output of this plug.

Related plugs · 8