TokenSafe
What it does
Reduce your AI bills by up to 99% locally: focused code, warm prompt caches & zero secret leaks.
- Connects パソコンでもクラウドでも
- Account or key Cloud: Works without a key · add Authorization if you have one (often raises limits) · Local: No key needed
- Category 開発者ツール
インストール
使っているAIアプリを選んで、設定をコピーしてください。
チェック 5/5 合格 · 質問内容は提供元のサーバー(api.tokensafe.dev)を通ります · ✓ コマンド確認済み 2026年11月14日
まず:どの AI を使っていますか?
使っているアプリを選ぶと、下に手順が表示されます。
Claude につなげます · 約 2 分
キー不要、インストール不要 · claude.ai かデスクトップアプリで一度設定すれば、チャットで使えます · 無料アカウントは 1 つまで · Team/Enterprise はオーナー(Owner)が追加
Claude の Connectors ページを開く
CustomizeConnectors
「Add」→「Custom」→「Web」を押し、この 2 つを入力
ここからコピーして Claude の同じ名前の欄に貼り付け、Continue を押します
Name · 名前TokenSafeRemote MCP server URL · アドレスhttps://api.tokensafe.dev/mcpClaude が検出したサインイン設定の画面で Continue を押す · Authentication は作者の説明どおり(Sign in now・Sign in when needed・No sign in)を選び Add を押します
チャットで有効にする
+ConnectorsTokenSafe
試してみる
TokenSafe を使って、私に何ができるか教えて、1 つやってみせて✓ Claude が TokenSafe を使っていると言うか、回答に TokenSafe のツール名が出れば接続成功です
メニュー名は 2026年11月11日 に Anthropic のヘルプページで確認 · アプリのバージョンにより画面が少し違うことがあります
ChatGPT との接続はプランしだい
フル MCP:Web 版 ChatGPT の Business・Enterprise・Edu · Pro:読み取り/取得の権限で接続、データを変えるツールは使えないことがあります · Plus:公式ドキュメントで未確認。プラグイン画面にカスタム MCP を追加する項目があれば試せます · Web のみ
Web 版 ChatGPT で MCP の追加ページを開く
Plugins+Add custom MCP server
名前とアドレスを入力
名前を入れ、Connection にアドレスを貼り付け、注意事項にチェックして Create as a plugin を押します
Name · 名前TokenSafeConnection · アドレスhttps://api.tokensafe.dev/mcpチャットで TokenSafe を選ぶ
新しいチャットを開き、入力前にプラグインの一覧から TokenSafe を選びます
試してみる
TokenSafe を使って、私に何ができるか教えて、1 つやってみせて✓ ChatGPT が TokenSafe を使っていると言うか、回答に TokenSafe のツール名が出れば接続成功です
メニュー名は 2026年11月11日 に OpenAI のヘルプページで確認 · アプリのバージョンにより画面が少し違うことがあります
Claude Code につなげます · 約 2 分
キー不要、インストール不要
ターミナルを開く
Mac:Command+スペースで Terminal と入力 · Windows:PowerShell を開く
このコマンドを貼り付けて Enter
claude mcp add --transport http --scope user tokensafe https://api.tokensafe.dev/mcpClaude Code で /mcp と入力
TokenSafe が一覧にあり、接続済みと表示されれば OK です
試してみる
TokenSafe を使って、私に何ができるか教えて、1 つやってみせて✓ Claude Code が TokenSafe を使っていると言うか、回答に TokenSafe のツール名が出れば接続成功です
メニュー名は 2026年11月11日 に Anthropic のヘルプページで確認 · アプリのバージョンにより画面が少し違うことがあります
Cursor につなげます · 約 2 分
キー不要、インストール不要
Cursor の AI チャットを Agent モードで開く
試してみる
TokenSafe を使って、私に何ができるか教えて、1 つやってみせて✓ Cursor が TokenSafe を使っていると言うか、回答に TokenSafe のツール名が出れば接続成功です
メニュー名は 2026年11月11日 に Cursor のヘルプページで確認 · アプリのバージョンにより画面が少し違うことがあります
VS Code につなげます · 約 2 分
キー不要、インストール不要
VS Code の AI チャットを Agent モードで開く
試してみる
TokenSafe を使って、私に何ができるか教えて、1 つやってみせて✓ VS Code が TokenSafe を使っていると言うか、回答に TokenSafe のツール名が出れば接続成功です
メニュー名は 2026年11月11日 に VS Code のヘルプページで確認 · アプリのバージョンにより画面が少し違うことがあります
Windsurf、Zed、Gemini CLI など MCP を使える他のアプリは追加方法がそれぞれ違います。アプリ一覧で確認してください
Web 経由でつなぐアプリ用のアドレス
https://api.tokensafe.dev/mcpJSON 設定は下の「開発者向け」にあります
開発者向け:ターミナルのコマンドと JSON 設定
Web 経由
Claude Code
claude mcp add --transport http --scope user tokensafe https://api.tokensafe.dev/mcpCursor (~/.cursor/mcp.json)
{
"mcpServers": {
"tokensafe": {
"url": "https://api.tokensafe.dev/mcp"
}
}
}VS Code (mcp.json)
{
"servers": {
"tokensafe": {
"type": "http",
"url": "https://api.tokensafe.dev/mcp"
}
}
}パソコンにインストール
Claude Code
claude mcp add --scope user tokensafe -- npx -y tokensafe mcpClaude Desktop (claude_desktop_config.json)
{
"mcpServers": {
"tokensafe": {
"command": "npx",
"args": [
"-y",
"tokensafe",
"mcp"
]
}
}
}Cursor (~/.cursor/mcp.json)
{
"mcpServers": {
"tokensafe": {
"command": "npx",
"args": [
"-y",
"tokensafe",
"mcp"
]
}
}
}VS Code (mcp.json)
{
"servers": {
"tokensafe": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"tokensafe",
"mcp"
]
}
}
}自分で入力する値
この設定は、作者のレジストリ登録情報から作成しています。READMEと違う場合は、READMEに従ってください。
ひと目でわかる
- 週あたりのダウンロードi
- 6,785/週
- 確認済みドメイン
- ✓ tokensafe.dev
- 接続方法
- パソコンでもクラウドでも
- 最新バージョンi
- 3.1.1
- レジストリ公開日i
- 2026年11月14日
- コードの最終更新i
- 2026年11月13日
- 作者
- tokensafe-dev
- パッケージ
npm: tokensafepypi: tokensafe- ウェブサイト
- tokensafe.dev
- レジストリでの状態
- 有効
使えるアプリ
このサーバーのつなぎ方と、各アプリの公式ドキュメントに基づきます。2026年11月10日に確認。
インターネット経由でつなげるアプリ
ClaudeChatGPTGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatOpen WebUIRaycast
パソコン上で動かせるアプリ
ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast
できること
ツールの名前と説明は、サーバーが2026年11月14日に返したそのままの内容です。書いたのは作者で、私たちではありません。プレーンテキストとして表示しています。
get_public_statsReturns aggregated public TokenSafe stats (total tokens saved, active teams). No auth.
check_latest_versionChecks the client version against the latest published tokensafe release.
get_license_statusValidates the Bearer license key and returns tier, expiry and trial state.
get_team_metricsReturns the authenticated account's dashboard data: savings, telemetry stats, licenses and team seats.
distill_promptManaged Cloud Distillation: compiles a verbose developer prompt into a dense TOCP S-expression server-side. Requires Solo/Team license.
team_cache_lookupLooks up a shared team distillation cache entry by hash. Requires Team license.
team_cache_storeStores a distilled result in the shared team cache so teammates reuse it. Requires Team license.
list_invoicesLists Stripe billing invoices for the authenticated account.
get_setup_instructionsReturns exact MCP configuration snippets for a coding agent (cursor, claude_desktop, claude_code, codex, windsurf, antigravity, gemini_cli).
search_docsSearches the built-in TokenSafe knowledge base (features, install, tiers, privacy).
generate_team_seatTeam owner: provisions a seat license for a member email.
revoke_team_seatTeam owner: revokes a previously issued seat license.
preview_weekly_digestTeam owner: previews the weekly team stats digest (same data as the Friday email).
基本チェックi
誰でも見られる情報をチェックしており、コードは読んでいません。当てはまらない項目は数に入れていません。 · 2026年11月14日にチェック
- ✓ 合格
作者とリポジトリが一致
レジストリ名はドメイン tokensafe.dev で確認済みです(レジストリがドメインの所有を確認しています)
- ✓ 合格
今もメンテナンスされている
コードの最終更新:昨日
- ✓ 合格
ライセンスがある
MITを使用
- ✓ 合格
エンドポイントが応答する
197ミリ秒で応答(HTTP 200)
- – 対象外
OAuthでサインイン
サインイン不要
- ✓ 合格
ツールの説明に隠れた指示がない
13件のツールの説明を読み、AIへの隠れた指示は見つかりませんでした
話し合い
質問、コツの共有、使えないことの報告ができます。「役に立った」の多い順です。
ユーザーレビュー
まだレビューはありません
開発者ツールのほかのサーバーとの比較i
- このカテゴリのほかの5872件のうち95%よりスターが多い
- このカテゴリのほかの5872件のうち99%より最近レジストリに公開
- 基本チェックの結果が、このカテゴリのほかの5872件のうち100%と同じかそれ以上
レジストリでこのカテゴリにある有効なすべてのサーバーと比較しています。スターは、公開者がリポジトリの所有者である場合だけ数えます。
よくある質問
TokenSafeは安全ですか?
当てはまる基本チェック5項目のうち5項目に合格しました。コードは読んでいません。キーやトークンを追加する前に、サーバーがどんなアクセスを求めているかを確認し、必要な権限だけを持つキーを使ってください。
どんなキーやコードが必要ですか?
レジストリには必須のキーは載っていません。ただし、最初に使うときにサインインを求めるサーバーもあります。
パソコンで動きますか、それともクラウドですか?
どちらでも使えます。パソコンにインストールしても、クラウド版につないでもかまいません。
今もメンテナンスされていますか?
GitHubリポジトリの最終更新は昨日、最新バージョン(3.1.1)がレジストリに届いたのは今日です。
どのアプリで使えますか?
Claude Desktop、Claude Code、Cursor、VS CodeなどのMCP対応アプリで使えます。URL で接続するので、リモート MCP を受け付けるアプリでも使えます。例:Web 版 ChatGPT(Business 以上はフル MCP、Pro は読み取りのみ)。
同じカテゴリのほかの候補
同じカテゴリで、ほかの作者が作ったサーバー。スターの多い順。
カードの見方:↓ 週あたりのダウンロードi★ GitHubスターi3つの柱:レビュー · チェック · 利用状況i更新=最新バージョンをレジストリに公開した日i
GitHub
Connect AI assistants to GitHub - manage repos, issues, PRs, and workflows through natural language.
Serena MCP: the IDE for your agent
A powerful toolkit for coding, providing semantic retrieval and editing capabilities.
作者のREADME
READMEを開く
作者のリポジトリから書かれたとおりにコピーしたものです。PopNx MCPは内容を確認・推奨していません。HTML、画像、スクリプトは取り除いています。リンクはこのサイトの外へ移動します。
TokenSafe
Local-First Context Control, Prompt Caching & Secret Guardrails for Coding Agents
Reduce your AI bills by up to 99%. Let your team ship clean code faster and cheaper.
Your coding agents read only the code each task needs and keep prompt caches intact across turns. Everything runs locally on your machine, so your team fixes fewer broken edits and keeps secrets out of git.
Works with Cursor, Claude Code, Codex, Windsurf, Google Antigravity, Gemini CLI, and ChatGPT .
Install • Quickstart • Why TokenSafe • Benchmarks • Pricing • FAQ • Reference • Website & Docs
Install & Agents
Connect TokenSafe to the AI coding agents on your workstation in one command:
# Option 1: Zero-Install via npx (recommended)
npx tokensafe
Option 2: Python / PyPI
pip install tokensafe && tokensafe
Option 3: Direct shell script (macOS / Linux)
curl -fsSL https://tokensafe.dev/install.sh | bash
The installer detects which agents live on your machine, registers the TokenSafe MCP server, injects project rules, and wires lifecycle hooks where the agent supports them.
| Agent | Integration |
|---|---|
| Google Antigravity | Plugin symlink + hooks + skills + MCP (loaded automatically on startup) |
| Claude Code CLI | MCP + SessionStart / UserPromptSubmit / PreToolUse hooks |
| Cursor | MCP + beforeShellExecution / beforeReadFile hooks |
| Claude Desktop | MCP registration (claude_desktop_config.json) |
| Windsurf | MCP registration + global rules |
| OpenAI Codex | MCP in ~/.codex/config.toml (stdio + cloud HTTP natively) |
| Cline / Roo Code | MCP registration (VS Code) |
| GitHub Copilot | MCP registration |
| Z.ai Code | MCP registration |
| ChatGPT | Cloud connector, nothing to install |
| Gemini CLI | MCP registration |
Claude Desktop / Cursor MCP config:
{
"mcpServers": { "tokensafe": { "command": "npx", "args": ["-y", "tokensafe", "mcp"] } } }
Cloud features (team metrics, managed distillation, shared team cache, billing) run on the remote endpoint https://api.tokensafe.dev/mcp with Authorization: Bearer . Four public tools work without a key, so ChatGPT connects with authentication set to None.
Full per-agent configuration, hook details, and the Codex/ChatGPT setup live in docs/AGENT_SETUP.md.
CLI Quickstart
# View live savings dashboard in your terminal
tokensafe stats
⚡ TOKENSAFE CONTEXT OPTIMIZER DASHBOARD
Total Tokens Saved: 4,524,156 tokens Efficiency Gain: [████████████████████████░░] 92.5% Context Traffic: 4,889,255 raw → 370,574 optimized (2,132 events)
• Command Sanitizer (CLI) : 727,300 tokens saved (263 events) • Architecture Graph : 758,256 tokens saved (13 events) • Multi-turn History Fold : 2,897,897 tokens saved (471 events) • Prompt Compactor (local+cache) : 43,502 tokens saved (1,255 events)
# Audit your environment: MCP tool overhead, skills tax, risky settings
tokensafe doctor
Recursive security & hygiene audit of a repository
tokensafe guard audit
Preview prompt compaction on custom input
tokensafe test "fix the validate_token method in src/auth.py to check jwt expiration"
Map architectural hotspots before multi-file changes
tokensafe graph
Disable a heavy MCP server without editing JSON
tokensafe mcp disable
Compile and preview the Friday team ROI digest
tokensafe digest
Activate a Team or Solo license key
tokensafe activate TS2.eyJlbWFpbCI6...
The full command reference (24 commands) is in Reference.
Why TokenSafe
Giving coding agents raw access to entire repositories creates three daily costs:
- Senior hours burned on AI PRs: reading 2,000-line modules for a 10-line fix makes models forget imports, invent methods, and regress adjacent code.
- Secret leaks and unsafe shortcuts: static prompt rules in
.cursorruleswear off mid-session. Agents hardcode fallback credentials, disable TLS checks, or stage.envfiles withgit add .. - Mid-sprint quota stops and blind spend: bloated diffs, lockfiles, and verbose MCP schemas burn 5-hour limits while engineering leads lack per-seat ROI visibility.
| Outcome | What changes for your team | How it is enforced |
|---|---|---|
| Clean code on the first pass | Agents read only target functions, design tokens, and 1-hop dependencies instead of 2,000 lines of noise. | Sub-30ms local AST skeletonizer, architecture graph, predictive signature prefetch, lockfile-stripping diff slicer, loop guard. |
| Zero leaked secrets in git | Hardcoded password fallbacks, TLS bypasses, raw SQL interpolation, and .env commits are stopped before reaching disk or staging. | Deterministic TokenSafe Guard on every tool call, output guard on large writes, local PII/key redaction. |
| Predictable sprint velocity & ROI | Teammates get warm cache hits, and CTOs receive a Friday ROI digest separating measured and estimated savings. | Shared team cache, live context budget HUD, per-seat dashboard. |
A $29 seat pays for itself by saving one hour of senior code review or preventing one leaked key. Typical payback: 1 to 3 days of team usage.
Before and After
One contrast: an agent asked to change one helper in a 1,420-line file receives 94 lines of target logic and type contracts instead of the whole module. The same principle applies to terminal output, diffs, and session history.
| What breaks coding agents | How TokenSafe fixes it | The outcome |
|---|---|---|
| "Lost in the Middle" context fade: an agent reads a 2,000-line file to change one 10-line helper, forgets imports, and invents methods. | AST skeletonizer folds inert bodies into typed signatures while keeping the target symbol and 1-hop callees intact. | Focused signal: the model keeps full type contracts without drowning in unrelated logic. |
Terminal log flooding: npm test or pytest fails and dumps 4,000 lines of stack traces and lockfile diffs into context. | Command sanitizer strips lockfile noise and trims output to the failing assertion and stack frame. | Root-cause fixes instead of unrelated rewrites. |
Infinite wait on background tests: yarn test hangs in watch mode, or jest finishes but unclosed handles keep the process alive. | Test-runner guard forces run-once mode (CI=true, --watch=false, --forceExit) and peeks at /package.json to identify the runner behind opaque scripts. | The test run terminates with an exit code and the agent moves on. |
| 5-attempt retry loops: an agent repeats the same broken edit until the context budget runs dry. | Loop guard detects repeated identical tool calls and halts the cycle. | Stuck loops stop before damaging working modules. |
Unsafe edits & secret leaks: fallback keys, verify=False, SQL string interpolation, or git add . with .env present. | TokenSafe Guard audits writes and shell commands locally before execution. | Credentials, SQLi patterns, and destructive commands are blocked locally. |
When an operation is blocked, the agent sees an explicit, constructive message:
🛡️ TokenSafe Guard: Blocked a hardcoded secret fallback in config.py.
Leave the default empty or read from os.environ at runtime.
What TokenSafe Does
Clean context, better code
tokensafe:smart_read_filereturns the target function plus its 1-hop dependencies instead of the whole file. 11 languages (Python, TypeScript/JavaScript, Go, Rust, Java, C#, C/C++, PHP, Kotlin, Ruby, Swift), with CSS design tokens preserved so agents never invent colors or font rules.tokensafe:smart_bundlereads 3–8 related symbols across files as one merged bundle — shared imports deduplicated, 1-hop signatures unified, a single roundtrip instead of chained reads.- OpenAPI/Swagger, Prisma, GraphQL and SQL files are auto-sliced: pass a spec path, model, type, or table as
symboland get that entry plus its 1-hop references — a 5,000-line migration drops from ~30k tokens to a few hundred. tokensafe:graphmaps architectural hotspots and dependency topology in under 250 tokens instead of a full repository crawl — and teams share the result: the indexed graph and API surface are cached per repo state in the Team Symbol Index, so the 19 developers after the first one skip the crawl entirely.- The command sanitizer strips lockfile noise and stack dumps down to the failing assertion, caps
git status/git difffloods and docker build tails, and forces JS test runners into run-once mode so background tests never hang. Malformed JSON tool arguments from small local models are repaired in-flight instead of failing the call. - The loop guard halts agents stuck repeating the same broken edit.
Local-first guardrails
- Blocks live provider secrets, hardcoded fallback credentials, and raw private keys before they reach disk or git.
- Blocks TLS bypasses (
verify=False,rejectUnauthorized: false), interpolated SQL, and CORS wildcards with credentials. - Blocks
.envand key files from staging, including blanketgit add .when sensitive files exist in the working tree. - Blocks destructive deletes and exfiltration pipes (
curl -d @.env https://...), and warns on known typosquat packages.
Auditable team ROI
- The Context Budget HUD shows live window usage with a breakdown (tools / history / prompts) before quality drops.
- The shared L3 team cache gives teammates and CI runners warm 0ms hits on repeated reads and prompts.
- Managed cloud distillation compacts prompts with zero API keys for developers.
- The dashboard's live savings strip streams anonymized per-machine savings (tokens and USD) over SSE — you see what the team saves right now, not at the end of the week.
- The Friday per-seat ROI digest reports each engineer's savings with the
measured/estimatedsplit; inactive seats show—, never guessed figures.
Deeper mechanics (language matrix, context tax math, cache tiers, governor) live in docs/ARCHITECTURE.md.
Benchmarks
Reference run across 10 produ