@bananapus/nana-sdk-core 2.24.4 → 2.25.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 (73) hide show
  1. package/dist/cjs/jbcenter/publish.d.ts +6 -5
  2. package/dist/cjs/jbcenter/publish.d.ts.map +1 -1
  3. package/dist/cjs/jbcenter/publish.js +37 -18
  4. package/dist/cjs/jbcenter/publish.js.map +1 -1
  5. package/dist/cjs/jbcenter/rateLimit.d.ts +12 -2
  6. package/dist/cjs/jbcenter/rateLimit.d.ts.map +1 -1
  7. package/dist/cjs/jbcenter/rateLimit.js +20 -3
  8. package/dist/cjs/jbcenter/rateLimit.js.map +1 -1
  9. package/dist/cjs/jbcenter.d.ts +1 -1
  10. package/dist/cjs/jbcenter.d.ts.map +1 -1
  11. package/dist/cjs/jbcenter.js +2 -1
  12. package/dist/cjs/jbcenter.js.map +1 -1
  13. package/dist/cjs/review/contractWrite.d.ts +3 -1
  14. package/dist/cjs/review/contractWrite.d.ts.map +1 -1
  15. package/dist/cjs/review/contractWrite.js +13 -11
  16. package/dist/cjs/review/contractWrite.js.map +1 -1
  17. package/dist/cjs/review/index.d.ts +1 -0
  18. package/dist/cjs/review/index.d.ts.map +1 -1
  19. package/dist/cjs/review/index.js +1 -0
  20. package/dist/cjs/review/index.js.map +1 -1
  21. package/dist/cjs/review/relayr.d.ts +54 -12
  22. package/dist/cjs/review/relayr.d.ts.map +1 -1
  23. package/dist/cjs/review/relayr.js +175 -43
  24. package/dist/cjs/review/relayr.js.map +1 -1
  25. package/dist/cjs/review/safeRelayr.d.ts +1 -1
  26. package/dist/cjs/review/safeRelayr.d.ts.map +1 -1
  27. package/dist/cjs/review/safeRelayr.js +27 -3
  28. package/dist/cjs/review/safeRelayr.js.map +1 -1
  29. package/dist/cjs/review/transaction-message.d.ts +3 -0
  30. package/dist/cjs/review/transaction-message.d.ts.map +1 -0
  31. package/dist/cjs/review/transaction-message.js +19 -0
  32. package/dist/cjs/review/transaction-message.js.map +1 -0
  33. package/dist/cjs/safeService.d.ts +152 -1
  34. package/dist/cjs/safeService.d.ts.map +1 -1
  35. package/dist/cjs/safeService.js +325 -1
  36. package/dist/cjs/safeService.js.map +1 -1
  37. package/dist/esm/jbcenter/publish.d.ts +6 -5
  38. package/dist/esm/jbcenter/publish.d.ts.map +1 -1
  39. package/dist/esm/jbcenter/publish.js +37 -18
  40. package/dist/esm/jbcenter/publish.js.map +1 -1
  41. package/dist/esm/jbcenter/rateLimit.d.ts +12 -2
  42. package/dist/esm/jbcenter/rateLimit.d.ts.map +1 -1
  43. package/dist/esm/jbcenter/rateLimit.js +19 -3
  44. package/dist/esm/jbcenter/rateLimit.js.map +1 -1
  45. package/dist/esm/jbcenter.d.ts +1 -1
  46. package/dist/esm/jbcenter.d.ts.map +1 -1
  47. package/dist/esm/jbcenter.js +1 -1
  48. package/dist/esm/jbcenter.js.map +1 -1
  49. package/dist/esm/review/contractWrite.d.ts +3 -1
  50. package/dist/esm/review/contractWrite.d.ts.map +1 -1
  51. package/dist/esm/review/contractWrite.js +13 -11
  52. package/dist/esm/review/contractWrite.js.map +1 -1
  53. package/dist/esm/review/index.d.ts +1 -0
  54. package/dist/esm/review/index.d.ts.map +1 -1
  55. package/dist/esm/review/index.js +1 -0
  56. package/dist/esm/review/index.js.map +1 -1
  57. package/dist/esm/review/relayr.d.ts +54 -12
  58. package/dist/esm/review/relayr.d.ts.map +1 -1
  59. package/dist/esm/review/relayr.js +170 -42
  60. package/dist/esm/review/relayr.js.map +1 -1
  61. package/dist/esm/review/safeRelayr.d.ts +1 -1
  62. package/dist/esm/review/safeRelayr.d.ts.map +1 -1
  63. package/dist/esm/review/safeRelayr.js +28 -4
  64. package/dist/esm/review/safeRelayr.js.map +1 -1
  65. package/dist/esm/review/transaction-message.d.ts +3 -0
  66. package/dist/esm/review/transaction-message.d.ts.map +1 -0
  67. package/dist/esm/review/transaction-message.js +16 -0
  68. package/dist/esm/review/transaction-message.js.map +1 -0
  69. package/dist/esm/safeService.d.ts +152 -1
  70. package/dist/esm/safeService.d.ts.map +1 -1
  71. package/dist/esm/safeService.js +314 -2
  72. package/dist/esm/safeService.js.map +1 -1
  73. package/package.json +1 -1
