0.1.4 • Published 8 months ago

@magpieim/mcp v0.1.4

Weekly downloads
-
License
MIT
Repository
-
Last release
8 months ago

Magpie Model Context Protocol

The Magpie Model Context Protocol server allows you to integrate with Magpie APIs through function calling. This protocol supports various tools to interact with different Magpie services.

Setup

To run the Magpie MCP server using npx, use the following command:

# To set up all available tools
npx -y @magpieim/mcp --tools=all --api-key=YOUR_MAGPIE_SECRET_KEY

# To set up specific tools
npx -y @magpieim/mcp --tools=customers.create,customers.read,charges.create --api-key=YOUR_MAGPIE_SECRET_KEY

Make sure to replace YOUR_MAGPIE_SECRET_KEY with your actual Magpie secret key. Alternatively, you could set the MAGPIE_SECRET_KEY in your environment variables.

Usage with Claude Desktop

Add the following to your claude_desktop_config.json. See here for more details.

{
    “mcpServers”: {
        “magpie”: {
            “command”: “npx”,
            “args”: [
                “-y”,
                “@magpieim/mcp”,
                “--tools=all”,
                “--api-key=MAGPIE_SECRET_KEY”
            ]
        }
    }
}

Available tools

ToolDescription
customers.createCreate a new customer
customers.readRetrieve customer information
charges.createCreate a new charge
charges.updateVoid, capture a charge
refunds.createRefund a charge
checkoutSessions.createCreate a new checkout session
checkoutSessions.readRetrieve checkout session information
paymentRequests.createCreate a new invoice
paymentRequests.readRetrieve invoice information
paymentLinks.createCreate a new payment link
paymentLinks.readRetrieve payment link information
paymentLinks.updateActivate, deactivate a payment link

Debugging the Server

To debug your server, you can use the MCP Inspector.

First build the server

npm run build

Run the following command in your terminal:

# Start MCP Inspector and server with all tools
npx @modelcontextprotocol/inspector node dist/index.js --tools=all --api-key=YOUR_MAGPIE_SECRET_KEY

Instructions

  1. Replace YOUR_MAGPIE_SECRET_KEY with your actual Magpie API secret key.
  2. Run the command to start the MCP Inspector.
  3. Open the MCP Inspector UI in your browser and click Connect to start the MCP server.
  4. You can see the list of tools you selected and test each tool individually.
0.1.4

8 months ago

0.1.3

8 months ago

0.1.2

8 months ago

0.1.1

8 months ago

0.1.0

8 months ago