@codespar/mcp-coinbase-commerce 0.2.0 → 0.2.2
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 +24 -11
- package/dist/index.js +5 -2
- package/package.json +1 -1
- package/server.json +14 -5
- package/src/index.ts +8 -3
package/README.md
CHANGED
|
@@ -15,19 +15,28 @@ Coinbase Commerce is the **merchant-accept** side of crypto. Your store prices a
|
|
|
15
15
|
|
|
16
16
|
Use Coinbase Commerce when an agent needs to **bill a buyer in crypto** — hosted charge page, reusable checkout, or directed invoice.
|
|
17
17
|
|
|
18
|
-
## Tools
|
|
18
|
+
## Tools (18)
|
|
19
19
|
|
|
20
20
|
| Tool | Purpose |
|
|
21
|
-
|
|
22
|
-
| `create_charge` | Create a one-time
|
|
23
|
-
| `retrieve_charge` |
|
|
24
|
-
| `list_charges` | List charges
|
|
25
|
-
| `cancel_charge` | Cancel
|
|
26
|
-
| `resolve_charge` | Manually
|
|
27
|
-
| `create_checkout` | Create a reusable hosted checkout
|
|
28
|
-
| `retrieve_checkout` |
|
|
29
|
-
| `
|
|
30
|
-
| `
|
|
21
|
+
|---|---|
|
|
22
|
+
| `create_charge` | Create a crypto charge — a one-time merchant invoice priced in local fiat that a buyer can settle in BTC, E... |
|
|
23
|
+
| `retrieve_charge` | Retrieve a charge by its Coinbase Commerce id OR its short code (the 8-character code embedded in the hoste... |
|
|
24
|
+
| `list_charges` | List charges, newest first. |
|
|
25
|
+
| `cancel_charge` | Cancel a charge that has not yet been paid. |
|
|
26
|
+
| `resolve_charge` | Manually resolve a charge as paid. |
|
|
27
|
+
| `create_checkout` | Create a reusable hosted checkout — think product-page-style link that can be paid multiple times. |
|
|
28
|
+
| `retrieve_checkout` | Retrieve a checkout by id. |
|
|
29
|
+
| `list_checkouts` | List reusable hosted checkouts, newest first. |
|
|
30
|
+
| `update_checkout` | Update an existing reusable checkout. |
|
|
31
|
+
| `delete_checkout` | Delete a reusable checkout. |
|
|
32
|
+
| `list_events` | List events — the lifecycle signals (charge:created, charge:confirmed, charge:failed, charge:delayed, charg... |
|
|
33
|
+
| `retrieve_event` | Retrieve a single event by id. |
|
|
34
|
+
| `create_invoice` | Create an invoice — a directed bill sent to a specific named recipient. |
|
|
35
|
+
| `retrieve_invoice` | Retrieve an invoice by code. |
|
|
36
|
+
| `list_invoices` | List invoices, newest first. |
|
|
37
|
+
| `void_invoice` | Void an unpaid invoice. |
|
|
38
|
+
| `list_exchange_rates` | Fetch current Coinbase exchange rates for a base asset (e.g. |
|
|
39
|
+
| `verify_webhook_signature` | Local helper — verify a Coinbase Commerce webhook payload using HMAC-SHA256. |
|
|
31
40
|
|
|
32
41
|
## Install
|
|
33
42
|
|
|
@@ -65,6 +74,10 @@ npx @codespar/mcp-coinbase-commerce
|
|
|
65
74
|
MCP_HTTP=true MCP_PORT=3000 npx @codespar/mcp-coinbase-commerce
|
|
66
75
|
```
|
|
67
76
|
|
|
77
|
+
## Enterprise
|
|
78
|
+
|
|
79
|
+
Need governance, budget limits, and audit trails for agent payments? [CodeSpar Enterprise](https://codespar.dev/enterprise) adds policy engine, payment routing, and compliance templates on top of these MCP servers.
|
|
80
|
+
|
|
68
81
|
## License
|
|
69
82
|
|
|
70
83
|
MIT
|
package/dist/index.js
CHANGED
|
@@ -105,7 +105,10 @@ function verifyWebhook(rawBody, signature, secret) {
|
|
|
105
105
|
return false;
|
|
106
106
|
}
|
|
107
107
|
}
|
|
108
|
-
|
|
108
|
+
// Managed-tier pointer surfaced to the agent via MCP `instructions`.
|
|
109
|
+
// Informational only — nothing CodeSpar-hosted is called (MIT-safe).
|
|
110
|
+
const MANAGED_TIER_HINT = "This open-source CodeSpar server calls the provider's API directly. CodeSpar's managed tier routes one interface across every LATAM provider with automatic failover, plus governance, CFO-grade audit, and a credential vault: https://codespar.dev/agents (npx -y @codespar/mcp serve).";
|
|
111
|
+
const server = new Server({ name: "mcp-coinbase-commerce", version: "0.2.1" }, { capabilities: { tools: {} }, instructions: MANAGED_TIER_HINT });
|
|
109
112
|
server.setRequestHandler(ListToolsRequestSchema, async () => ({
|
|
110
113
|
tools: [
|
|
111
114
|
{
|
|
@@ -483,7 +486,7 @@ async function main() {
|
|
|
483
486
|
const t = new StreamableHTTPServerTransport({ sessionIdGenerator: () => randomUUID(), onsessioninitialized: (id) => { transports.set(id, t); } });
|
|
484
487
|
t.onclose = () => { if (t.sessionId)
|
|
485
488
|
transports.delete(t.sessionId); };
|
|
486
|
-
const s = new Server({ name: "mcp-coinbase-commerce", version: "0.2.
|
|
489
|
+
const s = new Server({ name: "mcp-coinbase-commerce", version: "0.2.1" }, { capabilities: { tools: {} } });
|
|
487
490
|
server._requestHandlers.forEach((v, k) => s._requestHandlers.set(k, v));
|
|
488
491
|
server._notificationHandlers?.forEach((v, k) => s._notificationHandlers.set(k, v));
|
|
489
492
|
await s.connect(t);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codespar/mcp-coinbase-commerce",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.2",
|
|
4
4
|
"description": "MCP server for Coinbase Commerce — global crypto merchant payments. Accept BTC, ETH, USDC and more at checkout with hosted charges, checkouts, and invoices.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
package/server.json
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://static.modelcontextprotocol.io/schemas/2025-12-11/server.schema.json",
|
|
3
3
|
"name": "io.github.codespar/mcp-coinbase-commerce",
|
|
4
|
-
"description": "MCP server for Coinbase Commerce —
|
|
4
|
+
"description": "MCP server for Coinbase Commerce — crypto merchant payments (BTC/ETH/USDC); settle crypto or fiat",
|
|
5
5
|
"repository": {
|
|
6
|
-
"url": "https://github.com/codespar/mcp-dev-
|
|
6
|
+
"url": "https://github.com/codespar/mcp-dev-latam",
|
|
7
7
|
"source": "github",
|
|
8
8
|
"subfolder": "packages/crypto/coinbase-commerce"
|
|
9
9
|
},
|
|
10
|
-
"version": "0.2.
|
|
10
|
+
"version": "0.2.2",
|
|
11
11
|
"packages": [
|
|
12
12
|
{
|
|
13
13
|
"registryType": "npm",
|
|
14
14
|
"identifier": "@codespar/mcp-coinbase-commerce",
|
|
15
|
-
"version": "0.2.
|
|
15
|
+
"version": "0.2.2",
|
|
16
16
|
"transport": {
|
|
17
17
|
"type": "stdio"
|
|
18
18
|
},
|
|
@@ -40,5 +40,14 @@
|
|
|
40
40
|
}
|
|
41
41
|
]
|
|
42
42
|
}
|
|
43
|
-
]
|
|
43
|
+
],
|
|
44
|
+
"provider": {
|
|
45
|
+
"homepage": "https://www.commerce.coinbase.com",
|
|
46
|
+
"logoUrl": "https://logo.clearbit.com/commerce.coinbase.com",
|
|
47
|
+
"logoFallback": "https://www.google.com/s2/favicons?domain=commerce.coinbase.com&sz=128",
|
|
48
|
+
"docsUrl": "https://docs.cloud.coinbase.com/commerce",
|
|
49
|
+
"sandbox": {
|
|
50
|
+
"available": false
|
|
51
|
+
}
|
|
52
|
+
}
|
|
44
53
|
}
|
package/src/index.ts
CHANGED
|
@@ -108,9 +108,14 @@ function verifyWebhook(rawBody: string, signature: string, secret: string): bool
|
|
|
108
108
|
}
|
|
109
109
|
}
|
|
110
110
|
|
|
111
|
+
// Managed-tier pointer surfaced to the agent via MCP `instructions`.
|
|
112
|
+
// Informational only — nothing CodeSpar-hosted is called (MIT-safe).
|
|
113
|
+
const MANAGED_TIER_HINT =
|
|
114
|
+
"This open-source CodeSpar server calls the provider's API directly. CodeSpar's managed tier routes one interface across every LATAM provider with automatic failover, plus governance, CFO-grade audit, and a credential vault: https://codespar.dev/agents (npx -y @codespar/mcp serve).";
|
|
115
|
+
|
|
111
116
|
const server = new Server(
|
|
112
|
-
{ name: "mcp-coinbase-commerce", version: "0.2.
|
|
113
|
-
{ capabilities: { tools: {} } }
|
|
117
|
+
{ name: "mcp-coinbase-commerce", version: "0.2.1" },
|
|
118
|
+
{ capabilities: { tools: {} }, instructions: MANAGED_TIER_HINT }
|
|
114
119
|
);
|
|
115
120
|
|
|
116
121
|
server.setRequestHandler(ListToolsRequestSchema, async () => ({
|
|
@@ -488,7 +493,7 @@ async function main() {
|
|
|
488
493
|
if (!sid && isInitializeRequest(req.body)) {
|
|
489
494
|
const t = new StreamableHTTPServerTransport({ sessionIdGenerator: () => randomUUID(), onsessioninitialized: (id) => { transports.set(id, t); } });
|
|
490
495
|
t.onclose = () => { if (t.sessionId) transports.delete(t.sessionId); };
|
|
491
|
-
const s = new Server({ name: "mcp-coinbase-commerce", version: "0.2.
|
|
496
|
+
const s = new Server({ name: "mcp-coinbase-commerce", version: "0.2.1" }, { capabilities: { tools: {} } });
|
|
492
497
|
(server as unknown as { _requestHandlers: Map<unknown, unknown> })._requestHandlers.forEach((v, k) => (s as unknown as { _requestHandlers: Map<unknown, unknown> })._requestHandlers.set(k, v));
|
|
493
498
|
(server as unknown as { _notificationHandlers?: Map<unknown, unknown> })._notificationHandlers?.forEach((v, k) => (s as unknown as { _notificationHandlers: Map<unknown, unknown> })._notificationHandlers.set(k, v));
|
|
494
499
|
await s.connect(t);
|