inventpay-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,164 @@
1
+ # InventPay MCP Server
2
+
3
+ Give AI agents the ability to manage crypto payments, stores, products, and orders through the [Model Context Protocol](https://modelcontextprotocol.io).
4
+
5
+ ## Installation
6
+
7
+ ```bash
8
+ npm install -g inventpay-mcp
9
+ ```
10
+
11
+ Or run directly with npx:
12
+
13
+ ```bash
14
+ npx inventpay-mcp
15
+ ```
16
+
17
+ ## Configuration
18
+
19
+ ### Get your API Key
20
+
21
+ 1. Sign up at [inventpay.io](https://inventpay.io)
22
+ 2. Go to **Dashboard → Settings**
23
+ 3. Copy your API key
24
+
25
+ ### Claude Desktop
26
+
27
+ Add to your `claude_desktop_config.json`:
28
+
29
+ ```json
30
+ {
31
+ "mcpServers": {
32
+ "inventpay": {
33
+ "command": "npx",
34
+ "args": ["-y", "inventpay-mcp"],
35
+ "env": {
36
+ "INVENTPAY_API_KEY": "your-api-key-here"
37
+ }
38
+ }
39
+ }
40
+ }
41
+ ```
42
+
43
+ ### Claude Code
44
+
45
+ ```bash
46
+ claude mcp add inventpay -- npx -y inventpay-mcp
47
+ ```
48
+
49
+ Then set the environment variable:
50
+
51
+ ```bash
52
+ export INVENTPAY_API_KEY="your-api-key-here"
53
+ ```
54
+
55
+ ### Cursor
56
+
57
+ Add to your Cursor MCP settings (`.cursor/mcp.json`):
58
+
59
+ ```json
60
+ {
61
+ "mcpServers": {
62
+ "inventpay": {
63
+ "command": "npx",
64
+ "args": ["-y", "inventpay-mcp"],
65
+ "env": {
66
+ "INVENTPAY_API_KEY": "your-api-key-here"
67
+ }
68
+ }
69
+ }
70
+ }
71
+ ```
72
+
73
+ ### Windsurf
74
+
75
+ Add to your Windsurf MCP config:
76
+
77
+ ```json
78
+ {
79
+ "mcpServers": {
80
+ "inventpay": {
81
+ "command": "npx",
82
+ "args": ["-y", "inventpay-mcp"],
83
+ "env": {
84
+ "INVENTPAY_API_KEY": "your-api-key-here"
85
+ }
86
+ }
87
+ }
88
+ }
89
+ ```
90
+
91
+ ## Available Tools
92
+
93
+ ### Payments
94
+
95
+ | Tool | Description |
96
+ |------|-------------|
97
+ | `create_payment` | Create a crypto payment with a unique wallet address |
98
+ | `create_invoice` | Create a multi-currency invoice (customer chooses crypto) |
99
+ | `get_payment_status` | Check payment status, confirmations, and transaction details |
100
+
101
+ ### Balances
102
+
103
+ | Tool | Description |
104
+ |------|-------------|
105
+ | `get_balances` | Get all cryptocurrency balances (available, pending, earned, withdrawn) |
106
+
107
+ ### Withdrawals
108
+
109
+ | Tool | Description |
110
+ |------|-------------|
111
+ | `create_withdrawal` | Withdraw funds to an external wallet address |
112
+ | `get_withdrawal` | Check withdrawal status and transaction hash |
113
+
114
+ ### Store Management
115
+
116
+ | Tool | Description |
117
+ |------|-------------|
118
+ | `create_store` | Create a crypto-powered storefront |
119
+ | `get_store` | Get store details, product count, and order count |
120
+ | `update_store` | Update store name, description, logo, or visibility |
121
+
122
+ ### Products
123
+
124
+ | Tool | Description |
125
+ |------|-------------|
126
+ | `create_product` | Add a digital product with automatic delivery content |
127
+ | `list_products` | List products with search and pagination |
128
+ | `update_product` | Update product details, price, or digital content |
129
+ | `delete_product` | Deactivate a product |
130
+
131
+ ### Orders
132
+
133
+ | Tool | Description |
134
+ |------|-------------|
135
+ | `list_orders` | List orders with status filter and pagination |
136
+ | `get_order` | Get full order details (items, payment, customer) |
137
+ | `update_order_status` | Update fulfillment status |
138
+
139
+ ### Analytics
140
+
141
+ | Tool | Description |
142
+ |------|-------------|
143
+ | `get_store_analytics` | Get order counts, revenue breakdown, and product stats |
144
+
145
+ ## Example Prompts
146
+
147
+ Once connected, you can ask your AI agent things like:
148
+
149
+ - "Create a new store called 'Digital Downloads' and add a product for my e-book at $9.99"
150
+ - "Show me all my pending orders"
151
+ - "What's my current ETH balance?"
152
+ - "Create a payment for $50 in Bitcoin"
153
+ - "How much revenue has my store generated?"
154
+
155
+ ## Environment Variables
156
+
157
+ | Variable | Required | Description |
158
+ |----------|----------|-------------|
159
+ | `INVENTPAY_API_KEY` | Yes | Your InventPay merchant API key |
160
+ | `INVENTPAY_BASE_URL` | No | API base URL (default: `https://api.inventpay.io`) |
161
+
162
+ ## License
163
+
164
+ MIT
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export {};
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":""}
package/dist/index.js ADDED
@@ -0,0 +1,440 @@
1
+ #!/usr/bin/env node
2
+ import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
3
+ import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
4
+ import { z } from "zod";
5
+ // ============================================================================
6
+ // Configuration
7
+ // ============================================================================
8
+ const API_KEY = process.env.INVENTPAY_API_KEY;
9
+ const BASE_URL = process.env.INVENTPAY_BASE_URL || "https://api.inventpay.io";
10
+ if (!API_KEY) {
11
+ console.error("WARNING: INVENTPAY_API_KEY environment variable is not set. All API calls will fail.");
12
+ }
13
+ // ============================================================================
14
+ // HTTP Client
15
+ // ============================================================================
16
+ async function callApi(method, path, body) {
17
+ if (!API_KEY) {
18
+ return {
19
+ content: [
20
+ {
21
+ type: "text",
22
+ text: JSON.stringify({
23
+ success: false,
24
+ error: "INVENTPAY_API_KEY is not configured. Set it as an environment variable.",
25
+ }, null, 2),
26
+ },
27
+ ],
28
+ };
29
+ }
30
+ try {
31
+ const headers = {
32
+ "X-API-Key": API_KEY,
33
+ "Content-Type": "application/json",
34
+ };
35
+ const options = { method, headers };
36
+ if (body && (method === "POST" || method === "PUT")) {
37
+ options.body = JSON.stringify(body);
38
+ }
39
+ const response = await fetch(`${BASE_URL}${path}`, options);
40
+ const data = await response.json();
41
+ return {
42
+ content: [{ type: "text", text: JSON.stringify(data, null, 2) }],
43
+ };
44
+ }
45
+ catch (error) {
46
+ const message = error instanceof Error ? error.message : "Unknown error occurred";
47
+ return {
48
+ content: [
49
+ {
50
+ type: "text",
51
+ text: JSON.stringify({ success: false, error: `Request failed: ${message}` }, null, 2),
52
+ },
53
+ ],
54
+ };
55
+ }
56
+ }
57
+ function buildQuery(params) {
58
+ const entries = Object.entries(params).filter(([, v]) => v !== undefined && v !== null);
59
+ if (entries.length === 0)
60
+ return "";
61
+ return ("?" +
62
+ entries.map(([k, v]) => `${k}=${encodeURIComponent(String(v))}`).join("&"));
63
+ }
64
+ // ============================================================================
65
+ // Reusable Schemas
66
+ // ============================================================================
67
+ const digitalContentSchema = z
68
+ .object({
69
+ fileUrl: z.string().optional().describe("Download URL for the digital file"),
70
+ fileName: z.string().optional().describe("Display name for the file"),
71
+ fileSize: z.number().optional().describe("File size in bytes"),
72
+ licenseKey: z
73
+ .string()
74
+ .optional()
75
+ .describe("License or activation key"),
76
+ instructions: z
77
+ .string()
78
+ .optional()
79
+ .describe("Setup or access instructions for the customer"),
80
+ textContent: z
81
+ .string()
82
+ .optional()
83
+ .describe("Inline text content delivered directly to the customer"),
84
+ })
85
+ .optional()
86
+ .describe("Digital delivery content — auto-delivered after payment");
87
+ // ============================================================================
88
+ // Server Setup
89
+ // ============================================================================
90
+ const server = new McpServer({
91
+ name: "inventpay",
92
+ version: "1.0.0",
93
+ });
94
+ // ============================================================================
95
+ // PAYMENT TOOLS
96
+ // ============================================================================
97
+ server.tool("create_payment", "Create a crypto payment. Returns a unique wallet address, QR code, and invoice URL for the customer to pay.", {
98
+ amount: z.number().describe("Payment amount"),
99
+ amountCurrency: z
100
+ .enum(["USD", "USDT", "BTC", "LTC", "ETH"])
101
+ .default("USDT")
102
+ .describe("Currency the amount is denominated in"),
103
+ currency: z
104
+ .enum(["BTC", "ETH", "LTC", "USDT_ERC20", "USDT_BEP20"])
105
+ .describe("Cryptocurrency the customer will pay with"),
106
+ orderId: z
107
+ .string()
108
+ .optional()
109
+ .describe("Your internal order/reference ID"),
110
+ description: z
111
+ .string()
112
+ .optional()
113
+ .describe("Payment description shown to the customer"),
114
+ callbackUrl: z
115
+ .string()
116
+ .optional()
117
+ .describe("Webhook URL for payment status notifications"),
118
+ expirationMinutes: z
119
+ .number()
120
+ .optional()
121
+ .describe("Payment expiration in minutes (5-1440, default 30)"),
122
+ }, async (params) => callApi("POST", "/v1/create_payment", params));
123
+ server.tool("create_invoice", "Create a multi-currency invoice. The customer can choose which cryptocurrency to pay with. Returns an invoice URL.", {
124
+ amount: z.number().describe("Invoice amount"),
125
+ amountCurrency: z
126
+ .enum(["USD", "USDT", "BTC", "LTC", "ETH"])
127
+ .default("USDT")
128
+ .describe("Currency the amount is denominated in"),
129
+ orderId: z
130
+ .string()
131
+ .optional()
132
+ .describe("Your internal order/reference ID"),
133
+ description: z
134
+ .string()
135
+ .optional()
136
+ .describe("Invoice description"),
137
+ callbackUrl: z
138
+ .string()
139
+ .optional()
140
+ .describe("Webhook URL for payment status notifications"),
141
+ expirationMinutes: z
142
+ .number()
143
+ .optional()
144
+ .describe("Invoice expiration in minutes (5-1440, default 60)"),
145
+ }, async (params) => callApi("POST", "/v1/create_invoice", params));
146
+ server.tool("get_payment_status", "Check the current status of a payment or invoice. Returns status, amount, confirmations, and transaction details.", {
147
+ paymentId: z.string().describe("The payment or invoice ID"),
148
+ }, async ({ paymentId }) => callApi("GET", `/v1/invoice/${encodeURIComponent(paymentId)}/status`));
149
+ // ============================================================================
150
+ // BALANCE TOOLS
151
+ // ============================================================================
152
+ server.tool("get_balances", "Get all cryptocurrency balances for your merchant account. Shows available, pending, total earned, and total withdrawn for each currency.", {}, async () => callApi("GET", "/v1/balance"));
153
+ // ============================================================================
154
+ // WITHDRAWAL TOOLS
155
+ // ============================================================================
156
+ server.tool("create_withdrawal", "Create a withdrawal request to send funds to an external wallet address. Requires 2FA if enabled on the account.", {
157
+ amount: z.number().describe("Amount to withdraw"),
158
+ currency: z
159
+ .enum(["BTC", "ETH", "LTC", "USDT_ERC20", "USDT_BEP20"])
160
+ .describe("Cryptocurrency to withdraw"),
161
+ destinationAddress: z
162
+ .string()
163
+ .describe("External wallet address to send funds to"),
164
+ description: z
165
+ .string()
166
+ .optional()
167
+ .describe("Withdrawal description/memo"),
168
+ }, async (params) => callApi("POST", "/v1/merchant/withdrawal/create", params));
169
+ server.tool("get_withdrawal", "Check the status of a withdrawal request. Returns status, amount, transaction hash, and processing details.", {
170
+ withdrawalId: z.string().describe("The withdrawal ID"),
171
+ }, async ({ withdrawalId }) => callApi("GET", `/v1/withdrawal/${encodeURIComponent(withdrawalId)}`));
172
+ // ============================================================================
173
+ // STORE MANAGEMENT TOOLS
174
+ // ============================================================================
175
+ server.tool("create_store", "Create a new merchant storefront. Each merchant gets one store with a unique URL slug. Customers can browse and purchase digital products with crypto.", {
176
+ name: z
177
+ .string()
178
+ .describe("Store name (2-100 characters). A URL slug will be auto-generated."),
179
+ description: z
180
+ .string()
181
+ .optional()
182
+ .describe("Store description (max 1000 characters)"),
183
+ logo: z.string().optional().describe("HTTPS URL for the store logo"),
184
+ banner: z
185
+ .string()
186
+ .optional()
187
+ .describe("HTTPS URL for the store banner image"),
188
+ settings: z
189
+ .record(z.unknown())
190
+ .optional()
191
+ .describe("Custom store settings"),
192
+ }, async (params) => callApi("POST", "/v1/store/manage", params));
193
+ server.tool("get_store", "Get your store details including name, slug, URL, product count, and order count.", {}, async () => callApi("GET", "/v1/store/manage"));
194
+ server.tool("update_store", "Update your store details. Only provided fields are changed.", {
195
+ name: z.string().optional().describe("Store name (2-100 characters)"),
196
+ description: z
197
+ .string()
198
+ .optional()
199
+ .describe("Store description (max 1000 characters)"),
200
+ logo: z.string().optional().describe("HTTPS URL for the store logo"),
201
+ banner: z
202
+ .string()
203
+ .optional()
204
+ .describe("HTTPS URL for the store banner image"),
205
+ isActive: z
206
+ .boolean()
207
+ .optional()
208
+ .describe("Toggle store visibility (true = live, false = hidden)"),
209
+ settings: z
210
+ .record(z.unknown())
211
+ .optional()
212
+ .describe("Custom store settings"),
213
+ }, async (params) => callApi("PUT", "/v1/store/manage", params));
214
+ // ============================================================================
215
+ // PRODUCT TOOLS
216
+ // ============================================================================
217
+ server.tool("create_product", "Add a digital product to your store. Products are priced in USDT and auto-converted to crypto at checkout. Attach digitalContent for automatic delivery after payment.", {
218
+ name: z.string().describe("Product name (1-200 characters)"),
219
+ price: z.number().describe("Price in USDT (0.01 - 1,000,000)"),
220
+ description: z
221
+ .string()
222
+ .optional()
223
+ .describe("Product description (max 5000 characters)"),
224
+ images: z
225
+ .array(z.string())
226
+ .optional()
227
+ .describe("Array of HTTPS image URLs (max 10)"),
228
+ stock: z
229
+ .number()
230
+ .optional()
231
+ .describe("Available quantity. Omit for unlimited stock."),
232
+ variants: z
233
+ .array(z.unknown())
234
+ .optional()
235
+ .describe("Variant options (e.g., size, tier)"),
236
+ metadata: z
237
+ .record(z.unknown())
238
+ .optional()
239
+ .describe("Custom key-value metadata"),
240
+ digitalContent: digitalContentSchema,
241
+ }, async (params) => callApi("POST", "/v1/store/manage/products", params));
242
+ server.tool("list_products", "List all products in your store with optional search and pagination.", {
243
+ page: z.number().optional().describe("Page number (default 1)"),
244
+ limit: z
245
+ .number()
246
+ .optional()
247
+ .describe("Items per page, 1-50 (default 20)"),
248
+ search: z
249
+ .string()
250
+ .optional()
251
+ .describe("Search products by name"),
252
+ }, async (params) => callApi("GET", `/v1/store/manage/products${buildQuery(params)}`));
253
+ server.tool("update_product", "Update a product in your store. Only provided fields are changed. Updating the name regenerates the slug.", {
254
+ id: z.string().describe("Product ID"),
255
+ name: z.string().optional().describe("Product name (1-200 characters)"),
256
+ price: z
257
+ .number()
258
+ .optional()
259
+ .describe("Price in USDT (0.01 - 1,000,000)"),
260
+ description: z
261
+ .string()
262
+ .optional()
263
+ .describe("Product description (max 5000 characters)"),
264
+ images: z
265
+ .array(z.string())
266
+ .optional()
267
+ .describe("Array of HTTPS image URLs (max 10)"),
268
+ stock: z
269
+ .number()
270
+ .optional()
271
+ .describe("Available quantity (0-999,999)"),
272
+ isActive: z
273
+ .boolean()
274
+ .optional()
275
+ .describe("Toggle product visibility"),
276
+ sortOrder: z
277
+ .number()
278
+ .optional()
279
+ .describe("Display order (0-9999)"),
280
+ metadata: z
281
+ .record(z.unknown())
282
+ .optional()
283
+ .describe("Custom key-value metadata"),
284
+ digitalContent: digitalContentSchema,
285
+ }, async ({ id, ...body }) => callApi("PUT", `/v1/store/manage/products/${encodeURIComponent(id)}`, body));
286
+ server.tool("delete_product", "Deactivate a product from your store. Products with existing orders are soft-deleted (hidden, not removed).", {
287
+ id: z.string().describe("Product ID to deactivate"),
288
+ }, async ({ id }) => callApi("DELETE", `/v1/store/manage/products/${encodeURIComponent(id)}`));
289
+ // ============================================================================
290
+ // ORDER TOOLS
291
+ // ============================================================================
292
+ server.tool("list_orders", "List all orders for your store with optional status filter and pagination.", {
293
+ page: z.number().optional().describe("Page number (default 1)"),
294
+ limit: z
295
+ .number()
296
+ .optional()
297
+ .describe("Items per page, 1-50 (default 20)"),
298
+ status: z
299
+ .enum([
300
+ "PENDING",
301
+ "PAID",
302
+ "PROCESSING",
303
+ "SHIPPED",
304
+ "COMPLETED",
305
+ "CANCELLED",
306
+ "REFUNDED",
307
+ ])
308
+ .optional()
309
+ .describe("Filter by order status"),
310
+ }, async (params) => callApi("GET", `/v1/store/manage/orders${buildQuery(params)}`));
311
+ server.tool("get_order", "Get full details of a specific order including items, payment status, customer info, and timestamps.", {
312
+ id: z.string().describe("Order ID"),
313
+ }, async ({ id }) => callApi("GET", `/v1/store/manage/orders/${encodeURIComponent(id)}`));
314
+ server.tool("update_order_status", "Update the fulfillment status of an order. Valid transitions: PAID→PROCESSING, PROCESSING→SHIPPED/COMPLETED, SHIPPED→COMPLETED, COMPLETED→REFUNDED. Digital orders auto-transition to COMPLETED.", {
315
+ id: z.string().describe("Order ID"),
316
+ status: z
317
+ .enum([
318
+ "PROCESSING",
319
+ "SHIPPED",
320
+ "COMPLETED",
321
+ "CANCELLED",
322
+ "REFUNDED",
323
+ ])
324
+ .describe("New order status"),
325
+ notes: z
326
+ .string()
327
+ .optional()
328
+ .describe("Optional notes about this status change"),
329
+ }, async ({ id, ...body }) => callApi("PUT", `/v1/store/manage/orders/${encodeURIComponent(id)}/status`, body));
330
+ // ============================================================================
331
+ // ANALYTICS TOOL
332
+ // ============================================================================
333
+ server.tool("get_store_analytics", "Get store analytics: total orders, revenue breakdown by status, product count, and recent order activity.", {}, async () => {
334
+ if (!API_KEY) {
335
+ return {
336
+ content: [
337
+ {
338
+ type: "text",
339
+ text: JSON.stringify({
340
+ success: false,
341
+ error: "INVENTPAY_API_KEY is not configured.",
342
+ }),
343
+ },
344
+ ],
345
+ };
346
+ }
347
+ try {
348
+ const headers = {
349
+ "X-API-Key": API_KEY,
350
+ "Content-Type": "application/json",
351
+ };
352
+ // Fetch store info and orders in parallel
353
+ const [storeRes, ordersRes] = await Promise.all([
354
+ fetch(`${BASE_URL}/v1/store/manage`, { headers }),
355
+ fetch(`${BASE_URL}/v1/store/manage/orders?limit=50`, { headers }),
356
+ ]);
357
+ const storeData = await storeRes.json();
358
+ const ordersData = await ordersRes.json();
359
+ if (!storeData.success) {
360
+ return {
361
+ content: [
362
+ { type: "text", text: JSON.stringify(storeData, null, 2) },
363
+ ],
364
+ };
365
+ }
366
+ // Compute analytics from orders
367
+ const orders = ordersData.data?.orders || [];
368
+ const statusCounts = {};
369
+ let totalRevenue = 0;
370
+ let paidRevenue = 0;
371
+ for (const order of orders) {
372
+ const status = order.status || "UNKNOWN";
373
+ statusCounts[status] = (statusCounts[status] || 0) + 1;
374
+ const amount = parseFloat(order.total || "0");
375
+ totalRevenue += amount;
376
+ if (status === "PAID" ||
377
+ status === "COMPLETED" ||
378
+ status === "PROCESSING" ||
379
+ status === "SHIPPED") {
380
+ paidRevenue += amount;
381
+ }
382
+ }
383
+ const analytics = {
384
+ success: true,
385
+ data: {
386
+ store: {
387
+ name: storeData.data?.name,
388
+ slug: storeData.data?.slug,
389
+ isActive: storeData.data?.isActive,
390
+ url: `https://inventpay.io/store/${storeData.data?.slug}`,
391
+ },
392
+ orders: {
393
+ total: ordersData.data?.pagination?.total || orders.length,
394
+ byStatus: statusCounts,
395
+ recentCount: orders.length,
396
+ },
397
+ revenue: {
398
+ totalUSDT: totalRevenue.toFixed(2),
399
+ confirmedUSDT: paidRevenue.toFixed(2),
400
+ currency: "USDT",
401
+ },
402
+ products: {
403
+ total: storeData.data?._count?.products || null,
404
+ },
405
+ },
406
+ };
407
+ return {
408
+ content: [
409
+ { type: "text", text: JSON.stringify(analytics, null, 2) },
410
+ ],
411
+ };
412
+ }
413
+ catch (error) {
414
+ const message = error instanceof Error ? error.message : "Unknown error";
415
+ return {
416
+ content: [
417
+ {
418
+ type: "text",
419
+ text: JSON.stringify({
420
+ success: false,
421
+ error: `Analytics failed: ${message}`,
422
+ }),
423
+ },
424
+ ],
425
+ };
426
+ }
427
+ });
428
+ // ============================================================================
429
+ // Start Server
430
+ // ============================================================================
431
+ async function main() {
432
+ const transport = new StdioServerTransport();
433
+ await server.connect(transport);
434
+ console.error("InventPay MCP Server running on stdio");
435
+ }
436
+ main().catch((error) => {
437
+ console.error("Fatal error:", error);
438
+ process.exit(1);
439
+ });
440
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAEA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AACjF,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,+EAA+E;AAC/E,gBAAgB;AAChB,+EAA+E;AAE/E,MAAM,OAAO,GAAG,OAAO,CAAC,GAAG,CAAC,iBAAiB,CAAC;AAC9C,MAAM,QAAQ,GACZ,OAAO,CAAC,GAAG,CAAC,kBAAkB,IAAI,0BAA0B,CAAC;AAE/D,IAAI,C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AO,EAAE;qBACtC,CAAC;iBACH;aACF;SACF,CAAC;IACJ,CAAC;AACH,CAAC,CACF,CAAC;AAEF,+EAA+E;AAC/E,eAAe;AACf,+EAA+E;AAE/E,KAAK,UAAU,IAAI;IACjB,MAAM,SAAS,GAAG,IAAI,oBAAoB,EAAE,CAAC;IAC7C,MAAM,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;IAChC,OAAO,CAAC,KAAK,CAAC,uCAAuC,CAAC,CAAC;AACzD,CAAC;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,CAAC,KAAK,EAAE,EAAE;IACrB,OAAO,CAAC,KAAK,CAAC,cAAc,EAAE,KAAK,CAAC,CAAC;IACrC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC"}
package/package.json ADDED
@@ -0,0 +1,39 @@
1
+ {
2
+ "name": "inventpay-mcp",
3
+ "version": "1.0.0",
4
+ "description": "InventPay MCP Server - Give AI agents the ability to manage crypto payments, stores, products, and orders",
5
+ "type": "module",
6
+ "main": "dist/index.js",
7
+ "bin": {
8
+ "inventpay-mcp": "dist/index.js"
9
+ },
10
+ "scripts": {
11
+ "build": "tsc && chmod 755 dist/index.js",
12
+ "start": "node dist/index.js",
13
+ "dev": "tsc --watch"
14
+ },
15
+ "files": [
16
+ "dist"
17
+ ],
18
+ "keywords": [
19
+ "inventpay",
20
+ "mcp",
21
+ "model-context-protocol",
22
+ "crypto",
23
+ "payments",
24
+ "ai-agents",
25
+ "claude",
26
+ "cursor",
27
+ "windsurf"
28
+ ],
29
+ "author": "InventPay",
30
+ "license": "MIT",
31
+ "dependencies": {
32
+ "@modelcontextprotocol/sdk": "^1.12.1",
33
+ "zod": "^3.24.0"
34
+ },
35
+ "devDependencies": {
36
+ "@types/node": "^22.0.0",
37
+ "typescript": "^5.7.0"
38
+ }
39
+ }