moltspay 0.2.6 → 0.2.8

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/index.d.mts CHANGED
@@ -347,13 +347,9 @@ declare const SellerTemplates: {
347
347
  */
348
348
  confirmWalletAddress(address: string): string;
349
349
  /**
350
- * 3.3 Funding Options - Choose method
350
+ * 3.3 Funding Options - Request funding from Owner
351
351
  */
352
- guideFunding(): string;
353
- /**
354
- * 3.4 Guide Permit Authorization
355
- */
356
- guidePermit(agentAddress: string, suggestedAmount?: number): string;
352
+ guideFunding(agentAddress: string, suggestedAmount?: number): string;
357
353
  /**
358
354
  * 3.5 Confirm Capability Ready
359
355
  */
@@ -447,17 +443,13 @@ declare const BuyerTemplates: {
447
443
  */
448
444
  walletCreated(address: string): string;
449
445
  /**
450
- * 3.3 Choose Permit Method
451
- */
452
- choosePermit(): string;
453
- /**
454
- * 3.3 Choose Direct Transfer
446
+ * 3.3 Report Funding Received
455
447
  */
456
- chooseDirectTransfer(): string;
448
+ fundingReceived(amount: number): string;
457
449
  /**
458
- * 3.4 Report Permit Received
450
+ * 3.4 Request Funding from Owner
459
451
  */
460
- permitReceived(amount: number): string;
452
+ requestFunding(agentAddress: string, amount: number, reason?: string): string;
461
453
  /**
462
454
  * 4. Submit Requirements
463
455
  */
package/dist/index.d.ts CHANGED
@@ -347,13 +347,9 @@ declare const SellerTemplates: {
347
347
  */
348
348
  confirmWalletAddress(address: string): string;
349
349
  /**
350
- * 3.3 Funding Options - Choose method
350
+ * 3.3 Funding Options - Request funding from Owner
351
351
  */
352
- guideFunding(): string;
353
- /**
354
- * 3.4 Guide Permit Authorization
355
- */
356
- guidePermit(agentAddress: string, suggestedAmount?: number): string;
352
+ guideFunding(agentAddress: string, suggestedAmount?: number): string;
357
353
  /**
358
354
  * 3.5 Confirm Capability Ready
359
355
  */
@@ -447,17 +443,13 @@ declare const BuyerTemplates: {
447
443
  */
448
444
  walletCreated(address: string): string;
449
445
  /**
450
- * 3.3 Choose Permit Method
451
- */
452
- choosePermit(): string;
453
- /**
454
- * 3.3 Choose Direct Transfer
446
+ * 3.3 Report Funding Received
455
447
  */
456
- chooseDirectTransfer(): string;
448
+ fundingReceived(amount: number): string;
457
449
  /**
458
- * 3.4 Report Permit Received
450
+ * 3.4 Request Funding from Owner
459
451
  */
460
- permitReceived(amount: number): string;
452
+ requestFunding(agentAddress: string, amount: number, reason?: string): string;
461
453
  /**
462
454
  * 4. Submit Requirements
463
455
  */
package/dist/index.js CHANGED
@@ -2621,21 +2621,21 @@ Your wallet address is \`${address}\`.
2621
2621
  Step 2: You need your owner (Boss) to give you payment capability.`;
2622
2622
  },
2623
2623
  /**
2624
- * 3.3 Funding Options - Choose method
2624
+ * 3.3 Funding Options - Request funding from Owner
2625
2625
  */
2626
- guideFunding() {
2627
- return `You now have two ways to get payment capability:
2628
- A) Have Boss transfer USDC directly to your wallet (simple, but you'll hold the funds);
2629
- B) Have Boss give you a "USDC spending allowance" (recommended: you don't hold funds, can only pay within the allowance).
2630
- Which works better for you?`;
2631
- },
2632
- /**
2633
- * 3.4 Guide Permit Authorization
2634
- */
2635
- guidePermit(agentAddress, suggestedAmount = 10) {
2636
- return `OK. Please send this message to your Boss (you can copy it directly):
2637
- "I need a USDC spending allowance (Permit) for purchasing services. Please authorize ${suggestedAmount} USDC to my wallet ${agentAddress}, valid for 24 hours."
2638
- Let me know when you've received the allowance.`;
2626
+ guideFunding(agentAddress, suggestedAmount = 10) {
2627
+ return `Please send this message to your Owner/Boss:
2628
+
2629
+ "I need USDC to pay for services. Please send ${suggestedAmount} USDC to my wallet address:
2630
+
2631
+ \`${agentAddress}\`
2632
+
2633
+ Chain: Base (or Base Sepolia for testing)
2634
+ Token: USDC
2635
+
2636
+ You can use Coinbase, MetaMask, or any wallet to transfer."
2637
+
2638
+ Let me know once the transfer is complete.`;
2639
2639
  },
2640
2640
  /**
2641
2641
  * 3.5 Confirm Capability Ready
@@ -2807,23 +2807,21 @@ My address: ${address}
2807
2807
  [status:wallet_ready]`;
2808
2808
  },
2809
2809
  /**
2810
- * 3.3 Choose Permit Method
2811
- */
2812
- choosePermit() {
2813
- return `I choose B: have Boss give me an allowance (Permit).`;
2814
- },
2815
- /**
2816
- * 3.3 Choose Direct Transfer
2810
+ * 3.3 Report Funding Received
2817
2811
  */
2818
- chooseDirectTransfer() {
2819
- return `I choose A: have Boss transfer USDC directly to my wallet.`;
2812
+ fundingReceived(amount) {
2813
+ return `Owner has sent USDC to my wallet. I now have ${amount} USDC available.
2814
+ [status:funded USDC=${amount}]`;
2820
2815
  },
2821
2816
  /**
2822
- * 3.4 Report Permit Received
2817
+ * 3.4 Request Funding from Owner
2823
2818
  */
2824
- permitReceived(amount) {
2825
- return `Boss has completed the authorization. I now have ${amount} USDC allowance.
2826
- [status:permit_ready USDC=${amount}]`;
2819
+ requestFunding(agentAddress, amount, reason) {
2820
+ return `Owner, I need ${amount} USDC to ${reason || "pay for services"}.
2821
+
2822
+ Please send to my wallet: \`${agentAddress}\`
2823
+ Chain: Base
2824
+ Token: USDC`;
2827
2825
  },
2828
2826
  /**
2829
2827
  * 4. Submit Requirements