io.github.Abstract36/stakechain
Live Base staking/lending yields (APY, TVL, vaults) as MCP tools; x402 pay-per-request tier
التثبيت
أضف هذا إلى إعدادات MCP في عميلك (Claude Desktop: claude_desktop_config.json، وCursor: .cursor/mcp.json، ويستخدم VS Code وغيره الصيغة نفسها «mcpServers»).
claude mcp add --transport http stakechain 'https://stakechain-api.vercel.app/mcp'
{
"mcpServers": {
"stakechain": {
"type": "http",
"url": "https://stakechain-api.vercel.app/mcp"
}
}
}
stakechain-mcpclaude mcp add stakechain -e 'STAKECHAIN_API=https://stakechain-api.vercel.app' -- npx -y stakechain-mcp@0.3.0
{
"mcpServers": {
"stakechain": {
"command": "npx",
"args": [
"-y",
"stakechain-mcp@0.3.0"
],
"env": {
"STAKECHAIN_API": "https://stakechain-api.vercel.app"
}
}
}
}
متغيرات البيئة
STAKECHAIN_APIYields API base URL
التوثيق
مأخوذ من ملف README للمشروع على GitHub ويُحدَّث أسبوعيًا. تفتح الروابط على GitHub.
المحتويات
StakeChain Labs
Live: landing · dashboard · API · contract
STACH is tradeable: Uniswap v4 pool STACH/ETH live on Base (initial price 4,000,000 STACH/ETH) — routable through aggregators (LI.FI verified).
An open staking-yield experiment on Base. Live aggregator of staking and lending rates across Base protocols — readable by humans on a dashboard, consumable by AI agents over MCP, payable by machines over x402.
No seed round. No token presale. Just a running, open-source experiment. Concept and plan: docs/PIVOT-2026.md.
The product
| Piece | What it does |
|---|---|
| api/ | Base yields aggregator (DefiLlama source, 5-min cache, junk-farm filters) with x402 machine-payment endpoints |
| agents/ | MCP server exposing yields as AI-agent tools + resident-analyst pattern (Claude Agent SDK) |
| dashboard/ | React dashboard: Base Yields table, STACH staking, pools |
| contracts/ | STACH token + flexible/locked staking — audited & hardened (audit), 25 tests |
| website/ | Landing page (static, GitHub-Pages-ready) |
Legacy 2021–2023 material (Laravel site, old static site, branding, original docs) is kept under website-laravel/, website-static/, branding/, docs/.
Monetization: machines pay, on-chain, automatically — LIVE
Human endpoints (/yields, /vaults) are free. Machine endpoints
(/v1/*) speak the x402 protocol with enforcement
on: HTTP 402 + payment requirements → the client signs an EIP-3009
USDC authorization ($0.001/request) → our self-hosted settler verifies the
signature and submits it on-chain (no facilitator, no accounts, no API
keys). Revenue lands at the admin wallet; api/pay-test.js is a reference
paying client.
Real yield: collected USDC is distributed to STACH stakers through
RevenueDistributor
(verified; merkle epochs reproducible from public state via
contracts/scripts/revenue-snapshot.js, 180-day sweep-back).
Quickstart
# 1. Yields API
cd api && npm install && npm start # :4000
# 2. Dashboard
cd dashboard && npm install --legacy-peer-deps
npm start # :3000, reads the API
# 3. Give the data to your AI agent
cd agents/mcp-server && npm install
claude mcp add stakechain -- node agents/mcp-server/server.js
# 4. Contracts (test + cheap deploy)
cd contracts && npm install
npx hardhat test # 25 tests
npm run deploy:baseSepolia # free testnet
STACH token
Deployed at the same address on both networks (verified via Sourcify, exact match):
- Base mainnet:
0x82c5f9901CD9AEE3177053482b79aEA235507166 - Base Sepolia:
0x82c5f9901CD9AEE3177053482b79aEA235507166
Initial holder / admin: 0x2Ab5A19aabc599C1a24CC0541ECB757b56976661. The
dashboard targets mainnet by default; set REACT_APP_CHAIN=baseSepolia for
the testnet.
Fixed supply 42M. 3M held by the contract as the staking reward reserve
(1M flexible / 2M locked over 360 days), 39M to the admin wallet. The 2022
contract had two critical bugs (recipient-burning transferFrom, unbacked
reward minting) — fixed and regression-tested in 2026:
docs/AUDIT-2026-10.md.
Future revenue-share to STACH stakers is deliberately not built yet — revenue first, distribution second.
Honest part
This is an experiment, not "the future of finance". Everything here is MIT-licensed, the audit is public, the data endpoints filter out obvious degen traps (min TVL, APY ceiling, no-IL default). Nothing in this repository is financial advice.
الأسئلة الشائعة
ما هو io.github.Abstract36/stakechain؟
Live Base staking/lending yields (APY, TVL, vaults) as MCP tools; x402 pay-per-request tier
كيف أثبّت io.github.Abstract36/stakechain؟
يعمل كخادم بعيد. في Claude Code: claude mcp add --transport http stakechain 'https://stakechain-api.vercel.app/mcp'. وفي العملاء الآخرين، الصق إعداد JSON من هذه الصفحة في إعدادات MCP الخاصة بهم.
هل يحتاج io.github.Abstract36/stakechain إلى مفتاح API؟
لا يذكر إدراجه في السجل أي مفتاح أو سر إلزامي. قد تتطلب بعض الميزات حسابًا لدى الخدمة التي يتصل بها.
هل io.github.Abstract36/stakechain مفتوح المصدر؟
شيفرته علنية على GitHub، لكن المستودع لا يعلن ترخيصًا قياسيًا.
من يصون io.github.Abstract36/stakechain؟
ينشره Abstract36. يدرجه AI.tn لكنه لا يصونه ولا يوصي به.
من سجل MCP الرسمي. الإدراج ليس توصية: راجع شيفرة الخادم وصلاحياته قبل منحه الوصول إلى بياناتك.