Token Revoke MCP

Token Revoke MCP

Securely manage and revoke ERC-20 token allowances across multiple EVM chains

2
Stars
6
Forks
2
Watchers
4
Issues
Token Revoke MCP is a Model Context Protocol (MCP) server designed to enhance security by allowing users to check and revoke ERC-20 token allowances on over 50 EVM-compatible chains. It provides endpoints to fetch token approval data for wallets, submit revocation transactions, and check transaction statuses. The service leverages the Moralis API for blockchain data and supports natural language interactions for ease of use. It is intended to give users granular control over their token approvals and exposure.

Key Features

Fetch all ERC20 token approvals for a wallet on multiple chains
Display token balances, symbols, and USD values at risk
Submit transactions to revoke token allowances for specific spenders
Check status of revocation transactions (pending, success, failure)
Multi-chain support for over 50 EVM-compatible networks
Natural language prompt interpretation for user-friendly operation
Integration with Moralis API for real-time blockchain data
Configurable via environment variables (API keys, private key)
Detailed chain support including mainnets and testnets
MIT licensed for open usage

Use Cases

Auditing all ERC20 token approvals for a given wallet
Revoking unnecessary or risky token allowances programmatically
Monitoring transaction status of token revocation operations
Securing wallets by minimizing ERC20 approval exposure
Providing security tools to DeFi users and platforms
Automating response to potential ERC20 approval exploits
Managing multi-chain token approvals in a unified interface
Integrating revocation checks into wallet UIs or bots
Offering compliance and reporting tools for enterprise wallets
Enabling developers to build enhanced security workflows for crypto wallets

README

Token Revoke MCP

An MCP server for checking and revoking ERC-20 token allowances, enhancing security and control.

License Node.js Status

Features

  • Fetch Token Approvals: Retrieve all ERC20 token approvals for a wallet on a specified chain, including token details, balances, and USD values at risk.
  • Revoke Allowances: Submit transactions to revoke ERC20 token allowances for specific spenders.
  • Check Transaction Status: Verify the success or failure of submitted transactions using transaction hashes.
  • Multi-Chain Support: Supports over 50 EVM-compatible chains, including mainnets (e.g., Ethereum, Polygon, BSC) and testnets (e.g., Goerli, Mumbai).

Prerequisites

  • Node.js: Version 18 or higher (for native fetch support).
  • Moralis API Key: Required for fetching token approval data.
  • Private Key: An Ethereum-compatible private key for signing revocation transactions.

Installation

  1. Clone the Repository:

    bash
    git clone https://github.com/kukapay/token-revoke-mcp.git
    cd token-revoke-mcp
    
  2. Install Dependencies:

    bash
    npm install
    
  3. Client Configuration:

    json
    {
      "mcpServers": {
        "token-revoke-mcp": {
          "command": "node",
          "args": ["path/to/token-revoke-mcp/index.js"],
          "env": {
            "MORALIS_API_KEY": "your moralis api key",
            "PRIVATE_KEY": "your wallet private key"
          }
        }
      }
    }   
    

Usage

Below are examples of how you might interact with the server using natural language prompts as input. The outputs are the raw text values from the content array returned by the server, assuming a client translates the prompts into tool calls.

Example 1: Fetch Token Approvals

Input Prompt:

"Show me all the token approvals for my wallet on Polygon."

Output Response:

[
  {
    "tokenAddress": "0x2791bca1f2de4661ed88a30c99a7a9449aa84174",
    "tokenSymbol": "USDC",
    "balance": "100.5",
    "usdPrice": "1.00",
    "usdValueAtRisk": "50.25",
    "spenderAddress": "0x1111111254eeb25477b68fb85ed929f73a960582",
    "approvedAmount": "1000.0",
    "transactionHash": "0xabc...",
    "timestamp": "2023-10-01T12:00:00Z"
  }
]

Example 2: Revoke an Allowance

Input Prompt:

"Revoke the allowance for token 0x2791bca1f2de4661ed88a30c99a7a9449aa84174 to spender 0x1111111254eeb25477b68fb85ed929f73a960582 on BSC."

Output Response:

Allowance revocation submitted on bsc. Transaction hash: 0x123.... Note: Transaction is not yet confirmed.

Example 3: Check Transaction Status

Input Prompt:

"Did my transaction 0x123... on BSC go through?"

Output Response (possible outputs):

  • Pending:
    Transaction 0x123... on bsc is still pending or not found.
    
  • Success:
    Transaction 0x123... on bsc has completed with status: successful. Block number: 12345.
    
  • Failure:
    Transaction 0x123... on bsc has completed with status: failed. Block number: 12345.
    

Supported Chains