@@ -15,6 +15,8 @@ export declare const RELAYR_PAYMENT_ADDRESS: Address;
15
15
  export declare const RELAYR_PAYMENT_SELECTOR = "0x103903a7";
16
16
  /** keccak256 of the payment contract's runtime code. */
17
17
  export declare const RELAYR_PAYMENT_CODE_HASH: Hex;
18
+ /** Prepayment(bytes16 indexed payment_uuid, uint256 amount, uint40 deadline). */
19
+ export declare const RELAYR_PAYMENT_EVENT: Hex;
18
20
  /** The token Relayr quotes for a payment in the chain's native currency. */
19
21
  export declare const RELAYR_NATIVE_TOKEN: Address;
20
22
  /** The gas a payment is simulated and sent with. */
@@ -184,6 +186,8 @@ export type RelayrProofClient = {
184
186
  }): Promise<{
185
187
  hash: Hex | null;
186
188
  }>;
189
+ /** Required only to authenticate a successful wallet-wrapped payment. */
190
+ getCode?: PublicClient["getCode"];
187
191
  };
188
192
  /**
189
193
  * The chain or Relayr contradicts the expected transaction: this evidence can
@@ -196,6 +200,21 @@ export declare class RelayrProofError extends Error {
196
200
  export declare class RelayrProofUnavailableError extends Error {
197
201
  readonly name = "RelayrProofUnavailableError";
198
202
  }
203
+ /**
204
+ * A synchronous final guard refused after saving a payment attempt and before
205
+ * invoking the wallet. Construct only around that guard, never around the
206
+ * persistence callback or wallet call: their failures may hide a submission.
207
+ */
208
+ export declare class RelayrPaymentNotSentError extends Error {
209
+ readonly name = "RelayrPaymentNotSentError";
210
+ constructor(cause: unknown);
211
+ }
212
+ /**
213
+ * Normalize only errors from an invoked wallet: its result cannot prove a
214
+ * local guard refused before invocation. Preserve a branded error privately
215
+ * as `walletError`, not `cause`, which the rejection classifier traverses.
216
+ */
217
+ export declare function relayrWalletPaymentError(error: unknown): unknown;
199
218
  /**
200
219
  * The payment at `hash` is exactly the reviewed payment, canonically included,
201
220
  * and reverted, so that one transaction paid nothing. It does not show that
@@ -317,8 +336,16 @@ export declare function relayrPaymentOptions(quote: Pick<RelayrQuote, "bundle_uu
317
336
  /**
318
337
  * Prove the payment chain runs Relayr's payment contract: the code at
319
338
  * {@link RELAYR_PAYMENT_ADDRESS} hashes to {@link RELAYR_PAYMENT_CODE_HASH}.
339
+ * Pin a receipt's block for recovery; omit it for the latest pre-send check.
320
340
  */
