MCP Marketplace
BrowseHow It WorksFor CreatorsDocs
Sign inSign up
MCP Marketplace

The curated, security-first marketplace for AI tools.

Product

Browse ToolsSubmit a ToolDocumentationHow It WorksBlogFAQ

Legal

Terms of ServicePrivacy PolicyCommunity Guidelines

Connect

support@mcp-marketplace.ioTwitter / XDiscord

MCP Marketplace © 2026. All rights reserved.

Back to Browse

Tctc MCP Server

by Kofujimura
Developer ToolsModerate5.2MCP RegistryLocal
Free

Server data from the Official MCP Registry

ERC-7303 token-controlled roles for AI agents: grant, check, and revoke permissions on-chain

About

ERC-7303 token-controlled roles for AI agents: grant, check, and revoke permissions on-chain

Security Report

5.2
Moderate5.2Moderate Risk

A well-architected MCP server for ERC-7303 token-controlled access delegation. The codebase demonstrates strong security practices: environment variable protection for private keys, comprehensive config validation with private-key rejection, proper error handling, and no dangerous patterns detected. Minor code quality observations exist but do not materially affect security. Supply chain analysis found 4 known vulnerabilities in dependencies (1 critical, 3 high severity). Package verification found 1 issue.

7 files analyzed · 9 issues found

Security scores are indicators to help you make informed decisions, not guarantees. Always review permissions before connecting any MCP server.

Permissions Required

This plugin requests these system permissions. Most are normal for its category.

env_vars

Check that this permission is expected for this type of plugin.

HTTP Network Access

Connects to external APIs or services over the internet.

File System Read

Reads files on your machine. Normal for tools that analyze or process local data.

What You'll Need

Set these up before or after installing:

Issuer key enabling grant_role/revoke_role (admin mode). Omit for read-only mode: state-changing tools are then not even registeredRequired

Environment variable: TCTC_ADMIN_PRIVATE_KEY

How to Install

Add this to your MCP configuration file:

{
  "mcpServers": {
    "io-github-kofujimura-tctc-mcp": {
      "env": {
        "TCTC_ADMIN_PRIVATE_KEY": "your-tctc-admin-private-key-here"
      },
      "args": [
        "-y",
        "tctc-mcp"
      ],
      "command": "npx"
    }
  }
}

Documentation

View on GitHub

From the project's GitHub README.

tctc-mcp

npm version

An MCP server exposing ERC-7303 (Token-Controlled Token Circulation) roles to AI agents: agents check their own on-chain permissions, and human principals grant/revoke them by minting/burning control tokens — no permission server required.

Status: v0.3 — adds timed roles with gasless auto-expiry (below), on top of v0.2's IERC7303 auto-discovery; published on npm (tctc-mcp), unit-tested and verified end-to-end against the Sepolia demo deployment (grant → check → revoke → check, and grant-for-75s → auto-expiry, through a real MCP client).

Demo (60 seconds)

Watch the 60-second demo video

A human grants an AI agent a minting permission; the agent verifies it on-chain and mints an NFT. The human burns the role token — and the agent instantly loses the capability. Live on Sepolia, no permission server involved.

Quick start

The package is published on npm, so no clone or build is needed — npx fetches and runs it directly:

# 1. Get a config. The secret-free Sepolia demo config needs no API keys:
curl -fsSLO https://raw.githubusercontent.com/kofujimura/tctc-mcp/main/examples/config.sepolia.agent.json

# 2. Register with your MCP client, e.g. Claude Code
#    (read-only mode: only query tools are registered)
claude mcp add tctc -- npx -y tctc-mcp --config "$PWD/config.sepolia.agent.json"

# Admin mode (principal side): grant_role / revoke_role also registered.
# Provide the issuer key ONLY via the environment:
claude mcp add tctc-admin --env TCTC_ADMIN_PRIVATE_KEY=0x... \
  -- npx -y tctc-mcp --config "$PWD/config.sepolia.json"

Or in a project-scoped .mcp.json:

