@clawcard/cli 3.0.15 → 3.0.16
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/package.json +1 -1
- package/src/commands/agent.js +18 -5
package/package.json
CHANGED
package/src/commands/agent.js
CHANGED
|
@@ -534,11 +534,24 @@ export async function agentWalletSendCmd(options) {
|
|
|
534
534
|
|
|
535
535
|
if (result.success) {
|
|
536
536
|
console.log();
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
console.log(
|
|
537
|
+
if (result.protocol === "x402" || result.protocol === "mpp") {
|
|
538
|
+
console.log(` ${chalk.green("Paid!")} ${result.amountUsdc || "?"} USDC via ${result.protocol}`);
|
|
539
|
+
console.log(` URL: ${chalk.dim(result.url)}`);
|
|
540
|
+
console.log(` TX: ${chalk.dim(result.txHash)}`);
|
|
541
|
+
console.log();
|
|
542
|
+
if (result.data) {
|
|
543
|
+
console.log(` ${orange("Response:")}`);
|
|
544
|
+
try {
|
|
545
|
+
const parsed = JSON.parse(result.data);
|
|
546
|
+
console.log(JSON.stringify(parsed, null, 2));
|
|
547
|
+
} catch {
|
|
548
|
+
console.log(result.data.slice(0, 2000));
|
|
549
|
+
}
|
|
550
|
+
}
|
|
551
|
+
} else {
|
|
552
|
+
console.log(` ${chalk.green("Sent!")} ${result.amountUsdc} USDC → ${result.to}`);
|
|
553
|
+
console.log(` TX: ${chalk.dim(result.txHash)}`);
|
|
554
|
+
console.log(` Protocol: ${result.protocol}`);
|
|
542
555
|
}
|
|
543
556
|
console.log();
|
|
544
557
|
} else {
|