moltspay 0.2.0 → 0.2.1
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/cli.js.map +1 -1
- package/dist/cli.mjs.map +1 -1
- package/dist/guide/index.d.mts +7 -7
- package/dist/guide/index.d.ts +7 -7
- package/dist/guide/index.js +50 -50
- package/dist/guide/index.js.map +1 -1
- package/dist/guide/index.mjs +50 -50
- package/dist/guide/index.mjs.map +1 -1
- package/dist/index.d.mts +63 -63
- package/dist/index.d.ts +63 -63
- package/dist/index.js +206 -206
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +206 -206
- package/dist/index.mjs.map +1 -1
- package/dist/wallet/index.d.mts +50 -50
- package/dist/wallet/index.d.ts +50 -50
- package/dist/wallet/index.js +18 -18
- package/dist/wallet/index.js.map +1 -1
- package/dist/wallet/index.mjs +18 -18
- package/dist/wallet/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/wallet/index.d.mts
CHANGED
|
@@ -103,21 +103,21 @@ declare class SecureWallet {
|
|
|
103
103
|
}
|
|
104
104
|
|
|
105
105
|
/**
|
|
106
|
-
* createWallet -
|
|
106
|
+
* createWallet - Create a new wallet for Agent
|
|
107
107
|
*
|
|
108
|
-
*
|
|
109
|
-
* -
|
|
110
|
-
* -
|
|
111
|
-
* -
|
|
108
|
+
* Features:
|
|
109
|
+
* - Generate new Ethereum wallet
|
|
110
|
+
* - Securely store private key (encrypted or plaintext, depending on config)
|
|
111
|
+
* - Return wallet address (never return private key)
|
|
112
112
|
*/
|
|
113
113
|
interface CreateWalletOptions {
|
|
114
|
-
/**
|
|
114
|
+
/** Storage path, default ~/.moltspay/wallet.json */
|
|
115
115
|
storagePath?: string;
|
|
116
|
-
/**
|
|
116
|
+
/** Encryption password (optional, plaintext if not provided) */
|
|
117
117
|
password?: string;
|
|
118
|
-
/**
|
|
118
|
+
/** Wallet label/name */
|
|
119
119
|
label?: string;
|
|
120
|
-
/**
|
|
120
|
+
/** Overwrite if wallet exists */
|
|
121
121
|
overwrite?: boolean;
|
|
122
122
|
}
|
|
123
123
|
interface WalletData {
|
|
@@ -125,11 +125,11 @@ interface WalletData {
|
|
|
125
125
|
label?: string;
|
|
126
126
|
createdAt: string;
|
|
127
127
|
encrypted: boolean;
|
|
128
|
-
/**
|
|
128
|
+
/** Encrypted or plaintext private key */
|
|
129
129
|
privateKey: string;
|
|
130
|
-
/**
|
|
130
|
+
/** Encryption IV */
|
|
131
131
|
iv?: string;
|
|
132
|
-
/**
|
|
132
|
+
/** Encryption salt */
|
|
133
133
|
salt?: string;
|
|
134
134
|
}
|
|
135
135
|
interface CreateWalletResult {
|
|
@@ -137,28 +137,28 @@ interface CreateWalletResult {
|
|
|
137
137
|
address?: string;
|
|
138
138
|
storagePath?: string;
|
|
139
139
|
error?: string;
|
|
140
|
-
/**
|
|
140
|
+
/** Whether newly created (false means loaded existing) */
|
|
141
141
|
isNew?: boolean;
|
|
142
142
|
}
|
|
143
143
|
/**
|
|
144
|
-
*
|
|
144
|
+
* Create new wallet
|
|
145
145
|
*
|
|
146
146
|
* @example
|
|
147
147
|
* ```typescript
|
|
148
|
-
* //
|
|
148
|
+
* // Create unencrypted wallet
|
|
149
149
|
* const result = await createWallet();
|
|
150
|
-
* console.log('
|
|
150
|
+
* console.log('Wallet address:', result.address);
|
|
151
151
|
*
|
|
152
|
-
* //
|
|
152
|
+
* // Create encrypted wallet
|
|
153
153
|
* const result = await createWallet({ password: 'mySecurePassword' });
|
|
154
154
|
*
|
|
155
|
-
* //
|
|
155
|
+
* // Specify storage path
|
|
156
156
|
* const result = await createWallet({ storagePath: './my-wallet.json' });
|
|
157
157
|
* ```
|
|
158
158
|
*/
|
|
159
159
|
declare function createWallet(options?: CreateWalletOptions): CreateWalletResult;
|
|
160
160
|
/**
|
|
161
|
-
*
|
|
161
|
+
* Load existing wallet
|
|
162
162
|
*/
|
|
163
163
|
declare function loadWallet(options?: {
|
|
164
164
|
storagePath?: string;
|
|
@@ -170,61 +170,61 @@ declare function loadWallet(options?: {
|
|
|
170
170
|
error?: string;
|
|
171
171
|
};
|
|
172
172
|
/**
|
|
173
|
-
*
|
|
173
|
+
* Get wallet address (no password required)
|
|
174
174
|
*/
|
|
175
175
|
declare function getWalletAddress(storagePath?: string): string | null;
|
|
176
176
|
/**
|
|
177
|
-
*
|
|
177
|
+
* Check if wallet exists
|
|
178
178
|
*/
|
|
179
179
|
declare function walletExists(storagePath?: string): boolean;
|
|
180
180
|
|
|
181
181
|
/**
|
|
182
|
-
* PermitWallet -
|
|
182
|
+
* PermitWallet - Pay using Boss's Permit authorization
|
|
183
183
|
*
|
|
184
|
-
*
|
|
185
|
-
* - Agent
|
|
186
|
-
* - Agent
|
|
187
|
-
* - Agent
|
|
184
|
+
* Scenario:
|
|
185
|
+
* - Agent doesn't have USDC, but Boss gave a Permit authorization
|
|
186
|
+
* - Agent uses Permit signature + own wallet to execute transferFrom
|
|
187
|
+
* - Agent only needs small amount of ETH for gas, USDC is deducted from Boss's wallet
|
|
188
188
|
*/
|
|
189
189
|
|
|
190
190
|
interface PermitData {
|
|
191
|
-
/** Boss
|
|
191
|
+
/** Boss's wallet address (USDC holder) */
|
|
192
192
|
owner: string;
|
|
193
|
-
/** Agent
|
|
193
|
+
/** Agent's wallet address (authorized spender) */
|
|
194
194
|
spender: string;
|
|
195
|
-
/**
|
|
195
|
+
/** Authorized amount (USDC, raw 6 decimal value) */
|
|
196
196
|
value: string;
|
|
197
|
-
/**
|
|
197
|
+
/** Expiration timestamp */
|
|
198
198
|
deadline: number;
|
|
199
|
-
/**
|
|
199
|
+
/** Signature v */
|
|
200
200
|
v: number;
|
|
201
|
-
/**
|
|
201
|
+
/** Signature r */
|
|
202
202
|
r: string;
|
|
203
|
-
/**
|
|
203
|
+
/** Signature s */
|
|
204
204
|
s: string;
|
|
205
205
|
}
|
|
206
206
|
interface PermitWalletConfig {
|
|
207
207
|
chain?: ChainName;
|
|
208
|
-
/** Agent
|
|
208
|
+
/** Agent's private key (for executing transactions) */
|
|
209
209
|
privateKey?: string;
|
|
210
|
-
/**
|
|
210
|
+
/** Load private key from file */
|
|
211
211
|
walletPath?: string;
|
|
212
|
-
/**
|
|
212
|
+
/** Decryption password */
|
|
213
213
|
walletPassword?: string;
|
|
214
214
|
rpcUrl?: string;
|
|
215
215
|
}
|
|
216
216
|
interface TransferWithPermitParams {
|
|
217
|
-
/**
|
|
217
|
+
/** Recipient address */
|
|
218
218
|
to: string;
|
|
219
|
-
/**
|
|
219
|
+
/** Amount (USDC) */
|
|
220
220
|
amount: number;
|
|
221
|
-
/** Boss
|
|
221
|
+
/** Boss-signed Permit data */
|
|
222
222
|
permit: PermitData;
|
|
223
223
|
}
|
|
224
224
|
interface TransferWithPermitResult extends TransferResult {
|
|
225
|
-
/** Permit
|
|
225
|
+
/** Permit transaction hash */
|
|
226
226
|
permitTxHash?: string;
|
|
227
|
-
/** Transfer
|
|
227
|
+
/** Transfer transaction hash */
|
|
228
228
|
transferTxHash?: string;
|
|
229
229
|
}
|
|
230
230
|
declare class PermitWallet {
|
|
@@ -236,21 +236,21 @@ declare class PermitWallet {
|
|
|
236
236
|
private usdcContract;
|
|
237
237
|
constructor(config?: PermitWalletConfig);
|
|
238
238
|
/**
|
|
239
|
-
*
|
|
239
|
+
* Check if Permit is valid (current allowance)
|
|
240
240
|
*/
|
|
241
241
|
checkPermitAllowance(owner: string): Promise<string>;
|
|
242
242
|
/**
|
|
243
|
-
*
|
|
243
|
+
* Pay using Permit authorization
|
|
244
244
|
*
|
|
245
|
-
*
|
|
246
|
-
* 1.
|
|
247
|
-
* 2.
|
|
245
|
+
* Flow:
|
|
246
|
+
* 1. Call permit() to record Boss's authorization in the contract
|
|
247
|
+
* 2. Call transferFrom() to transfer from Boss's wallet to recipient
|
|
248
248
|
*
|
|
249
249
|
* @example
|
|
250
250
|
* ```typescript
|
|
251
251
|
* const wallet = new PermitWallet({ chain: 'base' });
|
|
252
252
|
*
|
|
253
|
-
* // Boss
|
|
253
|
+
* // Boss-signed permit data
|
|
254
254
|
* const permit = {
|
|
255
255
|
* owner: '0xBOSS...',
|
|
256
256
|
* spender: wallet.address,
|
|
@@ -270,16 +270,16 @@ declare class PermitWallet {
|
|
|
270
270
|
*/
|
|
271
271
|
transferWithPermit(params: TransferWithPermitParams): Promise<TransferWithPermitResult>;
|
|
272
272
|
/**
|
|
273
|
-
*
|
|
273
|
+
* Get ETH balance (for gas)
|
|
274
274
|
*/
|
|
275
275
|
getGasBalance(): Promise<string>;
|
|
276
276
|
/**
|
|
277
|
-
*
|
|
277
|
+
* Check if there's enough gas
|
|
278
278
|
*/
|
|
279
279
|
hasEnoughGas(minEth?: number): Promise<boolean>;
|
|
280
280
|
}
|
|
281
281
|
/**
|
|
282
|
-
*
|
|
282
|
+
* Format Permit request message (to send to Boss)
|
|
283
283
|
*/
|
|
284
284
|
declare function formatPermitRequest(params: {
|
|
285
285
|
agentAddress: string;
|
package/dist/wallet/index.d.ts
CHANGED
|
@@ -103,21 +103,21 @@ declare class SecureWallet {
|
|
|
103
103
|
}
|
|
104
104
|
|
|
105
105
|
/**
|
|
106
|
-
* createWallet -
|
|
106
|
+
* createWallet - Create a new wallet for Agent
|
|
107
107
|
*
|
|
108
|
-
*
|
|
109
|
-
* -
|
|
110
|
-
* -
|
|
111
|
-
* -
|
|
108
|
+
* Features:
|
|
109
|
+
* - Generate new Ethereum wallet
|
|
110
|
+
* - Securely store private key (encrypted or plaintext, depending on config)
|
|
111
|
+
* - Return wallet address (never return private key)
|
|
112
112
|
*/
|
|
113
113
|
interface CreateWalletOptions {
|
|
114
|
-
/**
|
|
114
|
+
/** Storage path, default ~/.moltspay/wallet.json */
|
|
115
115
|
storagePath?: string;
|
|
116
|
-
/**
|
|
116
|
+
/** Encryption password (optional, plaintext if not provided) */
|
|
117
117
|
password?: string;
|
|
118
|
-
/**
|
|
118
|
+
/** Wallet label/name */
|
|
119
119
|
label?: string;
|
|
120
|
-
/**
|
|
120
|
+
/** Overwrite if wallet exists */
|
|
121
121
|
overwrite?: boolean;
|
|
122
122
|
}
|
|
123
123
|
interface WalletData {
|
|
@@ -125,11 +125,11 @@ interface WalletData {
|
|
|
125
125
|
label?: string;
|
|
126
126
|
createdAt: string;
|
|
127
127
|
encrypted: boolean;
|
|
128
|
-
/**
|
|
128
|
+
/** Encrypted or plaintext private key */
|
|
129
129
|
privateKey: string;
|
|
130
|
-
/**
|
|
130
|
+
/** Encryption IV */
|
|
131
131
|
iv?: string;
|
|
132
|
-
/**
|
|
132
|
+
/** Encryption salt */
|
|
133
133
|
salt?: string;
|
|
134
134
|
}
|
|
135
135
|
interface CreateWalletResult {
|
|
@@ -137,28 +137,28 @@ interface CreateWalletResult {
|
|
|
137
137
|
address?: string;
|
|
138
138
|
storagePath?: string;
|
|
139
139
|
error?: string;
|
|
140
|
-
/**
|
|
140
|
+
/** Whether newly created (false means loaded existing) */
|
|
141
141
|
isNew?: boolean;
|
|
142
142
|
}
|
|
143
143
|
/**
|
|
144
|
-
*
|
|
144
|
+
* Create new wallet
|
|
145
145
|
*
|
|
146
146
|
* @example
|
|
147
147
|
* ```typescript
|
|
148
|
-
* //
|
|
148
|
+
* // Create unencrypted wallet
|
|
149
149
|
* const result = await createWallet();
|
|
150
|
-
* console.log('
|
|
150
|
+
* console.log('Wallet address:', result.address);
|
|
151
151
|
*
|
|
152
|
-
* //
|
|
152
|
+
* // Create encrypted wallet
|
|
153
153
|
* const result = await createWallet({ password: 'mySecurePassword' });
|
|
154
154
|
*
|
|
155
|
-
* //
|
|
155
|
+
* // Specify storage path
|
|
156
156
|
* const result = await createWallet({ storagePath: './my-wallet.json' });
|
|
157
157
|
* ```
|
|
158
158
|
*/
|
|
159
159
|
declare function createWallet(options?: CreateWalletOptions): CreateWalletResult;
|
|
160
160
|
/**
|
|
161
|
-
*
|
|
161
|
+
* Load existing wallet
|
|
162
162
|
*/
|
|
163
163
|
declare function loadWallet(options?: {
|
|
164
164
|
storagePath?: string;
|
|
@@ -170,61 +170,61 @@ declare function loadWallet(options?: {
|
|
|
170
170
|
error?: string;
|
|
171
171
|
};
|
|
172
172
|
/**
|
|
173
|
-
*
|
|
173
|
+
* Get wallet address (no password required)
|
|
174
174
|
*/
|
|
175
175
|
declare function getWalletAddress(storagePath?: string): string | null;
|
|
176
176
|
/**
|
|
177
|
-
*
|
|
177
|
+
* Check if wallet exists
|
|
178
178
|
*/
|
|
179
179
|
declare function walletExists(storagePath?: string): boolean;
|
|
180
180
|
|
|
181
181
|
/**
|
|
182
|
-
* PermitWallet -
|
|
182
|
+
* PermitWallet - Pay using Boss's Permit authorization
|
|
183
183
|
*
|
|
184
|
-
*
|
|
185
|
-
* - Agent
|
|
186
|
-
* - Agent
|
|
187
|
-
* - Agent
|
|
184
|
+
* Scenario:
|
|
185
|
+
* - Agent doesn't have USDC, but Boss gave a Permit authorization
|
|
186
|
+
* - Agent uses Permit signature + own wallet to execute transferFrom
|
|
187
|
+
* - Agent only needs small amount of ETH for gas, USDC is deducted from Boss's wallet
|
|
188
188
|
*/
|
|
189
189
|
|
|
190
190
|
interface PermitData {
|
|
191
|
-
/** Boss
|
|
191
|
+
/** Boss's wallet address (USDC holder) */
|
|
192
192
|
owner: string;
|
|
193
|
-
/** Agent
|
|
193
|
+
/** Agent's wallet address (authorized spender) */
|
|
194
194
|
spender: string;
|
|
195
|
-
/**
|
|
195
|
+
/** Authorized amount (USDC, raw 6 decimal value) */
|
|
196
196
|
value: string;
|
|
197
|
-
/**
|
|
197
|
+
/** Expiration timestamp */
|
|
198
198
|
deadline: number;
|
|
199
|
-
/**
|
|
199
|
+
/** Signature v */
|
|
200
200
|
v: number;
|
|
201
|
-
/**
|
|
201
|
+
/** Signature r */
|
|
202
202
|
r: string;
|
|
203
|
-
/**
|
|
203
|
+
/** Signature s */
|
|
204
204
|
s: string;
|
|
205
205
|
}
|
|
206
206
|
interface PermitWalletConfig {
|
|
207
207
|
chain?: ChainName;
|
|
208
|
-
/** Agent
|
|
208
|
+
/** Agent's private key (for executing transactions) */
|
|
209
209
|
privateKey?: string;
|
|
210
|
-
/**
|
|
210
|
+
/** Load private key from file */
|
|
211
211
|
walletPath?: string;
|
|
212
|
-
/**
|
|
212
|
+
/** Decryption password */
|
|
213
213
|
walletPassword?: string;
|
|
214
214
|
rpcUrl?: string;
|
|
215
215
|
}
|
|
216
216
|
interface TransferWithPermitParams {
|
|
217
|
-
/**
|
|
217
|
+
/** Recipient address */
|
|
218
218
|
to: string;
|
|
219
|
-
/**
|
|
219
|
+
/** Amount (USDC) */
|
|
220
220
|
amount: number;
|
|
221
|
-
/** Boss
|
|
221
|
+
/** Boss-signed Permit data */
|
|
222
222
|
permit: PermitData;
|
|
223
223
|
}
|
|
224
224
|
interface TransferWithPermitResult extends TransferResult {
|
|
225
|
-
/** Permit
|
|
225
|
+
/** Permit transaction hash */
|
|
226
226
|
permitTxHash?: string;
|
|
227
|
-
/** Transfer
|
|
227
|
+
/** Transfer transaction hash */
|
|
228
228
|
transferTxHash?: string;
|
|
229
229
|
}
|
|
230
230
|
declare class PermitWallet {
|
|
@@ -236,21 +236,21 @@ declare class PermitWallet {
|
|
|
236
236
|
private usdcContract;
|
|
237
237
|
constructor(config?: PermitWalletConfig);
|
|
238
238
|
/**
|
|
239
|
-
*
|
|
239
|
+
* Check if Permit is valid (current allowance)
|
|
240
240
|
*/
|
|
241
241
|
checkPermitAllowance(owner: string): Promise<string>;
|
|
242
242
|
/**
|
|
243
|
-
*
|
|
243
|
+
* Pay using Permit authorization
|
|
244
244
|
*
|
|
245
|
-
*
|
|
246
|
-
* 1.
|
|
247
|
-
* 2.
|
|
245
|
+
* Flow:
|
|
246
|
+
* 1. Call permit() to record Boss's authorization in the contract
|
|
247
|
+
* 2. Call transferFrom() to transfer from Boss's wallet to recipient
|
|
248
248
|
*
|
|
249
249
|
* @example
|
|
250
250
|
* ```typescript
|
|
251
251
|
* const wallet = new PermitWallet({ chain: 'base' });
|
|
252
252
|
*
|
|
253
|
-
* // Boss
|
|
253
|
+
* // Boss-signed permit data
|
|
254
254
|
* const permit = {
|
|
255
255
|
* owner: '0xBOSS...',
|
|
256
256
|
* spender: wallet.address,
|
|
@@ -270,16 +270,16 @@ declare class PermitWallet {
|
|
|
270
270
|
*/
|
|
271
271
|
transferWithPermit(params: TransferWithPermitParams): Promise<TransferWithPermitResult>;
|
|
272
272
|
/**
|
|
273
|
-
*
|
|
273
|
+
* Get ETH balance (for gas)
|
|
274
274
|
*/
|
|
275
275
|
getGasBalance(): Promise<string>;
|
|
276
276
|
/**
|
|
277
|
-
*
|
|
277
|
+
* Check if there's enough gas
|
|
278
278
|
*/
|
|
279
279
|
hasEnoughGas(minEth?: number): Promise<boolean>;
|
|
280
280
|
}
|
|
281
281
|
/**
|
|
282
|
-
*
|
|
282
|
+
* Format Permit request message (to send to Boss)
|
|
283
283
|
*/
|
|
284
284
|
declare function formatPermitRequest(params: {
|
|
285
285
|
agentAddress: string;
|
package/dist/wallet/index.js
CHANGED
|
@@ -773,24 +773,24 @@ var PermitWallet = class {
|
|
|
773
773
|
);
|
|
774
774
|
}
|
|
775
775
|
/**
|
|
776
|
-
*
|
|
776
|
+
* Check if Permit is valid (current allowance)
|
|
777
777
|
*/
|
|
778
778
|
async checkPermitAllowance(owner) {
|
|
779
779
|
const allowance = await this.usdcContract.allowance(owner, this.address);
|
|
780
780
|
return (Number(allowance) / 1e6).toFixed(2);
|
|
781
781
|
}
|
|
782
782
|
/**
|
|
783
|
-
*
|
|
783
|
+
* Pay using Permit authorization
|
|
784
784
|
*
|
|
785
|
-
*
|
|
786
|
-
* 1.
|
|
787
|
-
* 2.
|
|
785
|
+
* Flow:
|
|
786
|
+
* 1. Call permit() to record Boss's authorization in the contract
|
|
787
|
+
* 2. Call transferFrom() to transfer from Boss's wallet to recipient
|
|
788
788
|
*
|
|
789
789
|
* @example
|
|
790
790
|
* ```typescript
|
|
791
791
|
* const wallet = new PermitWallet({ chain: 'base' });
|
|
792
792
|
*
|
|
793
|
-
* // Boss
|
|
793
|
+
* // Boss-signed permit data
|
|
794
794
|
* const permit = {
|
|
795
795
|
* owner: '0xBOSS...',
|
|
796
796
|
* spender: wallet.address,
|
|
@@ -913,14 +913,14 @@ var PermitWallet = class {
|
|
|
913
913
|
}
|
|
914
914
|
}
|
|
915
915
|
/**
|
|
916
|
-
*
|
|
916
|
+
* Get ETH balance (for gas)
|
|
917
917
|
*/
|
|
918
918
|
async getGasBalance() {
|
|
919
919
|
const balance = await this.provider.getBalance(this.address);
|
|
920
920
|
return import_ethers3.ethers.formatEther(balance);
|
|
921
921
|
}
|
|
922
922
|
/**
|
|
923
|
-
*
|
|
923
|
+
* Check if there's enough gas
|
|
924
924
|
*/
|
|
925
925
|
async hasEnoughGas(minEth = 1e-3) {
|
|
926
926
|
const balance = await this.getGasBalance();
|
|
@@ -932,17 +932,17 @@ function formatPermitRequest(params) {
|
|
|
932
932
|
const chainConfig = getChain(chain);
|
|
933
933
|
const deadline = Math.floor(Date.now() / 1e3) + deadlineHours * 3600;
|
|
934
934
|
const value = BigInt(Math.floor(amount * 1e6)).toString();
|
|
935
|
-
return `\u{1F510} **USDC
|
|
935
|
+
return `\u{1F510} **USDC Spending Allowance Request**
|
|
936
936
|
|
|
937
|
-
${reason ?
|
|
937
|
+
${reason ? `**Purpose:** ${reason}
|
|
938
938
|
` : ""}
|
|
939
|
-
|
|
940
|
-
-
|
|
941
|
-
-
|
|
942
|
-
-
|
|
943
|
-
-
|
|
939
|
+
**Authorization Details:**
|
|
940
|
+
- Authorized address (Agent): \`${agentAddress}\`
|
|
941
|
+
- Amount: ${amount} USDC
|
|
942
|
+
- Valid for: ${deadlineHours} hours
|
|
943
|
+
- Chain: ${chainConfig.name}
|
|
944
944
|
|
|
945
|
-
|
|
945
|
+
**Please sign the following EIP-2612 Permit with your wallet:**
|
|
946
946
|
|
|
947
947
|
\`\`\`json
|
|
948
948
|
{
|
|
@@ -972,9 +972,9 @@ ${reason ? `**\u7528\u9014:** ${reason}
|
|
|
972
972
|
}
|
|
973
973
|
\`\`\`
|
|
974
974
|
|
|
975
|
-
|
|
975
|
+
After signing, send { v, r, s, deadline } to the Agent.
|
|
976
976
|
|
|
977
|
-
\u26A0\uFE0F
|
|
977
|
+
\u26A0\uFE0F Note: This authorization only allows the Agent to spend up to ${amount} USDC from your wallet. Your private key is never exposed.`;
|
|
978
978
|
}
|
|
979
979
|
// Annotate the CommonJS export names for ESM import in node:
|
|
980
980
|
0 && (module.exports = {
|