{ "mcpServers": { "tctc": { "command": "npx",
    "args": ["-y", "tctc-mcp", "--config", "examples/config.sepolia.agent.json"] } } }

A fuller registration example is in examples/claude.mcp.json. The admin private key is only ever read from the TCTC_ADMIN_PRIVATE_KEY environment variable; configs containing anything that looks like a private key are rejected at startup.

Tools

ToolModePurpose
list_rolesbothConfigured roles and their control tokens
check_rolebothDoes an account hold a role? (live balanceOf, with evidence)
check_all_rolesbothSession-start self-assessment across all roles
discover_rolesbothIntrospect any contract via IERC7303 — no role config needed
resolve_agentboth*ERC-8004 agentId → owner / agentURI / agentWallet / ERC-6551 TBA
grant_roleadminMint the control token to a subject
revoke_roleadminBurn the subject's control token — the kill switch

* registered only when the config has an identity section.

Subjects can be given as a raw address, as an ERC-8004 agentId (resolved to its ERC-6551 Token Bound Account, the recommended binding target), or omitted to use the config's self.

IERC7303 auto-discovery (v0.2)

ERC-7303 now defines an introspection interface (ethereum/ERCs#1872, merged 2026-07-11): compliant contracts expose hasRole, control-token getters, configuration events, and ERC-165 detection (interfaceId 0x4ee69337). tctc-mcp uses it two ways:

  • target roles — a role config names only the target contract; the server reads which control tokens gate the role from the contract itself, and the verdict is the target's own hasRole() answer:

    "roles": { "MINTER_ROLE": {
        "target": { "address": "0x4C0a78803D47154B9C6F42EC4AEbab2D1C94c97D" } } }
    
  • discover_roles — introspect any address at run time, with no role configuration at all. Non-compliant contracts report supportsIERC7303: false; static controlTokens configs remain the fallback for pre-IERC7303 deployments.

Working example: examples/config.sepolia.discovery.json (secret-free, public RPC), verified live by scripts/e2e-discovery.mjs.

Timed roles: gasless auto-expiry (v0.3)

Delegation to an agent is usually short-term — "mint for one hour", "act for the duration of this task". With an expiring control token (ExpiringControlTokens), balanceOf() returns 0 once the holder's expiry passes, so the role revokes by itself, with no transaction — even if the principal forgets, goes offline, or loses keys. The ERC-7303 target contract needs no changes at all (the Sepolia expiry demo target is a byte-for-byte copy of TCTCDemoToken).

  • Granting: a role whose grant template has $expiresAt requires an expiry — grant_role with expiresInSeconds: 3600 is "grant MINTER_ROLE for one hour":

    "admin": { "grant": { "function": "mint(address,uint256,uint64)",
                          "args": ["$subject", "$typeId", "$expiresAt"] } }
    
  • Checking: check_role evidence reports expiresAt (unix seconds) when the control token exposes it, so an agent can self-report "this permission expires in 5 minutes".

  • Kill switch unchanged: expiry is a fail-safe, not a replacement — revoke_role (issuer burn) still revokes immediately within the validity window.

Working example: the TIMED_MINTER_ROLE in examples/config.sepolia.json, verified live by scripts/e2e-expiry.mjs (grant for 75 s → watch it expire with no further transaction).

Documents

  • docs/CONCEPT.md — background and rationale: TCTC as the authorization layer for AI agents, its relationship to ERC-8004 (Trustless Agents) and ERC-6551 (Token Bound Accounts), recommended ERC-7303 spec updates, and the adoption strategy.
  • docs/MCP_SERVER_SPEC.md — v1 design specification (architecture, config, tools, security, roadmap).
  • docs/ERC_DRAFT_EXPIRABLE_1155.md — working draft of a planned ERC, "Expirable ERC-1155 Tokens": the standard behind the timed roles above (per-holder expiry, time-aware balanceOf, expiresAt/ExpiryUpdated, interface ID 0x300e616b). Not yet submitted to ethereum/ERCs; feedback welcome.
  • docs/TEST_REPORT.md — v1 test report: 24 unit tests and the live Sepolia E2E (on-chain kill-switch cycle through a real MCP client).
  • examples/config.sepolia.json — concrete config for the Sepolia demo deployment (primary roles, static bindings) and the TCTC repo's MyComplexToken sample (COMPLEX_* roles, resolved via IERC7303 target discovery).
  • examples/config.sepolia.agent.json — secret-free agent-side config for the same demo deployment (public RPC, no API keys); the one used in the Quick start above.
  • examples/config.sepolia.discovery.json — IERC7303 auto-discovery variant: no control tokens configured, the target contract explains its own role structure.
  • examples/contracts/ — sources of the demo contracts deployed on Sepolia (AgentControlTokens, TCTCDemoToken, ERC7303, IERC7303).

Demo deployment (Sepolia, Etherscan-verified)

  • AgentControlTokens (soulbound, issuer-burnable ERC-1155): 0x12342A7F0190B3AF3F4b47546D34006EDA54eE0B
  • TCTCDemoToken (ERC-721 + ERC-7303 target, implements the IERC7303 introspection interface — hasRole, control-token getters, ERC-165 detectable via interfaceId 0x4ee69337): 0x4C0a78803D47154B9C6F42EC4AEbab2D1C94c97D
  • ExpiringControlTokens (soulbound, issuer-burnable ERC-1155 with per-holder expiry; time-aware balanceOf — the basis of timed roles): 0xb5abB6c060ed287e8B25aD121c8B46eE404fF09b
  • Expiry demo target (unmodified TCTCDemoToken bytecode bound to the expiring control tokens): 0x3eAb11DE9655817A2e2977A486d9D33eBD10c9Ce

Development

git clone https://github.com/kofujimura/tctc-mcp.git && cd tctc-mcp
npm install && npm run build
node dist/index.js --config examples/config.sepolia.agent.json

npm test                  # unit tests (vitest)
node scripts/e2e-live.mjs # live E2E: spawns the server via MCP stdio client
                          # (needs ALCHEMY_API_KEY; admin phase additionally
                          #  TCTC_ADMIN_PRIVATE_KEY and E2E_SUBJECT)

Related

  • npm package: https://www.npmjs.com/package/tctc-mcp
  • Agent skill (teaches agents to use TCTC safely; install with npx skills add kofujimura/tctc-skills): https://github.com/kofujimura/tctc-skills
  • TCTC reference implementation: https://github.com/kofujimura/TCTC

Reviews

No reviews yet

Be the first to review this server!

0

installs

New

no ratings yet

Is this your server?

Claim ownership to manage your listing, respond to reviews, and track installs from your dashboard.

Claim with GitHub

Sign up with the GitHub account that owns this repo

Links

Source Codenpm Package

Details

Published July 11, 2026
Version 0.3.1
0 installs
Local Plugin

More Developer Tools MCP Servers

Git

Free

by Modelcontextprotocol · Developer Tools

Read, search, and manipulate Git repositories programmatically

80.0K
Stars
7
Installs
6.5
Security
No ratings yet
Local

Toleno

Free

by Toleno · Developer Tools

Toleno Network MCP Server — Manage your Toleno mining account with Claude AI using natural language.

137
Stars
543
Installs
8.0
Security
4.8
Local

mcp-creator-python

Free

by mcp-marketplace · Developer Tools

Create, build, and publish Python MCP servers to PyPI — conversationally.

-
Stars
81
Installs
10.0
Security
4.6
Local

MarkItDown

Free

by Microsoft · Content & Media

Convert files (PDF, Word, Excel, images, audio) to Markdown for LLM consumption

156.1K
Stars
50
Installs
6.0
Security
5.0
Local

MCP Marketplace

Free

by mcp-marketplace · Developer Tools

Search and install MCP servers from inside your AI client.

-
Stars
43
Installs
10.0
Security
5.0
Remote

FinAgent

Free

by mcp-marketplace · Finance

Free stock data and market news for any MCP-compatible AI assistant.

-
Stars
26
Installs
10.0
Security
No ratings yet
Local