321
- export declare function requireRelayrPaymentRuntime(client: Pick<PublicClient, "getCode">): Promise<void>;
341
+ export declare function requireRelayrPaymentRuntime(client: Pick<PublicClient, "getCode">, blockNumber?: bigint): Promise<void>;
342
+ /**
343
+ * Exactly one matching Prepayment from the pinned payment contract. The
344
+ * caller separately proves the receipt's chain, canonical inclusion, success
345
+ * and runtime. This event proves bundle funding, not the debited account.
346
+ * Uses the pinned runtime's event; older Relayr source has another event.
347
+ */
348
+ export declare function hasRelayrPaymentEvent(logs: unknown, bundleUuid: string, amount: bigint, deadline: bigint): boolean;
322
349
  /**
323
350
  * Simulate the exact payment from `from` with the gas it is sent with,
324
351
  * without CCIP-read. Relayr's contract returns nothing, so a revert or any
@@ -358,14 +385,17 @@ type ReviewedPayment = Pick<RelayrPaymentDetails, "chainId" | "target" | "callda
358
385
  amount: bigint | string;
359
386
  };
360
387
  /**
361
- * Prove a Relayr payment from the chain: the transaction at `hash` is exactly
362
- * `payment` sent by `from` (chain, payment contract, calldata, value),
363
- * canonically included, and successful. Pass the hash that was mined: when a
364
- * wallet speeds a payment up, viem's receipt is the replacement's, so verify
388
+ * Prove funding from a canonical successful transaction. A direct payment
389
+ * must exactly match `from`, contract, calldata and value. A wallet-wrapped
390
+ * payment instead requires the pinned runtime and its unique exact payment
391
+ * event; this proves bundle funding, not whose account was debited.
392
+ * Pass the hash that was mined: when a wallet speeds a payment up, viem's
393
+ * receipt is the replacement's, so verify
365
394
  * its `transactionHash`, not the hash the wallet first returned.
366
395
  *
367
- * Throws {@link RelayrPaymentRevertedError} when it canonically reverted. That
368
- * transaction paid nothing, but the bundle may still be paid by another, so
396
+ * Throws {@link RelayrPaymentRevertedError} only for an exact direct payment
397
+ * that canonically reverted. A wrapped revert cannot prove an inner payment.
398
+ * That transaction paid nothing, but the bundle may still be paid by another, so
369
399
  * only {@link requireRelayrPaymentRetry} clears the quote to be paid again.
370
400
  * {@link RelayrProofError} means the transaction is a different one: never pay
371
401
  * again. Any other error means the proof is unavailable for now.
@@ -433,6 +463,15 @@ export declare function verifyRelayrDestination(client: RelayrProofClient, { ent
433
463
  entry: RelayrEntry;
434
464
  hash: Hex;
435
465
  }): Promise<TransactionReceipt>;
466
+ /**
467
+ * Bind Relayr's status records to a quote in binding order, using the same
468
+ * inventory, request and optional account checks as {@link relayrDestinationHashes}.
469
+ * Missing or malformed hashes do not prevent a record from naming its call;
470
+ * available hashes must still be unique. These records describe progress,
471
+ * not execution proof: verify each reported hash with {@link verifyRelayrDestination}.
472
+ * Throws on incomplete or contradictory bindings; never pay again on an error.
473
+ */
474
+ export declare function relayrDestinationRecords(expected: Parameters<typeof matchingDestinationRecords>[0]): RelayrTransactionRecord[];
436
475
  /**
437
476
  * Bind Relayr's reported destination hashes to a quote. `bindings` are the
438
477
  * quote's {@link RelayrQuote.expectedTransactions}; `records` are Relayr's
@@ -450,11 +489,13 @@ export declare function verifyRelayrDestination(client: RelayrProofClient, { ent
450
489
  * {@link RelayrProofError} when Relayr contradicts a binding and another error
451
490
  * while the reported inventory is incomplete. Never pay again on any error.
452
491
  */
453
- export declare function relayrDestinationHashes({ bindings, records, account, }: {
492
+ export declare function relayrDestinationHashes(expected: Parameters<typeof matchingDestinationRecords>[0]): Hex[];
493
+ /** Yield in binding order so callers can validate each result before the next match. */
494
+ declare function matchingDestinationRecords({ bindings, records, account, }: {
454
495
  bindings: readonly RelayrTransactionBinding[];
455
496
  records: readonly RelayrTransactionRecord[];
456
497
  account?: Address;
457
- }): Hex[];
498
+ }): Generator<RelayrTransactionRecord>;
458
499
  /**
459
500
  * Validate all bindings with {@link relayrDestinationHashes}, then prove each
460
501
  * destination with {@link verifyRelayrDestination}. Returns canonical receipts
@@ -695,9 +736,10 @@ export declare function relayrRetryOption(payments: readonly Pick<RelayrSentPaym
695
736
  * Where a failed payment attempt leaves its quote: `reverted` when the
696
737
  * payment reverted onchain, or when the wallet declined to pay a quote paid
697
738
  * before, which stays on {@link requireRelayrPaymentRetry}'s rule; `unpaid`
698
- * when the wallet declined its first payment; null when nothing is known, and
699
- * the journal stays as it is. `sending` is whether the wallet held the
700
- * payment, and `paid` whether the quote was paid before.
739
+ * when the wallet declined its first payment. A typed final guard refusal
740
+ * before the wallet call has the same outcome. Null means nothing is known,
741
+ * and the journal stays as it is. `sending` is whether the attempt's marker
742
+ * was saved, and `paid` whether the quote was paid before.
701
743
  */
