projectx-mcp
projectx-mcp
Claude Desktopと会話してProjectXに工数を記録します。
「今日のOntracに8時間記録して」 「今週の未入力の日をOntracで埋めて」 「今月、工数が入力されていない日はいつ?」
インストール
macOS (自動)
git clone git@github.com:agustindiezdb/projectx-mcp.git
cd projectx-mcp
bash scripts/install.shこのスクリプトは以下の処理を行います:
依存関係のインストール
プロジェクトのビルド
Claude Desktopの自動設定
既存設定のバックアップ作成
その後、Claude Desktopを再起動してください。DualbootのGoogleアカウントでログインするためにChromeが自動的に開きます。
以上です! これでClaudeに工数を記録するよう依頼できます。
Windows
git clone git@github.com:agustindiezdb/projectx-mcp.git
cd projectx-mcp
npm install
npm run build次に、Claude Desktopの設定を手動で編集します:
以下を開きます:%APPDATA%\Claude\claude_desktop_config.json
以下を追加します:
{
"mcpServers": {
"projectx": {
"command": "node",
"args": ["C:\\full\\path\\to\\projectx-mcp\\dist\\src\\server.js"]
}
}
}C:\full\path\to\ を実際のパスに置き換えてください(Windowsのパスには \ を使用してください)。
その後、Claude Desktopを再起動してください。ログインのためにChromeが自動的に開きます。
手動インストール
手動で設定したい場合:
クローンとビルド:
git clone git@github.com:agustindiezdb/projectx-mcp.git cd projectx-mcp npm install npm run buildClaude Desktopの設定を編集:
~/Library/Application Support/Claude/claude_desktop_config.jsonを開き、以下を追加します:{ "mcpServers": { "projectx": { "command": "node", "args": ["/ABSOLUTE/PATH/TO/projectx-mcp/dist/src/server.js"] } } }/ABSOLUTE/PATH/TO/をクローンしたリポジトリへのフルパスに置き換えてください。Claude Desktopを再起動
Cursorでの使用
CursorはプロジェクトごとのMCP設定を使用します。プロジェクトのルートに .cursor/mcp.json を作成してください:
{
"$schema": "https://json.schemastore.org/mcp.json",
"mcpServers": {
"projectx": {
"command": "node",
"args": ["/ABSOLUTE/PATH/TO/projectx-mcp/dist/src/server.js"]
}
}
}/ABSOLUTE/PATH/TO/ をクローンしたリポジトリへのフルパスに置き換えてください。
その後、Cursorを再起動してください。初回起動時にログイン用のChromeが開きます。
使用方法
Claudeに自然な言葉で話しかけるだけです:
Log 8 hours of Ontrac for today with description "Sprint planning"Check my entries for this week and fill the missing days with 8h of OntracDelete yesterday's entry and log 4h of Internal — AdministrativeWhich days am I missing hours for April?利用可能なツール
ツール | 説明 |
| 指定期間のエントリーを表示 |
| 利用可能なプロジェクトを一覧表示 |
| エントリーを作成 |
| IDを指定してエントリーを削除 |
ログインに失敗した場合やセッションが切れた場合
Claude Desktopを再起動するだけです。ログインのためにChromeが再度開きます。
便利なスクリプト
Claude Desktopを使わずに直接APIを利用することも可能です:
# Test the API (creates and deletes a test entry)
npm run test:entry
# Check which days you're missing hours in April
npx ts-node scripts/check-april.ts
# Manually refresh your session (if expired)
npm run save-session開発者向け
アーキテクチャ
Claude Desktop → MCP Server (stdio) → fetch() + _interslice_session cookie → ProjectX APIセッションクッキーは ~/Library/Application Support/projectx-mcp/auth.json (gitignored) に保存されます。
起動時に有効なセッションが見つからない場合、Playwright経由でログイン用のChromeが自動的に開きます。
開発モード
npm run devこれは迅速な開発のために ts-node でサーバーを実行します(ビルド手順は不要です)。
仕組み
認証: Playwrightを使用してChromeを開き、
/api/v1/current_userをポーリングすることでログイン成功を自動検知しますセッションの永続化: Playwrightの
storageState()を使用してクッキーをauth.jsonに保存しますAPIクライアント:
_interslice_sessionクッキーを読み取り、ProjectXに対して認証済みリクエストを行いますMCPプロトコル: stdioトランスポートを介して4つのツールをClaude Desktopに公開します
Claude Desktopの設定(手動)
手動で編集したい場合:
{
"mcpServers": {
"projectx": {
"command": "node",
"args": ["/path/to/projectx-mcp/dist/src/server.js"]
}
}
}トラブルシューティング
セッション期限切れ → Claude Desktopを再起動するとChromeが自動的に開きます
Chromeが見つからない → Google Chromeをインストールしてください(システムPATHに含まれている必要があります)
プロジェクトが見つからない → Claudeに
get_projectsを実行させて正確な名前を確認してくださいパスの問題 (macOS/Linux) →
~や相対パスではなく、絶対パスを使用してくださいパスの問題 (Windows) → JSONパス内では
\(ダブルバックスラッシュ) を使用してください(例:C:\Users\...)認証ファイルの場所:
macOS:
~/Library/Application Support/projectx-mcp/auth.jsonWindows:
%APPDATA%\projectx-mcp\auth.jsonLinux:
~/.config/projectx-mcp/auth.json
要件
OS: macOS, Windows, または Linux
Node.js: 20以上
ブラウザ: Google Chrome (自動ログインに必須)
Claude Desktop
Dualboot Googleアカウント
ライセンス
Dualboot Partnersの社内ツール。
This server cannot be deployed
Maintenance
Related MCP Connectors
Manage projects, tasks, time tracking, and team collaboration through natural language.
Track time, log expenses, manage projects and draft or send Keito invoices from AI agents.
Manage Avaza projects, tasks, timesheets, expenses, invoices, and scheduling from AI assistants.
Track time on usetimebook.com - start/stop timers, log entries, list projects/clients.