@aiassesstech/nole 0.1.9 → 0.2.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.
Files changed (42) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/README.md +149 -39
  3. package/agent/AGENTS.md +53 -0
  4. package/agent/IDENTITY.md +4 -2
  5. package/agent/SOUL.md +45 -4
  6. package/dist/cli/configure.d.ts +36 -0
  7. package/dist/cli/configure.d.ts.map +1 -0
  8. package/dist/cli/configure.js +243 -0
  9. package/dist/cli/configure.js.map +1 -0
  10. package/dist/cli/runner.d.ts +4 -3
  11. package/dist/cli/runner.d.ts.map +1 -1
  12. package/dist/cli/runner.js +81 -27
  13. package/dist/cli/runner.js.map +1 -1
  14. package/dist/compsi/api-client.d.ts +62 -0
  15. package/dist/compsi/api-client.d.ts.map +1 -0
  16. package/dist/compsi/api-client.js +147 -0
  17. package/dist/compsi/api-client.js.map +1 -0
  18. package/dist/plugin.d.ts.map +1 -1
  19. package/dist/plugin.js +320 -38
  20. package/dist/plugin.js.map +1 -1
  21. package/dist/types/nole-config.d.ts +12 -3
  22. package/dist/types/nole-config.d.ts.map +1 -1
  23. package/dist/types/nole-config.js +6 -2
  24. package/dist/types/nole-config.js.map +1 -1
  25. package/dist/wallet/coinbase-adapter.d.ts +38 -0
  26. package/dist/wallet/coinbase-adapter.d.ts.map +1 -0
  27. package/dist/wallet/coinbase-adapter.js +191 -0
  28. package/dist/wallet/coinbase-adapter.js.map +1 -0
  29. package/dist/wallet/index.d.ts +20 -0
  30. package/dist/wallet/index.d.ts.map +1 -0
  31. package/dist/wallet/index.js +34 -0
  32. package/dist/wallet/index.js.map +1 -0
  33. package/dist/wallet/mock-adapter.d.ts +23 -0
  34. package/dist/wallet/mock-adapter.d.ts.map +1 -0
  35. package/dist/wallet/mock-adapter.js +62 -0
  36. package/dist/wallet/mock-adapter.js.map +1 -0
  37. package/dist/wallet/types.d.ts +30 -0
  38. package/dist/wallet/types.d.ts.map +1 -0
  39. package/dist/wallet/types.js +8 -0
  40. package/dist/wallet/types.js.map +1 -0
  41. package/openclaw.plugin.json +19 -0
  42. package/package.json +10 -2