702
744
  export declare function relayrPaymentAttemptOutcome(error: unknown, { sending, paid }: {
703
745
  sending: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"relayr.d.ts","sourceRoot":"","sources":["../../../src/review/relayr.ts"],"names":[],"mappings":"AAAA,OAAO,EAQL,KAAK,OAAO,EACZ,KAAK,GAAG,EACR,KAAK,YAAY,EACjB,KAAK,kBAAkB,EACxB,MAAM,MAAM,CAAC;AACd,OAAO,EACL,mBAAmB,EAEpB,MAAM,0BAA0B,CAAC;AAYlC,yBAAyB;AACzB,eAAO,MAAM,UAAU,iCAAiC,CAAC;AAEzD;;;;GAIG;AACH,eAAO,MAAM,sBAAsB,EACe,OAAO,CAAC;AAE1D;;;GAGG;AACH,eAAO,MAAM,uBAAuB,eAAe,CAAC;AAEpD,wDAAwD;AACxD,eAAO,MAAM,wBAAwB,EACqC,GAAG,CAAC;AAE9E,4EAA4E;AAC5E,eAAO,MAAM,mBAAmB,EACkB,OAAO,CAAC;AAE1D,oDAAoD;AACpD,eAAO,MAAM,kBAAkB,UAAW,CAAC;AAE3C;;;GAGG;AACH,eAAO,MAAM,iCAAiC,QAAe,CAAC;AAE9D,uDAAuD;AACvD,eAAO,MAAM,qBAAqB;;;;;;;;;;;E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;;GAGG;AACH,MAAM,MAAM,mBAAmB,GAAG,iBAAiB,GACjD,IAAI,CAAC,qBAAqB,EAAE,UAAU,CAAC,CAAC;AAE1C,sEAAsE;AACtE,KAAK,aAAa,GAAG;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,kDAAkD;IAClD,QAAQ,EAAE,SAAS,iBAAiB,EAAE,CAAC;IACvC,0DAA0D;IAC1D,OAAO,EAAE,SAAS,aAAa,EAAE,CAAC;IAClC,mBAAmB,EAAE,SAAS,MAAM,EAAE,CAAC;IACvC,+CAA+C;IAC/C,OAAO,EAAE,MAAM,CAAC;CACjB,CAAC;AAyFF;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAsB,mBAAmB,CACvC,SAAS,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,mBAAmB,GAAG,SAAS,EAC/D,KAAK,EAAE,aAAa,EACpB,EACE,KAAK,EAAE,WAA8B,EACrC,KAAK,GACN,GAAE;IAAE,KAAK,CAAC,EAAE,OAAO,UAAU,CAAC,KAAK,CAAC;IAAC,KAAK,CAAC,EAAE,MAAM,CAAA;CAAO,GAC1D,OAAO,CAAC;IACT,KAAK,EAAE,QAAQ,GAAG,SAAS,GAAG,UAAU,CAAC;IACzC,OAAO,EAAE,uBAAuB,EAAE,GAAG,IAAI,CAAC;CAC3C,CAAC,CAmCD"}
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.MAX_RELAYR_SENT_PAYMENTS = exports.RelayrPaymentRetryError = exports.RelayrDestinationRevertedError = exports.RelayrPaymentRevertedError = exports.RelayrProofUnavailableError = exports.RelayrProofError = exports.RELAYR_UUID_RE = exports.FORWARD_REQUEST_TYPES = exports.TRUSTED_FORWARDER_ABI = exports.RELAYR_FORWARDER_DEADLINE_SECONDS = exports.RELAYR_PAYMENT_GAS = exports.RELAYR_NATIVE_TOKEN = exports.RELAYR_PAYMENT_CODE_HASH = exports.RELAYR_PAYMENT_SELECTOR = exports.RELAYR_PAYMENT_ADDRESS = exports.RELAYR_API = void 0;
3
+ exports.MAX_RELAYR_SENT_PAYMENTS = exports.RelayrPaymentRetryError = exports.RelayrDestinationRevertedError = exports.RelayrPaymentRevertedError = exports.RelayrPaymentNotSentError = exports.RelayrProofUnavailableError = exports.RelayrProofError = exports.RELAYR_UUID_RE = exports.FORWARD_REQUEST_TYPES = exports.TRUSTED_FORWARDER_ABI = exports.RELAYR_FORWARDER_DEADLINE_SECONDS = exports.RELAYR_PAYMENT_GAS = exports.RELAYR_NATIVE_TOKEN = exports.RELAYR_PAYMENT_EVENT = exports.RELAYR_PAYMENT_CODE_HASH = exports.RELAYR_PAYMENT_SELECTOR = exports.RELAYR_PAYMENT_ADDRESS = exports.RELAYR_API = void 0;
4
+ exports.relayrWalletPaymentError = relayrWalletPaymentError;
4
5
  exports.relayrSupportsChain = relayrSupportsChain;
5
6
  exports.relayrSupportsChains = relayrSupportsChains;
6
7
  exports.relayrPaymentChains = relayrPaymentChains;
@@ -11,6 +12,7 @@ exports.quoteExpired = quoteExpired;
11
12
  exports.relayrPaymentDetails = relayrPaymentDetails;
12
13
  exports.relayrPaymentOptions = relayrPaymentOptions;
13
14
  exports.requireRelayrPaymentRuntime = requireRelayrPaymentRuntime;
15
+ exports.hasRelayrPaymentEvent = hasRelayrPaymentEvent;
14
16
  exports.simulateRelayrPayment = simulateRelayrPayment;
15
17
  exports.relayrStateIsSuccess = relayrStateIsSuccess;
16
18
  exports.relayrStateIsPending = relayrStateIsPending;
@@ -23,6 +25,7 @@ exports.verifyRelayrPayment = verifyRelayrPayment;
23
25
  exports.requireRelayrPaymentRetry = requireRelayrPaymentRetry;
24
26
  exports.requireRelayrBundleUnpaid = requireRelayrBundleUnpaid;
25
27
  exports.verifyRelayrDestination = verifyRelayrDestination;
28
+ exports.relayrDestinationRecords = relayrDestinationRecords;
26
29
  exports.relayrDestinationHashes = relayrDestinationHashes;
27
30
  exports.verifyRelayrDestinations = verifyRelayrDestinations;
28
31
  exports.atCanonicalFinalizedBlock = atCanonicalFinalizedBlock;
@@ -68,6 +71,8 @@ exports.RELAYR_PAYMENT_ADDRESS = "0x1c05f7841379d4393574c0ffa17908ec40ffd97d";
68
71
  exports.RELAYR_PAYMENT_SELECTOR = "0x103903a7";
69
72
  /** keccak256 of the payment contract's runtime code. */
70
73
  exports.RELAYR_PAYMENT_CODE_HASH = "0x6006b5acadb4cd60aa5c00cb844c34563e182dff83d4f4ff4fde226f7df16fa6";
74
+ /** Prepayment(bytes16 indexed payment_uuid, uint256 amount, uint40 deadline). */
75
+ exports.RELAYR_PAYMENT_EVENT = "0xb96b060a9c075a83da0cf1f9405deeb5df21df681a762de16c3d5eaf99531cd8";
71
76
  /** The token Relayr quotes for a payment in the chain's native currency. */
72
77
  exports.RELAYR_NATIVE_TOKEN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee";
73
78
  /** The gas a payment is simulated and sent with. */
@@ -137,6 +142,31 @@ class RelayrProofUnavailableError extends Error {
137
142
  }
138
143
  }
