Skip to main content
Glama
gbrlpzz

prime-agent-stripe-mcp

by gbrlpzz

prime-agent-stripe-mcp

Prime Agent 向けの公式 Stripe MCP 統合。

CI License: MIT Python

Prime Agent は、Stripe の公式リモート MCP サーバー https://mcp.stripe.com に接続します。エージェントは、他の MCP クライアントと同じ API サーフェスを通じて Stripe リソースを検査および管理できます。

[!NOTE] Stripe の MCP サーバーはパブリックプレビュー中です。読み取りと書き込みの両方のツールを公開しています。 開発中は接続をテストモードに保ってください。

┌─────────────────────────────────┐                      ┌─────────────────────────────────┐
│ │ from stripe import         │  │                      │ │ mcp.stripe.com              │ │
│ │   stripe                   │  │                      │ │ API · billing · reporting   │ │
│ │ await stripe.list_tools()  │──┼   OAuth 2.1 + PKCE   │ │ products · customers        │ │
│ │ await stripe.call_tool(    │  │                      │ │ subscriptions · events      │ │
│ auth.json: mcp:stripe           │                      │ │ documentation search        │ │
└─────────────────────────────────┘                      └─────────────────────────────────┘

この統合の理由

  • Stripe ホスト型サーバー — このリポジトリには自己ホスト型プロキシも Stripe API キーもありません。

  • Prime Agent ネイティブ — このモジュールは McpIntegration を拡張し、Python カーネルからライブツールインベントリを公開します。

  • OAuth 2.1 with PKCE — ブラウザでの承認は、Prime Agent のプライベートな auth.jsonmcp:stripe にのみ保存されます。

  • テストモード対応 — Liminal Stripe アカウントを承認し、開発中はテストモードのリソースのみを使用します。

Related MCP server: stripe-mcp

インストール

Python カーネルと Python 3.10 以降を備えた Prime Agent が必要です。

  1. リポジトリをクローンし、スキルを所定の場所にリンクします:

    git clone https://github.com/gbrlpzz/prime-agent-stripe-mcp.git ~/prime-agent-stripe-mcp
    rm -rf ~/.agents/skills/stripe
    ln -s ~/prime-agent-stripe-mcp ~/.agents/skills/stripe
  2. Prime Agent のカーネル環境に編集可能なパッケージをインストールします:

    uv pip install --python ~/.prime/agent/kernel-venv/bin/python -e ~/prime-agent-stripe-mcp
  3. Prime Agent の MCP 設定にリモートサーバーを一度追加します:

    {
      "mcpServers": {
        "stripe": {
          "type": "http",
          "url": "https://mcp.stripe.com",
          "oauth": true
        }
      }
    }
  4. Prime Agent をリロードし、Stripe アカウントを承認します:

    /reload
    /mcp login stripe

Liminal Stripe アカウントを承認してください。この開発ワークフローの外に置くべき個人用や本番用のアカウントではありません。Prime Agent は資格情報を mcp:stripe として保存します。このリポジトリに書き込まれることはありません。

使用方法

from stripe import stripe, auth_status

print(auth_status())               # credential state, no token values
tools = await stripe.list_tools()  # live Stripe MCP inventory
# Inspect the live schema before calling a read or write tool.
result = await stripe.call_tool("<live-tool-name>", {"<live-argument>": "..."})

auth_status() はシークレットを含まない小さな dict を返します:

{"enabled": True, "expires_fresh": True, "type": "oauth"}

ツール名とパラメータは Stripe に属し、パブリックプレビュー中に変更される可能性があります。最初に list_tools() を呼び出すか、ライブインベントリから自動的にバインドされたメソッドを使用してください。

サーバーには、Stripe API の検出、API の読み取りと書き込み、アカウント情報、請求リソース、ドキュメント、レポートのためのツールが含まれています。書き込み操作は Stripe データを変更します。作成、更新、キャンセル、返金、削除を行う前に、人間の確認を求めてください。

トークン更新のフォールバック

Prime Agent は保存されたトークンを自動的に更新します。それが利用できないホストでは、モジュールレベルのフォールバックを呼び出してください:

from stripe import refresh

refresh()  # exchanges the stored refresh token; rewrites auth.json with mode 600

Liminal 開発ワークフロー

  1. 個人ユーザーを Liminal Stripe アカウントのチームメンバーとして追加します。

  2. そのユーザーとしてこの統合を承認します。

  3. Stripe ダッシュボードがテストモードであることを確認します。

  4. テスト用の商品、価格、顧客、サブスクリプションのみを作成します。

  5. Supabase の stripe-webhook 関数を、結果のテスト用ウェブフック署名シークレットで個別に設定します。MCP 資格情報は、サーバー側の STRIPE_SECRET_KEYSTRIPE_WEBHOOK_SECRET を置き換えるものではありません。

トラブルシューティング

症状

修正

auth_status() が資格情報なしと報告する

/mcp login stripe を再度実行します。

長い一時停止の後に呼び出しが失敗する

refresh() を実行します。False が返された場合は再度ログインします。

ツール名が不明である

await stripe.list_tools() を再実行します。プレビュー中にインベントリが変更される可能性があります。

開発

python3 tests/test_skill.py                             # standalone suite, no Prime Agent needed
~/.prime/agent/kernel-venv/bin/python -m pytest tests/  # inside Prime Agent's kernel

CI は main へのプッシュのたびにスタンドアロンスイートを実行します。

セキュリティ

  • このリポジトリや Git 履歴には資格情報は存在しません。

  • OAuth トークンは Prime Agent のプライベートな auth.json にのみ保存されます。

  • モジュールは https://mcp.stripe.com と Stripe の OAuth 認可サーバーとのみ通信します。

  • すべての開発用変更は Stripe テストモードで行ってください。

  • Stripe のシークレット値や秘密鍵の素材をソース、テスト、ドキュメント、Git 履歴に置かないでください。

ライセンス

MIT — LICENSE を参照してください。Stripe は Stripe, Inc. の商標です。これは Stripe の公式 MCP サーバー向けの独立したクライアント統合です (NOTICE を参照)。

A
license - permissive license
Not graded
quality - not tested
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    Not graded
    quality
    C
    maintenance
    MCP server for the Stripe API with 10 tools covering payments, customers, invoices, and subscriptions. Generated with MCPForge. Destructive and financial operations require human approval.
    40
    MIT
  • A
    license
    Not graded
    quality
    C
    maintenance
    Enables natural language interaction with Stripe accounts to query customers, revenue, invoices, subscriptions, disputes, and issue refunds.
    59
    1
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables integration with Stripe APIs through function calling, supporting operations on customers, products, invoices, subscriptions, and more.
    10,572
    MIT

View all related MCP servers

Related MCP Connectors

  • Stripe MCP Pack — read-only access to Stripe data via API key.

  • MCP server integrating with Stripe - tools for customers, products, payments, and more.

  • Agent Commerce Protocol MCP — bridges Stripe ACP + Google AP2 + Coinbase x402 for agent payments

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/gbrlpzz/prime-agent-stripe-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server