Skip to content

Guides

Step-by-step recipes for reading onchain data: fixing a specific error you hit, or pulling a specific value out of a protocol like Aave, Uniswap, or Chainlink. Copy the snippet, adapt the address, move on.

Pendle PT exchange rate — reading getPtToAssetRate via API across Ethereum, Base, and BNB Chain
Guide

Pendle PT Exchange Rate: How to Read It via API

How to read a Pendle PT token's exchange rate to its underlying asset via API, using Pendle's own getPtToAssetRate oracle across Ethereum, Base, and BNB Chain.

A TypeScript script comparing a Chainlink Proof of Reserve answer with WBTC and cbBTC total supply
Guide

WBTC and cbBTC Proof of Reserves Check in TypeScript

Compare Chainlink's WBTC and cbBTC Proof of Reserve feeds with on-chain totalSupply in a TypeScript script that exits non-zero when the ratio or feed age slips.

A Google Sheets table with an ERC20_BALANCE formula returning a token balance
Guide

Google Sheets ERC-20 Token Balance: A Custom Function with Apps Script

Add an ERC20_BALANCE function to Google Sheets with Apps Script: cached lookups, an API key kept out of cells, and a daily trigger that logs a snapshot row.

Morpho Blue — read health factor and liquidation price via API
Guide

Morpho Blue: Read Health Factor and Liquidation Price via API

Morpho Blue has no healthFactor field. Compute it from position(), market(), and the market's own oracle price and LLTV — one batched API call, no SDK required.

Uniswap V3 position tick range with the pool's current tick outside it, triggering a Telegram alert
Guide

Uniswap V3 Out-of-Range Alert: Get a Telegram Message When Your LP Position Stops Earning

Build a Uniswap V3 out-of-range alert in TypeScript: read a position's tick range and the pool tick in one request, then message Telegram on each change.

Lido stETH exchange rate — shares vs. balance and the wstETH conversion rate
Guide

Lido stETH Exchange Rate: How to Read It Correctly via API

How to read Lido's real stETH exchange rate via API: shares vs. balance, the wstETH rate, and why balanceOf alone isn't precise enough for accounting.

Aave V4 health factor, what changed from V3 and how to read a spoke position onchain
Guide

Aave V4 Health Factor: What Changed From V3 and How to Read It

Aave V4 health factor explained: hubs and spokes, per-spoke positions, the variable liquidation bonus, and how to read getUserAccountData onchain with one REST call.

Python depeg alert for USDC, USDT and DAI built on Chainlink USD feeds and Telegram
Guide

Stablecoin Depeg Alert in Python With Chainlink and Telegram

Build a Python depeg alert for USDC, USDT and DAI that reads Chainlink feeds in one request, sends Telegram messages on state changes only and runs from cron.

A Telegram message warning that an Aave V3 health factor dropped below the alert threshold
Guide

Liquidation Alert Telegram Bot in Python for Aave, Compound and Morpho

Build a Python Telegram bot that watches one wallet on Aave V3, Compound V3 and Morpho Blue in a single request, alerts on transitions only, and runs from cron.