139
144
  exports.RelayrProofUnavailableError = RelayrProofUnavailableError;
145
+ /**
146
+ * A synchronous final guard refused after saving a payment attempt and before
147
+ * invoking the wallet. Construct only around that guard, never around the
148
+ * persistence callback or wallet call: their failures may hide a submission.
149
+ */
150
+ class RelayrPaymentNotSentError extends Error {
151
+ constructor(cause) {
152
+ super(cause instanceof Error
153
+ ? cause.message
154
+ : "The payment was not sent. Review the payment again.");
155
+ this.name = "RelayrPaymentNotSentError";
156
+ withCause(this, cause);
157
+ }
158
+ }
159
+ exports.RelayrPaymentNotSentError = RelayrPaymentNotSentError;
160
+ /**
161
+ * Normalize only errors from an invoked wallet: its result cannot prove a
162
+ * local guard refused before invocation. Preserve a branded error privately
163
+ * as `walletError`, not `cause`, which the rejection classifier traverses.
164
+ */
165
+ function relayrWalletPaymentError(error) {
166
+ return error instanceof RelayrPaymentNotSentError
167
+ ? withHidden(new Error(error.message), "walletError", error)
168
+ : error;
169
+ }
140
170
  /**
141
171
  * The payment at `hash` is exactly the reviewed payment, canonically included,
142
172
  * and reverted, so that one transaction paid nothing. It does not show that
@@ -650,13 +680,14 @@ function relayrPaymentOptions(quote, destinationChainIds, nowSeconds) {
650
680
  /**
651
681
  * Prove the payment chain runs Relayr's payment contract: the code at
652
682
  * {@link RELAYR_PAYMENT_ADDRESS} hashes to {@link RELAYR_PAYMENT_CODE_HASH}.
683
+ * Pin a receipt's block for recovery; omit it for the latest pre-send check.
653
684
  */