The server supports a wide range of EVM-compatible chains based on the Moralis JS SDK’s chaindata.ts. Examples include:

  • Mainnets: ethereum, polygon, bsc, avalanche, fantom, arbitrum, optimism, etc.
  • Testnets: goerli, mumbai, bsc testnet, arbitrum goerli, optimism sepolia, etc.
  • Full list: See SUPPORTED_CHAINS in server.js.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Star History

Star History Chart

Repository Owner

kukapay
kukapay

User

Repository Details

Language JavaScript
Default Branch main
Size 19 KB
Contributors 1
License MIT License
MCP Verified Nov 12, 2025

Programming Languages

JavaScript
100%

Tags

Join Our Newsletter

Stay updated with the latest AI tools, news, and offers by subscribing to our weekly newsletter.

We respect your privacy. Unsubscribe at any time.

Related MCPs

Discover similar Model Context Protocol servers

  • EVM MCP Server

    EVM MCP Server

    Unified Model Context Protocol server for multi-chain EVM blockchain access

    EVM MCP Server provides a comprehensive Model Context Protocol-compliant interface for blockchain services across 30+ EVM-compatible networks. It enables AI agents and other clients to interact programmatically with Ethereum, Optimism, Arbitrum, Base, Polygon, and more via standardized tools and resources. Features include blockchain data access, smart contract interactions, token transfers (including NFTs), ENS name resolution, and multi-network support. The server ensures a consistent and context-aware interface for AI and software agents to discover and leverage on-chain functionality.

    • 340
    • MCP
    • mcpdotdirect/evm-mcp-server
  • Blockchain MCP powered by Tatum

    Blockchain MCP powered by Tatum

    MCP server for universal blockchain data access across 130+ networks.

    Blockchain MCP powered by Tatum is a Model Context Protocol (MCP) server that enables large language models (LLMs) to read and write blockchain data across more than 130 networks. It provides unified access to both the Tatum Blockchain Data API and direct RPC gateways, supporting tools for retrieving balances, portfolios, transactions, and more. The platform is designed for seamless integration via API key and configurable MCP client setups, making it easier to build blockchain-aware AI solutions. Comprehensive documentation and extensive network compatibility facilitate robust development and scalability.

    • 12
    • MCP
    • tatumio/blockchain-mcp
  • Wallet Inspector MCP

    Wallet Inspector MCP

    Empowering AI agents to inspect wallet balances and onchain activity across multiple blockchains.

    Wallet Inspector MCP is an MCP server that enables AI agents to query wallet balances and view onchain activity on major EVM chains as well as the Solana blockchain. It supports flexible output formats, multi-chain querying, and is designed for integration with MCP-compatible clients such as Claude Desktop CLI. The tool facilitates secure, natural language interactions to check balances, activities, and transaction histories for any supported wallet address.

    • 7
    • MCP
    • kukapay/wallet-inspector-mcp
  • Uniswap Trader MCP

    Uniswap Trader MCP

    Automate token swaps on Uniswap across multiple blockchains for AI agents.

    Uniswap Trader MCP provides an MCP server interface enabling AI agents to automate token swaps on Uniswap V3 across several EVM-compatible blockchains. It offers real-time price quoting, optimized trade route suggestions, and direct execution of swaps with configurable slippage and deadlines. Multi-chain support allows seamless integration with networks such as Ethereum, Polygon, Arbitrum, and others for robust DeFi trading automation.

    • 34
    • MCP
    • kukapay/uniswap-trader-mcp
  • MCP XRPL Server

    MCP XRPL Server

    Unified Model Context Protocol server for seamless AI-driven interaction with the XRP Ledger.

    MCP XRPL Server provides a comprehensive Model Context Protocol implementation for the XRP Ledger, enabling AI agents to access blockchain services seamlessly across MainNet, TestNet, and DevNet. It offers an extensive suite of features including account management, token transfers, NFT operations, DIDs, AMM operations, and oracle interactions, all via a standardized MCP interface. The server supports context-driven interactions, making XRPL functionality readily accessible for AI-powered agents.

    • 5
    • MCP
    • RomThpt/mcp-xrpl
  • Keycloak MCP Server

    Keycloak MCP Server

    MCP server for streamlined Keycloak administration and user management

    Keycloak MCP Server provides a Model Context Protocol (MCP) interface for managing Keycloak users and realms. It enables easy creation, deletion, and listing of users and realms through standardized tools. Designed for integration with platforms like Claude Desktop and tools like Smithery, it automates repeated Keycloak admin tasks and supports both NPM and local development setups.

    • 33
    • MCP
    • ChristophEnglisch/keycloak-model-context-protocol
  • Didn't find tool you were looking for?

    Be as detailed as possible for better results