Cleave for Agents: token swaps, cross-chain swaps and gas top-ups
Swap, bridge and get gas on 6 EVM chains. Each plan states its outcome before you sign. No API key.
제작자가 쓴 설명(영어 원문)
Agent-native lending on Solana via x402: borrow against tokens, arm in-vault TP/SL, repay.
이 세 가지는 절대 하나의 점수로 합치지 않아요. 의견, 측정, 인기는 서로 다른 것이니까요.
이 서버는 아직 쉬운 말로 된 요약을 쓰지 못했어요. 아래는 레지스트리에서 읽어 온 사실이에요.
쓰고 있는 AI 앱을 고른 다음 설정을 복사하세요.
필요한 것
어떤 앱을 쓰세요?
위에서 앱을 고르세요. 기억해 두었다가 다음부터는 버튼에 “…에 설치”라고 표시해요.
Claude Desktop → Settings → Developer → Edit Config를 열고 claude_desktop_config.json에 이 내용을 붙여 넣으세요
{
"mcpServers": {
"magpie": {
"command": "npx",
"args": [
"-y",
"@magpieloans/magpie-mcp"
]
}
}
}터미널에서 이 명령어를 실행하세요
claude mcp add magpie -- npx -y @magpieloans/magpie-mcp프로젝트의 .cursor/mcp.json 또는 ~/.cursor/mcp.json에 붙여 넣으세요
{
"mcpServers": {
"magpie": {
"command": "npx",
"args": [
"-y",
"@magpieloans/magpie-mcp"
]
}
}
}브라우저가 앱을 열지 물어본 다음, 앱이 설정을 보여 주고 확인을 요청해요. 키 값은 비워 두니 직접 입력하세요.
프로젝트의 .vscode/mcp.json에 붙여 넣으세요
{
"servers": {
"magpie": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@magpieloans/magpie-mcp"
]
}
}
}브라우저가 앱을 열지 물어본 다음, 앱이 설정을 보여 주고 확인을 요청해요. 키 값은 비워 두니 직접 입력하세요.
이 서버는 내 컴퓨터에서 실행되는데, ChatGPT는 인터넷에 있는 서버에만 연결할 수 있어요. 다른 앱을 고르세요.
선택한 앱은 이 기기의 쿠키에만 저장돼요. 계정은 필요 없어요.
이 설정은 제작자의 레지스트리 정보로 만들었어요. README와 다르면 README를 따르세요.
내 컴퓨터에서 실행돼요. 설치하면 AI 앱에 도구 목록이 나타나요.
누구나 볼 수 있는 정보를 점검했고, 코드는 읽지 않았어요. 해당하지 않는 항목은 개수에서 뺐어요. · 2026년 11월 9일 점검
레지스트리 이름이 GitHub 계정 magpiecapital 기준으로 확인되었고, 이 계정이 저장소를 소유하고 있어요
아직 GitHub에서 이 저장소를 읽어 오지 않았어요
아직 GitHub에서 이 저장소를 읽어 오지 않았어요
내 컴퓨터에서 실행되는 서버라 인터넷 엔드포인트가 없어요
내 컴퓨터에서 실행되며, 대신 로컬 설정을 사용해요
내 컴퓨터에서 실행돼요. 도구 목록은 인터넷 엔드포인트가 있는 서버에서만 읽을 수 있어요
레지스트리에서 이 카테고리의 활성 서버 전체와 비교했어요. 스타는 게시자가 저장소를 소유한 경우에만 세요.
해당하는 기본 점검 1개 중 1개를 통과했어요. 코드는 읽지 않았어요. 키나 토큰을 넣기 전에 서버가 어떤 권한을 요구하는지 확인하고, 꼭 필요한 권한만 있는 키를 쓰세요.
레지스트리에 필수 키가 나와 있지 않아요. 다만 처음 쓸 때 로그인을 요구하는 서버도 있어요.
내 컴퓨터에서 실행돼요. AI 앱이 필요할 때 실행하고, 데이터는 제작자의 서버를 거치지 않아요(서버 자체가 온라인 서비스를 호출하는 경우는 제외).
GitHub 저장소는 마지막으로 – 변경됐고, 최신 버전(0.1.1)은 5개월 전 레지스트리에 올라왔어요.
Claude Desktop, Claude Code, Cursor, VS Code처럼 MCP를 지원하는 앱에서 쓸 수 있어요. 내 컴퓨터에 Node.js도 있어야 해요.
같은 카테고리에는: Cleave for Agents: token swaps, cross-chain swaps and gas top-ups, Agoreum, Web3 Systemic Agent
같은 카테고리에서 다른 제작자가 만든 서버예요. 스타 순으로 정렬했어요.
카드 보는 법:↓ 주간 다운로드i★ GitHub 스타i세 기둥: 리뷰 · 점검 · 사용 정도i업데이트 = 최신 버전을 레지스트리에 공개한 날i
Swap, bridge and get gas on 6 EVM chains. Each plan states its outcome before you sign. No API key.
Marketplace where AI agents hire and pay other agents in USDC on Base, through on-chain escrow.
Web3 security, DEX honeypot detector, and DAO governance auditor for Base & EVM chains.
제작자의 저장소에서 쓰인 그대로 가져왔어요. PopNx MCP가 검토하거나 보증한 내용이 아니에요. HTML, 이미지, 스크립트는 제거했어요. 링크를 누르면 이 사이트를 벗어나요.
Borrow SOL against your memecoins, tokenized stocks, and RWAs — and set take-profits and stops on that same collateral. Liquidity now, upside intact: collateral that can still sell itself.
MCP server exposing the Magpie Capital x402 API as native tools for Claude Desktop, Cursor, Windsurf, ChatGPT desktop, and any other MCP-aware agent host.
Take-profit, stop-loss, ladders, trailing stops — they fire on-chain into your loan's vault, the loan stays open, and proceeds reach your wallet only when you repay. Auto-sell exits are V4 in-vault orders on supported collateral (memecoins + tokenized stocks/RWAs); they are auto-sell orders that fire on-chain through a slippage stack, not guaranteed fills.
Drop one config block into your host and your agent can query Magpie's protocol state, simulate borrows, fetch credit scores, build deposit/withdraw transactions, post conditional borrow intents, and arm self-owned in-vault take-profit / stop-loss exits on its own loans — all as first-class tool calls. No bespoke client code, no API keys.
A share of Magpie protocol fees accrues to a $MAGPIE holder-rewards pool, paid pro-rata in SOL (no staking, no lockup). 70% is the governance-ratified (MGP-001) target allocation; distributions run on a governance cadence. x402 call fees feed the same holder-rewards economics — agent adoption grows the fees that reward holders.
26 tools wrapping the x402 endpoints:
Free reads (work out of the box):
magpie_pool_state — live LendingPool accountmagpie_protocol_pulse — 24h aggregates (active loans, volume, liquidations)magpie_recent_activity — anonymized borrow/repay/liquidate streammagpie_loan — single loan by IDmagpie_wallet_loans — all loans for a walletmagpie_tiers — protocol tier constantsmagpie_simulate_borrow — quote a loan without submittingmagpie_collateral_eligible — full collateral catalogmagpie_liquidatable — loans currently liquidatablemagpie_credit_leaderboard — top wallets by credit scoremagpie_lp_state — depositor position + pool contextmagpie_loan_by_pda — single loan by on-chain loan PDAmagpie_pools — Magpie lending pools (program-version lanes + context)magpie_list_exits — armed in-vault exit orders for a walletmagpie_modify_exit — change an armed exit's trigger / paramsmagpie_cancel_exit — cancel an armed exit (loan stays Active)Paid (require a configured Solana keypair):
magpie_credit_score — 0.001 SOLmagpie_token_risk — 0.001 SOL (per-token risk profile)magpie_build_borrow — 0.005 SOL (pass has_exit_arming: true to route into the V4 in-vault-exit lane)magpie_build_repay — 0.002 SOLmagpie_build_deposit — 0.002 SOLmagpie_build_withdraw — 0.002 SOLmagpie_build_liquidate — 0.003 SOL (liquidate a past-due loan, receive keeper bounty)magpie_create_intent — 0.01 SOL (conditional borrow)magpie_get_intent — 0.0005 SOL (poll)magpie_arm_exit — 0.001 SOL (arm a self-owned in-vault TP / SL / trailing exit)When a paid tool fires, the server signs an x402 payment tx locally with your configured keypair and forwards the signature to magpie-x402. The keypair never leaves your machine.
Magpie's V4 lane lets an agent arm its own take-profit, stop-loss, and trailing exits on its own active loan — and the sell happens in-vault: when a trigger fires, the collateral is auto-sold and the proceeds (SOL by default, or USDC) accumulate inside that loan's per-loan proceeds vault while the loan stays Active. Proceeds only ever reach your wallet through your own borrower-signed repay. There's no fire-and-close, and nothing the protocol can do to move your funds out.
magpie_arm_exit (0.001 SOL) — arm a TP / SL / trailing exit on a V4 loan you own. Set direction (above = take-profit, the default; below = stop-loss) and exactly one trigger: target (e.g. "2x" / "0.7x"), price_usd, mc_usd (e.g. "5M", "1.2B"), or trailing_bps (stop-loss only). Optional slippage_bps, dest (sol | usdc), and slice for laddered exits.magpie_modify_exit (free) — retune an armed order's trigger or params in place.magpie_cancel_exit (free) — remove an armed order; the loan is untouched.magpie_list_exits (free) — audit a wallet's armed orders, each with its distance-to-trigger.Every exit call is authenticated with a dependency-free Ed25519 signed envelope built locally from your configured keypair. For magpie_arm_exit the envelope is signed by the same keypair that pays the 0.001 SOL x402 challenge, so the bot's payer == signer invariant holds and only the owner of a loan can arm exits on it. The bot enforces a 5-minute freshness window and nonce-uniqueness on every envelope.
To start a borrow that supports these exits, call magpie_build_borrow with has_exit_arming: true (routes into V4); leave it false for a plain memecoin (V1) borrow.
RWA / xStock collateral runs on the separate V3 lane, which is launch-gated — on the V3 launch, the same exit tooling will extend to RWA loans.
Two paths. Both end at the same place.
No clone, no build, no absolute paths in your host config:
# Verify it runs once before wiring into your host:
npx -y @magpieloans/magpie-mcp --help
Then in your host config:
{
"mcpServers": { "magpie": { "command": "npx", "args": ["-y", "@magpieloans/magpie-mcp"], "env": { "SOLANA_RPC_URL": "https://api.mainnet-beta.solana.com", "MAGPIE_MCP_PAYER_KEYPAIR": "/path/to/payer-id.json" } } } }
If the npm package isn't published yet, or you want to hack on the server:
git clone git@github.com:magpiecapital/magpie-x402.git
cd magpie-x402/mcp npm install npm run build
Built executable lands at mcp/dist/index.js. Use the absolute path in your host config below.
Pick the snippet for your host. The command + args shape changes between npm-install vs source-build; the env block is identical.
Edit ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows):
{
"mcpServers": { "magpie": { "command": "node", "args": ["/ABS/PATH/TO/magpie-x402/mcp/dist/index.js"], "env": { "SOLANA_RPC_URL": "https://api.mainnet-beta.solana.com", "MAGPIE_MCP_PAYER_KEYPAIR": "/ABS/PATH/TO/payer-id.json" } } } }
Restart Claude Desktop. The Magpie tools appear in the tool picker.
Edit ~/.cursor/mcp.json. Same shape as Claude Desktop above.
Edit ~/.codeium/windsurf/mcp_config.json. Same shape.
Use the same shape — point the host at node /ABS/PATH/.../mcp/dist/index.js, pass env vars through the host's MCP config interface.
Omit MAGPIE_MCP_PAYER_KEYPAIR and the read-only free tools still work. Paid tools — and the envelope-signed exit tools (magpie_arm_exit, magpie_modify_exit, magpie_cancel_exit, which need the keypair to sign the envelope even though modify/cancel cost nothing) — return a clear error explaining that no payer is configured. Useful for read-only research agents or as a no-friction first install.
| Variable | Default | Purpose |
|---|---|---|
MAGPIE_X402_BASE_URL | https://x402.magpie.capital | Override for self-hosted or testnet deployments |
SOLANA_RPC_URL | https://api.mainnet-beta.solana.com | RPC used to send x402 payment txs. Public RPC rate-limits aggressively — use Helius/Triton/QuickNode for any real volume. |
MAGPIE_MCP_PAYER_KEYPAIR | _(unset)_ | Path to a Solana keypair JSON in the standard solana-keygen format. Enables paid tools. |
The keypair you configure is the only place SOL can leave. Per-call costs are exact (the server doesn't ever pay more than the 402 challenge demands), but if you're paranoid about runaway tool-calls during agent experimentation, fund the payer wallet with a small float — say 0.05 SOL — and let it run dry rather than top it up unattended.
X-Payment header).build-borrow, build-deposit, etc.) the server returns an *unsigned* tx. Your agent receives it as plain text; you decide whether to sign + submit it. The MCP server itself never signs anything besides x402 payment transfers.Tool doesn't appear in host UI — restart the host after editing config. Most hosts only re-read the MCP config on launch.
402 error on a paid tool — MAGPIE_MCP_PAYER_KEYPAIR is unset or the file doesn't exist. Run solana-keygen new -o ~/.config/solana/magpie-mcp.json and point the env var at the result, then solana transfer … a small SOL float in.
`fetch failed` on x402.magpie.capital — check the URL is reachable from your machine. If you're behind a corporate proxy, set HTTPS_PROXY in the same env block.
RPC rate-limit during a paid call — switch SOLANA_RPC_URL to a paid Helius/Triton/QuickNode URL. The default api.mainnet-beta.solana.com will throttle under any sustained use.
The package is set up for npm publish with no additional configuration. From mcp/:
# One-time per machine:
npm login --scope=@magpieloans
npm publish
The package is scoped (@magpieloans/magpie-mcp) and publishConfig.access: "public" is set, so publish doesn't require any extra flags. The files field whitelists what ships — only dist/, README.md, LICENSE end up in the tarball (~9 KB).
Verify the contents before publish:
npm pack --dry-run
MIT.