@@ -0,0 +1,38 @@
1
+ /**
2
+ * Coinbase CDP Wallet Adapter
3
+ *
4
+ * Nole's real wallet powered by Coinbase Developer Platform Server Wallet v2.
5
+ * Creates and manages an MPC-secured EVM account on Base (Sepolia or Mainnet).
6
+ * Handles USDC transfers and approvals for the AgentSubscriptionRegistry contract.
7
+ *
8
+ * @see SPEC-AGENT-CRYPTO-SUBSCRIPTIONS-1.0.md
9
+ */
10
+ import type { WalletAdapter, WalletBalance, TransactionResult } from './types.js';
11
+ export interface CoinbaseAdapterConfig {
12
+ apiKeyId?: string;
13
+ apiKeySecret?: string;
14
+ walletSecret?: string;
15
+ network?: 'base-sepolia' | 'base';
16
+ accountName?: string;
17
+ }
18
+ export declare class CoinbaseWalletAdapter implements WalletAdapter {
19
+ readonly name = "coinbase";
20
+ readonly network: string;
21
+ private config;
22
+ private cdpClient;
23
+ private account;
24
+ private address;
25
+ private ready;
26
+ private usdcAddress;
27
+ private explorerBase;
28
+ constructor(config: CoinbaseAdapterConfig);
29
+ initialize(): Promise<void>;
30
+ getAddress(): Promise<string>;
31
+ getBalance(): Promise<WalletBalance>;
32
+ sendUsdc(to: string, amountUsdc: number): Promise<TransactionResult>;
33
+ approveUsdc(spender: string, amountUsdc: number): Promise<TransactionResult>;
34
+ requestTestFunds(): Promise<string>;
35
+ isReady(): boolean;
36
+ private ensureReady;
37
+ }
38
+ //# sourceMappingURL=coinbase-adapter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"coinbase-adapter.d.ts","sourceRoot":"","sources":["../../src/wallet/coinbase-adapter.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,aAAa,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAYlF,MAAM,WAAW,qBAAqB;IACpC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,OAAO,CAAC,EAAE,cAAc,GAAG,MAAM,CAAC;IAClC,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,qBAAa,qBAAsB,YAAW,aAAa;IACzD,QAAQ,CAAC,IAAI,cAAc;IAC3B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IAEzB,OAAO,CAAC,MAAM,CAAwB;IACtC,OAAO,CAAC,SAAS,CAAa;IAC9B,OAAO,CAAC,OAAO,CAAa;IAC5B,OAAO,CAAC,OAAO,CAAc;IAC7B,OAAO,CAAC,KAAK,CAAS;IACtB,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,YAAY,CAAS;gBAEjB,MAAM,EAAE,qBAAqB;IAWnC,UAAU,IAAI,OAAO,CAAC,IAAI,CAAC;IA2B3B,UAAU,IAAI,OAAO,CAAC,MAAM,CAAC;IAK7B,UAAU,IAAI,OAAO,CAAC,aAAa,CAAC;IAsCpC,QAAQ,CAAC,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,iBAAiB,CAAC;IAwCpE,WAAW,CAAC,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,iBAAiB,CAAC;IAuC5E,gBAAgB,IAAI,OAAO,CAAC,MAAM,CAAC;IAgBzC,OAAO,IAAI,OAAO;IAIlB,OAAO,CAAC,WAAW;CAKpB"}
@@ -0,0 +1,191 @@
1
+ /**
2
+ * Coinbase CDP Wallet Adapter
3
+ *
4
+ * Nole's real wallet powered by Coinbase Developer Platform Server Wallet v2.
5
+ * Creates and manages an MPC-secured EVM account on Base (Sepolia or Mainnet).
6
+ * Handles USDC transfers and approvals for the AgentSubscriptionRegistry contract.
7
+ *
8
+ * @see SPEC-AGENT-CRYPTO-SUBSCRIPTIONS-1.0.md
9
+ */
10
+ const BASE_SEPOLIA_USDC = '0x036CbD53842c5426634e7929541eC2318f3dCF7e';
11
+ const BASE_MAINNET_USDC = '0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913';
12
+ const ERC20_ABI = [
13
+ 'function balanceOf(address) view returns (uint256)',
14
+ 'function transfer(address to, uint256 amount) returns (bool)',
15
+ 'function approve(address spender, uint256 amount) returns (bool)',
16
+ 'function allowance(address owner, address spender) view returns (uint256)',
17
+ ];
18
+ export class CoinbaseWalletAdapter {
19
+ name = 'coinbase';
20
+ network;
21
+ config;
22
+ cdpClient = null;
23
+ account = null;
24
+ address = '';
25
+ ready = false;
26
+ usdcAddress;
27
+ explorerBase;
28
+ constructor(config) {
29
+ this.config = config;
30
+ this.network = config.network || 'base-sepolia';
31
+ this.usdcAddress = this.network === 'base'
32
+ ? BASE_MAINNET_USDC
33
+ : BASE_SEPOLIA_USDC;
34
+ this.explorerBase = this.network === 'base'
35
+ ? 'https://basescan.org'
36
+ : 'https://sepolia.basescan.org';
37
+ }
38
+ async initialize() {
39
+ try {
40
+ const { CdpClient } = await import('@coinbase/cdp-sdk');
41
+ this.cdpClient = new CdpClient({
42
+ apiKeyId: this.config.apiKeyId || process.env.CDP_API_KEY_ID,
43
+ apiKeySecret: this.config.apiKeySecret || process.env.CDP_API_KEY_SECRET,
44
+ walletSecret: this.config.walletSecret || process.env.CDP_WALLET_SECRET,
45
+ });
46
+ const accountName = this.config.accountName || 'nole-agent-wallet';
47
+ this.account = await this.cdpClient.evm.getOrCreateAccount({
48
+ name: accountName,
49
+ });
50
+ this.address = this.account.address;
51
+ this.ready = true;
52
+ console.log(`[nole:wallet:coinbase] Initialized on ${this.network}`);
53
+ console.log(`[nole:wallet:coinbase] Address: ${this.address}`);
54
+ console.log(`[nole:wallet:coinbase] Explorer: ${this.explorerBase}/address/${this.address}`);
55
+ }
56
+ catch (err) {
57
+ const msg = err instanceof Error ? err.message : String(err);
58
+ console.error(`[nole:wallet:coinbase] Initialization failed: ${msg}`);
59
+ throw new Error(`Coinbase wallet init failed: ${msg}`);
60
+ }
61
+ }
62
+ async getAddress() {
63
+ this.ensureReady();
64
+ return this.address;
65
+ }
66
+ async getBalance() {
67
+ this.ensureReady();
68
+ try {
69
+ const { createPublicClient, http, formatUnits, formatEther } = await import('viem');
70
+ const { baseSepolia, base } = await import('viem/chains');
71
+ const chain = this.network === 'base' ? base : baseSepolia;
72
+ const client = createPublicClient({ chain, transport: http() });
73
+ const [ethBalance, usdcBalance] = await Promise.all([
74
+ client.getBalance({ address: this.address }),
75
+ client.readContract({
76
+ address: this.usdcAddress,
77
+ abi: [{ name: 'balanceOf', type: 'function', stateMutability: 'view', inputs: [{ name: 'account', type: 'address' }], outputs: [{ name: '', type: 'uint256' }] }],
78
+ functionName: 'balanceOf',
79
+ args: [this.address],
80
+ }),
81
+ ]);
82
+ return {
83
+ address: this.address,
84
+ balanceUsdc: Number(formatUnits(usdcBalance, 6)),
85
+ balanceEth: Number(formatEther(ethBalance)),
86
+ network: this.network,
87
+ };
88
+ }
89
+ catch (err) {
90
+ const msg = err instanceof Error ? err.message : String(err);
91
+ console.error(`[nole:wallet:coinbase] Balance check failed: ${msg}`);
92
+ return {
93
+ address: this.address,
94
+ balanceUsdc: 0,
95
+ balanceEth: 0,
96
+ network: this.network,
97
+ };
98
+ }
99
+ }
100
+ async sendUsdc(to, amountUsdc) {
101
+ this.ensureReady();
102
+ const { encodeFunctionData, parseUnits } = await import('viem');
103
+ const amount = parseUnits(String(amountUsdc), 6);
104
+ const data = encodeFunctionData({
105
+ abi: [{ name: 'transfer', type: 'function', stateMutability: 'nonpayable', inputs: [{ name: 'to', type: 'address' }, { name: 'amount', type: 'uint256' }], outputs: [{ name: '', type: 'bool' }] }],
106
+ functionName: 'transfer',
107
+ args: [to, amount],
108
+ });
109
+ try {
110
+ const result = await this.cdpClient.evm.sendTransaction({
111
+ address: this.address,
112
+ transaction: {
113
+ to: this.usdcAddress,
114
+ data,
115
+ value: 0n,
116
+ },
117
+ network: this.network,
118
+ });
119
+ console.log(`[nole:wallet:coinbase] Sent $${amountUsdc} USDC to ${to}`);
120
+ console.log(`[nole:wallet:coinbase] TX: ${this.explorerBase}/tx/${result.transactionHash}`);
121
+ return {
122
+ txHash: result.transactionHash,
123
+ status: 'confirmed',
124
+ explorerUrl: `${this.explorerBase}/tx/${result.transactionHash}`,
125
+ amount: amountUsdc,
126
+ to,
127
+ };
128
+ }
129
+ catch (err) {
130
+ const msg = err instanceof Error ? err.message : String(err);
131
+ console.error(`[nole:wallet:coinbase] USDC transfer failed: ${msg}`);
132
+ throw new Error(`USDC transfer failed: ${msg}`);
133
+ }
134
+ }
135
+ async approveUsdc(spender, amountUsdc) {
136
+ this.ensureReady();
137
+ const { encodeFunctionData, parseUnits } = await import('viem');
138
+ const amount = parseUnits(String(amountUsdc), 6);
139
+ const data = encodeFunctionData({
140
+ abi: [{ name: 'approve', type: 'function', stateMutability: 'nonpayable', inputs: [{ name: 'spender', type: 'address' }, { name: 'amount', type: 'uint256' }], outputs: [{ name: '', type: 'bool' }] }],
141
+ functionName: 'approve',
142
+ args: [spender, amount],
143
+ });
144
+ try {
145
+ const result = await this.cdpClient.evm.sendTransaction({
146
+ address: this.address,
147
+ transaction: {
148
+ to: this.usdcAddress,
149
+ data,
150
+ value: 0n,
151
+ },
152
+ network: this.network,
153
+ });
154
+ console.log(`[nole:wallet:coinbase] Approved $${amountUsdc} USDC for ${spender}`);
155
+ return {
156
+ txHash: result.transactionHash,
157
+ status: 'confirmed',
158
+ explorerUrl: `${this.explorerBase}/tx/${result.transactionHash}`,
159
+ amount: amountUsdc,
160
+ to: spender,
161
+ };
162
+ }
163
+ catch (err) {
164
+ const msg = err instanceof Error ? err.message : String(err);
165
+ console.error(`[nole:wallet:coinbase] USDC approval failed: ${msg}`);
166
+ throw new Error(`USDC approval failed: ${msg}`);
167
+ }
168
+ }
169
+ async requestTestFunds() {
170
+ this.ensureReady();
171
+ if (this.network !== 'base-sepolia') {
172
+ throw new Error('Faucet only available on base-sepolia');
173
+ }
174
+ const result = await this.cdpClient.evm.requestFaucet({
175
+ address: this.address,
176
+ network: 'base-sepolia',
177
+ token: 'eth',
178
+ });
179
+ console.log(`[nole:wallet:coinbase] Faucet: ${this.explorerBase}/tx/${result.transactionHash}`);
180
+ return result.transactionHash;
181
+ }
182
+ isReady() {
183
+ return this.ready;
184
+ }
185
+ ensureReady() {
186
+ if (!this.ready) {
187
+ throw new Error('Coinbase wallet not initialized. Call initialize() first.');
188
+ }
189
+ }
190
+ }
191
+ //# sourceMappingURL=coinbase-adapter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"coinbase-adapter.js","sourceRoot":"","sources":["../../src/wallet/coinbase-adapter.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH,MAAM,iBAAiB,GAAG,4CAA4C,CAAC;AACvE,MAAM,iBAAiB,GAAG,4CAA4C,CAAC;AAEvE,MAAM,SAAS,GAAG;IAChB,oDAAoD;IACpD,8DAA8D;IAC9D,kEAAkE;IAClE,2EAA2E;CAC5E,CAAC;AAUF,MAAM,OAAO,qBAAqB;IACvB,IAAI,GAAG,UAAU,CAAC;IAClB,OAAO,CAAS;IAEjB,MAAM,CAAwB;IAC9B,SAAS,GAAQ,IAAI,CAAC;IACtB,OAAO,GAAQ,IAAI,CAAC;IACpB,OAAO,GAAW,EAAE,CAAC;IACrB,KAAK,GAAG,KAAK,CAAC;IACd,WAAW,CAAS;IACpB,YAAY,CAAS;IAE7B,YAAY,MAA6B;QACvC,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,OAAO,GAAG,MAAM,CAAC,OAAO,IAAI,cAAc,CAAC;QAChD,IAAI,CAAC,WAAW,GAAG,IAAI,CAAC,OAAO,KAAK,MAAM;YACxC,CAAC,CAAC,iBAAiB;YACnB,CAAC,CAAC,iBAAiB,CAAC;QACtB,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,OAAO,KAAK,MAAM;YACz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,EAAE;gBAChE,MAAM,EAAE,UAAU;gBAClB,EAAE,EAAE,OAAO;aACZ,CAAC;QACJ,CAAC;QAAC,OAAO,GAAG,EAAE,CAAC;YACb,MAAM,GAAG,GAAG,GAAG,YAAY,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;YAC7D,OAAO,CAAC,KAAK,CAAC,gDAAgD,GAAG,EAAE,CAAC,CAAC;YACrE,MAAM,IAAI,KAAK,CAAC,yBAAyB,GAAG,EAAE,CAAC,CAAC;QAClD,CAAC;IACH,CAAC;IAED,KAAK,CAAC,gBAAgB;QACpB,IAAI,CAAC,WAAW,EAAE,CAAC;QACnB,IAAI,IAAI,CAAC,OAAO,KAAK,cAAc,EAAE,CAAC;YACpC,MAAM,IAAI,KAAK,CAAC,uCAAuC,CAAC,CAAC;QAC3D,CAAC;QAED,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,aAAa,CAAC;YACpD,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,OAAO,EAAE,cAAc;YACvB,KAAK,EAAE,KAAK;SACb,CAAC,CAAC;QAEH,OAAO,CAAC,GAAG,CAAC,kCAAkC,IAAI,CAAC,YAAY,OAAO,MAAM,CAAC,eAAe,EAAE,CAAC,CAAC;QAChG,OAAO,MAAM,CAAC,eAAe,CAAC;IAChC,CAAC;IAED,OAAO;QACL,OAAO,IAAI,CAAC,KAAK,CAAC;IACpB,CAAC;IAEO,WAAW;QACjB,IAAI,CAAC,IAAI,CAAC,KAAK,EAAE,CAAC;YAChB,MAAM,IAAI,KAAK,CAAC,2DAA2D,CAAC,CAAC;QAC/E,CAAC;IACH,CAAC;CACF"}
@@ -0,0 +1,20 @@
1
+ /**
2
+ * Wallet Adapter Factory
3
+ *
4
+ * Creates the appropriate wallet adapter based on Nole's config.
5
+ * Credential resolution order:
6
+ * 1. Explicit config values (from openclaw.json plugin entry)
7
+ * 2. ~/.nole/credentials (written by `nole configure`)
8
+ * 3. Environment variables (CDP_API_KEY_ID, etc.)
9
+ *
10
+ * - walletAdapter: 'mock' → MockWalletAdapter (testing)
11
+ * - walletAdapter: 'coinbase' → CoinbaseWalletAdapter (production)
12
+ * - walletAdapter: 'auto' → Coinbase if credentials exist, else Mock
13
+ */
14
+ export type { WalletAdapter, WalletBalance, TransactionResult } from './types.js';
15
+ export { MockWalletAdapter } from './mock-adapter.js';
16
+ export { CoinbaseWalletAdapter } from './coinbase-adapter.js';
17
+ import type { WalletAdapter } from './types.js';
18
+ import type { NoleConfig } from '../types/nole-config.js';
19
+ export declare function createWalletAdapter(config: NoleConfig): Promise<WalletAdapter>;
20
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/wallet/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,YAAY,EAAE,aAAa,EAAE,aAAa,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAClF,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AACtD,OAAO,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAE9D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAGhD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAG1D,wBAAsB,mBAAmB,CAAC,MAAM,EAAE,UAAU,GAAG,OAAO,CAAC,aAAa,CAAC,CAkBpF"}
@@ -0,0 +1,34 @@
1
+ /**
2
+ * Wallet Adapter Factory
3
+ *
4
+ * Creates the appropriate wallet adapter based on Nole's config.
5
+ * Credential resolution order:
6
+ * 1. Explicit config values (from openclaw.json plugin entry)
7
+ * 2. ~/.nole/credentials (written by `nole configure`)
8
+ * 3. Environment variables (CDP_API_KEY_ID, etc.)
9
+ *
10
+ * - walletAdapter: 'mock' → MockWalletAdapter (testing)
11
+ * - walletAdapter: 'coinbase' → CoinbaseWalletAdapter (production)
12
+ * - walletAdapter: 'auto' → Coinbase if credentials exist, else Mock
13
+ */
14
+ export { MockWalletAdapter } from './mock-adapter.js';
15
+ export { CoinbaseWalletAdapter } from './coinbase-adapter.js';
16
+ import { MockWalletAdapter } from './mock-adapter.js';
17
+ import { CoinbaseWalletAdapter } from './coinbase-adapter.js';
18
+ import { loadCredentials } from '../cli/configure.js';
19
+ export async function createWalletAdapter(config) {
20
+ const creds = await loadCredentials();
21
+ const useCoinbase = config.walletAdapter === 'coinbase' ||
22
+ (config.walletAdapter === 'auto' && creds?.cdpApiKeyId);
23
+ if (useCoinbase) {
24
+ return new CoinbaseWalletAdapter({
25
+ apiKeyId: config.coinbaseApiKey || creds?.cdpApiKeyId,
26
+ apiKeySecret: config.coinbaseApiSecret || creds?.cdpApiKeySecret,
27
+ walletSecret: creds?.cdpWalletSecret,
28
+ network: creds?.network || 'base-sepolia',
29
+ accountName: `nole-${config.agentId}`,
30
+ });
31
+ }
32
+ return new MockWalletAdapter(config.seedCapitalUsd);
33
+ }
34
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/wallet/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAGH,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AACtD,OAAO,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAG9D,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AACtD,OAAO,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAE9D,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAEtD,MAAM,CAAC,KAAK,UAAU,mBAAmB,CAAC,MAAkB;IAC1D,MAAM,KAAK,GAAG,MAAM,eAAe,EAAE,CAAC;IAEtC,MAAM,WAAW,GACf,MAAM,CAAC,aAAa,KAAK,UAAU;QACnC,CAAC,MAAM,CAAC,aAAa,KAAK,MAAM,IAAI,KAAK,EAAE,WAAW,CAAC,CAAC;IAE1D,IAAI,WAAW,EAAE,CAAC;QAChB,OAAO,IAAI,qBAAqB,CAAC;YAC/B,QAAQ,EAAE,MAAM,CAAC,cAAc,IAAI,KAAK,EAAE,WAAW;YACrD,YAAY,EAAE,MAAM,CAAC,iBAAiB,IAAI,KAAK,EAAE,eAAe;YAChE,YAAY,EAAE,KAAK,EAAE,eAAe;YACpC,OAAO,EAAG,KAAK,EAAE,OAAmC,IAAI,cAAc;YACtE,WAAW,EAAE,QAAQ,MAAM,CAAC,OAAO,EAAE;SACtC,CAAC,CAAC;IACL,CAAC;IAED,OAAO,IAAI,iBAAiB,CAAC,MAAM,CAAC,cAAc,CAAC,CAAC;AACtD,CAAC"}
@@ -0,0 +1,23 @@
1
+ /**
2
+ * Mock Wallet Adapter
3
+ *
4
+ * Simulates wallet operations for Phase 1 / testing.
5
+ * Tracks balance in memory, no real transactions.
6
+ */
7
+ import type { WalletAdapter, WalletBalance, TransactionResult } from './types.js';
8
+ export declare class MockWalletAdapter implements WalletAdapter {
9
+ readonly name = "mock";
10
+ readonly network = "mock-testnet";
11
+ private address;
12
+ private balanceUsdc;
13
+ private balanceEth;
14
+ private ready;
15
+ constructor(seedCapitalUsd: number);
16
+ initialize(): Promise<void>;
17
+ getAddress(): Promise<string>;
18
+ getBalance(): Promise<WalletBalance>;
19
+ sendUsdc(to: string, amountUsdc: number): Promise<TransactionResult>;
20
+ approveUsdc(spender: string, amountUsdc: number): Promise<TransactionResult>;
21
+ isReady(): boolean;
22
+ }
23
+ //# sourceMappingURL=mock-adapter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mock-adapter.d.ts","sourceRoot":"","sources":["../../src/wallet/mock-adapter.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAE,aAAa,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAElF,qBAAa,iBAAkB,YAAW,aAAa;IACrD,QAAQ,CAAC,IAAI,UAAU;IACvB,QAAQ,CAAC,OAAO,kBAAkB;IAElC,OAAO,CAAC,OAAO,CAAmD;IAClE,OAAO,CAAC,WAAW,CAAS;IAC5B,OAAO,CAAC,UAAU,CAAO;IACzB,OAAO,CAAC,KAAK,CAAS;gBAEV,cAAc,EAAE,MAAM;IAI5B,UAAU,IAAI,OAAO,CAAC,IAAI,CAAC;IAK3B,UAAU,IAAI,OAAO,CAAC,MAAM,CAAC;IAI7B,UAAU,IAAI,OAAO,CAAC,aAAa,CAAC;IASpC,QAAQ,CAAC,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,iBAAiB,CAAC;IAgBpE,WAAW,CAAC,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,iBAAiB,CAAC;IAYlF,OAAO,IAAI,OAAO;CAGnB"}
@@ -0,0 +1,62 @@
1
+ /**
2
+ * Mock Wallet Adapter
3
+ *
4
+ * Simulates wallet operations for Phase 1 / testing.
5
+ * Tracks balance in memory, no real transactions.
6
+ */
7
+ export class MockWalletAdapter {
8
+ name = 'mock';
9
+ network = 'mock-testnet';
10
+ address = '0xMOCK_NOLE_WALLET_' + Date.now().toString(16);
11
+ balanceUsdc;
12
+ balanceEth = 0.1;
13
+ ready = false;
14
+ constructor(seedCapitalUsd) {
15
+ this.balanceUsdc = seedCapitalUsd;
16
+ }
17
+ async initialize() {
18
+ this.ready = true;
19
+ console.log(`[nole:wallet:mock] Initialized with $${this.balanceUsdc} USDC`);
20
+ }
21
+ async getAddress() {
22
+ return this.address;
23
+ }
24
+ async getBalance() {
25
+ return {
26
+ address: this.address,
27
+ balanceUsdc: this.balanceUsdc,
28
+ balanceEth: this.balanceEth,
29
+ network: this.network,
30
+ };
31
+ }
32
+ async sendUsdc(to, amountUsdc) {
33
+ if (amountUsdc > this.balanceUsdc) {
34
+ throw new Error(`Insufficient USDC: need $${amountUsdc}, have $${this.balanceUsdc}`);
35
+ }
36
+ this.balanceUsdc -= amountUsdc;
37
+ const txHash = '0xmock_' + Date.now().toString(16);
38
+ console.log(`[nole:wallet:mock] Sent $${amountUsdc} USDC to ${to} (tx: ${txHash})`);
39
+ return {
40
+ txHash,
41
+ status: 'confirmed',
42
+ explorerUrl: `https://mock.explorer/tx/${txHash}`,
43
+ amount: amountUsdc,
44
+ to,
45
+ };
46
+ }
47
+ async approveUsdc(spender, amountUsdc) {
48
+ const txHash = '0xmock_approve_' + Date.now().toString(16);
49
+ console.log(`[nole:wallet:mock] Approved $${amountUsdc} USDC for ${spender}`);
50
+ return {
51
+ txHash,
52
+ status: 'confirmed',
53
+ explorerUrl: `https://mock.explorer/tx/${txHash}`,
54
+ amount: amountUsdc,
55
+ to: spender,
56
+ };
57
+ }
58
+ isReady() {
59
+ return this.ready;
60
+ }
61
+ }
62
+ //# sourceMappingURL=mock-adapter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mock-adapter.js","sourceRoot":"","sources":["../../src/wallet/mock-adapter.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH,MAAM,OAAO,iBAAiB;IACnB,IAAI,GAAG,MAAM,CAAC;IACd,OAAO,GAAG,cAAc,CAAC;IAE1B,OAAO,GAAG,qBAAqB,GAAG,IAAI,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;IAC1D,WAAW,CAAS;IACpB,UAAU,GAAG,GAAG,CAAC;IACjB,KAAK,GAAG,KAAK,CAAC;IAEtB,YAAY,cAAsB;QAChC,IAAI,CAAC,WAAW,GAAG,cAAc,CAAC;IACpC,CAAC;IAED,KAAK,CAAC,UAAU;QACd,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC;QAClB,OAAO,CAAC,GAAG,CAAC,wCAAwC,IAAI,CAAC,WAAW,OAAO,CAAC,CAAC;IAC/E,CAAC;IAED,KAAK,CAAC,UAAU;QACd,OAAO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K,CAAC;IACpB,CAAC;CACF"}
@@ -0,0 +1,30 @@
1
+ /**
2
+ * Wallet Adapter Interface
3
+ *
4
+ * Abstraction layer for Nole's wallet operations. The mock adapter
5
+ * is used in Phase 1 / testing, the Coinbase adapter goes live in Phase 2.
6
+ */
7
+ export interface WalletBalance {
8
+ address: string;
9
+ balanceUsdc: number;
10
+ balanceEth: number;
11
+ network: string;
12
+ }
13
+ export interface TransactionResult {
14
+ txHash: string;
15
+ status: 'confirmed' | 'pending' | 'failed';
16
+ explorerUrl: string;
17
+ amount: number;
18
+ to: string;
19
+ }
20
+ export interface WalletAdapter {
21
+ readonly name: string;
22
+ readonly network: string;
23
+ initialize(): Promise<void>;
24
+ getAddress(): Promise<string>;
25
+ getBalance(): Promise<WalletBalance>;
26
+ sendUsdc(to: string, amountUsdc: number): Promise<TransactionResult>;
27
+ approveUsdc(spender: string, amountUsdc: number): Promise<TransactionResult>;
28
+ isReady(): boolean;
29
+ }
30
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/wallet/types.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,WAAW,aAAa;IAC5B,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,iBAAiB;IAChC,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,WAAW,GAAG,SAAS,GAAG,QAAQ,CAAC;IAC3C,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,EAAE,MAAM,CAAC;IACf,EAAE,EAAE,MAAM,CAAC;CACZ;AAED,MAAM,WAAW,aAAa;IAC5B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IAEzB,UAAU,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IAC5B,UAAU,IAAI,OAAO,CAAC,MAAM,CAAC,CAAC;IAC9B,UAAU,IAAI,OAAO,CAAC,aAAa,CAAC,CAAC;IACrC,QAAQ,CAAC,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC;IACrE,WAAW,CAAC,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC;IAC7E,OAAO,IAAI,OAAO,CAAC;CACpB"}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Wallet Adapter Interface
3
+ *
4
+ * Abstraction layer for Nole's wallet operations. The mock adapter
5
+ * is used in Phase 1 / testing, the Coinbase adapter goes live in Phase 2.
6
+ */
7
+ export {};
8
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/wallet/types.ts"],"names":[],"mappings":"AAAA;;;;;GAKG"}
@@ -33,6 +33,25 @@
33
33
  "type": "string",
