CLI
Install the pinelabs-mcp CLI to run an MCP server locally with auto-configuration for Claude Desktop, Cursor, VS Code, and more.
The pinelabs-mcp CLI is an MCP client for the Pine Labs payment gateway. Use it to connect Claude Desktop, Cursor, VS Code, Windsurf, OpenCode, GitHub Copilot, and OpenAI Codex to Pine Labs payment APIs using your client credentials — all from one command-line tool.
Prerequisites
Download Node.js and verify with node --version.
A Pine Labs Online merchant account with API access enabled.
Your X-Client-Id and X-Client-Secret from the Pine Labs Dashboard.
Step 1 — Get your API credentials
Visit the Pine Labs Dashboard.
Navigate to your merchant account settings.
Copy your X-Client-Id and X-Client-Secret.
Step 2 — Install the Pine Labs MCP CLI
npm i pinelabs-mcp
Step 3 — Configure your credentials
Save your Pine Labs MCP credentials locally using the Client ID and Client Secret from Step 1.
pinelabs-mcp configure --client-id=X --client-secret=Y [--env=uat | prod]
Environment variables
| Variable | Required | Default | Description |
|---|---|---|---|
PINELABS_CLIENT_ID | Yes | — | Your Pine Labs client ID |
PINELABS_CLIENT_SECRET | Yes | — | Your Pine Labs client secret |
PINELABS_ENV | No | uat | Environment: uat or prod |
PINELABS_MCP_ENDPOINT | No | — | Custom endpoint URL (overrides PINELABS_ENV) |
DEBUG | No | false | Enable debug logging (true or 1) |
Step 4 — Test your connection
After saving the configuration, restart your AI client. Then try this in your assistant:
npx pinelabs-mcp test
If everything is configured correctly, the assistant responds and confirms your MCP connection is live.
CLI command reference
| Command | Description |
|---|---|
pinelabs-mcp start | Start MCP server (stdio mode) |
pinelabs-mcp configure | Interactive credential setup |
pinelabs-mcp configure --client-id=X --client-secret=Y [--env=uat | prod] | Configure CLI with client and secret |
pinelabs-mcp test | Test connectivity and credentials |
pinelabs-mcp setup <client> | Auto-configure an AI client |
pinelabs-mcp setup <client> --local | Use local path (dev mode) |
pinelabs-mcp setup <client> --print | Preview config without writing |
pinelabs-mcp status | Show current configuration |
pinelabs-mcp help | Show help message |
pinelabs-mcp --version | Show version |
Supported AI clients
| Client | Setup command | Config path |
|---|---|---|
| Claude Desktop | setup claude-desktop | Platform-specific Claude config |
| Cursor | setup cursor | ~/.cursor/mcp.json |
| VS Code | setup vscode | .vscode/mcp.json (project) |
| Windsurf | setup windsurf | ~/.codeium/windsurf/mcp_config.json |
| OpenCode | setup opencode | .opencode/config.json (project) |
| GitHub Copilot | setup copilot | ~/.copilot/mcp-config.json |
| OpenAI Codex | setup codex | .codex/config.toml |
Available tools
The MCP server exposes 20+ tools across these categories:
- Payment Links — Create, retrieve, cancel, and resend payment links.
- Orders — Create, track, and cancel checkout orders.
- Payments — QR code generation for UPI payments.
- Refunds — Create and retrieve refund details.
- Settlements — Settlements APIs.
See the Available Tools reference for full details.
Manual configuration
If you prefer to configure manually, add the following to your AI client's MCP config:
{
"mcpServers": {
"pinelabs": {
"command": "npx",
"args": ["-y", "pinelabs-mcp"],
"env": {
"PINELABS_CLIENT_ID": "your_client_id",
"PINELABS_CLIENT_SECRET": "your_client_secret"
}
}
}
}
- VS Code uses
"servers"instead of"mcpServers"as the top-level key. - Production: add
"PINELABS_ENV": "prod"to theenvblock.
Troubleshooting
| Issue | Fix |
|---|---|
| Missing credentials | Run npx pinelabs-mcp configure or set PINELABS_CLIENT_ID / PINELABS_CLIENT_SECRET in your MCP client's env block. |
| Tools not appearing | Restart your AI assistant; verify Node.js 18+ (node --version); set "DEBUG": "true" in env. |
| Connection issues | Verify credentials; check network access to mcp.pinelabs.com; allow HTTPS if behind a proxy. |
Next steps
- Try the Use Cases — real prompts and what happens behind the scenes.
- Browse the Available Tools reference.
- Read the FAQs for limits and authentication details.
