{"id":48343673,"url":"https://github.com/lis186/ccxray","last_synced_at":"2026-04-11T19:13:23.444Z","repository":{"id":348890198,"uuid":"1200161269","full_name":"lis186/ccxray","owner":"lis186","description":"X-ray vision for AI agent sessions — a transparent HTTP proxy and dashboard for Claude Code","archived":false,"fork":false,"pushed_at":"2026-04-06T01:32:08.000Z","size":2166,"stargazers_count":83,"open_issues_count":0,"forks_count":11,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-04-07T08:03:32.576Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lis186.png","metadata":{"files":{"readme":"README.ja.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-04-03T05:19:06.000Z","updated_at":"2026-04-07T06:01:45.000Z","dependencies_parsed_at":"2026-04-07T08:00:50.899Z","dependency_job_id":null,"html_url":"https://github.com/lis186/ccxray","commit_stats":null,"previous_names":["lis186/ccxray"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/lis186/ccxray","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lis186%2Fccxray","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lis186%2Fccxray/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lis186%2Fccxray/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lis186%2Fccxray/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lis186","download_url":"https://codeload.github.com/lis186/ccxray/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lis186%2Fccxray/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31547845,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-07T16:28:08.000Z","status":"online","status_checked_at":"2026-04-08T02:00:06.127Z","response_time":54,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-04-05T06:00:53.873Z","updated_at":"2026-04-11T19:13:23.422Z","avatar_url":"https://github.com/lis186.png","language":"JavaScript","funding_links":[],"categories":["Latest Additions","最新添加"],"sub_categories":[],"readme":"# ccxray\n\n[English](README.md) | [正體中文](README.zh-TW.md) | **日本語**\n\nAIエージェントセッションのX線ビュー。ゼロ設定のHTTPプロキシで、Claude CodeとAnthropic API間のすべてのAPI呼び出しを記録し、エージェント内部で実際に何が起きているかを確認できるリアルタイムダッシュボードを提供します。\n\n![License](https://img.shields.io/badge/license-MIT-blue)\n\n![ccxrayダッシュボード](https://raw.githubusercontent.com/lis186/ccxray/main/docs/dashboard.png)\n\n## なぜ必要か\n\nClaude Codeはブラックボックスです。以下が見えません：\n- どんなシステムプロンプトを送信しているか（バージョン間の変更も含む）\n- 各ツール呼び出しのコスト\n- なぜ30秒も思考しているのか\n- 200Kトークンのコンテキストウィンドウを何が消費しているのか\n\nccxrayはそれをガラス箱に変えます。\n\n## クイックスタート\n\n```bash\nnpx ccxray claude\n```\n\nこれだけです。プロキシが起動し、Claude Codeがプロキシ経由で接続し、ダッシュボードが自動的にブラウザで開きます。複数のターミナルで実行すると、自動的に一つのダッシュボードを共有します。\n\n### その他の実行方法\n\n```bash\nccxray                           # プロキシ + ダッシュボードのみ\nccxray claude --continue         # すべてのclaude引数がそのまま渡される\nccxray --port 8080 claude        # カスタムポート（独立モード、hub共有なし）\nccxray claude --no-browser       # ブラウザの自動オープンをスキップ\nccxray status                    # hubの情報と接続中のクライアントを表示\nANTHROPIC_BASE_URL=http://localhost:5577 claude   # 手動設定（既存セッション）\n```\n\n### マルチプロジェクト\n\n複数のターミナルで `ccxray claude` を実行すると、自動的に単一のプロキシとダッシュボードを共有します。設定は不要です。\n\n```bash\n# Terminal 1\ncd ~/project-a \u0026\u0026 ccxray claude     # hubを起動 + claude\n\n# Terminal 2\ncd ~/project-b \u0026\u0026 ccxray claude     # 既存のhubに接続\n\n# 両プロジェクトが http://localhost:5577 のダッシュボードに表示\n```\n\nHubプロセスがクラッシュした場合、接続中のクライアントは数秒以内に自動的に復旧します。\n\n```bash\n$ ccxray status\nHub: http://localhost:5577 (pid 12345, uptime 3600s, v1.1.0)\nConnected clients (2):\n  [1] pid 23456 — ~/dev/project-a\n  [2] pid 34567 — ~/dev/project-b\n```\n\n`--port` を使用すると独立モードで実行できます。\n\n## 機能\n\n### タイムライン\n\nエージェントの思考をリアルタイムで観察。各ターンを思考ブロック（所要時間付き）、ツール呼び出しのインラインプレビュー、アシスタント応答に分解します。\n\n![タイムラインビュー](https://raw.githubusercontent.com/lis186/ccxray/main/docs/timeline.png)\n\n### 使用量とコスト\n\n実際の支出を把握。セッションヒートマップ、消費レート、ROI計算 — トークンの行き先を正確に把握できます。\n\n![使用量分析](https://raw.githubusercontent.com/lis186/ccxray/main/docs/usage.png)\n\n### システムプロンプト追跡\n\nバージョンの自動検出とdiffビューア。すべてのエージェントタイプ — メインエージェント、サブエージェント（Explore、Web Searchなど）— のシステムプロンプトを閲覧し、更新ごとの変更点を正確に把握できます。\n\n![システムプロンプト追跡](https://raw.githubusercontent.com/lis186/ccxray/main/docs/system-prompt.png)\n\n### その他\n\n- **セッション検出** — Claude Codeセッションごとに自動グループ化。プロジェクト/作業ディレクトリの抽出付き\n- **トークン会計** — ターンごとの内訳：input/output/cache-read/cache-createトークン、USD単位のコスト、コンテキストウィンドウ使用率バー\n\n## 仕組み\n\n```\nClaude Code  ──►  ccxray (:5577)  ──►  api.anthropic.com（または ANTHROPIC_BASE_URL）\n                      │\n                      ▼\n          ~/.ccxray/logs/ (JSON)\n                      │\n                      ▼\n                  ダッシュボード（同じポート）\n```\n\nccxrayは透過型HTTPプロキシです。リクエストをそのままAnthropicに転送し、リクエストとレスポンスの両方をJSONファイルとして記録し、同じポートでWebダッシュボードを提供します。APIキーは不要です — Claude Codeが送信する内容をそのまま通過させます。\n\n## 設定\n\n### CLIフラグ\n\n| フラグ | 説明 |\n|---|---|\n| `--port \u003cnumber\u003e` | プロキシ + ダッシュボードのポート（デフォルト: 5577）。hub共有を無効化 |\n| `--no-browser` | ダッシュボードをブラウザで自動オープンしない |\n\n### 環境変数\n\n| 変数 | デフォルト | 説明 |\n|---|---|---|\n| `PROXY_PORT` | `5577` | プロキシ + ダッシュボードのポート（`--port`で上書き） |\n| `BROWSER` | — | `none`に設定すると自動オープンを無効化 |\n| `AUTH_TOKEN` | _（なし）_ | アクセス制御用APIキー（未設定時は無効） |\n| `CCXRAY_HOME` | `~/.ccxray` | hubロックファイル、ログ、hub.logの基本ディレクトリ |\n| `CCXRAY_MAX_ENTRIES` | `5000` | メモリ上の最大エントリ数（古いものから削除。ディスクログには影響なし） |\n| `ANTHROPIC_BASE_URL` | — | カスタム上流Anthropicエンドポイント（企業ゲートウェイなど）。ccxrayは起動時にこの値を読み取り、`api.anthropic.com`の代わりにそこへ転送します。`ANTHROPIC_TEST_*`が設定されている場合はそちらが優先されます。 |\n\nログは`~/.ccxray/logs/`に`{timestamp}_req.json`と`{timestamp}_res.json`として保存されます。v1.0からアップグレードする場合、`./logs/`のログは初回起動時に自動的に移行されます。\n\n## Docker\n\n```bash\ndocker build -t ccxray .\ndocker run -p 5577:5577 ccxray\n```\n\n## 要件\n\n- Node.js 18+\n\n## 作者の他のプロジェクト\n\n- [SourceAtlas](https://sourceatlas.io/) — あらゆるコードベースへのマップ\n- [AskRoundtable](https://github.com/AskRoundtable/expert-skills) — AIをMunger、Feynman、Paul Grahamのように思考させる\n- Xで [@lis186](https://x.com/lis186) をフォローして最新情報をチェック\n\n## ライセンス\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flis186%2Fccxray","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flis186%2Fccxray","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flis186%2Fccxray/lists"}