Fx Stablecoin Peg
by Tanod utilpeek in Onchain & crypto
Stablecoin peg check: price vs USD, deviation in basis points and peg status for USDC, USDT, DAI, USDe and PYUSD from public Ethereum pools (utilpeek by Tanod). Use when an agent must check whether USDC, USDT, DAI, USDe or PYUSD still trades at one dollar, from on-chain pools.
POST https://tanod.dev/v1/fx/stablecoin-peg
Last 30 days
Status and outage history · Atom feed
- Uptime
- 80.0%
- Response time
- 450 ms typical, 764 ms slowest 5%
- Last check
- 1 h ago
- Next check
- any minute now
How to call it
POST https://tanod.dev/v1/fx/stablecoin-peg
Each call costs $0.001 in USDC on Base, paid with the request over x402.
Run a free test callOne unpaid request, the way an agent sends it. You see the payment challenge it gets back. Nothing is charged.
Example request
From the listing.
POST https://tanod.dev/v1/fx/stablecoin-peg
content-type: application/json
{}Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
coins | array of string or null | No | Stablecoins to check, any of USDC, USDT, DAI, USDe and PYUSD (case does not matter). Omit for all five; an unknown coin is a 422 that lists the supported ones. Default: null. |
Example response
The provider's example. We can't check it without paying.
Example response, 93 lines
{
"age_s": 0,
"block": 26181166,
"cached": false,
"chain": "ethereum",
"coins": [
{
"coin": "USDC",
"cross_check": [
{
"coin_price_in_usdc": "0.99887095",
"depth_usd": 33902678,
"implied_usdc_price_usd": "1.0011303",
"pool": "0x3416cF6C708Da44DB2624D63ea0AAef7113527C6",
"venue": "uniswap_v3",
"vs": "USDT"
},
{
"coin_price_in_usdc": "0.99996720",
"depth_usd": 1421443,
"implied_usdc_price_usd": "1.0000328",
"pool": "0x5777d92f208679DB4b9778590Fa3CAB3aC9e2168",
"venue": "uniswap_v3",
"vs": "DAI"
}
],
"depth_usd": null,
"deviation_bps": 2.43,
"pools": [],
"price_basis": "cross_check",
"price_usd": "1.0002433",
"quoted_in": null,
"reference_spread_bps": 11.74,
"status": "on_peg",
"thin": false
},
{
"coin": "USDT",
"depth_usd": 33902678,
"deviation_bps": -11.29,
"pool_spread_bps": 1.87,
"pools": [
{
"ask": "0.99897097",
"bid": "0.99877095",
"coin_in_pool": 28342870,
"depth_usd": 33902678,
"deviation_bps": -11.29,
"fee_tier": 100,
"impact_bps_10k": 0.11,
"pool": "0x3416cF6C708Da44DB2624D63ea0AAef7113527C6",
"price_usd": "0.99887095",
"thin": false,
"usdc_in_pool": 5559808,
"venue": "uniswap_v3"
},
{
"ask": "0.99955757",
"bid": "0.99855719",
"coin_in_pool": 348500,
"depth_usd": 497183,
"deviation_bps": -9.43,
"fee_tier": 500,
"impact_bps_10k": 0.86,
"pool": "0x7858E59e0C01EA06Df3aF3D20aC7B0003275D4Bf",
"price_usd": "0.99905725",
"thin": false,
"usdc_in_pool": 148683,
"venue": "uniswap_v3"
}
],
"price_basis": "pool",
"price_usd": "0.99887095",
"quoted_in": "USDC",
"status": "on_peg",
"thin": false
}
],
"disclaimer": "Indicative on-chain prices read from public Uniswap V3 pools on Ethereum at the stated block. They…",
"errors": [],
"indicative": true,
"licence": "Chain data: no licence restrictions, anyone may read and use it.",
"method": "Each coin is priced against USDC in Uniswap V3 pools on Ethereum (QuoterV2 eth_calls at USD 100, fe…",
"quote_asset": "USDC",
"read_at": "2026-10-13T04:25:33Z",
"thresholds_bps": {
"off_peg_above": 200,
"on_peg_below": 50,
"rule": "on_peg if |deviation_bps| < 50; watch from 50 to 200; off_peg if above 200"
},
"timestamp": "2026-10-13T04:25:23Z",
"warnings": []
}Call it from code
The curl command shows the payment challenge. The JavaScript and Python versions pay and call, and never pay more than $0.001.
curl: see the payment challenge
# bash or zsh: see the payment challenge. Nothing is charged.
curl -sS -g -i -X POST 'https://tanod.dev/v1/fx/stablecoin-peg' \
-H 'content-type: application/json' \
--data-raw '{}'
# x402 v2 sends the challenge base64-encoded in the PAYMENT-REQUIRED header (v1 sends it in the body).
# To read the header:
curl -sS -g -o /dev/null -D - -X POST 'https://tanod.dev/v1/fx/stablecoin-peg' \
-H 'content-type: application/json' \
--data-raw '{}' \
| grep -i '^payment-required:' | cut -d' ' -f2 | tr -d '\r' | base64 --decodeJavaScript: pay and call
// npm i @x402/fetch @x402/evm viem
import { wrapFetchWithPayment, x402Client } from "@x402/fetch";
import { registerExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
// Pays at most $0.001 per call.
const client = new x402Client().setSpendControls({ maxAmountPerPayment: "$0.001" });
registerExactEvmScheme(client, { signer: privateKeyToAccount(process.env.EVM_PRIVATE_KEY) });
const pay = wrapFetchWithPayment(fetch, client);
// Not sure it's safe to pay? ToolVet checks it first for $0.005. Pay for that from a separate
// client: this one is capped at $0.001 per payment. GET https://toolvet.app/api/v1/check?url=https%3A%2F%2Ftanod.dev%2Fv1%2Ffx%2Fstablecoin-peg&method=POST
const res = await pay("https://tanod.dev/v1/fx/stablecoin-peg", {
method: "POST",
headers: { "content-type": "application/json" },
body: JSON.stringify({}),
});
console.log(res.status, await res.text());Python: pay and call
# pip install "x402[requests,evm]"
import os
from eth_account import Account
from x402 import x402ClientSync
from x402.http.clients import x402_requests
from x402.mechanisms.evm import EthAccountSigner
from x402.mechanisms.evm.exact.register import register_exact_evm_client
# Pays at most $0.001 per call.
client = x402ClientSync().set_spend_controls({"max_amount_per_payment": "$0.001"})
register_exact_evm_client(client, EthAccountSigner(Account.from_key(os.environ["EVM_PRIVATE_KEY"])))
with x402_requests(client) as session:
res = session.post(
"https://tanod.dev/v1/fx/stablecoin-peg",
json={},
)
print(res.status_code, res.text)Security scan
- No findings. We scan names, descriptions and tool definitions for hidden instructions and other prompt-injection patterns.
Recent checks
| When | Result | HTTP | Time | Price |
|---|---|---|---|---|
| 1 h ago | Passed | 402 | 1.0 s | $0.001 |
| 6 h ago | Passed | 402 | 406 ms | $0.001 |
| 10 h ago | Passed | 402 | 450 ms | $0.001 |
| 13 h ago | Expected HTTP 402, got 502 | 502 | 1.8 s | - |
| 22 h ago | Passed | 402 | 764 ms | $0.001 |