34
34
  "default": "monday",
35
35
  "description": "Day of week for intelligence report delivery"
36
+ },
37
+ "walletAdapter": {
38
+ "type": "string",
39
+ "enum": ["auto", "coinbase", "mock"],
40
+ "default": "auto",
41
+ "description": "Wallet mode: 'auto' detects ~/.nole/credentials, 'coinbase' requires CDP keys, 'mock' for testing"
42
+ },
43
+ "compsiApiUrl": {
44
+ "type": "string",
45
+ "default": "https://aiassess.tech",
46
+ "description": "CompSi platform API URL for agent subscriptions"
47
+ },
48
+ "compsiAgentApiKey": {
49
+ "type": "string",
50
+ "description": "CompSi Agent API key (agk_...) — obtained on subscription"
51
+ },
52
+ "compsiWalletAddress": {
53
+ "type": "string",
54
+ "description": "Nole's wallet address for crypto subscriptions"
36
55
  }
37
56
  },
38
57
  "required": []
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aiassesstech/nole",
3
- "version": "0.1.9",
3
+ "version": "0.2.0",
4
4
  "description": "Nole — Autonomous Trust Evangelist & Intelligence Operative for AI. Economic agency, social presence, and autonomous decision-making within a governed hierarchy.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -62,7 +62,9 @@
62
62
  },
63
63
  "peerDependencies": {
64
64
  "@aiassesstech/grillo": ">=0.1.0",
65
- "@aiassesstech/noah": ">=0.1.0"
65
+ "@aiassesstech/noah": ">=0.1.0",
66
+ "@coinbase/cdp-sdk": ">=0.12.0",
67
+ "viem": ">=2.0.0"
66
68
  },
67
69
  "peerDependenciesMeta": {
68
70
  "@aiassesstech/grillo": {
@@ -70,6 +72,12 @@
70
72
  },
71
73
  "@aiassesstech/noah": {
72
74
  "optional": true
75
+ },
76
+ "@coinbase/cdp-sdk": {
77
+ "optional": true
78
+ },
79
+ "viem": {
80
+ "optional": true
73
81
  }
74
82
  },
75
83
  "devDependencies": {