654
- async function requireRelayrPaymentRuntime(client) {
685
+ async function requireRelayrPaymentRuntime(client, blockNumber) {
655
686
  let code;
656
687
  try {
657
688
  code = await client.getCode({
658
689
  address: exports.RELAYR_PAYMENT_ADDRESS,
659
- blockTag: "latest",
690
+ ...(blockNumber === undefined ? { blockTag: "latest" } : { blockNumber }),
660
691
  });
661
692
  }
662
693
  catch (cause) {
@@ -671,6 +702,40 @@ async function requireRelayrPaymentRuntime(client) {
671
702
  throw new Error("Relayr payment contract code is not recognized.");
672
703
  }
673
704
  }
705
+ /**
706
+ * Exactly one matching Prepayment from the pinned payment contract. The
707
+ * caller separately proves the receipt's chain, canonical inclusion, success
708
+ * and runtime. This event proves bundle funding, not the debited account.
709
+ * Uses the pinned runtime's event; older Relayr source has another event.
710
+ */
711
+ function hasRelayrPaymentEvent(logs, bundleUuid, amount, deadline) {
712
+ if (!Array.isArray(logs) ||
713
+ logs.length > 1_024 ||
714
+ typeof bundleUuid !== "string" ||
715
+ !exports.RELAYR_UUID_RE.test(bundleUuid) ||
716
+ typeof amount !== "bigint" ||
717
+ amount < 0n ||
718
+ amount >= 1n << 256n ||
719
+ typeof deadline !== "bigint" ||
720
+ deadline < 0n ||
721
+ deadline >= 1n << 40n)
722
+ return false;
723
+ const matching = logs.filter((log) => {
724
+ if (log === null || typeof log !== "object" || Array.isArray(log))
725
+ return false;
726
+ return (typeof log.address === "string" &&
727
+ log.address.toLowerCase() === exports.RELAYR_PAYMENT_ADDRESS &&
728
+ Array.isArray(log.topics) &&
729
+ log.topics[0] === exports.RELAYR_PAYMENT_EVENT);
730
+ });
731
+ const event = matching[0];
732
+ return (matching.length === 1 &&
733
+ event.removed !== true &&
734
+ event.topics.length === 2 &&
735
+ event.topics[1] === `0x${bundleUuid.replaceAll("-", "").padEnd(64, "0")}` &&
736
+ event.data ===
737
+ `0x${amount.toString(16).padStart(64, "0")}${deadline.toString(16).padStart(64, "0")}`);
738
+ }
674
739
  /**
675
740
  * The node's own words for a failure: a viem error's `details` in its first
676
741
  * eight causes. Its `message` is never read, since over HTTP it quotes the
@@ -796,22 +861,14 @@ function relayrForwardRequest(entry) {
796
861
  return null;
797
862
  }
798
863
  }
799
- /**
800
- * Read `expected.hash` and prove it is exactly the expected transaction,
801
- * canonically included. Returns its receipt, successful or reverted. A
802
- * transaction hash commits to its sender, target, calldata, value and chain,
803
- * so any difference there is a {@link RelayrProofError}. A receipt,
804
- * transaction and block that disagree (a lagging node, a reorg) prove nothing
805
- * either way.
806
- */
807
- async function proveTransaction(client, expected, words) {
808
- const hash = expected.hash.toLowerCase();
864
+ async function readTransaction(client, expectedHash, words) {
865
+ const hash = expectedHash.toLowerCase();
809
866
  let transaction;
810
867
  let receipt;
811
868
  try {
812
869
  [transaction, receipt] = await Promise.all([
813
- client.getTransaction({ hash: expected.hash }),
814
- client.getTransactionReceipt({ hash: expected.hash }),
870
+ client.getTransaction({ hash: expectedHash }),
871
+ client.getTransactionReceipt({ hash: expectedHash }),
815
872
  ]);
816
873
  }
817
874
  catch (cause) {
@@ -821,6 +878,9 @@ async function proveTransaction(client, expected, words) {
821
878
  receipt?.transactionHash?.toLowerCase() !== hash) {
822
879
  throw new RelayrProofUnavailableError(words.unavailable);
823
880
  }
881
+ return { transaction, receipt };
882
+ }
883
+ function requireExpectedTransaction(transaction, expected, words) {
824
884
  if (transaction.chainId !== expected.chainId ||
825
885
  !sameAddress(transaction.to, expected.to) ||
826
886
  typeof transaction.input !== "string" ||
@@ -830,7 +890,9 @@ async function proveTransaction(client, expected, words) {
830
890
  !sameAddress(transaction.from, expected.from))) {
831
891
  throw new RelayrProofError(words.mismatch);
832
892
  }
833
- if (!sameAddress(receipt.to, expected.to) ||
893
+ }
894
+ async function proveReceipt(client, { transaction, receipt }, target, words) {
895
+ if (!sameAddress(receipt.to, target) ||
834
896
  typeof receipt.blockHash !== "string" ||
835
897
  !(0, untrusted_js_1.isBytes32)(receipt.blockHash) ||
836
898
  transaction.blockHash?.toLowerCase() !== receipt.blockHash.toLowerCase() ||
@@ -851,6 +913,15 @@ async function proveTransaction(client, expected, words) {
851
913
  }
852
914
  return receipt;
853
915
  }
916
+ /**
917
+ * Prove the exact transaction and its canonical inclusion. Identity
918
+ * differences contradict the proof; inconsistent RPC answers prove nothing.
919
+ */
920
+ async function proveTransaction(client, expected, words) {
921
+ const proof = await readTransaction(client, expected.hash, words);
922
+ requireExpectedTransaction(proof.transaction, expected, words);
923
+ return proveReceipt(client, proof, expected.to, words);
924
+ }
854
925
  /** A reviewed payment's parts, or null unless it is an authenticated Relayr payment. */
855
926
  function readReviewedPayment(payment) {
856
927
  const bundleUuid = uuidOf(payment?.bundleUuid);
@@ -881,14 +952,17 @@ function verifiablePayment(hashes, from, payment) {
881
952
  : null;
882
953
  }
883
954
  /**
884
- * Prove a Relayr payment from the chain: the transaction at `hash` is exactly
885
- * `payment` sent by `from` (chain, payment contract, calldata, value),
886
- * canonically included, and successful. Pass the hash that was mined: when a
887
- * wallet speeds a payment up, viem's receipt is the replacement's, so verify
955
+ * Prove funding from a canonical successful transaction. A direct payment
956
+ * must exactly match `from`, contract, calldata and value. A wallet-wrapped
957
+ * payment instead requires the pinned runtime and its unique exact payment
958
+ * event; this proves bundle funding, not whose account was debited.
959
+ * Pass the hash that was mined: when a wallet speeds a payment up, viem's
960
+ * receipt is the replacement's, so verify
888
961
  * its `transactionHash`, not the hash the wallet first returned.
889
962
  *
890
- * Throws {@link RelayrPaymentRevertedError} when it canonically reverted. That
891
- * transaction paid nothing, but the bundle may still be paid by another, so
963
+ * Throws {@link RelayrPaymentRevertedError} only for an exact direct payment
964
+ * that canonically reverted. A wrapped revert cannot prove an inner payment.
965
+ * That transaction paid nothing, but the bundle may still be paid by another, so
892
966
  * only {@link requireRelayrPaymentRetry} clears the quote to be paid again.
893
967
  * {@link RelayrProofError} means the transaction is a different one: never pay
894
968
  * again. Any other error means the proof is unavailable for now.
@@ -897,18 +971,51 @@ async function verifyRelayrPayment(client, { hash, from, payment, }) {
897
971
  const reviewed = verifiablePayment([hash], from, payment);
898
972
  if (!reviewed)
899
973
  throw new Error(UNVERIFIABLE);
900
- const receipt = await proveTransaction(client, {
901
- hash,
902
- chainId: reviewed.chainId,
903
- from,
904
- to: exports.RELAYR_PAYMENT_ADDRESS,
905
- data: reviewed.calldata,
906
- value: reviewed.amount,
907
- }, {
974
+ const words = {
908
975
  unavailable: `Could not read Relayr payment ${hash} on chain ${reviewed.chainId}. Do not pay again; check it later.`,
909
976
  mismatch: "The funding transaction does not match the reviewed Relayr payment. Do not pay again; inspect the wallet's activity and the saved bundle.",
910
977
  notCanonical: "The Relayr funding receipt is no longer canonical. Do not pay again; check it later.",
911
- });
978
+ };
979
+ const proof = await readTransaction(client, hash, words);
980
+ const { transaction } = proof;
981
+ if (sameAddress(transaction.to, exports.RELAYR_PAYMENT_ADDRESS)) {
982
+ // A direct call retains all reviewed identity checks, even if its logs
983
+ // contain a payment event (e.g. trailing calldata or another sender).
984
+ requireExpectedTransaction(transaction, {
985
+ hash,
986
+ chainId: reviewed.chainId,
987
+ from,
988
+ to: exports.RELAYR_PAYMENT_ADDRESS,
989
+ data: reviewed.calldata,
990
+ value: reviewed.amount,
991
+ }, words);
992
+ }
993
+ else {
994
+ if (transaction.chainId !== reviewed.chainId ||
995
+ !isAddressLike(transaction.to))
996
+ throw new RelayrProofError(words.mismatch);
997
+ const receipt = await proveReceipt(client, proof, transaction.to, words);
998
+ if (receipt.status !== "success")
999
+ throw new RelayrProofUnavailableError(words.unavailable);
1000
+ if (!hasRelayrPaymentEvent(receipt.logs, reviewed.bundleUuid, reviewed.amount, reviewed.deadline))
1001
+ throw new RelayrProofError(words.mismatch);
1002
+ if (receipt.logs.some((log) => typeof log?.transactionHash !== "string" ||
1003
+ log.transactionHash.toLowerCase() !== hash.toLowerCase() ||
1004
+ typeof log.blockHash !== "string" ||
1005
+ log.blockHash.toLowerCase() !== receipt.blockHash.toLowerCase() ||
1006
+ log.blockNumber !== receipt.blockNumber))
1007
+ throw new RelayrProofUnavailableError(words.unavailable);
1008
+ if (!client.getCode)
1009
+ throw new RelayrProofUnavailableError(words.unavailable);
1010
+ try {
1011
+ await requireRelayrPaymentRuntime({ getCode: client.getCode }, receipt.blockNumber);
1012
+ }
1013
+ catch (cause) {
1014
+ throw withCause(new RelayrProofUnavailableError(words.unavailable), cause);
1015
+ }
1016
+ }
1017
+ // Check canonicality after runtime/event reads too, bracketing a reorg.
1018
+ const receipt = await proveReceipt(client, proof, transaction.to, words);
912
1019
  if (receipt.status === "reverted") {
913
1020
  throw new RelayrPaymentRevertedError("The Relayr funding transaction reverted onchain.", hash, reviewed.chainId);
914
1021
  }
@@ -1032,6 +1139,19 @@ async function verifyRelayrDestination(client, { entry, hash }) {
1032
1139
  }
1033
1140
  return receipt;
1034
1141
  }
1142
+ /**
1143
+ * Bind Relayr's status records to a quote in binding order, using the same
1144
+ * inventory, request and optional account checks as {@link relayrDestinationHashes}.
1145
+ * Missing or malformed hashes do not prevent a record from naming its call;
1146
+ * available hashes must still be unique. These records describe progress,
1147
+ * not execution proof: verify each reported hash with {@link verifyRelayrDestination}.
1148
+ * Throws on incomplete or contradictory bindings; never pay again on an error.
1149
+ */
1150
+ function relayrDestinationRecords(expected) {
1151
+ const records = Array.from(matchingDestinationRecords(expected));
1152
+ requireUniqueDestinationHashes(records.flatMap((record) => relayrDestinationHash(record) ?? []));
1153
+ return records;
1154
+ }
1035
1155
  /**
1036
1156
  * Bind Relayr's reported destination hashes to a quote. `bindings` are the
1037
1157
  * quote's {@link RelayrQuote.expectedTransactions}; `records` are Relayr's
@@ -1049,7 +1169,18 @@ async function verifyRelayrDestination(client, { entry, hash }) {
1049
1169
  * {@link RelayrProofError} when Relayr contradicts a binding and another error
1050
1170
  * while the reported inventory is incomplete. Never pay again on any error.
1051
1171
  */
1052
- function relayrDestinationHashes({ bindings, records, account, }) {
1172
+ function relayrDestinationHashes(expected) {
1173
+ const hashes = Array.from(matchingDestinationRecords(expected), (record) => {
1174
+ const hash = relayrDestinationHash(record);
1175
+ if (!hash)
1176
+ throw new Error(NOT_IDENTIFIED);
1177
+ return hash;
1178
+ });
1179
+ requireUniqueDestinationHashes(hashes);
1180
+ return hashes;
1181
+ }
1182
+ /** Yield in binding order so callers can validate each result before the next match. */
1183
+ function* matchingDestinationRecords({ bindings, records, account, }) {
1053
1184
  const ids = bindings.map((binding) => uuidOf(binding?.txUuid));
1054
1185
  if (!bindings.length ||
1055
1186
  ids.some((id) => id === null) ||
@@ -1076,7 +1207,7 @@ function relayrDestinationHashes({ bindings, records, account, }) {
1076
1207
  new Set(recordIds).size !== records.length) {
1077
1208
  throw new RelayrProofError("Relayr's status names a transaction this quote did not bind. Keep the original bundle pending; do not pay again.");
1078
1209
  }
1079
- const hashes = bindings.map((binding, index) => {
1210
+ for (const [index, binding] of bindings.entries()) {
1080
1211
  const matches = records.filter((record, recordIndex) => relayrRecordChain(record) === binding.chain &&
1081
1212
  (record.request !== undefined && record.request !== null
1082
1213
  ? isRequestFor(record.request, binding.entry, "when-present")
@@ -1084,15 +1215,13 @@ function relayrDestinationHashes({ bindings, records, account, }) {
1084
1215
  if (matches.length !== 1) {
1085
1216
  throw new RelayrProofError("Relayr's destination call does not match the signed request. Keep the original bundle pending; do not pay again.");
1086
1217
  }
1087
- const hash = relayrDestinationHash(matches[0]);
1088
- if (!hash)
1089
- throw new Error(NOT_IDENTIFIED);
1090
- return hash;
1091
- });
1218
+ yield matches[0];
1219
+ }
1220
+ }
1221
+ function requireUniqueDestinationHashes(hashes) {
1092
1222
  if (new Set(hashes.map((hash) => hash.toLowerCase())).size !== hashes.length) {
1093
1223
  throw new RelayrProofError("Relayr reported one destination transaction for two signed calls. Keep the original bundle pending; do not pay again.");
1094
1224
  }
1095
- return hashes;
1096
1225
  }
1097
1226
  /**
1098
1227
  * Validate all bindings with {@link relayrDestinationHashes}, then prove each
@@ -1459,14 +1588,17 @@ function relayrRetryOption(payments, options) {
1459
1588
  * Where a failed payment attempt leaves its quote: `reverted` when the
1460
1589
  * payment reverted onchain, or when the wallet declined to pay a quote paid
1461
1590
  * before, which stays on {@link requireRelayrPaymentRetry}'s rule; `unpaid`
1462
- * when the wallet declined its first payment; null when nothing is known, and
1463
- * the journal stays as it is. `sending` is whether the wallet held the
1464
- * payment, and `paid` whether the quote was paid before.
1591
+ * when the wallet declined its first payment. A typed final guard refusal
1592
+ * before the wallet call has the same outcome. Null means nothing is known,
1593
+ * and the journal stays as it is. `sending` is whether the attempt's marker
1594
+ * was saved, and `paid` whether the quote was paid before.
1465
1595
  */
1466
1596
  function relayrPaymentAttemptOutcome(error, { sending, paid }) {
1467
1597
  if (error instanceof RelayrPaymentRevertedError)
1468
1598
  return "reverted";
1469
- if (sending && (0, contractWrite_js_1.isDefiniteWalletRejection)(error)) {
1599
+ if (sending &&
1600
+ (error instanceof RelayrPaymentNotSentError ||
1601
+ (0, contractWrite_js_1.isDefiniteWalletRejection)(error))) {
1470
1602
  return paid ? "reverted" : "unpaid";
1471
1603
  }
1472
1604
  return null;