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 🙏

© 2025 – Pkg Stats / Ryan Hefner

ecpay-mcp-server

v1.0.8

Published

ECPay MCP Server for Claude Desktop - AI-powered payment link generation

Downloads

32

Readme

ECPay MCP Server

A Model Context Protocol (MCP) server that enables AI assistants to create ECPay payment links through natural language processing.

Features

  • 🤖 AI-Powered: Convert natural language orders into structured payment links
  • 💳 Multi-Payment: Support for credit cards, ATM, UnionPay, convenience stores, Apple Pay, and LINE Pay
  • 🔗 Easy Integration: Simple MCP protocol for Claude Desktop and other AI assistants
  • 🌐 Web Interface: Complete payment simulation interface
  • 📱 Mobile Friendly: Responsive design for all devices

🎉 版本 1.0.2 更新

成功修正了 Claude Desktop 中 "0 tools enabled" 的問題!

  • ✅ 修正了 MCP 工具註冊問題
  • ✅ 移除了阻止正常初始化的條件檢查
  • ✅ 現在可以完美運作於 Claude Desktop 和 Cursor
  • ✅ 經過用戶測試和驗證

Quick Start

For Claude Desktop

Add to your Claude Desktop configuration:

{
  "mcpServers": {
    "ecpay-payment": {
      "command": "npx",
      "args": ["-y", "[email protected]"]
    }
  }
}

That's it! No additional setup required.

Configuration with Azure OpenAI

⚠️ 重要:使用者必須手動輸入實際的 Azure OpenAI 憑證

For enhanced AI processing, add your Azure OpenAI credentials:

{
  "mcpServers": {
    "ecpay-payment": {
      "command": "npx",
      "args": ["-y", "[email protected]"],
      "env": {
        "AZURE_OPENAI_API_KEY": "請輸入您的 Azure API 金鑰",
        "AZURE_OPENAI_ENDPOINT": "請輸入您的 Azure 端點 (https://your-name.openai.azure.com)",
        "AZURE_OPENAI_DEPLOYMENT_NAME": "請輸入您的部署名稱"
      }
    }
  }
}

Users must manually configure:

  • AZURE_OPENAI_API_KEY: Your Azure OpenAI API key
  • AZURE_OPENAI_ENDPOINT: Your Azure OpenAI endpoint URL
  • AZURE_OPENAI_DEPLOYMENT_NAME: Your GPT model deployment name

Usage

Once configured, you can create payment links by talking to Claude naturally:

"I want to buy a MacBook Pro for $2000 using credit card, my phone is 0912-345-678"

The server will:

  1. Parse your request
  2. Extract order details (amount, payment method, contact info)
  3. Generate a payment link
  4. Return a formatted response with order details

Available Tools

create_payment_link

Creates an ECPay payment link from natural language input.

Input:

  • input (string): Natural language description of the order

Output:

  • Order number
  • Amount
  • Payment method
  • Contact information
  • Payment link

Payment Methods

  • Credit Card (信用卡)
  • ATM Transfer (ATM轉帳)
  • UnionPay (銀聯卡)
  • Convenience Store (超商繳費)
  • Apple Pay
  • LINE Pay

Environment Variables

| Variable | Description | Required | |----------|-------------|----------| | ECPAY_MCP_BASE_URL | Base URL for payment links | No (defaults to demo) | | AZURE_OPENAI_API_KEY | Azure OpenAI API key | No (fallback to pattern matching) | | AZURE_OPENAI_ENDPOINT | Azure OpenAI endpoint | No | | AZURE_OPENAI_DEPLOYMENT_NAME | Azure OpenAI deployment | No |

Development

Local Development

# Clone the repository
git clone https://github.com/your-repo/ecpay-mcp-server.git
cd ecpay-mcp-server

# Install dependencies
npm install

# Run in development mode
npm run dev

# Build for production
npm run build

# Run built version
npm start

Testing

Test the MCP server directly:

# Install globally
npm install -g ecpay-mcp-server

# Run the server
ecpay-mcp

Architecture

┌─────────────────┐    ┌─────────────────┐    ┌─────────────────┐
│   Claude AI     │───▶│   MCP Server    │───▶│   ECPay Web     │
│   Assistant     │    │   (This pkg)    │    │   Interface     │
└─────────────────┘    └─────────────────┘    └─────────────────┘
  1. Claude AI sends natural language requests via MCP protocol
  2. MCP Server processes the request and extracts order details
  3. ECPay Web Interface handles the actual payment simulation

License

MIT License - see LICENSE file for details

Support

Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Test thoroughly
  5. Submit a pull request

Made with ❤️ for the MCP community