@openpump/mcp 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,201 @@
1
+ # @openpump/mcp
2
+
3
+ MCP (Model Context Protocol) server for Solana token operations on [pump.fun](https://pump.fun) via [OpenPump](https://openpump.io). Works with Claude Desktop, Claude Code, Cursor, and any MCP-compatible client.
4
+
5
+ ## Features
6
+
7
+ - **23 tools** for token creation, trading, transfers, wallet management, and market data
8
+ - **Dual transport**: stdio (for `npx` / Claude Desktop) and HTTP (for remote deployment)
9
+ - **API key authentication** via the OpenPump REST API -- no database required
10
+ - **Zero workspace dependencies** -- installable from npm without access to the monorepo
11
+
12
+ ## Quick Start
13
+
14
+ ### 1. Get an API Key
15
+
16
+ Sign up at [openpump.io](https://openpump.io) and generate an API key from Settings. Keys start with `op_sk_live_`.
17
+
18
+ ### 2. Auto-configure (recommended)
19
+
20
+ The CLI installer detects installed AI clients, prompts for your API key, and writes the correct config files automatically:
21
+
22
+ ```bash
23
+ npx @openpump/mcp init
24
+ ```
25
+
26
+ Or pass the key directly:
27
+
28
+ ```bash
29
+ npx @openpump/mcp init --api-key op_sk_live_abc123
30
+ ```
31
+
32
+ **Supported clients:** Claude Desktop (macOS, Windows, Linux), Cursor, Claude Code.
33
+
34
+ The installer:
35
+ - Detects which clients are installed on your system
36
+ - Lets you choose which ones to configure
37
+ - Merges the OpenPump entry into existing config without overwriting other MCP servers
38
+ - Creates config directories and files if they don't exist
39
+ - Warns before overwriting an existing OpenPump entry
40
+
41
+ Run `npx @openpump/mcp init --help` for all options.
42
+
43
+ ### 3. Run via npx (manual)
44
+
45
+ If you prefer to set up manually, run the MCP server directly:
46
+
47
+ ```bash
48
+ OPENPUMP_API_KEY=op_sk_live_abc123 npx @openpump/mcp
49
+ ```
50
+
51
+ ## Client Setup (Manual)
52
+
53
+ If you prefer manual configuration over `npx @openpump/mcp init`, add the following to each client's config file.
54
+
55
+ ### Claude Desktop
56
+
57
+ Add to `~/Library/Application Support/Claude/claude_desktop_config.json` (macOS) or `%APPDATA%\Claude\claude_desktop_config.json` (Windows):
58
+
59
+ ```json
60
+ {
61
+ "mcpServers": {
62
+ "openpump": {
63
+ "command": "npx",
64
+ "args": ["-y", "@openpump/mcp@latest"],
65
+ "env": {
66
+ "OPENPUMP_API_KEY": "op_sk_live_..."
67
+ }
68
+ }
69
+ }
70
+ }
71
+ ```
72
+
73
+ ### Claude Code
74
+
75
+ Use the CLI or add to `.claude/settings.json`:
76
+
77
+ ```bash
78
+ claude mcp add openpump --transport stdio -- npx -y @openpump/mcp@latest
79
+ ```
80
+
81
+ Or manually add to `.claude/settings.json` in your project or `~/.claude/settings.json` globally:
82
+
83
+ ```json
84
+ {
85
+ "mcpServers": {
86
+ "openpump": {
87
+ "command": "npx",
88
+ "args": ["-y", "@openpump/mcp@latest"],
89
+ "env": {
90
+ "OPENPUMP_API_KEY": "op_sk_live_..."
91
+ }
92
+ }
93
+ }
94
+ }
95
+ ```
96
+
97
+ ### Cursor
98
+
99
+ Add to `~/.cursor/mcp.json`:
100
+
101
+ ```json
102
+ {
103
+ "mcpServers": {
104
+ "openpump": {
105
+ "command": "npx",
106
+ "args": ["-y", "@openpump/mcp@latest"],
107
+ "env": {
108
+ "OPENPUMP_API_KEY": "op_sk_live_..."
109
+ }
110
+ }
111
+ }
112
+ }
113
+ ```
114
+
115
+ ## HTTP Transport
116
+
117
+ For remote deployments or multi-tenant setups, use the HTTP transport:
118
+
119
+ ```bash
120
+ OPENPUMP_API_URL=https://openpump.io PORT=3001 node -e "import('@openpump/mcp/http')"
121
+ ```
122
+
123
+ Or when installed locally:
124
+
125
+ ```bash
126
+ npm start:http
127
+ ```
128
+
129
+ The HTTP transport exposes `POST /mcp`, `GET /mcp`, and `DELETE /mcp` endpoints with per-request API key authentication via `Authorization: Bearer` or `x-api-key` headers.
130
+
131
+ ## Environment Variables
132
+
133
+ | Variable | Required | Default | Description |
134
+ |----------|----------|---------|-------------|
135
+ | `OPENPUMP_API_KEY` | Yes (stdio) | -- | Your OpenPump API key (`op_sk_live_...`) |
136
+ | `OPENPUMP_API_URL` | No | `https://openpump.io` | OpenPump API base URL |
137
+ | `PORT` | No | `3001` | HTTP transport port |
138
+ | `MCP_SESSION_TTL_HOURS` | No | `4` | HTTP session idle timeout (hours) |
139
+
140
+ ## Available Tools
141
+
142
+ ### Token Operations
143
+ - `create-token` -- Create a new token on pump.fun
144
+
145
+ ### Trading
146
+ - `buy-token` -- Buy tokens
147
+ - `sell-token` -- Sell tokens
148
+ - `bundle-buy` -- Bundle buy across multiple wallets
149
+ - `bundle-sell` -- Bundle sell across multiple wallets
150
+ - `estimate-bundle-cost` -- Estimate cost for a bundle operation
151
+ - `claim-creator-fees` -- Claim accumulated creator fees
152
+
153
+ ### Transfers
154
+ - `transfer-sol` -- Transfer SOL between wallets
155
+ - `transfer-token` -- Transfer SPL tokens between wallets
156
+
157
+ ### Wallet Management
158
+ - `create-wallet` -- Create a new managed wallet
159
+ - `list-wallets` -- List all wallets
160
+ - `get-wallet-balance` -- Get SOL balance for a wallet
161
+ - `get-aggregate-balance` -- Get total balance across all wallets
162
+ - `get-wallet-deposit-address` -- Get deposit address for a wallet
163
+ - `get-wallet-transactions` -- Get transaction history
164
+
165
+ ### Market Data
166
+ - `get-token-info` -- Get token metadata and details
167
+ - `get-token-market-info` -- Get live market data (price, volume, holders)
168
+ - `get-token-holdings` -- Get token holdings for a wallet
169
+ - `get-token-quote` -- Get a buy/sell quote
170
+ - `list-my-tokens` -- List tokens created by the authenticated user
171
+ - `get-creator-fees` -- Get claimable creator fees
172
+ - `get-jito-tip-levels` -- Get current Jito tip levels
173
+
174
+ ### Jobs
175
+ - `poll-job` -- Poll the status of an async job (token creation, trades)
176
+
177
+ ## Development
178
+
179
+ ```bash
180
+ # Install dependencies
181
+ pnpm install
182
+
183
+ # Run in dev mode (auto-reload)
184
+ pnpm run dev
185
+
186
+ # Build
187
+ pnpm run build
188
+
189
+ # Run tests
190
+ pnpm run test
191
+
192
+ # Type check
193
+ pnpm run typecheck
194
+
195
+ # Lint
196
+ pnpm run lint
197
+ ```
198
+
199
+ ## License
200
+
201
+ MIT
@@ -0,0 +1,9 @@
1
+ #!/usr/bin/env node
2
+ import {
3
+ createApiKeyMiddleware,
4
+ validateApiKey
5
+ } from "./chunk-P5IDZOR3.js";
6
+ export {
7
+ createApiKeyMiddleware,
8
+ validateApiKey
9
+ };