uniderp-mcp
Version:
> A plug-and-play MCP tool server to **send ETH**, **transfer ERC-20 tokens**, **deploy tokens**, and **interact with smart contracts** on the **UNICHAIN** — built for **Claude Desktop**, **AI agents**, and **developers.**
21 lines (20 loc) • 877 B
JavaScript
import { privateKeyToAccount } from "viem/accounts";
import { uniswapTrade } from "../functions/uniswapTradeTool.js";
import { checkTransactionHash } from "../util.js";
const test = async () => {
const account = privateKeyToAccount("0x783b373c7dc246dbf6253764e333213e138fad07ec09f74feb77c0e693332a1a" // 0x20518e4cc0E1E866Ef31ab0232b166fA367305C9
);
const inputToken = "ETH";
const outputToken = "0x8339CA9530d13b5c55B7F1b6E5A073618b20b0f0"; // CAT (Uniderp MeME) - Unichain Sepolia
// const outputToken = "0x1c7d4b196cb0c7b01d743fbc6116a902379c7238"; // USDC - sepolia
const amount = "0.0000001";
const txHash = await uniswapTrade({
account,
inputToken,
outputToken,
amount,
});
const txUrl = await checkTransactionHash(txHash);
console.log(`Uniswap transaction sent successfully. ${txUrl}`);
};
test();