suzi-cli 0.1.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/dist/commands/agents.d.ts +3 -0
- package/dist/commands/agents.d.ts.map +1 -0
- package/dist/commands/agents.js +274 -0
- package/dist/commands/agents.js.map +1 -0
- package/dist/commands/deploy.d.ts +3 -0
- package/dist/commands/deploy.d.ts.map +1 -0
- package/dist/commands/deploy.js +149 -0
- package/dist/commands/deploy.js.map +1 -0
- package/dist/commands/import.d.ts +3 -0
- package/dist/commands/import.d.ts.map +1 -0
- package/dist/commands/import.js +70 -0
- package/dist/commands/import.js.map +1 -0
- package/dist/commands/list-tools.d.ts +3 -0
- package/dist/commands/list-tools.d.ts.map +1 -0
- package/dist/commands/list-tools.js +163 -0
- package/dist/commands/list-tools.js.map +1 -0
- package/dist/commands/login.d.ts +13 -0
- package/dist/commands/login.d.ts.map +1 -0
- package/dist/commands/login.js +311 -0
- package/dist/commands/login.js.map +1 -0
- package/dist/commands/portfolio.d.ts +3 -0
- package/dist/commands/portfolio.d.ts.map +1 -0
- package/dist/commands/portfolio.js +170 -0
- package/dist/commands/portfolio.js.map +1 -0
- package/dist/commands/preferences.d.ts +3 -0
- package/dist/commands/preferences.d.ts.map +1 -0
- package/dist/commands/preferences.js +121 -0
- package/dist/commands/preferences.js.map +1 -0
- package/dist/commands/prompt-suggestions.d.ts +3 -0
- package/dist/commands/prompt-suggestions.d.ts.map +1 -0
- package/dist/commands/prompt-suggestions.js +148 -0
- package/dist/commands/prompt-suggestions.js.map +1 -0
- package/dist/commands/skills.d.ts +3 -0
- package/dist/commands/skills.d.ts.map +1 -0
- package/dist/commands/skills.js +571 -0
- package/dist/commands/skills.js.map +1 -0
- package/dist/commands/subagents.d.ts +3 -0
- package/dist/commands/subagents.d.ts.map +1 -0
- package/dist/commands/subagents.js +194 -0
- package/dist/commands/subagents.js.map +1 -0
- package/dist/commands/transactions.d.ts +3 -0
- package/dist/commands/transactions.d.ts.map +1 -0
- package/dist/commands/transactions.js +153 -0
- package/dist/commands/transactions.js.map +1 -0
- package/dist/commands/wallet.d.ts +3 -0
- package/dist/commands/wallet.d.ts.map +1 -0
- package/dist/commands/wallet.js +183 -0
- package/dist/commands/wallet.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +95 -0
- package/dist/index.js.map +1 -0
- package/dist/lib/api.d.ts +12 -0
- package/dist/lib/api.d.ts.map +1 -0
- package/dist/lib/api.js +82 -0
- package/dist/lib/api.js.map +1 -0
- package/dist/lib/config.d.ts +42 -0
- package/dist/lib/config.d.ts.map +1 -0
- package/dist/lib/config.js +85 -0
- package/dist/lib/config.js.map +1 -0
- package/dist/utils/ui.d.ts +26 -0
- package/dist/utils/ui.d.ts.map +1 -0
- package/dist/utils/ui.js +111 -0
- package/dist/utils/ui.js.map +1 -0
- package/package.json +46 -0
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.registerListToolsCommand = registerListToolsCommand;
|
|
7
|
+
const chalk_1 = __importDefault(require("chalk"));
|
|
8
|
+
const ui_1 = require("../utils/ui");
|
|
9
|
+
const PROTOCOLS = [
|
|
10
|
+
{
|
|
11
|
+
name: 'polymarket',
|
|
12
|
+
description: 'Prediction markets trading on Polygon',
|
|
13
|
+
chain: 'EVM',
|
|
14
|
+
actions: [
|
|
15
|
+
{ name: 'place_order', type: 'write', description: 'Place a limit or market order' },
|
|
16
|
+
{ name: 'cancel_order', type: 'write', description: 'Cancel a single order' },
|
|
17
|
+
{ name: 'cancel_all_orders', type: 'write', description: 'Cancel all open orders' },
|
|
18
|
+
{ name: 'cancel_market_orders', type: 'write', description: 'Cancel orders for a market' },
|
|
19
|
+
{ name: 'post_orders_batch', type: 'write', description: 'Place multiple orders at once' },
|
|
20
|
+
{ name: 'set_allowances', type: 'write', description: 'Set token allowances' },
|
|
21
|
+
{ name: 'split_position', type: 'write', description: 'Split conditional tokens' },
|
|
22
|
+
{ name: 'merge_positions', type: 'write', description: 'Merge conditional tokens' },
|
|
23
|
+
{ name: 'redeem_positions', type: 'write', description: 'Redeem resolved positions' },
|
|
24
|
+
{ name: 'list_markets', type: 'read', description: 'List available markets' },
|
|
25
|
+
{ name: 'get_market_by_id', type: 'read', description: 'Get market details' },
|
|
26
|
+
{ name: 'get_market_by_slug', type: 'read', description: 'Get market by slug' },
|
|
27
|
+
{ name: 'list_events', type: 'read', description: 'List prediction events' },
|
|
28
|
+
{ name: 'public_search', type: 'read', description: 'Search markets and events' },
|
|
29
|
+
{ name: 'get_positions', type: 'read', description: 'Get wallet positions' },
|
|
30
|
+
{ name: 'get_trades', type: 'read', description: 'Get trade history' },
|
|
31
|
+
{ name: 'get_open_orders', type: 'read', description: 'Get open orders' },
|
|
32
|
+
{ name: 'get_my_trades', type: 'read', description: 'Get your trade history' },
|
|
33
|
+
],
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
name: 'hyperliquid',
|
|
37
|
+
description: 'Perpetual futures & spot trading',
|
|
38
|
+
chain: 'EVM',
|
|
39
|
+
actions: [
|
|
40
|
+
{ name: 'place_order', type: 'write', description: 'Place a perp order' },
|
|
41
|
+
{ name: 'cancel_order', type: 'write', description: 'Cancel a perp order' },
|
|
42
|
+
{ name: 'close_position', type: 'write', description: 'Close an open position' },
|
|
43
|
+
{ name: 'set_leverage', type: 'write', description: 'Set leverage for a market' },
|
|
44
|
+
{ name: 'twap_order', type: 'write', description: 'Place a TWAP order' },
|
|
45
|
+
{ name: 'scaled_orders', type: 'write', description: 'Place scaled orders' },
|
|
46
|
+
{ name: 'usdc_transfer', type: 'write', description: 'Transfer USDC' },
|
|
47
|
+
{ name: 'bridge_to_hyperliquid', type: 'write', description: 'Bridge funds in' },
|
|
48
|
+
{ name: 'bridge_from_hyperliquid', type: 'write', description: 'Bridge funds out' },
|
|
49
|
+
{ name: 'spot_place_order', type: 'write', description: 'Place a spot order' },
|
|
50
|
+
{ name: 'spot_cancel_order', type: 'write', description: 'Cancel a spot order' },
|
|
51
|
+
{ name: 'list_markets', type: 'read', description: 'List perp markets' },
|
|
52
|
+
{ name: 'get_prices', type: 'read', description: 'Get current prices' },
|
|
53
|
+
{ name: 'get_positions', type: 'read', description: 'Get open positions' },
|
|
54
|
+
{ name: 'get_account_info', type: 'read', description: 'Get account state' },
|
|
55
|
+
{ name: 'spot_get_balances', type: 'read', description: 'Get spot balances' },
|
|
56
|
+
{ name: 'spot_list_markets', type: 'read', description: 'List spot markets' },
|
|
57
|
+
],
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
name: 'solana',
|
|
61
|
+
description: 'Solana blockchain read operations',
|
|
62
|
+
chain: 'SOL',
|
|
63
|
+
actions: [
|
|
64
|
+
{ name: 'get_native_balance', type: 'read', description: 'Get SOL balance' },
|
|
65
|
+
{ name: 'get_token_balance', type: 'read', description: 'Get SPL token balance' },
|
|
66
|
+
],
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
name: 'meteora',
|
|
70
|
+
description: 'Meteora DLMM liquidity pools on Solana',
|
|
71
|
+
chain: 'SOL',
|
|
72
|
+
actions: [
|
|
73
|
+
{ name: 'add_liquidity', type: 'write', description: 'Add liquidity to a pool' },
|
|
74
|
+
{ name: 'remove_liquidity', type: 'write', description: 'Remove liquidity' },
|
|
75
|
+
{ name: 'close_position', type: 'write', description: 'Close LP position' },
|
|
76
|
+
{ name: 'list_pools', type: 'read', description: 'List available pools' },
|
|
77
|
+
{ name: 'get_pool_info', type: 'read', description: 'Get pool details' },
|
|
78
|
+
{ name: 'get_active_bin', type: 'read', description: 'Get active bin price' },
|
|
79
|
+
{ name: 'get_all_positions', type: 'read', description: 'Get your LP positions' },
|
|
80
|
+
],
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
name: 'dflow',
|
|
84
|
+
description: 'DEX aggregator swaps on Solana',
|
|
85
|
+
chain: 'SOL',
|
|
86
|
+
actions: [
|
|
87
|
+
{ name: 'swap', type: 'write', description: 'Execute a token swap' },
|
|
88
|
+
{ name: 'get_quote', type: 'read', description: 'Get a swap quote' },
|
|
89
|
+
],
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
name: 'suzi',
|
|
93
|
+
description: 'Platform utilities (storage, logging, notifications)',
|
|
94
|
+
chain: 'N/A',
|
|
95
|
+
actions: [
|
|
96
|
+
{ name: 'set_to_store', type: 'write', description: 'Save key-value data' },
|
|
97
|
+
{ name: 'get_from_store', type: 'read', description: 'Read stored data' },
|
|
98
|
+
{ name: 'log', type: 'write', description: 'Write to agent logs' },
|
|
99
|
+
{ name: 'notify', type: 'write', description: 'Send notification (Telegram)' },
|
|
100
|
+
{ name: 'get_evm_address', type: 'read', description: 'Get agent EVM wallet' },
|
|
101
|
+
{ name: 'get_svm_address', type: 'read', description: 'Get agent SOL wallet' },
|
|
102
|
+
{ name: 'sleep', type: 'write', description: 'Pause execution' },
|
|
103
|
+
],
|
|
104
|
+
},
|
|
105
|
+
];
|
|
106
|
+
function registerListToolsCommand(program) {
|
|
107
|
+
program
|
|
108
|
+
.command('list-tools')
|
|
109
|
+
.alias('tools')
|
|
110
|
+
.description('List all available protocols and actions')
|
|
111
|
+
.option('--protocol <name>', 'Filter by protocol name')
|
|
112
|
+
.option('--verbose', 'Show all actions per protocol')
|
|
113
|
+
.action((opts) => {
|
|
114
|
+
(0, ui_1.header)('Available Tools');
|
|
115
|
+
console.log();
|
|
116
|
+
const filtered = opts.protocol
|
|
117
|
+
? PROTOCOLS.filter((p) => p.name === opts.protocol)
|
|
118
|
+
: PROTOCOLS;
|
|
119
|
+
if (filtered.length === 0) {
|
|
120
|
+
(0, ui_1.info)(`Protocol "${opts.protocol}" not found.`);
|
|
121
|
+
(0, ui_1.info)(`Available: ${PROTOCOLS.map((p) => p.name).join(', ')}`);
|
|
122
|
+
return;
|
|
123
|
+
}
|
|
124
|
+
for (const protocol of filtered) {
|
|
125
|
+
const chainBadge = protocol.chain === 'SOL'
|
|
126
|
+
? ui_1.colors.sol(`[${protocol.chain}]`)
|
|
127
|
+
: protocol.chain === 'EVM'
|
|
128
|
+
? ui_1.colors.evm(`[${protocol.chain}]`)
|
|
129
|
+
: ui_1.colors.muted(`[${protocol.chain}]`);
|
|
130
|
+
console.log(` ${chalk_1.default.bold(protocol.name)} ${chainBadge}`);
|
|
131
|
+
console.log(` ${ui_1.colors.muted(protocol.description)}`);
|
|
132
|
+
if (opts.verbose || opts.protocol) {
|
|
133
|
+
const readActions = protocol.actions.filter((a) => a.type === 'read');
|
|
134
|
+
const writeActions = protocol.actions.filter((a) => a.type === 'write');
|
|
135
|
+
if (writeActions.length > 0) {
|
|
136
|
+
console.log();
|
|
137
|
+
console.log(` ${chalk_1.default.yellow('Write Actions:')}`);
|
|
138
|
+
for (const action of writeActions) {
|
|
139
|
+
console.log(` ${ui_1.colors.highlight(action.name)} ${ui_1.colors.muted(action.description)}`);
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
if (readActions.length > 0) {
|
|
143
|
+
console.log();
|
|
144
|
+
console.log(` ${chalk_1.default.cyan('Read Actions:')}`);
|
|
145
|
+
for (const action of readActions) {
|
|
146
|
+
console.log(` ${ui_1.colors.highlight(action.name)} ${ui_1.colors.muted(action.description)}`);
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
else {
|
|
151
|
+
const writeCount = protocol.actions.filter((a) => a.type === 'write').length;
|
|
152
|
+
const readCount = protocol.actions.filter((a) => a.type === 'read').length;
|
|
153
|
+
console.log(` ${ui_1.colors.muted(`${writeCount} write`)} + ${ui_1.colors.muted(`${readCount} read`)} actions`);
|
|
154
|
+
}
|
|
155
|
+
console.log();
|
|
156
|
+
}
|
|
157
|
+
const totalActions = PROTOCOLS.reduce((sum, p) => sum + p.actions.length, 0);
|
|
158
|
+
(0, ui_1.divider)();
|
|
159
|
+
(0, ui_1.info)(`${PROTOCOLS.length} protocols, ${totalActions} total actions`);
|
|
160
|
+
(0, ui_1.info)('Use --verbose or --protocol <name> for details.');
|
|
161
|
+
});
|
|
162
|
+
}
|
|
163
|
+
//# sourceMappingURL=list-tools.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list-tools.js","sourceRoot":"","sources":["../../src/commands/list-tools.ts"],"names":[],"mappings":";;;;;AA8GA,4DAmEC;AAhLD,kDAA0B;AAE1B,oCAA4D;AAS5D,MAAM,SAAS,GAAmB;IAChC;QACE,IAAI,EAAE,YAAY;QAClB,WAAW,EAAE,uCAAuC;QACpD,KAAK,EAAE,KAAK;QACZ,OAAO,EAAE;YACP,EAAE,IAAI,EAAE,aAAa,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,+BAA+B,EAAE;YACpF,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,uBAAuB,EAAE;YAC7E,EAAE,IAAI,EAAE,mBAAmB,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,wBAAwB,EAAE;YACnF,EAAE,IAAI,EAAE,sBAAsB,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,4BAA4B,EAAE;YAC1F,EAAE,IAAI,EAAE,mBAAmB,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,+BAA+B,EAAE;YAC1F,EAAE,IAAI,EAAE,gBAAgB,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,sBAAsB,EAAE;YAC9E,EAAE,IAAI,EAAE,gBAAgB,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,0BAA0B,EAAE;YAClF,EAAE,IAAI,EAAE,iBAAiB,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,0BAA0B,EAAE;YACnF,EAA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M,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,MAAM,CAAC,CAAC,MAAM,CAAC;gBAC3E,OAAO,CAAC,GAAG,CACT,KAAK,WAAM,CAAC,KAAK,CAAC,GAAG,UAAU,QAAQ,CAAC,MAAM,WAAM,CAAC,KAAK,CAAC,GAAG,SAAS,OAAO,CAAC,UAAU,CAC1F,CAAC;YACJ,CAAC;YAED,OAAO,CAAC,GAAG,EAAE,CAAC;QAChB,CAAC;QAED,MAAM,YAAY,GAAG,SAAS,CAAC,MAAM,CAAC,CAAC,GAAG,EAAE,CAAC,EAAE,EAAE,CAAC,GAAG,GAAG,CAAC,CAAC,OAAO,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC;QAC7E,IAAA,YAAO,GAAE,CAAC;QACV,IAAA,SAAI,EAAC,GAAG,SAAS,CAAC,MAAM,eAAe,YAAY,gBAAgB,CAAC,CAAC;QACrE,IAAA,SAAI,EAAC,iDAAiD,CAAC,CAAC;IAC1D,CAAC,CAAC,CAAC;AACP,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
/**
|
|
3
|
+
* OAuth Login via Web App redirect.
|
|
4
|
+
*
|
|
5
|
+
* Flow:
|
|
6
|
+
* 1. Start a local HTTP server to receive the callback
|
|
7
|
+
* 2. Open browser to web app's /cli/auth page with callback URL
|
|
8
|
+
* 3. Web app handles Privy authentication and redirects back with identity token
|
|
9
|
+
* 4. CLI sends token to Suzi API /api/user/verify
|
|
10
|
+
* 5. API returns JWT + user data, CLI stores credentials locally
|
|
11
|
+
*/
|
|
12
|
+
export declare function registerLoginCommand(program: Command): void;
|
|
13
|
+
//# sourceMappingURL=login.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"login.d.ts","sourceRoot":"","sources":["../../src/commands/login.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAUpC;;;;;;;;;GASG;AACH,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,OAAO,GAAG,IAAI,CAyI3D"}
|
|
@@ -0,0 +1,311 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.registerLoginCommand = registerLoginCommand;
|
|
7
|
+
const chalk_1 = __importDefault(require("chalk"));
|
|
8
|
+
const ora_1 = __importDefault(require("ora"));
|
|
9
|
+
const open_1 = __importDefault(require("open"));
|
|
10
|
+
const express_1 = __importDefault(require("express"));
|
|
11
|
+
const qrcode_terminal_1 = __importDefault(require("qrcode-terminal"));
|
|
12
|
+
const config_1 = require("../lib/config");
|
|
13
|
+
const api_1 = require("../lib/api");
|
|
14
|
+
const ui_1 = require("../utils/ui");
|
|
15
|
+
/**
|
|
16
|
+
* OAuth Login via Web App redirect.
|
|
17
|
+
*
|
|
18
|
+
* Flow:
|
|
19
|
+
* 1. Start a local HTTP server to receive the callback
|
|
20
|
+
* 2. Open browser to web app's /cli/auth page with callback URL
|
|
21
|
+
* 3. Web app handles Privy authentication and redirects back with identity token
|
|
22
|
+
* 4. CLI sends token to Suzi API /api/user/verify
|
|
23
|
+
* 5. API returns JWT + user data, CLI stores credentials locally
|
|
24
|
+
*/
|
|
25
|
+
function registerLoginCommand(program) {
|
|
26
|
+
program
|
|
27
|
+
.command('login')
|
|
28
|
+
.description('Sign in to Suzi with Google (OAuth2.0)')
|
|
29
|
+
.option('--api-url <url>', 'Override API URL')
|
|
30
|
+
.option('--web-url <url>', 'Override Web App URL')
|
|
31
|
+
.action(async (opts) => {
|
|
32
|
+
console.log((0, ui_1.logo)());
|
|
33
|
+
(0, ui_1.header)('Sign in to Suzi');
|
|
34
|
+
console.log();
|
|
35
|
+
if (opts.apiUrl) {
|
|
36
|
+
const { setApiUrl } = require('../lib/config');
|
|
37
|
+
setApiUrl(opts.apiUrl);
|
|
38
|
+
}
|
|
39
|
+
if (opts.webUrl) {
|
|
40
|
+
(0, config_1.setWebUrl)(opts.webUrl);
|
|
41
|
+
}
|
|
42
|
+
const config = (0, config_1.getConfig)();
|
|
43
|
+
(0, ui_1.info)(`API endpoint: ${config.apiUrl}`);
|
|
44
|
+
(0, ui_1.info)(`Web app: ${config.webUrl}`);
|
|
45
|
+
console.log();
|
|
46
|
+
const port = await findFreePort(9876);
|
|
47
|
+
const callbackUrl = `http://localhost:${port}/callback`;
|
|
48
|
+
const spinner = (0, ora_1.default)('Waiting for browser authentication...').start();
|
|
49
|
+
try {
|
|
50
|
+
const token = await startCallbackServer(port, callbackUrl, config.webUrl, spinner);
|
|
51
|
+
spinner.text = 'Verifying with Suzi API...';
|
|
52
|
+
const response = await (0, api_1.post)('/api/user/verify', { token });
|
|
53
|
+
if (!response.ok) {
|
|
54
|
+
spinner.fail();
|
|
55
|
+
(0, ui_1.error)(`Authentication failed: ${response.data?.error || response.data?.message || 'Unknown error'}`);
|
|
56
|
+
process.exit(1);
|
|
57
|
+
}
|
|
58
|
+
const { accessToken, user, accounts, activeAccountId } = response.data;
|
|
59
|
+
// Store credentials
|
|
60
|
+
(0, config_1.setToken)(accessToken);
|
|
61
|
+
(0, config_1.setUser)(user);
|
|
62
|
+
(0, config_1.setAccounts)(accounts.map((a) => ({
|
|
63
|
+
id: a.id,
|
|
64
|
+
name: a.name,
|
|
65
|
+
svmWalletAddress: a.svmWalletAddress,
|
|
66
|
+
evmWalletAddress: a.evmWalletAddress,
|
|
67
|
+
})));
|
|
68
|
+
(0, config_1.setActiveAccountId)(activeAccountId);
|
|
69
|
+
spinner.succeed('Authenticated successfully!');
|
|
70
|
+
console.log();
|
|
71
|
+
(0, ui_1.divider)();
|
|
72
|
+
(0, ui_1.label)('User', user.email || user.id);
|
|
73
|
+
(0, ui_1.label)('Account', accounts.find((a) => a.id === activeAccountId)?.name || 'Default');
|
|
74
|
+
const activeAcc = accounts.find((a) => a.id === activeAccountId);
|
|
75
|
+
if (activeAcc?.svmWalletAddress) {
|
|
76
|
+
(0, ui_1.label)('SOL Wallet', (0, ui_1.truncateAddress)(activeAcc.svmWalletAddress));
|
|
77
|
+
}
|
|
78
|
+
if (activeAcc?.evmWalletAddress) {
|
|
79
|
+
(0, ui_1.label)('EVM Wallet', activeAcc.evmWalletAddress);
|
|
80
|
+
}
|
|
81
|
+
(0, ui_1.divider)();
|
|
82
|
+
console.log();
|
|
83
|
+
// Onboarding: show wallet QR and wait for deposit
|
|
84
|
+
if (activeAcc?.svmWalletAddress) {
|
|
85
|
+
await onboardNewUser(activeAcc.svmWalletAddress);
|
|
86
|
+
}
|
|
87
|
+
else {
|
|
88
|
+
(0, ui_1.success)('You are now logged in. Run `suzi --help` to see available commands.');
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
catch (err) {
|
|
92
|
+
spinner.fail('Authentication failed');
|
|
93
|
+
(0, ui_1.error)(err.message);
|
|
94
|
+
process.exit(1);
|
|
95
|
+
}
|
|
96
|
+
});
|
|
97
|
+
program
|
|
98
|
+
.command('logout')
|
|
99
|
+
.description('Sign out and clear stored credentials')
|
|
100
|
+
.action(() => {
|
|
101
|
+
const { clearAuth } = require('../lib/config');
|
|
102
|
+
clearAuth();
|
|
103
|
+
(0, ui_1.success)('Logged out successfully.');
|
|
104
|
+
});
|
|
105
|
+
program
|
|
106
|
+
.command('whoami')
|
|
107
|
+
.description('Show current authenticated user')
|
|
108
|
+
.action(async () => {
|
|
109
|
+
const config = (0, config_1.getConfig)();
|
|
110
|
+
if (!config.accessToken) {
|
|
111
|
+
(0, ui_1.error)('Not logged in. Run `suzi login` first.');
|
|
112
|
+
return;
|
|
113
|
+
}
|
|
114
|
+
const { get } = require('../lib/api');
|
|
115
|
+
const spinner = (0, ora_1.default)('Fetching user info...').start();
|
|
116
|
+
const response = await get('/api/user/me');
|
|
117
|
+
if (!response.ok) {
|
|
118
|
+
spinner.fail();
|
|
119
|
+
(0, ui_1.error)('Session expired. Run `suzi login` to re-authenticate.');
|
|
120
|
+
return;
|
|
121
|
+
}
|
|
122
|
+
spinner.stop();
|
|
123
|
+
const user = response.data;
|
|
124
|
+
const account = config.accounts?.find((a) => a.id === config.activeAccountId);
|
|
125
|
+
(0, ui_1.header)('Current User');
|
|
126
|
+
console.log();
|
|
127
|
+
(0, ui_1.label)('Email', user.email || 'N/A');
|
|
128
|
+
(0, ui_1.label)('User ID', user.id);
|
|
129
|
+
(0, ui_1.label)('Account', account?.name || 'N/A');
|
|
130
|
+
if (account?.svmWalletAddress) {
|
|
131
|
+
(0, ui_1.label)('SOL Wallet', account.svmWalletAddress);
|
|
132
|
+
}
|
|
133
|
+
if (account?.evmWalletAddress) {
|
|
134
|
+
(0, ui_1.label)('EVM Wallet', account.evmWalletAddress);
|
|
135
|
+
}
|
|
136
|
+
if (user.telegramChatId) {
|
|
137
|
+
const { colors } = require('../utils/ui');
|
|
138
|
+
(0, ui_1.label)('Telegram', colors.success('Connected'));
|
|
139
|
+
}
|
|
140
|
+
});
|
|
141
|
+
}
|
|
142
|
+
function generateQR(text) {
|
|
143
|
+
return new Promise((resolve) => {
|
|
144
|
+
qrcode_terminal_1.default.generate(text, { small: true }, (code) => {
|
|
145
|
+
console.log(code);
|
|
146
|
+
resolve();
|
|
147
|
+
});
|
|
148
|
+
});
|
|
149
|
+
}
|
|
150
|
+
async function onboardNewUser(walletAddress) {
|
|
151
|
+
console.log(ui_1.colors.primary.bold(' Fund your wallet to get started'));
|
|
152
|
+
console.log();
|
|
153
|
+
console.log(` ${ui_1.colors.muted('SOL Address:')} ${walletAddress}`);
|
|
154
|
+
console.log();
|
|
155
|
+
await generateQR(walletAddress);
|
|
156
|
+
const spinner = (0, ora_1.default)({
|
|
157
|
+
text: 'Waiting for deposit... (Ctrl+C to skip)',
|
|
158
|
+
spinner: 'dots',
|
|
159
|
+
}).start();
|
|
160
|
+
const POLL_INTERVAL = 5000;
|
|
161
|
+
let deposited = false;
|
|
162
|
+
let balance = 0;
|
|
163
|
+
const onExit = () => {
|
|
164
|
+
spinner.stop();
|
|
165
|
+
console.log();
|
|
166
|
+
(0, ui_1.info)('Skipped deposit check.');
|
|
167
|
+
(0, ui_1.success)('You are now logged in. Run `suzi --help` to see available commands.');
|
|
168
|
+
process.exit(0);
|
|
169
|
+
};
|
|
170
|
+
process.on('SIGINT', onExit);
|
|
171
|
+
try {
|
|
172
|
+
while (!deposited) {
|
|
173
|
+
try {
|
|
174
|
+
const resp = await (0, api_1.post)('/api/actions/execute', {
|
|
175
|
+
name: 'solana.get_native_balance',
|
|
176
|
+
params: { address: walletAddress },
|
|
177
|
+
});
|
|
178
|
+
if (resp.ok && resp.data?.result && resp.data.result.balance > 0) {
|
|
179
|
+
deposited = true;
|
|
180
|
+
balance = resp.data.result.balance;
|
|
181
|
+
break;
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
catch {
|
|
185
|
+
// Network error — keep polling
|
|
186
|
+
}
|
|
187
|
+
await new Promise((r) => setTimeout(r, POLL_INTERVAL));
|
|
188
|
+
}
|
|
189
|
+
spinner.succeed('Deposit received!');
|
|
190
|
+
console.log();
|
|
191
|
+
(0, ui_1.divider)();
|
|
192
|
+
(0, ui_1.label)('SOL Balance', (0, ui_1.formatSol)(balance));
|
|
193
|
+
// Check for USDC too
|
|
194
|
+
try {
|
|
195
|
+
const usdcResp = await (0, api_1.post)('/api/actions/execute', {
|
|
196
|
+
name: 'solana.get_token_balance',
|
|
197
|
+
params: { address: walletAddress, token: 'USDC' },
|
|
198
|
+
});
|
|
199
|
+
if (usdcResp.ok && usdcResp.data?.result && usdcResp.data.result.balance > 0) {
|
|
200
|
+
(0, ui_1.label)('USDC Balance', `${usdcResp.data.result.balance.toFixed(2)} USDC`);
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
catch {
|
|
204
|
+
// Ignore token check errors
|
|
205
|
+
}
|
|
206
|
+
(0, ui_1.divider)();
|
|
207
|
+
console.log();
|
|
208
|
+
(0, ui_1.success)('You\'re all set! Run `suzi --help` to see available commands.');
|
|
209
|
+
}
|
|
210
|
+
finally {
|
|
211
|
+
process.removeListener('SIGINT', onExit);
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
function startCallbackServer(port, callbackUrl, webUrl, spinner) {
|
|
215
|
+
return new Promise((resolve, reject) => {
|
|
216
|
+
const app = (0, express_1.default)();
|
|
217
|
+
let server;
|
|
218
|
+
// Callback endpoint receives the Privy identity token from the web app
|
|
219
|
+
app.get('/callback', (req, res) => {
|
|
220
|
+
const token = req.query.token;
|
|
221
|
+
if (!token) {
|
|
222
|
+
res.status(400).send(errorPage('No token received'));
|
|
223
|
+
reject(new Error('No token received from authentication'));
|
|
224
|
+
return;
|
|
225
|
+
}
|
|
226
|
+
res.send(successPage());
|
|
227
|
+
setTimeout(() => {
|
|
228
|
+
server?.close();
|
|
229
|
+
resolve(token);
|
|
230
|
+
}, 500);
|
|
231
|
+
});
|
|
232
|
+
server = app.listen(port, () => {
|
|
233
|
+
const loginUrl = `${webUrl}/cli/auth?callback=${encodeURIComponent(callbackUrl)}`;
|
|
234
|
+
spinner.text = `Opening browser for sign-in... (${chalk_1.default.underline(loginUrl)})`;
|
|
235
|
+
(0, open_1.default)(loginUrl).catch(() => {
|
|
236
|
+
spinner.text = `Open this URL in your browser: ${chalk_1.default.underline(loginUrl)}`;
|
|
237
|
+
});
|
|
238
|
+
});
|
|
239
|
+
// Timeout after 5 minutes
|
|
240
|
+
setTimeout(() => {
|
|
241
|
+
server?.close();
|
|
242
|
+
reject(new Error('Login timed out. Please try again.'));
|
|
243
|
+
}, 5 * 60 * 1000);
|
|
244
|
+
});
|
|
245
|
+
}
|
|
246
|
+
function findFreePort(preferred) {
|
|
247
|
+
return new Promise((resolve) => {
|
|
248
|
+
const net = require('net');
|
|
249
|
+
const server = net.createServer();
|
|
250
|
+
server.listen(preferred, () => {
|
|
251
|
+
server.close(() => resolve(preferred));
|
|
252
|
+
});
|
|
253
|
+
server.on('error', () => {
|
|
254
|
+
const server2 = net.createServer();
|
|
255
|
+
server2.listen(0, () => {
|
|
256
|
+
const port = server2.address().port;
|
|
257
|
+
server2.close(() => resolve(port));
|
|
258
|
+
});
|
|
259
|
+
});
|
|
260
|
+
});
|
|
261
|
+
}
|
|
262
|
+
function successPage() {
|
|
263
|
+
return `<!DOCTYPE html>
|
|
264
|
+
<html>
|
|
265
|
+
<head>
|
|
266
|
+
<title>Suzi CLI - Success</title>
|
|
267
|
+
<style>
|
|
268
|
+
body {
|
|
269
|
+
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
|
|
270
|
+
background: linear-gradient(135deg, #0f0f23 0%, #1a1a3e 50%, #2d1b69 100%);
|
|
271
|
+
min-height: 100vh;
|
|
272
|
+
display: flex;
|
|
273
|
+
align-items: center;
|
|
274
|
+
justify-content: center;
|
|
275
|
+
color: #fff;
|
|
276
|
+
}
|
|
277
|
+
.container { text-align: center; padding: 2rem; }
|
|
278
|
+
.check {
|
|
279
|
+
font-size: 4rem;
|
|
280
|
+
margin-bottom: 1rem;
|
|
281
|
+
animation: pop 0.4s ease;
|
|
282
|
+
}
|
|
283
|
+
@keyframes pop { 0% { transform: scale(0); } 100% { transform: scale(1); } }
|
|
284
|
+
h2 { margin-bottom: 0.5rem; }
|
|
285
|
+
p { color: #94a3b8; }
|
|
286
|
+
</style>
|
|
287
|
+
</head>
|
|
288
|
+
<body>
|
|
289
|
+
<div class="container">
|
|
290
|
+
<div class="check">✓</div>
|
|
291
|
+
<h2>Authenticated!</h2>
|
|
292
|
+
<p>You can close this window and return to the terminal.</p>
|
|
293
|
+
</div>
|
|
294
|
+
</body>
|
|
295
|
+
</html>`;
|
|
296
|
+
}
|
|
297
|
+
function errorPage(message) {
|
|
298
|
+
return `<!DOCTYPE html>
|
|
299
|
+
<html>
|
|
300
|
+
<head><title>Suzi CLI - Error</title>
|
|
301
|
+
<style>
|
|
302
|
+
body { font-family: sans-serif; background: #0f0f23; color: #fff; display: flex; align-items: center; justify-content: center; min-height: 100vh; }
|
|
303
|
+
.container { text-align: center; padding: 2rem; }
|
|
304
|
+
h2 { color: #ef4444; }
|
|
305
|
+
p { color: #94a3b8; }
|
|
306
|
+
</style>
|
|
307
|
+
</head>
|
|
308
|
+
<body><div class="container"><h2>Authentication Failed</h2><p>${message}</p><p>Please close this window and try again.</p></div></body>
|
|
309
|
+
</html>`;
|
|
310
|
+
}
|
|
311
|
+
//# sourceMappingURL=login.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"login.js","sourceRoot":"","sources":["../../src/commands/login.ts"],"names":[],"mappings":";;;;;AAoBA,oDAyIC;AA5JD,kDAA0B;AAC1B,8CAAsB;AACtB,gDAAwB;AACxB,sDAA8B;AAC9B,sEAAqC;AACrC,0CAAyG;AACzG,oCAAkC;AAClC,oCAAqH;AAErH;;;;;;;;;GASG;AACH,SAAgB,oBAAoB,CAAC,OAAgB;IACnD,OAAO;SACJ,OAAO,CAAC,OAAO,CAAC;SAChB,WAAW,CAAC,wCAAwC,CAAC;SACrD,MAAM,CAAC,iBAAiB,EAAE,kBAAkB,CAAC;SAC7C,MAAM,CAAC,iBAAiB,EAAE,sBAAsB,CAAC;SACjD,MAAM,CAAC,KAAK,EAAE,IAAI,EAAE,EAAE;QACrB,OAAO,CAAC,GAAG,CAAC,IAAA,SAAI,GAAE,CAAC,CAAC;QACpB,IAAA,WAAM,EAAC,iBAAiB,CAAC,CAAC;QAC1B,OAAO,CAAC,GAAG,EAAE,CAAC;QAEd,IAAI,IAAI,CAAC,MAAM,EAAE,CAAC;YAChB,MAAM,EAAE,SAAS,EAAE,GAAG,OAAO,CAAC,eAAe,CAAC,CAAC;YAC/C,SAAS,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;QACzB,CAAC;QACD,IAAI,IAAI,CAAC,MAAM,EAAE,CAAC;YAChB,IAAA,kBAAS,EAA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