✨
SaucerSwap Arbitrage
SaucerSwap Arbitrage · v1.0.0
入口已确认,内容待校验
文件树里有 SKILL.md,但正文还没采回,frontmatter 未核对。
1.1k 下载
0 安装
2.5k 收藏
4 浏览
简介
SaucerSwap Arbitrage
原始描述
Perform triangular arbitrage on Hedera using SaucerSwap to find, calculate, and execute profitable multi-hop token swaps atomically.
通过你的 Agent 添加
安装目录:saucerswap-arbitrage/(目录名取自 SKILL.md 的 frontmatter name,不是 URL 里的 slug)。
点「快速安装」复制一段指令贴给你的 Agent:它会先下载到 /tmp、把文件清单和校验值给你看,你确认之后才解压安装。不会一步装完、也不改系统其它位置。
或者手动安装
Claude Code~/.claude/skills/saucerswap-arbitrage/
Codex CLI~/.codex/skills/saucerswap-arbitrage/
DeepSeek Harness~/.agents/skills/saucerswap-arbitrage/
包是「根级 SKILL.md + 作者附带的文件」,解压到上面的 <slug>/ 目录即可;
目录名不用换,也不要把包直接解压到 skills 根目录。
技能申请的权限由作者决定:装之前先看清单里有没有脚本、它会读写什么。
技能正文
name: saucerswap-arbitrage
description: Execute triangular arbitrage on Hedera via SaucerSwap. Use for: (1) Finding arbitrage opportunities on HBAR DEX, (2) Multi-hop token swaps, (3) Calculating profit across pools, (4) Executing atomic swaps.
SaucerSwap Arbitrage
Overview
Overview
SaucerSwap is the main DEX on Hedera. Triangular arbitrage: profit from price differences between 3 tokens.
Key Contracts (Mainnet)
- SaucerSwap V1:
0xcaec9706a4622D356d2D3aEd8f8D40c51f0C0dF
- SaucerSwap V2:
0xA6F4E11E5D8A3F62A7D4E3E6B1E7F3C9E8F2A1B4
Get Quotes (V1)
const axios = require('axios');
async function getQuote(amountIn, path) {
const [tokenA, tokenB, tokenC] = path;
const url = `https://mainnet-api.saucerswap.fi/route?from=${tokenA}&to=${tokenB}&amount=${amountIn}`;
const response = await axios.get(url);
return response.data;
}
Token Addresses (Hedera)
- HBAR:
0.0.1000 (wrapped: 0x... in EVM format)
- USDC:
0.0.456719
- USDT:
0.0.456720
- ETH:
0.0.456721
- WBTC:
0.0.456722
- SAUCE:
0.0.456723
Arbitrage Logic
1. Check Prices
// Get prices for potential paths
const paths = [
['USDC', 'HBAR', 'USDC'],
['USDC', 'SAUCE', 'USDC'],
['HBAR', 'USDC', 'HBAR']
];
for (const path of paths) {
const out = await getQuote(1000, path);
const profit = out - 1000;
console.log(`${path.join(' → ')}: ${profit}`);
}
2. Execute Swap
// Via HashPack or direct contract call
const tx = new ContractExecuteTransaction()
.setContractId(poolAddress)
.setFunction("swap")
.setParameters([...]);
Safety Checks
- Slippage: Set min output = expected * 0.97
- Gas: Estimate network fees (tinybars)
- Pool Depth: Check liquidity before large trades
- Hedera Gossip: Account for network latency
Key Differences from EVM
- No EOA signatures: Must use Hedera native signing
- Network fees: Paid in tinybars (not gas)
- Transaction types: Use HAPI, not EVM
- Token format: Use
0.0.xxxxx not 0x...
0xcaec9706a4622D356d2D3aEd8f8D40c51f0C0dF0xA6F4E11E5D8A3F62A7D4E3E6B1E7F3C9E8F2A1B4const axios = require('axios');
async function getQuote(amountIn, path) {
const [tokenA, tokenB, tokenC] = path;
const url = `https://mainnet-api.saucerswap.fi/route?from=${tokenA}&to=${tokenB}&amount=${amountIn}`;
const response = await axios.get(url);
return response.data;
}
Token Addresses (Hedera)
- HBAR:
0.0.1000 (wrapped: 0x... in EVM format)
- USDC:
0.0.456719
- USDT:
0.0.456720
- ETH:
0.0.456721
- WBTC:
0.0.456722
- SAUCE:
0.0.456723
Arbitrage Logic
1. Check Prices
// Get prices for potential paths
const paths = [
['USDC', 'HBAR', 'USDC'],
['USDC', 'SAUCE', 'USDC'],
['HBAR', 'USDC', 'HBAR']
];
for (const path of paths) {
const out = await getQuote(1000, path);
const profit = out - 1000;
console.log(`${path.join(' → ')}: ${profit}`);
}
2. Execute Swap
0.0.1000 (wrapped: 0x... in EVM format)0.0.4567190.0.4567200.0.4567210.0.4567220.0.4567231. Check Prices
// Get prices for potential paths
const paths = [
['USDC', 'HBAR', 'USDC'],
['USDC', 'SAUCE', 'USDC'],
['HBAR', 'USDC', 'HBAR']
];
for (const path of paths) {
const out = await getQuote(1000, path);
const profit = out - 1000;
console.log(`${path.join(' → ')}: ${profit}`);
}
// Via HashPack or direct contract call
const tx = new ContractExecuteTransaction()
.setContractId(poolAddress)
.setFunction("swap")
.setParameters([...]);
Safety Checks
- Slippage: Set min output = expected * 0.97
- Gas: Estimate network fees (tinybars)
- Pool Depth: Check liquidity before large trades
- Hedera Gossip: Account for network latency
Key Differences from EVM
- No EOA signatures: Must use Hedera native signing
- Network fees: Paid in tinybars (not gas)
- Transaction types: Use HAPI, not EVM
- Token format: Use
0.0.xxxxx not 0x...
- No EOA signatures: Must use Hedera native signing
- Network fees: Paid in tinybars (not gas)
- Transaction types: Use HAPI, not EVM
- Token format: Use
0.0.xxxxxnot0x...
正文来自原始发布页, 版权归作者所有,许可未标注。 权利人认为有不妥,可申请下架。
标签
同类 Skill
✨
self-improving-agent
self-improving-agent
下载 416.7k
✨
self-improving-agent
self-improving-agent
下载 416.7k
✨
self-improving-agent
self-improving-agent
下载 416.7k
✨
self-improving-agent
self-improving-agent
下载 416.7k
✨
Self-Improving + Proactive Agent
Self-Improving + Proactive Agent
下载 177.1k
✨
Gog
Gog
下载 165k