moltspay 1.6.0 → 2.0.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 (55) hide show
  1. package/README.md +1 -0
  2. package/dist/cdp/index.js.map +1 -1
  3. package/dist/cdp/index.mjs.map +1 -1
  4. package/dist/{cdp-DeohBe1o.d.ts → cdp-B5PhDUTC.d.ts} +1 -1
  5. package/dist/{cdp-p_eHuQpb.d.mts → cdp-D-5Hg3y_.d.mts} +1 -1
  6. package/dist/chains/index.d.mts +37 -1
  7. package/dist/chains/index.d.ts +37 -1
  8. package/dist/chains/index.js +22 -0
  9. package/dist/chains/index.js.map +1 -1
  10. package/dist/chains/index.mjs +19 -0
  11. package/dist/chains/index.mjs.map +1 -1
  12. package/dist/cli/index.js +1466 -61
  13. package/dist/cli/index.js.map +1 -1
  14. package/dist/cli/index.mjs +1466 -61
  15. package/dist/cli/index.mjs.map +1 -1
  16. package/dist/client/index.d.mts +41 -0
  17. package/dist/client/index.d.ts +41 -0
  18. package/dist/client/index.js +824 -10
  19. package/dist/client/index.js.map +1 -1
  20. package/dist/client/index.mjs +824 -10
  21. package/dist/client/index.mjs.map +1 -1
  22. package/dist/client/web/index.d.mts +17 -1
  23. package/dist/client/web/index.mjs +11 -0
  24. package/dist/client/web/index.mjs.map +1 -1
  25. package/dist/facilitators/index.d.mts +161 -4
  26. package/dist/facilitators/index.d.ts +161 -4
  27. package/dist/facilitators/index.js +370 -0
  28. package/dist/facilitators/index.js.map +1 -1
  29. package/dist/facilitators/index.mjs +365 -0
  30. package/dist/facilitators/index.mjs.map +1 -1
  31. package/dist/index.d.mts +77 -2
  32. package/dist/index.d.ts +77 -2
  33. package/dist/index.js +1412 -31
  34. package/dist/index.js.map +1 -1
  35. package/dist/index.mjs +1406 -31
  36. package/dist/index.mjs.map +1 -1
  37. package/dist/mcp/index.js +828 -14
  38. package/dist/mcp/index.js.map +1 -1
  39. package/dist/mcp/index.mjs +828 -14
  40. package/dist/mcp/index.mjs.map +1 -1
  41. package/dist/{registry-OsEO2dOu.d.mts → registry-DIo0WNoO.d.mts} +8 -1
  42. package/dist/{registry-OsEO2dOu.d.ts → registry-DIo0WNoO.d.ts} +8 -1
  43. package/dist/server/index.d.mts +95 -2
  44. package/dist/server/index.d.ts +95 -2
  45. package/dist/server/index.js +554 -14
  46. package/dist/server/index.js.map +1 -1
  47. package/dist/server/index.mjs +554 -14
  48. package/dist/server/index.mjs.map +1 -1
  49. package/dist/verify/index.js.map +1 -1
  50. package/dist/verify/index.mjs.map +1 -1
  51. package/dist/wallet/index.js.map +1 -1
  52. package/dist/wallet/index.mjs.map +1 -1
  53. package/package.json +7 -1
  54. package/schemas/moltspay.services.schema.json +100 -6
  55. package/scripts/postinstall.js +91 -0
@@ -326,6 +326,22 @@ declare function solanaSigner(adapter: SolanaSignerAdapter): PaymentSigner;
326
326
 
327
327
  declare function composeSigners(...signers: PaymentSigner[]): PaymentSigner;
328
328
 
329
+ /**
330
+ * Browser stub for the Alipay rail (design §5.2.7).
331
+ *
332
+ * The Alipay rail is driven by the `alipay-bot` Node CLI, which cannot run in
333
+ * a browser. 2.0.0 deliberately ships no real Web implementation rather than a
334
+ * fake promise — the cashier-URL fallback (skill guide §6) is slated for
335
+ * 1.7.1 / 1.8.0. This stub exists so the Web bundle can reference the rail and
336
+ * fail loudly with a stable, actionable error instead of a missing import.
337
+ *
338
+ * IMPORTANT: this file must NOT import `../alipay/*` — those modules pull in
339
+ * Node `child_process`/`fs` and would break the browser bundle.
340
+ */
341
+ declare class AlipayWebClient {
342
+ pay(): Promise<never>;
343
+ }
344
+
329
345
  /**
330
346
  * MoltsPay Web Client
331
347
  *
@@ -415,4 +431,4 @@ declare class MoltsPayWebClient {
415
431
  private paySolana;
416
432
  }
417
433
 
418
- export { type ChainName, type Eip1193ChainMetadata, type Eip1193Provider, type Eip1193SignerOptions, InsufficientBalanceError, MoltsPayError, MoltsPayWebClient, type MoltsPayWebClientOptions, NeedsApprovalError, PaymentRejectedError, type PaymentSigner, ServerError, type SolanaSignerAdapter, SpendingLedger, SpendingLimitExceededError, type SpendingLimitsConfig, UnsupportedChainError, type WebPayOptions, composeSigners, eip1193Signer, solanaSigner };
434
+ export { AlipayWebClient, type ChainName, type Eip1193ChainMetadata, type Eip1193Provider, type Eip1193SignerOptions, InsufficientBalanceError, MoltsPayError, MoltsPayWebClient, type MoltsPayWebClientOptions, NeedsApprovalError, PaymentRejectedError, type PaymentSigner, ServerError, type SolanaSignerAdapter, SpendingLedger, SpendingLimitExceededError, type SpendingLimitsConfig, UnsupportedChainError, type WebPayOptions, composeSigners, eip1193Signer, solanaSigner };
@@ -838,6 +838,16 @@ function composeSigners(...signers) {
838
838
  };
839
839
  }
840
840
 
841
+ // src/client/web/alipay.ts
842
+ var AlipayWebClient = class {
843
+ async pay() {
844
+ throw new UnsupportedChainError(
845
+ "alipay",
846
+ "alipay rail is not available in the browser; use the Node CLI (moltspay pay --rail alipay) or wait for v1.8.0"
847
+ );
848
+ }
849
+ };
850
+
841
851
  // src/client/web/index.ts
842
852
  var MoltsPayWebClient = class {
843
853
  constructor(options) {
@@ -1273,6 +1283,7 @@ var MoltsPayWebClient = class {
1273
1283
  }
1274
1284
  };
1275
1285
  export {
1286
+ AlipayWebClient,
1276
1287
  InsufficientBalanceError,
1277
1288
  MoltsPayError,
1278
1289
  MoltsPayWebClient,