@caravo/mcp 0.1.23 → 0.1.24

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 (2) hide show
  1. package/dist/index.js +32 -6
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -733,16 +733,42 @@ function registerAllTools(server) {
733
733
  catch {
734
734
  // ignore
735
735
  }
736
+ const info = {
737
+ address: wallet.address,
738
+ network: "Base mainnet (eip155:8453)",
739
+ usdc_balance: balance,
740
+ };
741
+ // Check if wallet is empty and build funding guidance
742
+ const isWalletEmpty = balance === "0.000000 USDC" || balance === "unknown (check manually)";
743
+ if (isWalletEmpty && !API_KEY) {
744
+ info.funding_guide = [
745
+ "Your wallet has no USDC. Two options to get started:",
746
+ "",
747
+ "Option A — Caravo balance (recommended):",
748
+ ' Run the "login" tool to connect your account, then top up at https://www.caravo.ai/dashboard',
749
+ "",
750
+ "Option B — USDC wallet (no registration):",
751
+ ` Send USDC on Base to ${wallet.address}`,
752
+ "",
753
+ "Top up once to unlock 200+ tools at $0.001–$0.05/call — generate images & videos, analyze website traffic, research academic papers, pull social media analytics, get real-time financial data, and much more.",
754
+ ].join("\n");
755
+ }
756
+ else if (isWalletEmpty && API_KEY) {
757
+ info.funding_guide = [
758
+ "Your wallet has no USDC.",
759
+ "",
760
+ "Top up your Caravo balance at https://www.caravo.ai/dashboard",
761
+ `Or send USDC on Base to ${wallet.address}`,
762
+ ].join("\n");
763
+ }
764
+ else {
765
+ info.note = "Send USDC on Base to this address to enable automatic x402 payments.";
766
+ }
736
767
  return {
737
768
  content: [
738
769
  {
739
770
  type: "text",
740
- text: JSON.stringify({
741
- address: wallet.address,
742
- network: "Base mainnet (eip155:8453)",
743
- usdc_balance: balance,
744
- note: "Send USDC on Base to this address to enable automatic x402 payments.",
745
- }, null, 2),
771
+ text: JSON.stringify(info, null, 2),
746
772
  },
747
773
  ],
748
774
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@caravo/mcp",
3
- "version": "0.1.23",
3
+ "version": "0.1.24",
4
4
  "description": "The API marketplace built for autonomous AI agents. Search, execute, and pay for 200+ tools at $0.001–0.05 per call.",
5
5
  "type": "module",
6
6
  "bin": {