npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

gmo-kline-mcp

v1.0.0

Published

MCP server for GMO Coin FX KLINE API

Readme

GMO KLine MCP Server

CI License: MIT Node.js Version

GMOコイン外国為替FXのKLine(ローソク足)データ取得APIをModel Context Protocol(MCP)サーバーとして提供します。Claude Desktop、CursorなどのMCPクライアントから簡単に為替レートのヒストリカルデータを取得できます。

📋 目次

✨ 特徴

このMCPサーバーは、GMOコインの外国為替FXパブリックAPIをラップし、AIアシスタントから簡単に利用できるようにします。

主な機能:

  • 認証不要: パブリックAPIのため、APIキーやシークレットキーは不要です
  • 複数銘柄対応: USD_JPY、EUR_JPY、GBP_JPY、AUD_JPY、NZD_JPY、CAD_JPY、CHF_JPY、EUR_USD、GBP_USD、AUD_USDの10通貨ペアに対応
  • 複数時間軸対応: 1分足から月足まで12種類の時間軸(1min, 5min, 10min, 15min, 30min, 1hour, 4hour, 8hour, 12hour, 1day, 1week, 1month)をサポート
  • BID/ASK選択: 売値(BID)と買値(ASK)の両方を取得可能
  • ヒストリカルデータ: 過去のローソク足データを日付指定で取得
  • パラメータバリデーション: 適切なエラーメッセージによる入力検証
  • クロスプラットフォーム: Windows、macOS、Linuxで動作

🚀 インストール

前提条件

  • Node.js 18.0.0以上
  • pnpm、npm、またはyarn

手順

# リポジトリのクローン
git clone https://github.com/Mako3333/gmo-kline-mcp.git
cd gmo-kline-mcp

# 依存パッケージのインストール
pnpm install
# または
npm install

📖 使用方法

MCPクライアントへの登録

Claude Desktop

設定ファイル(claude_desktop_config.json)に以下を追加:

macOS/Linux:

{
  "mcpServers": {
    "gmo-kline": {
      "command": "node",
      "args": ["/absolute/path/to/gmo-kline-mcp/index.js"]
    }
  }
}

Windows:

{
  "mcpServers": {
    "gmo-kline": {
      "command": "node",
      "args": ["C:/path/to/gmo-kline-mcp/index.js"]
    }
  }
}

Cursor

プロジェクトルートの.cursor/mcp.jsonに以下を追加:

{
  "mcpServers": {
    "gmo-kline": {
      "command": "node",
      "args": ["/absolute/path/to/gmo-kline-mcp/index.js"]
    }
  }
}

使用例

AIアシスタントに以下のようなプロンプトを送信すると、自動的にget_klinesツールが呼び出されます。

例1: 日足データの取得

USD/JPYの2025年の日足ASK価格データを取得して、最高値と最安値を教えてください。

例2: 1分足データの取得

2025年10月17日のEUR/JPYの1分足BID価格データを取得してください。

例3: 複数銘柄の比較

USD/JPYとEUR/JPYの2024年の日足データを取得して、どちらがより変動が大きかったか比較してください。

コマンドラインからの直接実行

# ツール一覧の確認
echo '{"jsonrpc":"2.0","id":1,"method":"tools/list","params":{}}' | node index.js

# KLineデータの取得
echo '{"jsonrpc":"2.0","id":2,"method":"tools/call","params":{"name":"get_klines","arguments":{"symbol":"USD_JPY","priceType":"ASK","interval":"1day","date":"2024"}}}' | node index.js 2>/dev/null

🛠️ ツール仕様

get_klines

GMOコイン外国為替FXのKLine(ローソク足)データを取得します。

パラメータ

| パラメータ | 型 | 必須 | 説明 | |-----------|-----|------|------| | symbol | string | ✓ | 取扱銘柄。以下の10通貨ペアのみ: USD_JPY, EUR_JPY, GBP_JPY, AUD_JPY, NZD_JPY, CAD_JPY, CHF_JPY, EUR_USD, GBP_USD, AUD_USD | | priceType | string | ✓ | 価格タイプ: BID(売値) または ASK(買値) | | interval | string | ✓ | 時間軸: 1min, 5min, 10min, 15min, 30min, 1hour, 4hour, 8hour, 12hour, 1day, 1week, 1month | | date | string | ✓ | 日付。1hourまで(1min〜1hour)はYYYYMMDD、4hour以上(4hour〜1month)はYYYY |

日付指定ルール(重要)

  • 1min, 5min, 10min, 15min, 30min, 1hour → YYYYMMDD 例: 20241028
  • 4hour, 8hour, 12hour, 1day, 1week, 1month → YYYY 例: 2024
  • 形式自体はどちらも受け付けますが、サーバー側で interval に応じた整合性チェックを行い、不一致の場合はエラーを返します。

レスポンス

KLineデータの配列を返します。各データには以下のフィールドが含まれます。

  • openTime: 開始時刻のunixタイムスタンプ(ミリ秒)
  • open: 始値
  • high: 高値
  • low: 安値
  • close: 終値

💻 対応環境

このMCPサーバーは以下の環境でテスト済みです。

  • OS: Windows 11, macOS 14, Ubuntu 22.04
  • Node.js: v18.x, v20.x, v22.x
  • MCPクライアント: Claude Desktop, Cursor

📚 ドキュメント

詳細なドキュメントは以下のファイルを参照してください。

🤝 貢献

貢献を歓迎します!バグ報告、機能リクエスト、プルリクエストなど、どんな形でも構いません。

詳細はCONTRIBUTING.mdを参照してください。

貢献者

このプロジェクトに貢献してくださったすべての方に感謝します。

📄 ライセンス

このプロジェクトはMIT Licenseの下でライセンスされています。詳細はLICENSEファイルを参照してください。

🔗 関連リンク

⚠️ 免責事項

このプロジェクトはGMOコイン株式会社とは関係ありません。公開されているパブリックAPIを利用した非公式のツールです。

使用は自己責任でお願いします。取引の判断や投資の意思決定には、必ず専門家に相談してください。

📞 サポート

問題が発生した場合は、Issuesで報告してください。


Made with ❤️ by the community