The Problem
Stablecoin depegs cause billions in losses. In 2022 TerraUSD collapsed overnight, wiping out billions in savings. Most people had no idea it was happening until it was too late.
The existing monitoring tools have a fundamental flaw — they rely on a single price source. One source can be wrong, manipulated, or just slow.
The Solution — Median of Medians
I built PegCheck, a stablecoin depeg monitoring API that aggregates from 6 independent sources:
CoinGecko
Coinbase
Binance
Kraken
DefiLlama
Chainlink price feeds
Then calculates a median across all of them — producing a single manipulation-resistant consensus price across 1,500+ data points.
The Chainlink Integration
Adding Chainlink took PegCheck to another level:
Price Feeds — USDT, USDC, USDS and TUSD price feeds on Ethereum Mainnet, added as a verified on-chain source to the median calculation.
Proof of Reserve — Chainlink PoR data for TUSD, giving verified on-chain reserve verification directly in the API response.
On-chain depeg logging — Every depeg event is permanently logged to an Ethereum smart contract. Immutable, public, verifiable by anyone at pegcheck.uk/onchain.
The API
Five clean REST endpoints.
GET /api/v1/coins
GET /api/v1/coins/{slug}
GET /api/v1/coins/{slug}/history
GET /api/v1/alerts/status
POST /api/v1/webhooks/register
Bearer token auth, three pricing tiers, Stripe payments, auto key generation, customer dashboard.
Quick Example
Javascript
fetch("https://pegcheck.uk/api/v1/coins", {
headers: { "Authorization": "Bearer YOUR_KEY" }
})
.then(r => r.json())
.then(data => console.log(data))
Returns:
Json
{
"slug": "usdt",
"price": 0.9998,
"status": "stable",
"deviation": -0.02,
"chainlink_por": {
"reserves": 50192890088,
"updated_at": "2026-04-30T12:00:00Z"
}
}
Try It Free
30 day free trial, no credit card needed.
👉 pegcheck.uk/developers
Top comments (0)