@moonpay/cli 0.6.0 → 0.6.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/dist/{chunk-GSAFAKB7.js → chunk-AL5WDHLT.js} +15 -2
- package/dist/chunk-AL5WDHLT.js.map +1 -0
- package/dist/{chunk-DCHEUKV7.js → chunk-P764SORF.js} +16 -12
- package/dist/chunk-P764SORF.js.map +1 -0
- package/dist/index.js +3 -3
- package/dist/{mcp-6IZ4QWFM.js → mcp-PNM25UVD.js} +3 -3
- package/dist/{store-UAGR3DWU.js → store-QVVENVIP.js} +2 -2
- package/package.json +1 -1
- package/skills/moonpay-auth/SKILL.md +24 -4
- package/skills/moonpay-mcp/SKILL.md +3 -2
- package/dist/chunk-DCHEUKV7.js.map +0 -1
- package/dist/chunk-GSAFAKB7.js.map +0 -1
- /package/dist/{mcp-6IZ4QWFM.js.map → mcp-PNM25UVD.js.map} +0 -0
- /package/dist/{store-UAGR3DWU.js.map → store-QVVENVIP.js.map} +0 -0
package/dist/index.js
CHANGED
|
@@ -23,12 +23,12 @@ import {
|
|
|
23
23
|
walletList,
|
|
24
24
|
walletRetrieve,
|
|
25
25
|
x402Request
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-P764SORF.js";
|
|
27
27
|
import {
|
|
28
28
|
KEY_CHAIN_MAP,
|
|
29
29
|
chainSchema,
|
|
30
30
|
findWalletOrThrow
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-AL5WDHLT.js";
|
|
32
32
|
|
|
33
33
|
// src/index.ts
|
|
34
34
|
import { createRequire } from "module";
|
|
@@ -575,7 +575,7 @@ function printUpdateNotice() {
|
|
|
575
575
|
if (notice) process.stderr.write(notice);
|
|
576
576
|
}
|
|
577
577
|
program.command("mcp").description("Start MCP server over stdio (for Claude Desktop, Claude Code, etc.)").action(async () => {
|
|
578
|
-
const { startMcpServer } = await import("./mcp-
|
|
578
|
+
const { startMcpServer } = await import("./mcp-PNM25UVD.js");
|
|
579
579
|
await startMcpServer();
|
|
580
580
|
});
|
|
581
581
|
function getOrCreateGroup(parent, segments) {
|
|
@@ -14,8 +14,8 @@ import {
|
|
|
14
14
|
walletList,
|
|
15
15
|
walletRetrieve,
|
|
16
16
|
x402Request
|
|
17
|
-
} from "./chunk-
|
|
18
|
-
import "./chunk-
|
|
17
|
+
} from "./chunk-P764SORF.js";
|
|
18
|
+
import "./chunk-AL5WDHLT.js";
|
|
19
19
|
|
|
20
20
|
// src/mcp.ts
|
|
21
21
|
import { Server } from "@modelcontextprotocol/sdk/server/index.js";
|
|
@@ -148,4 +148,4 @@ async function startMcpServer() {
|
|
|
148
148
|
export {
|
|
149
149
|
startMcpServer
|
|
150
150
|
};
|
|
151
|
-
//# sourceMappingURL=mcp-
|
|
151
|
+
//# sourceMappingURL=mcp-PNM25UVD.js.map
|
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
removeWallet,
|
|
9
9
|
resolveSigningKey,
|
|
10
10
|
saveWallets
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-AL5WDHLT.js";
|
|
12
12
|
export {
|
|
13
13
|
addWallet,
|
|
14
14
|
findWallet,
|
|
@@ -19,4 +19,4 @@ export {
|
|
|
19
19
|
resolveSigningKey,
|
|
20
20
|
saveWallets
|
|
21
21
|
};
|
|
22
|
-
//# sourceMappingURL=store-
|
|
22
|
+
//# sourceMappingURL=store-QVVENVIP.js.map
|
package/package.json
CHANGED
|
@@ -24,8 +24,11 @@ mp --help
|
|
|
24
24
|
## Auth commands
|
|
25
25
|
|
|
26
26
|
```bash
|
|
27
|
-
# Log in (
|
|
28
|
-
mp login
|
|
27
|
+
# Log in (sends OTP to email)
|
|
28
|
+
mp login --email user@example.com
|
|
29
|
+
|
|
30
|
+
# Verify OTP code
|
|
31
|
+
mp verify --email user@example.com --code 123456
|
|
29
32
|
|
|
30
33
|
# Check current user
|
|
31
34
|
mp user retrieve
|
|
@@ -64,15 +67,32 @@ mp wallet delete --wallet "my-wallet" --confirm
|
|
|
64
67
|
## Workflow
|
|
65
68
|
|
|
66
69
|
1. Run `mp user retrieve` to check if authenticated.
|
|
67
|
-
2. If it fails, run `mp login`
|
|
70
|
+
2. If it fails, run `mp login --email <email>`, then `mp verify --email <email> --code <code>`.
|
|
68
71
|
3. Run `mp wallet list` to see local wallets.
|
|
69
72
|
4. If no wallets, create one: `mp wallet create --name "default"`.
|
|
70
73
|
|
|
74
|
+
## Autonomous login
|
|
75
|
+
|
|
76
|
+
Agents can log in without human intervention if they have access to the user's email. For example, with the `gog` CLI (Google Workspace):
|
|
77
|
+
|
|
78
|
+
```bash
|
|
79
|
+
# 1. Send OTP
|
|
80
|
+
mp login --email user@example.com
|
|
81
|
+
|
|
82
|
+
# 2. Read the OTP code from email
|
|
83
|
+
gog gmail search "Your MoonPay verification code" --max-results 1
|
|
84
|
+
|
|
85
|
+
# 3. Verify with the code
|
|
86
|
+
mp verify --email user@example.com --code <code>
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
This enables fully autonomous agent setup — no human in the loop.
|
|
90
|
+
|
|
71
91
|
## Config locations
|
|
72
92
|
|
|
73
93
|
- **Wallets:** `~/.config/moonpay/wallets.json` (encrypted, AES-256-GCM)
|
|
74
94
|
- **Encryption key:** OS keychain (`moonpay-cli` / `encryption-key`)
|
|
75
|
-
- **Credentials:** `~/.config/moonpay/credentials.json` (
|
|
95
|
+
- **Credentials:** `~/.config/moonpay/credentials.json` (encrypted, AES-256-GCM)
|
|
76
96
|
- **Config:** `~/.config/moonpay/config.json` (base URL, client ID)
|
|
77
97
|
|
|
78
98
|
## Security
|
|
@@ -14,7 +14,8 @@ Configure the MoonPay CLI as an MCP server so Claude Desktop, Claude Code, or an
|
|
|
14
14
|
|
|
15
15
|
```bash
|
|
16
16
|
npm i -g @moonpay/cli
|
|
17
|
-
mp login
|
|
17
|
+
mp login --email user@example.com
|
|
18
|
+
mp verify --email user@example.com --code <code>
|
|
18
19
|
```
|
|
19
20
|
|
|
20
21
|
## Claude Code setup
|
|
@@ -56,7 +57,7 @@ After setup, ask Claude: "What MoonPay tools do you have?" — it should list al
|
|
|
56
57
|
|
|
57
58
|
## Auth
|
|
58
59
|
|
|
59
|
-
The MCP server uses the same credentials as the CLI (`~/.config/moonpay/credentials.json`). Run `mp login` to authenticate.
|
|
60
|
+
The MCP server uses the same credentials as the CLI (`~/.config/moonpay/credentials.json`). Run `mp login --email <email>` then `mp verify --email <email> --code <code>` to authenticate.
|
|
60
61
|
|
|
61
62
|
## Related skills
|
|
62
63
|
|