@tokenops/sdk 2.0.0-alpha.2 → 2.0.0-alpha.4

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 (160) hide show
  1. package/CHANGELOG.md +92 -3
  2. package/README.md +76 -34
  3. package/SUPPORT.md +1 -1
  4. package/dist/{chunk-PYYSB5ZN.js → chunk-2ND7US2I.js} +1 -1
  5. package/dist/{chunk-EYDA6Q6C.js → chunk-3ZSPRHR3.js} +63 -12
  6. package/dist/{chunk-X7WBPCEU.js → chunk-67Q6KSVV.js} +4578 -3383
  7. package/dist/{chunk-UHHMVBLU.cjs → chunk-6AYJRUGP.cjs} +7 -50
  8. package/dist/{chunk-FEDX7B6T.cjs → chunk-6FUHF73F.cjs} +5 -5
  9. package/dist/{chunk-NWFMBLSQ.js → chunk-7KY4K4PH.js} +1 -1
  10. package/dist/{chunk-FHWSBGWE.cjs → chunk-ARZ5C3FS.cjs} +7 -7
  11. package/dist/{chunk-SPLNGUFF.js → chunk-AX6MQAWU.js} +2 -2
  12. package/dist/{chunk-IGO5XSPS.js → chunk-BSXEX2SH.js} +3 -3
  13. package/dist/{chunk-44YJPMQC.js → chunk-CHGY6B7L.js} +34 -81
  14. package/dist/{chunk-IUKKNJ2R.cjs → chunk-DFK5GCJP.cjs} +55 -72
  15. package/dist/{chunk-PZZK3O3S.cjs → chunk-E4IV4M4E.cjs} +4598 -3403
  16. package/dist/{chunk-A4DCEE33.js → chunk-GHGF65LN.js} +16 -12
  17. package/dist/{chunk-TWT3STIX.js → chunk-K3R27WX4.js} +8 -46
  18. package/dist/{chunk-GADGBQJO.js → chunk-KJUNBOJQ.js} +52 -71
  19. package/dist/{chunk-MM5BV5CS.cjs → chunk-PO3A2AQX.cjs} +4 -4
  20. package/dist/{chunk-EBLBPUPI.cjs → chunk-QHDMPT7I.cjs} +72 -19
  21. package/dist/{chunk-3YHBO2DL.cjs → chunk-S47IBDTA.cjs} +36 -83
  22. package/dist/{chunk-UG5RKLU2.cjs → chunk-SUYBAF27.cjs} +1 -1
  23. package/dist/{chunk-WJMEBBU7.js → chunk-TWU7L5H7.js} +5 -48
  24. package/dist/{chunk-WJLECC22.cjs → chunk-UUSSWOPR.cjs} +9 -47
  25. package/dist/{chunk-AREQJHKA.cjs → chunk-VHKMWWBA.cjs} +428 -22
  26. package/dist/{chunk-FT5H2Q7Y.cjs → chunk-YAL6JSAZ.cjs} +16 -12
  27. package/dist/{chunk-VW356KR3.js → chunk-YMWMIWBP.js} +421 -25
  28. package/dist/core/addresses.d.ts +4 -4
  29. package/dist/core/errors.d.ts +1 -1
  30. package/dist/core/index.d.ts +1 -0
  31. package/dist/core/pending.d.ts +57 -0
  32. package/dist/core/version.d.ts +1 -1
  33. package/dist/fhe/operators.d.ts +6 -5
  34. package/dist/fhe/types.d.ts +1 -1
  35. package/dist/fhe-airdrop/abis/airdrop-base.d.ts +97 -1
  36. package/dist/fhe-airdrop/abis/ecdsa.d.ts +117 -1
  37. package/dist/fhe-airdrop/abis/factory.d.ts +332 -1
  38. package/dist/fhe-airdrop/abis/merkle.d.ts +116 -1
  39. package/dist/fhe-airdrop/advanced/index.cjs +8 -4
  40. package/dist/fhe-airdrop/advanced/index.d.cts +1 -0
  41. package/dist/fhe-airdrop/advanced/index.d.ts +1 -0
  42. package/dist/fhe-airdrop/advanced/index.js +1 -1
  43. package/dist/fhe-airdrop/advanced/react/index.cjs +145 -137
  44. package/dist/fhe-airdrop/advanced/react/index.d.cts +1 -0
  45. package/dist/fhe-airdrop/advanced/react/index.d.ts +1 -0
  46. package/dist/fhe-airdrop/advanced/react/index.js +85 -78
  47. package/dist/fhe-airdrop/advanced/react/useClearCompliancePolicy.d.ts +3 -1
  48. package/dist/fhe-airdrop/advanced/react/useDisableCustomFee.d.ts +4 -1
  49. package/dist/fhe-airdrop/advanced/react/useFactoryComplianceDelegate.d.ts +2 -4
  50. package/dist/fhe-airdrop/advanced/react/useFactoryRenounceRole.d.ts +4 -3
  51. package/dist/fhe-airdrop/advanced/react/useFactoryRevokeRole.d.ts +9 -7
  52. package/dist/fhe-airdrop/advanced/react/useFactoryRoleMembers.d.ts +6 -5
  53. package/dist/fhe-airdrop/advanced/react/useSetComplianceDelegate.d.ts +7 -7
  54. package/dist/fhe-airdrop/advanced/react/useSetComplianceManagerImpl.d.ts +3 -1
  55. package/dist/fhe-airdrop/advanced/react/useSetCompliancePolicy.d.ts +2 -1
  56. package/dist/fhe-airdrop/advanced/react/useSetCustomFee.d.ts +4 -1
  57. package/dist/fhe-airdrop/advanced/react/useSetDefaultDelegateToCompliance.d.ts +5 -4
  58. package/dist/fhe-airdrop/advanced/react/useSetDefaultGasFee.d.ts +7 -3
  59. package/dist/fhe-airdrop/advanced/react/useSetMaxGasFee.d.ts +37 -0
  60. package/dist/fhe-airdrop/airdrop-base.d.ts +142 -18
  61. package/dist/fhe-airdrop/campaign.d.ts +37 -73
  62. package/dist/fhe-airdrop/compliance-clone.d.ts +21 -0
  63. package/dist/fhe-airdrop/constants.d.ts +11 -1
  64. package/dist/fhe-airdrop/ecdsa.d.ts +79 -26
  65. package/dist/fhe-airdrop/encryption.d.ts +19 -6
  66. package/dist/fhe-airdrop/errors.d.ts +136 -2
  67. package/dist/fhe-airdrop/factory-params.d.ts +2361 -0
  68. package/dist/fhe-airdrop/factory.d.ts +189 -75
  69. package/dist/fhe-airdrop/guards.d.ts +183 -19
  70. package/dist/fhe-airdrop/index.cjs +88 -56
  71. package/dist/fhe-airdrop/index.d.cts +12 -10
  72. package/dist/fhe-airdrop/index.d.ts +12 -10
  73. package/dist/fhe-airdrop/index.js +5 -5
  74. package/dist/fhe-airdrop/merkle-tree.d.ts +9 -9
  75. package/dist/fhe-airdrop/merkle.d.ts +32 -11
  76. package/dist/fhe-airdrop/react/_shared.d.ts +12 -6
  77. package/dist/fhe-airdrop/react/index.cjs +336 -240
  78. package/dist/fhe-airdrop/react/index.d.cts +19 -9
  79. package/dist/fhe-airdrop/react/index.d.ts +19 -9
  80. package/dist/fhe-airdrop/react/index.js +158 -97
  81. package/dist/fhe-airdrop/react/keys.d.ts +54 -7
  82. package/dist/fhe-airdrop/react/useAccessEcdsaClaimAmount.d.ts +6 -3
  83. package/dist/fhe-airdrop/react/useAccessMerkleClaimAmount.d.ts +2 -2
  84. package/dist/fhe-airdrop/react/useAirdropConfig.d.ts +8 -3
  85. package/dist/fhe-airdrop/react/useAirdropPause.d.ts +5 -0
  86. package/dist/fhe-airdrop/react/useBuildMerkleCampaign.d.ts +4 -6
  87. package/dist/fhe-airdrop/react/useComplianceManager.d.ts +2 -2
  88. package/dist/fhe-airdrop/react/useComplianceManagerOf.d.ts +1 -2
  89. package/dist/fhe-airdrop/react/useCreateAndFundEcdsaAirdrop.d.ts +16 -11
  90. package/dist/fhe-airdrop/react/useCreateAndFundMerkleAirdrop.d.ts +23 -7
  91. package/dist/fhe-airdrop/react/useCreateEcdsaAirdrop.d.ts +13 -8
  92. package/dist/fhe-airdrop/react/useCreateMerkleAirdrop.d.ts +27 -7
  93. package/dist/fhe-airdrop/react/useDedupMode.d.ts +16 -0
  94. package/dist/fhe-airdrop/react/useDiscloseHandleToParty.d.ts +4 -3
  95. package/dist/fhe-airdrop/react/useEcdsaClaim.d.ts +6 -4
  96. package/dist/fhe-airdrop/react/useEcdsaClaimAndUnwrap.d.ts +15 -8
  97. package/dist/fhe-airdrop/react/useEcdsaDomain.d.ts +1 -1
  98. package/dist/fhe-airdrop/react/useEncryptCampaignAmounts.d.ts +5 -7
  99. package/dist/fhe-airdrop/react/useExtendClaimWindow.d.ts +4 -1
  100. package/dist/fhe-airdrop/react/useFactoryFees.d.ts +11 -4
  101. package/dist/fhe-airdrop/react/useFundAirdrop.d.ts +3 -4
  102. package/dist/fhe-airdrop/react/useGrantInstanceRoles.d.ts +2 -1
  103. package/dist/fhe-airdrop/react/useIsAirdrop.d.ts +44 -0
  104. package/dist/fhe-airdrop/react/useIsSignatureValid.d.ts +5 -4
  105. package/dist/fhe-airdrop/react/useMerkleClaim.d.ts +4 -1
  106. package/dist/fhe-airdrop/react/useMerkleClaimAndUnwrap.d.ts +14 -3
  107. package/dist/fhe-airdrop/react/usePlanMerkleCampaign.d.ts +18 -3
  108. package/dist/fhe-airdrop/react/usePreflightClaim.d.ts +1 -1
  109. package/dist/fhe-airdrop/react/usePreflightCreateAirdrop.d.ts +34 -13
  110. package/dist/fhe-airdrop/react/useRefreshComplianceBalance.d.ts +36 -0
  111. package/dist/fhe-airdrop/react/useRescueERC20.d.ts +3 -3
  112. package/dist/fhe-airdrop/react/useRescueNativeToken.d.ts +23 -0
  113. package/dist/fhe-airdrop/react/useResolveGasFee.d.ts +30 -0
  114. package/dist/fhe-airdrop/react/useRotateMerkleRoot.d.ts +5 -2
  115. package/dist/fhe-airdrop/react/useSignClaimAuthorization.d.ts +4 -0
  116. package/dist/fhe-airdrop/react/useTokenOf.d.ts +29 -0
  117. package/dist/fhe-airdrop/react/useUnwrapRequest.d.ts +25 -0
  118. package/dist/fhe-airdrop/react/useWithdrawConfidential.d.ts +4 -0
  119. package/dist/fhe-airdrop/roles.d.ts +82 -7
  120. package/dist/fhe-airdrop/types.d.ts +122 -14
  121. package/dist/fhe-disperse/errors.d.ts +3 -3
  122. package/dist/fhe-disperse/index.cjs +22 -22
  123. package/dist/fhe-disperse/index.d.cts +2 -1
  124. package/dist/fhe-disperse/index.d.ts +2 -1
  125. package/dist/fhe-disperse/index.js +3 -3
  126. package/dist/fhe-disperse/react/index.cjs +27 -25
  127. package/dist/fhe-disperse/react/index.d.cts +2 -1
  128. package/dist/fhe-disperse/react/index.d.ts +2 -1
  129. package/dist/fhe-disperse/react/index.js +8 -6
  130. package/dist/fhe-disperse/react/useDisperse.d.ts +6 -2
  131. package/dist/fhe-disperse/react/useRegister.d.ts +9 -3
  132. package/dist/fhe-disperse/react/useSingletonWithdrawTokenFee.d.ts +7 -2
  133. package/dist/fhe-disperse/react/useWithdrawTokenFee.d.ts +7 -2
  134. package/dist/fhe-disperse/singleton.d.ts +33 -19
  135. package/dist/fhe-disperse/types.d.ts +48 -8
  136. package/dist/fhe-vesting/advanced/index.cjs +6 -6
  137. package/dist/fhe-vesting/advanced/index.js +4 -4
  138. package/dist/fhe-vesting/advanced/react/index.cjs +9 -9
  139. package/dist/fhe-vesting/advanced/react/index.js +6 -6
  140. package/dist/fhe-vesting/factory.d.ts +31 -8
  141. package/dist/fhe-vesting/index.cjs +23 -23
  142. package/dist/fhe-vesting/index.d.cts +3 -2
  143. package/dist/fhe-vesting/index.d.ts +3 -2
  144. package/dist/fhe-vesting/index.js +4 -4
  145. package/dist/fhe-vesting/manager.d.ts +27 -2
  146. package/dist/fhe-vesting/react/index.cjs +126 -126
  147. package/dist/fhe-vesting/react/index.d.cts +3 -2
  148. package/dist/fhe-vesting/react/index.d.ts +3 -2
  149. package/dist/fhe-vesting/react/index.js +5 -5
  150. package/dist/fhe-vesting/react/useCreateManager.d.ts +16 -9
  151. package/dist/fhe-vesting/react/useCreateManagerAndGetAddress.d.ts +9 -5
  152. package/dist/fhe-vesting/react/useSplitVesting.d.ts +9 -3
  153. package/dist/index.cjs +18 -18
  154. package/dist/index.js +1 -1
  155. package/dist/testnet-faucet/faucet.d.ts +3 -0
  156. package/dist/testnet-faucet/index.cjs +15 -15
  157. package/dist/testnet-faucet/index.js +3 -3
  158. package/dist/testnet-faucet/react/index.cjs +9 -9
  159. package/dist/testnet-faucet/react/index.js +4 -4
  160. package/package.json +1 -1
@@ -1,9 +1,9 @@
1
1
  import type { Address, Hex, PublicClient } from "viem";
2
2
  import type { PreflightResult } from "../core/preflight.js";
3
- import type { DeploymentMode } from "./constants.js";
3
+ import { type DeploymentMode } from "./constants.js";
4
4
  import { type AirdropVariant } from "./errors.js";
5
5
  import type { ConfidentialAirdropFactoryClient } from "./factory.js";
6
- import type { EcdsaAirdropParams, MerkleAirdropParams } from "./types.js";
6
+ import type { CreateCommitments, EcdsaAirdropParams, MerkleAirdropParams, PlannedCampaign } from "./types.js";
7
7
  /**
8
8
  * Chains the airdrop v2 contracts are reachable on.
9
9
  *
@@ -104,6 +104,57 @@ export interface AssertSaltAvailableArgs {
104
104
  * @alpha
105
105
  */
106
106
  export declare function assertSaltAvailable(args: AssertSaltAvailableArgs): Promise<void>;
107
+ /**
108
+ * The slice of {@link ConfidentialAirdropFactoryClient} the create fee checks
109
+ * read. Structural so this module keeps its runtime-import-free shape; the real
110
+ * client satisfies it as-is.
111
+ *
112
+ * @alpha
113
+ */
114
+ export interface GasFeeResolver {
115
+ address: Address;
116
+ resolveGasFee(creator: Address): Promise<bigint>;
117
+ }
118
+ /**
119
+ * Inputs for {@link assertCreateGasFee}.
120
+ *
121
+ * @alpha
122
+ */
123
+ export interface AssertGasFeeAcceptedArgs {
124
+ factory: GasFeeResolver;
125
+ /** The account that will send `create*`; fee overrides are per-creator. */
126
+ creator: Address;
127
+ /** `CommonAirdropParams.maxAcceptedGasFee`, in wei. */
128
+ maxAcceptedGasFee: bigint;
129
+ /** Label for the thrown error. */
130
+ method: string;
131
+ }
132
+ /**
133
+ * Both create-time fee checks, in the order the factory's `_create` runs them:
134
+ * the resolved fee against the factory's own `maxGasFee` ceiling first
135
+ * (`GasFeeExceedsMaximum`), then against the creator's `maxAcceptedGasFee`
136
+ * (`GasFeeNotAccepted`). Reporting the bound first would tell a creator to
137
+ * raise it when the ceiling would refuse the create anyway.
138
+ *
139
+ * The contract enforces both. Doing it here buys the reason: the revert
140
+ * carries the numbers but not which factory knob produced them, and a creator
141
+ * who sees `resolvedFee` next to their own bound can tell a raised default from
142
+ * a custom override they did not know they had.
143
+ *
144
+ * The range check is not redundant with the comparison - a bound outside
145
+ * `uint96` silently wraps at the ABI edge and could encode as a SMALLER number
146
+ * than intended, turning "accept anything" into "accept almost nothing".
147
+ *
148
+ * @throws {@link InvalidArgumentError} when `maxAcceptedGasFee` is outside `uint96`, or on `gasFee` when the resolved fee exceeds the ceiling.
149
+ * @throws {@link GasFeeNotAcceptedError} when the resolved fee is within the ceiling but above the bound.
150
+ *
151
+ * @internal
152
+ */
153
+ export declare function assertCreateGasFee(args: AssertGasFeeAcceptedArgs & {
154
+ factory: GasFeeResolver & {
155
+ maxGasFee(): Promise<bigint>;
156
+ };
157
+ }): Promise<void>;
107
158
  /**
108
159
  * Inputs for {@link assertPredictionFresh}.
109
160
  *
@@ -132,6 +183,38 @@ export interface AssertPredictionFreshArgs {
132
183
  * @alpha
133
184
  */
134
185
  export declare function assertPredictionFresh(args: AssertPredictionFreshArgs): void;
186
+ /**
187
+ * Inputs for {@link resolvePlannedCreate}.
188
+ *
189
+ * @internal
190
+ */
191
+ export interface ResolvePlannedCreateArgs {
192
+ /** Label for the thrown error. */
193
+ method: string;
194
+ params: MerkleAirdropParams;
195
+ expected?: Partial<CreateCommitments> | undefined;
196
+ /** Preflight only; the write path reads the live hash itself. */
197
+ expectedInitCodeHash?: Hex | undefined;
198
+ plan?: PlannedCampaign | undefined;
199
+ }
200
+ /**
201
+ * Fold a {@link PlannedCampaign} into the pins a Merkle create is sent with.
202
+ *
203
+ * Without a plan the caller's `expected` and `expectedInitCodeHash` come back
204
+ * untouched. With one, `expected.airdrop` becomes `plan.predictedAddress` and
205
+ * the drift check is judged against `plan.initCodeHashAfter`. A caller-supplied
206
+ * value that disagrees with the plan is refused rather than overridden, so the
207
+ * plan never silently wins over something the caller wrote down. Static: no RPC.
208
+ *
209
+ * @throws {@link InvalidArgumentError} when `params.merkleRoot`, `expected.airdrop`
210
+ * or `expectedInitCodeHash` disagrees with the plan.
211
+ *
212
+ * @internal
213
+ */
214
+ export declare function resolvePlannedCreate(args: ResolvePlannedCreateArgs): {
215
+ expected: Partial<CreateCommitments> | undefined;
216
+ expectedInitCodeHash: Hex | undefined;
217
+ };
135
218
  /** Fields shared by both variants of {@link PreflightCreateArgs}. */
136
219
  interface PreflightCreateCommon {
137
220
  factory: ConfidentialAirdropFactoryClient;
@@ -140,11 +223,35 @@ interface PreflightCreateCommon {
140
223
  creator: Address;
141
224
  userSalt: Hex;
142
225
  /**
143
- * The variant's init-code hash observed when the address was predicted -
144
- * e.g. `PlannedCampaign.initCodeHashAfter`. Supplying it turns on the
145
- * drift check; omitting it skips that one check only.
226
+ * The variant's init-code hash observed when the address was predicted.
227
+ * Supplying it turns on the drift check; omitting it skips that one check
228
+ * only. A Merkle `plan` supplies `plan.initCodeHashAfter` for you.
146
229
  */
147
230
  expectedInitCodeHash?: Hex | undefined;
231
+ /**
232
+ * Commitments to pin instead of quoting fresh at send time. Anything omitted is read
233
+ * from the factory just before the transaction. For a {@link PlannedCampaign}, pass
234
+ * `plan` on the Merkle arm instead; `{ airdrop: plan.predictedAddress }` here is the
235
+ * lower-level equivalent of its pin.
236
+ *
237
+ * The preflight compares each pinned field with the factory's fresh quote and reports a
238
+ * `CreateCommitmentMismatchError` blocker (with that `field`) when they differ, since the
239
+ * factory would revert the create on it.
240
+ */
241
+ expected?: Partial<CreateCommitments> | undefined;
242
+ }
243
+ /** @alpha */
244
+ export interface PreflightCreateResult extends PreflightResult {
245
+ /**
246
+ * The commitments the create would be sent with - the fresh quote with any pinned
247
+ * `expected` field taking precedence - what an app shows the creator and compares with a
248
+ * published record. A pinned field that differs from the fresh quote is reported here as
249
+ * pinned and also as a `CreateCommitmentMismatchError` blocker. Absent when a read
250
+ * producing the quote failed: with nothing pinned no blocker is added, and with a pin
251
+ * the failure is a blocker (a typed SDK error) or is rethrown (anything else), so the
252
+ * mismatch check is never skipped silently.
253
+ */
254
+ commitments?: CreateCommitments;
148
255
  }
149
256
  /**
150
257
  * Inputs for {@link preflightCreate}.
@@ -157,32 +264,49 @@ export type PreflightCreateArgs = PreflightCreateCommon & ({
157
264
  } | {
158
265
  variant: "merkle";
159
266
  params: MerkleAirdropParams;
267
+ /**
268
+ * The {@link PlannedCampaign} the create will realise. Pins
269
+ * `expected.airdrop` to `plan.predictedAddress` and turns the drift check
270
+ * on against `plan.initCodeHashAfter`. A `params.merkleRoot`,
271
+ * `expected.airdrop` or `expectedInitCodeHash` that disagrees with the
272
+ * plan is reported as an `InvalidArgumentError` blocker.
273
+ */
274
+ plan?: PlannedCampaign | undefined;
160
275
  });
161
276
  /**
162
277
  * Run every create-time guardrail read-only and report what would block the
163
278
  * transaction, instead of throwing on the first problem.
164
279
  *
165
280
  * Same checks and the same typed errors the write path enforces: chain
166
- * support, the Merkle/UUPS refusal, the creator's effective
281
+ * support, the Merkle/UUPS refusal, params the instance initializer would
282
+ * revert on (a zero token, an `endTime` less than a minute away, a window
283
+ * that does not open before it closes, a zero immutable Merkle root, a zero
284
+ * ECDSA signer; `InvalidArgumentError` naming the field), the creator's resolved gas fee against
285
+ * `common.maxAcceptedGasFee` and against the factory's `maxGasFee` ceiling
286
+ * (an `InvalidArgumentError` on `gasFee`, the same error the create's
287
+ * `GasFeeExceedsMaximum` revert maps to), the creator's effective
167
288
  * upgradeability policy when `mode: "uups"` is requested, the stock-wrapper
168
289
  * probe when `unwrappable` is set, a salt collision on the predicted
169
- * address, and - when `expectedInitCodeHash` is supplied - implementation
170
- * drift since the prediction was taken.
290
+ * address (the pinned `expected.airdrop` when given), a pinned commitment
291
+ * that no longer matches the factory's fresh quote, and - when
292
+ * `expectedInitCodeHash` or a Merkle `plan` is supplied - implementation
293
+ * drift since the prediction was taken. A `plan` that disagrees with
294
+ * `params.merkleRoot`, `expected.airdrop` or `expectedInitCodeHash` is an
295
+ * `InvalidArgumentError` blocker.
171
296
  *
172
- * @returns `{ ready, blockers }`. `blockers` carries the errors `create*`
173
- * would have thrown, so a UI can branch on `error.code` exactly as it does
174
- * in `onError`.
297
+ * @returns `{ ready, blockers, commitments }`. `blockers` carries the errors
298
+ * `create*` would have thrown, so a UI can branch on `error.code` exactly as
299
+ * it does in `onError`; `commitments` is what the create would be sent with.
175
300
  *
176
301
  * @example
177
302
  * const { ready, blockers } = await preflightCreate({
178
- * factory, variant: "merkle", params, mode: "clone", creator, userSalt,
179
- * expectedInitCodeHash: plan.initCodeHashAfter,
303
+ * factory, variant: "merkle", params, mode: "clone", creator, userSalt, plan,
180
304
  * });
181
305
  * if (!ready) return blockers.map((b) => b.code);
182
306
  *
183
307
  * @alpha
184
308
  */
185
- export declare function preflightCreate(args: PreflightCreateArgs): Promise<PreflightResult>;
309
+ export declare function preflightCreate(args: PreflightCreateArgs): Promise<PreflightCreateResult>;
186
310
  /**
187
311
  * The subset of an instance client {@link preflightClaim} reads.
188
312
  *
@@ -222,6 +346,40 @@ export interface ClaimPreflightTarget {
222
346
  signature: Hex;
223
347
  }) => Promise<boolean>;
224
348
  }
349
+ /**
350
+ * The slice of {@link ConfidentialAirdropFactoryClient} the genuineness check reads.
351
+ *
352
+ * @alpha
353
+ */
354
+ export interface AirdropRegistry {
355
+ readonly address: Address;
356
+ /**
357
+ * The chain this factory is bound to. Checked against the instance's own
358
+ * `chainId` before the registry is consulted - a registry answer from the
359
+ * wrong chain is worse than no answer, because it reads as a `true`.
360
+ */
361
+ readonly chainId: number;
362
+ isAirdrop(candidate: Address): Promise<boolean>;
363
+ }
364
+ /**
365
+ * Refuse an instance the canonical factory's registry does not contain.
366
+ *
367
+ * The factory has to be one the caller already trusts - taken from
368
+ * `src/core/addresses.ts`, not read off the instance. An instance that names
369
+ * its own factory proves nothing: a fake instance names a fake factory, which
370
+ * answers `true`.
371
+ *
372
+ * @throws {@link UnrecognisedAirdropError} when the registry does not contain `airdrop`.
373
+ *
374
+ * @alpha
375
+ */
376
+ export declare function assertKnownAirdrop(args: {
377
+ factory: AirdropRegistry;
378
+ airdrop: Address;
379
+ /** The chain the instance being vetted lives on. */
380
+ chainId: number;
381
+ method: string;
382
+ }): Promise<void>;
225
383
  /**
226
384
  * The signature material {@link preflightClaim} needs to check an ECDSA claim.
227
385
  *
@@ -265,25 +423,31 @@ export interface PreflightClaimArgs {
265
423
  * `isSignatureValid`, it adds the authorisation check to the report.
266
424
  */
267
425
  signature?: EcdsaClaimPreflightSignature | undefined;
426
+ /**
427
+ * The canonical factory, from `src/core/addresses.ts`. Supplying it adds the
428
+ * genuineness check (audit-10): every other blocker here describes a claim
429
+ * that will fail, but a claim against a look-alike instance SUCCEEDS and
430
+ * delivers nothing. Omitting it skips that one check.
431
+ */
432
+ factory?: AirdropRegistry | undefined;
268
433
  }
269
434
  /**
270
435
  * The three argument-relation rules the Merkle claim path enforces before it touches the
271
- * coprocessor. All are decidable from the arguments alone, so both `preflightClaim` and
272
- * the client's own write path run them — no RPC, no chance of a wasted fee.
436
+ * coprocessor: non-zero account, `claimAndUnwrap` is self-only, and only the account itself
437
+ * may redirect payout. All are decidable from the arguments alone, so both `preflightClaim`
438
+ * and the client's own write path run them - no RPC, no chance of a wasted fee.
273
439
  *
274
440
  * @param account The claim identity (`claim`'s leading argument).
275
441
  * @param submitter The address that will send the transaction.
276
- * @param boundTo The address the entry's input proof is bound to, when known.
277
442
  * @param to The payout destination, if one will be passed.
278
443
  * @param entrypoint `claimAndUnwrap` is self-only; `claim` accepts a third-party submitter.
279
- * @throws {@link InvalidArgumentError} on a zero `account`, a proof bound to another address, or a relayed `claimAndUnwrap`.
444
+ * @throws {@link InvalidArgumentError} on a zero `account` or a third-party `claimAndUnwrap`.
280
445
  * @throws {@link UnauthorizedRedirectError} when a third party tries to redirect payout.
281
446
  */
282
447
  export declare function assertMerkleClaimIdentity(args: {
283
448
  method: string;
284
449
  account: Address;
285
450
  submitter: Address;
286
- boundTo?: Address | undefined;
287
451
  to?: Address | undefined;
288
452
  entrypoint?: "claim" | "claimAndUnwrap" | undefined;
289
453
  }): void;
@@ -1,14 +1,14 @@
1
1
  'use strict';
2
2
 
3
- var chunkIUKKNJ2R_cjs = require('../chunk-IUKKNJ2R.cjs');
4
- var chunkPZZK3O3S_cjs = require('../chunk-PZZK3O3S.cjs');
5
- var chunkAREQJHKA_cjs = require('../chunk-AREQJHKA.cjs');
3
+ var chunkDFK5GCJP_cjs = require('../chunk-DFK5GCJP.cjs');
4
+ var chunkE4IV4M4E_cjs = require('../chunk-E4IV4M4E.cjs');
5
+ var chunkVHKMWWBA_cjs = require('../chunk-VHKMWWBA.cjs');
6
6
  var chunkKFRDLKMA_cjs = require('../chunk-KFRDLKMA.cjs');
7
7
  require('../chunk-FAXIIH5R.cjs');
8
8
  var chunkFWHYQZ5E_cjs = require('../chunk-FWHYQZ5E.cjs');
9
- require('../chunk-UG5RKLU2.cjs');
9
+ require('../chunk-SUYBAF27.cjs');
10
10
  require('../chunk-MVDQMV25.cjs');
11
- require('../chunk-FT5H2Q7Y.cjs');
11
+ require('../chunk-YAL6JSAZ.cjs');
12
12
  require('../chunk-JK4XMMKM.cjs');
13
13
  require('../chunk-66IHPTOK.cjs');
14
14
  var chunk67OV5CX2_cjs = require('../chunk-67OV5CX2.cjs');
@@ -16,209 +16,241 @@ require('../chunk-VJKZWYYJ.cjs');
16
16
 
17
17
 
18
18
 
19
+ Object.defineProperty(exports, "MERKLE_BATCH_LIMIT", {
20
+ enumerable: true,
21
+ get: function () { return chunkDFK5GCJP_cjs.MERKLE_BATCH_LIMIT; }
22
+ });
19
23
  Object.defineProperty(exports, "buildMerkleCampaign", {
20
24
  enumerable: true,
21
- get: function () { return chunkIUKKNJ2R_cjs.buildMerkleCampaign; }
25
+ get: function () { return chunkDFK5GCJP_cjs.buildMerkleCampaign; }
22
26
  });
23
27
  Object.defineProperty(exports, "buildMerkleTree", {
24
28
  enumerable: true,
25
- get: function () { return chunkIUKKNJ2R_cjs.buildMerkleTree; }
29
+ get: function () { return chunkDFK5GCJP_cjs.buildMerkleTree; }
30
+ });
31
+ Object.defineProperty(exports, "encodeInstanceRoleSplit", {
32
+ enumerable: true,
33
+ get: function () { return chunkDFK5GCJP_cjs.encodeInstanceRoleSplit; }
26
34
  });
27
35
  Object.defineProperty(exports, "encryptCampaignAmounts", {
28
36
  enumerable: true,
29
- get: function () { return chunkIUKKNJ2R_cjs.encryptCampaignAmounts; }
37
+ get: function () { return chunkDFK5GCJP_cjs.encryptCampaignAmounts; }
30
38
  });
31
39
  Object.defineProperty(exports, "grantInstanceRoles", {
32
40
  enumerable: true,
33
- get: function () { return chunkIUKKNJ2R_cjs.grantInstanceRoles; }
41
+ get: function () { return chunkDFK5GCJP_cjs.grantInstanceRoles; }
34
42
  });
35
43
  Object.defineProperty(exports, "leafOf", {
36
44
  enumerable: true,
37
- get: function () { return chunkIUKKNJ2R_cjs.leafOf; }
45
+ get: function () { return chunkDFK5GCJP_cjs.leafOf; }
38
46
  });
39
47
  Object.defineProperty(exports, "planInstanceRoleSplit", {
40
48
  enumerable: true,
41
- get: function () { return chunkIUKKNJ2R_cjs.planInstanceRoleSplit; }
49
+ get: function () { return chunkDFK5GCJP_cjs.planInstanceRoleSplit; }
42
50
  });
43
51
  Object.defineProperty(exports, "planMerkleCampaign", {
44
52
  enumerable: true,
45
- get: function () { return chunkIUKKNJ2R_cjs.planMerkleCampaign; }
53
+ get: function () { return chunkDFK5GCJP_cjs.planMerkleCampaign; }
46
54
  });
47
55
  Object.defineProperty(exports, "rotateMerkleRoot", {
48
56
  enumerable: true,
49
- get: function () { return chunkIUKKNJ2R_cjs.rotateMerkleRoot; }
57
+ get: function () { return chunkDFK5GCJP_cjs.rotateMerkleRoot; }
50
58
  });
51
59
  Object.defineProperty(exports, "validateCampaignRecipients", {
52
60
  enumerable: true,
53
- get: function () { return chunkIUKKNJ2R_cjs.validateCampaignRecipients; }
61
+ get: function () { return chunkDFK5GCJP_cjs.validateCampaignRecipients; }
54
62
  });
55
63
  Object.defineProperty(exports, "AirdropBaseClient", {
56
64
  enumerable: true,
57
- get: function () { return chunkPZZK3O3S_cjs.AirdropBaseClient; }
65
+ get: function () { return chunkE4IV4M4E_cjs.AirdropBaseClient; }
58
66
  });
59
67
  Object.defineProperty(exports, "CLAIM_TYPEHASH", {
60
68
  enumerable: true,
61
- get: function () { return chunkPZZK3O3S_cjs.CLAIM_TYPEHASH; }
69
+ get: function () { return chunkE4IV4M4E_cjs.CLAIM_TYPEHASH; }
62
70
  });
63
71
  Object.defineProperty(exports, "CLAIM_TYPES", {
64
72
  enumerable: true,
65
- get: function () { return chunkPZZK3O3S_cjs.CLAIM_TYPES; }
73
+ get: function () { return chunkE4IV4M4E_cjs.CLAIM_TYPES; }
66
74
  });
67
75
  Object.defineProperty(exports, "ComplianceManagerClient", {
68
76
  enumerable: true,
69
- get: function () { return chunkPZZK3O3S_cjs.ComplianceManagerClient; }
77
+ get: function () { return chunkE4IV4M4E_cjs.ComplianceManagerClient; }
70
78
  });
71
79
  Object.defineProperty(exports, "ConfidentialAirdropFactoryClient", {
72
80
  enumerable: true,
73
- get: function () { return chunkPZZK3O3S_cjs.ConfidentialAirdropFactoryClient; }
81
+ get: function () { return chunkE4IV4M4E_cjs.ConfidentialAirdropFactoryClient; }
74
82
  });
75
83
  Object.defineProperty(exports, "EIP712_DOMAIN_NAME", {
76
84
  enumerable: true,
77
- get: function () { return chunkPZZK3O3S_cjs.EIP712_DOMAIN_NAME; }
85
+ get: function () { return chunkE4IV4M4E_cjs.EIP712_DOMAIN_NAME; }
78
86
  });
79
87
  Object.defineProperty(exports, "EIP712_DOMAIN_VERSION", {
80
88
  enumerable: true,
81
- get: function () { return chunkPZZK3O3S_cjs.EIP712_DOMAIN_VERSION; }
89
+ get: function () { return chunkE4IV4M4E_cjs.EIP712_DOMAIN_VERSION; }
82
90
  });
83
91
  Object.defineProperty(exports, "EcdsaAirdropClient", {
84
92
  enumerable: true,
85
- get: function () { return chunkPZZK3O3S_cjs.EcdsaAirdropClient; }
93
+ get: function () { return chunkE4IV4M4E_cjs.EcdsaAirdropClient; }
86
94
  });
87
95
  Object.defineProperty(exports, "FACTORY_ROLE_CONCENTRATION_NOTE", {
88
96
  enumerable: true,
89
- get: function () { return chunkPZZK3O3S_cjs.FACTORY_ROLE_CONCENTRATION_NOTE; }
97
+ get: function () { return chunkE4IV4M4E_cjs.FACTORY_ROLE_CONCENTRATION_NOTE; }
90
98
  });
91
99
  Object.defineProperty(exports, "MerkleAirdropClient", {
92
100
  enumerable: true,
93
- get: function () { return chunkPZZK3O3S_cjs.MerkleAirdropClient; }
101
+ get: function () { return chunkE4IV4M4E_cjs.MerkleAirdropClient; }
94
102
  });
95
103
  Object.defineProperty(exports, "airdropFactoryAbi", {
96
104
  enumerable: true,
97
- get: function () { return chunkPZZK3O3S_cjs.airdropFactoryAbi; }
105
+ get: function () { return chunkE4IV4M4E_cjs.airdropFactoryAbi; }
98
106
  });
99
107
  Object.defineProperty(exports, "complianceRoleManagerAbi", {
100
108
  enumerable: true,
101
- get: function () { return chunkPZZK3O3S_cjs.complianceRoleManagerAbi; }
109
+ get: function () { return chunkE4IV4M4E_cjs.complianceRoleManagerAbi; }
102
110
  });
103
111
  Object.defineProperty(exports, "confidentialAirdropBaseAbi", {
104
112
  enumerable: true,
105
- get: function () { return chunkPZZK3O3S_cjs.confidentialAirdropBaseAbi; }
113
+ get: function () { return chunkE4IV4M4E_cjs.confidentialAirdropBaseAbi; }
106
114
  });
107
115
  Object.defineProperty(exports, "createAirdropBaseClient", {
108
116
  enumerable: true,
109
- get: function () { return chunkPZZK3O3S_cjs.createAirdropBaseClient; }
117
+ get: function () { return chunkE4IV4M4E_cjs.createAirdropBaseClient; }
110
118
  });
111
119
  Object.defineProperty(exports, "createComplianceManagerClient", {
112
120
  enumerable: true,
113
- get: function () { return chunkPZZK3O3S_cjs.createComplianceManagerClient; }
121
+ get: function () { return chunkE4IV4M4E_cjs.createComplianceManagerClient; }
114
122
  });
115
123
  Object.defineProperty(exports, "createConfidentialAirdropFactoryClient", {
116
124
  enumerable: true,
117
- get: function () { return chunkPZZK3O3S_cjs.createConfidentialAirdropFactoryClient; }
125
+ get: function () { return chunkE4IV4M4E_cjs.createConfidentialAirdropFactoryClient; }
118
126
  });
119
127
  Object.defineProperty(exports, "createEcdsaAirdropClient", {
120
128
  enumerable: true,
121
- get: function () { return chunkPZZK3O3S_cjs.createEcdsaAirdropClient; }
129
+ get: function () { return chunkE4IV4M4E_cjs.createEcdsaAirdropClient; }
122
130
  });
123
131
  Object.defineProperty(exports, "createMerkleAirdropClient", {
124
132
  enumerable: true,
125
- get: function () { return chunkPZZK3O3S_cjs.createMerkleAirdropClient; }
133
+ get: function () { return chunkE4IV4M4E_cjs.createMerkleAirdropClient; }
126
134
  });
127
135
  Object.defineProperty(exports, "ecdsaConfidentialAirdropAbi", {
128
136
  enumerable: true,
129
- get: function () { return chunkPZZK3O3S_cjs.ecdsaConfidentialAirdropAbi; }
137
+ get: function () { return chunkE4IV4M4E_cjs.ecdsaConfidentialAirdropAbi; }
130
138
  });
131
139
  Object.defineProperty(exports, "encryptUint64", {
132
140
  enumerable: true,
133
- get: function () { return chunkPZZK3O3S_cjs.encryptUint64; }
141
+ get: function () { return chunkE4IV4M4E_cjs.encryptUint64; }
134
142
  });
135
143
  Object.defineProperty(exports, "encryptUint64Batch", {
136
144
  enumerable: true,
137
- get: function () { return chunkPZZK3O3S_cjs.encryptUint64Batch; }
145
+ get: function () { return chunkE4IV4M4E_cjs.encryptUint64Batch; }
138
146
  });
139
147
  Object.defineProperty(exports, "isAclPropagationError", {
140
148
  enumerable: true,
141
- get: function () { return chunkPZZK3O3S_cjs.isAclPropagationError; }
149
+ get: function () { return chunkE4IV4M4E_cjs.isAclPropagationError; }
142
150
  });
143
151
  Object.defineProperty(exports, "merkleConfidentialAirdropAbi", {
144
152
  enumerable: true,
145
- get: function () { return chunkPZZK3O3S_cjs.merkleConfidentialAirdropAbi; }
153
+ get: function () { return chunkE4IV4M4E_cjs.merkleConfidentialAirdropAbi; }
146
154
  });
147
155
  Object.defineProperty(exports, "resolveEncryptor", {
148
156
  enumerable: true,
149
- get: function () { return chunkPZZK3O3S_cjs.resolveEncryptor; }
157
+ get: function () { return chunkE4IV4M4E_cjs.resolveEncryptor; }
150
158
  });
151
159
  Object.defineProperty(exports, "signClaimAuthorization", {
152
160
  enumerable: true,
153
- get: function () { return chunkPZZK3O3S_cjs.signClaimAuthorization; }
161
+ get: function () { return chunkE4IV4M4E_cjs.signClaimAuthorization; }
154
162
  });
155
163
  Object.defineProperty(exports, "AIRDROP_CONTRACTS_COMMIT", {
156
164
  enumerable: true,
157
- get: function () { return chunkAREQJHKA_cjs.AIRDROP_CONTRACTS_COMMIT; }
165
+ get: function () { return chunkVHKMWWBA_cjs.AIRDROP_CONTRACTS_COMMIT; }
158
166
  });
159
167
  Object.defineProperty(exports, "AlreadyClaimedError", {
160
168
  enumerable: true,
161
- get: function () { return chunkAREQJHKA_cjs.AlreadyClaimedError; }
169
+ get: function () { return chunkVHKMWWBA_cjs.AlreadyClaimedError; }
162
170
  });
163
171
  Object.defineProperty(exports, "ClaimNotStartedError", {
164
172
  enumerable: true,
165
- get: function () { return chunkAREQJHKA_cjs.ClaimNotStartedError; }
173
+ get: function () { return chunkVHKMWWBA_cjs.ClaimNotStartedError; }
166
174
  });
167
175
  Object.defineProperty(exports, "ClaimWindowClosedError", {
168
176
  enumerable: true,
169
- get: function () { return chunkAREQJHKA_cjs.ClaimWindowClosedError; }
177
+ get: function () { return chunkVHKMWWBA_cjs.ClaimWindowClosedError; }
178
+ });
179
+ Object.defineProperty(exports, "ClawbackRequiresPauseError", {
180
+ enumerable: true,
181
+ get: function () { return chunkVHKMWWBA_cjs.ClawbackRequiresPauseError; }
182
+ });
183
+ Object.defineProperty(exports, "CreateCommitmentMismatchError", {
184
+ enumerable: true,
185
+ get: function () { return chunkVHKMWWBA_cjs.CreateCommitmentMismatchError; }
170
186
  });
171
187
  Object.defineProperty(exports, "DEDUP_MODE", {
172
188
  enumerable: true,
173
- get: function () { return chunkAREQJHKA_cjs.DEDUP_MODE; }
189
+ get: function () { return chunkVHKMWWBA_cjs.DEDUP_MODE; }
174
190
  });
175
191
  Object.defineProperty(exports, "DEPLOYMENT_MODE", {
176
192
  enumerable: true,
177
- get: function () { return chunkAREQJHKA_cjs.DEPLOYMENT_MODE; }
193
+ get: function () { return chunkVHKMWWBA_cjs.DEPLOYMENT_MODE; }
178
194
  });
179
195
  Object.defineProperty(exports, "DedupIdConsumedError", {
180
196
  enumerable: true,
181
- get: function () { return chunkAREQJHKA_cjs.DedupIdConsumedError; }
197
+ get: function () { return chunkVHKMWWBA_cjs.DedupIdConsumedError; }
182
198
  });
183
199
  Object.defineProperty(exports, "FeeCollectorSelfAdministeredError", {
184
200
  enumerable: true,
185
- get: function () { return chunkAREQJHKA_cjs.FeeCollectorSelfAdministeredError; }
201
+ get: function () { return chunkVHKMWWBA_cjs.FeeCollectorSelfAdministeredError; }
202
+ });
203
+ Object.defineProperty(exports, "GasFeeNotAcceptedError", {
204
+ enumerable: true,
205
+ get: function () { return chunkVHKMWWBA_cjs.GasFeeNotAcceptedError; }
186
206
  });
187
207
  Object.defineProperty(exports, "MerkleUupsUnsupportedError", {
188
208
  enumerable: true,
189
- get: function () { return chunkAREQJHKA_cjs.MerkleUupsUnsupportedError; }
209
+ get: function () { return chunkVHKMWWBA_cjs.MerkleUupsUnsupportedError; }
210
+ });
211
+ Object.defineProperty(exports, "NativeRescueRequiresZeroFeeError", {
212
+ enumerable: true,
213
+ get: function () { return chunkVHKMWWBA_cjs.NativeRescueRequiresZeroFeeError; }
190
214
  });
191
215
  Object.defineProperty(exports, "NonStockWrapperError", {
192
216
  enumerable: true,
193
- get: function () { return chunkAREQJHKA_cjs.NonStockWrapperError; }
217
+ get: function () { return chunkVHKMWWBA_cjs.NonStockWrapperError; }
194
218
  });
195
219
  Object.defineProperty(exports, "PredictionDriftError", {
196
220
  enumerable: true,
197
- get: function () { return chunkAREQJHKA_cjs.PredictionDriftError; }
221
+ get: function () { return chunkVHKMWWBA_cjs.PredictionDriftError; }
198
222
  });
199
223
  Object.defineProperty(exports, "SaltCollisionError", {
200
224
  enumerable: true,
201
- get: function () { return chunkAREQJHKA_cjs.SaltCollisionError; }
225
+ get: function () { return chunkVHKMWWBA_cjs.SaltCollisionError; }
202
226
  });
203
227
  Object.defineProperty(exports, "SignatureExpiredError", {
204
228
  enumerable: true,
205
- get: function () { return chunkAREQJHKA_cjs.SignatureExpiredError; }
229
+ get: function () { return chunkVHKMWWBA_cjs.SignatureExpiredError; }
230
+ });
231
+ Object.defineProperty(exports, "UINT96_MAX", {
232
+ enumerable: true,
233
+ get: function () { return chunkVHKMWWBA_cjs.UINT96_MAX; }
206
234
  });
207
235
  Object.defineProperty(exports, "UnauthorizedRedirectError", {
208
236
  enumerable: true,
209
- get: function () { return chunkAREQJHKA_cjs.UnauthorizedRedirectError; }
237
+ get: function () { return chunkVHKMWWBA_cjs.UnauthorizedRedirectError; }
238
+ });
239
+ Object.defineProperty(exports, "UnrecognisedAirdropError", {
240
+ enumerable: true,
241
+ get: function () { return chunkVHKMWWBA_cjs.UnrecognisedAirdropError; }
210
242
  });
211
243
  Object.defineProperty(exports, "UpgradeabilityNotAllowedError", {
212
244
  enumerable: true,
213
- get: function () { return chunkAREQJHKA_cjs.UpgradeabilityNotAllowedError; }
245
+ get: function () { return chunkVHKMWWBA_cjs.UpgradeabilityNotAllowedError; }
214
246
  });
215
247
  Object.defineProperty(exports, "preflightClaim", {
216
248
  enumerable: true,
217
- get: function () { return chunkAREQJHKA_cjs.preflightClaim; }
249
+ get: function () { return chunkVHKMWWBA_cjs.preflightClaim; }
218
250
  });
219
251
  Object.defineProperty(exports, "preflightCreate", {
220
252
  enumerable: true,
221
- get: function () { return chunkAREQJHKA_cjs.preflightCreate; }
253
+ get: function () { return chunkVHKMWWBA_cjs.preflightCreate; }
222
254
  });
223
255
  Object.defineProperty(exports, "ERC7984_OPERATOR_MAX_DEADLINE", {
224
256
  enumerable: true,
@@ -2,9 +2,10 @@
2
2
  * `@tokenops/sdk/fhe-airdrop` - confidential airdrop campaigns on the
3
3
  * TokenOps airdrop v2 contracts.
4
4
  *
5
- * **Unaudited contracts. Alpha software. No stability promise.** This module
6
- * targets `tokenops-fhe-airdrop-v2`, which has not been audited. It is
7
- * intended for the `alpha` npm dist-tag only, and must not be published to
5
+ * **Alpha software. No stability promise.**
6
+ * This module targets `tokenops-fhe-airdrop-v2` at `AIRDROP_CONTRACTS_COMMIT`, through
7
+ * the Sepolia deployment in `DEPLOYED_ADDRESSES`. It is intended for the `alpha` npm
8
+ * dist-tag only, and must not be published to
8
9
  * `latest`: the release that first ships this module is the one that sets
9
10
  * that tag. Two contract
10
11
  * behaviours would otherwise produce a wrong result rather than a revert,
@@ -27,22 +28,23 @@
27
28
  * Address prediction and its integrity guards live on the
28
29
  * `@tokenops/sdk/fhe-airdrop/advanced` subpath.
29
30
  */
30
- export { AIRDROP_CONTRACTS_COMMIT, DEDUP_MODE, DEPLOYMENT_MODE, type DedupMode, type DeploymentMode, } from "./constants.js";
31
+ export { AIRDROP_CONTRACTS_COMMIT, DEDUP_MODE, DEPLOYMENT_MODE, UINT96_MAX, type DedupMode, type DeploymentMode, } from "./constants.js";
31
32
  export { ConfidentialAirdropFactoryClient, createConfidentialAirdropFactoryClient, FACTORY_ROLE_CONCENTRATION_NOTE, type CompliancePolicy, type ConfidentialAirdropFactoryClientConfig, type CustomFee, type FundInput, type UpgradeabilityPolicy, } from "./factory.js";
32
- export { AirdropBaseClient, createAirdropBaseClient, type AirdropBaseClientConfig, type WriteAccountOverride, } from "./airdrop-base.js";
33
+ export { AirdropBaseClient, createAirdropBaseClient, type AirdropBaseClientConfig, type UnwrapRequest, type UnwrapRequestSource, type WriteAccountOverride, } from "./airdrop-base.js";
33
34
  export { CLAIM_TYPEHASH, CLAIM_TYPES, createEcdsaAirdropClient, EcdsaAirdropClient, EIP712_DOMAIN_NAME, EIP712_DOMAIN_VERSION, type Eip712Domain, type EcdsaAirdropClientConfig, type EcdsaClaimArgs, type GetClaimAmountArgs as EcdsaGetClaimAmountArgs, type IsSignatureValidArgs, } from "./ecdsa.js";
34
35
  export { createMerkleAirdropClient, MerkleAirdropClient, type GetClaimAmountArgs as MerkleGetClaimAmountArgs, type MerkleClaimArgs, } from "./merkle.js";
35
36
  export { buildMerkleTree, leafOf, type BuildMerkleTreeArgs, type BuiltMerkleTree, type LeafOfArgs, type MerkleLeafInput, } from "./merkle-tree.js";
36
37
  export { ComplianceManagerClient, createComplianceManagerClient, isAclPropagationError, type ComplianceManagerClientConfig, } from "./compliance.js";
37
- export type { BuiltCampaign, CampaignEntry, CampaignRecipient, CommonAirdropParams, CreateAirdropArgs, CreateAirdropResult, EcdsaAirdropParams, MerkleAirdropParams, } from "./types.js";
38
+ export type { AirdropVariantParams, BuiltCampaign, CampaignEntry, CampaignRecipient, CommonAirdropParams, CreateAirdropArgs, CreateAirdropResult, CreateCommitments, CreateMerkleAirdropArgs, EcdsaAirdropParams, MerkleAirdropParams, PendingCreateAirdropResult, } from "./types.js";
39
+ export type { MinedWrite, PendingWrite, ReceiptMode } from "../core/pending.js";
38
40
  export type { EncryptedInput, EncryptedInputs, EncryptedViewResult } from "../fhe/types.js";
39
- export { buildMerkleCampaign, encryptCampaignAmounts, planMerkleCampaign, rotateMerkleRoot, validateCampaignRecipients, type BuildMerkleCampaignArgs, type CampaignSubmitterOption, type EncryptCampaignAmountsArgs, type EncryptedCampaignLeaf, type PlanMerkleCampaignArgs, type PlannedCampaign, type RotatedCampaign, type RotateMerkleRootArgs, } from "./campaign.js";
40
- export { grantInstanceRoles, planInstanceRoleSplit, type InstanceRoleAssignment, type RoleGrantOutcome, type RoleGrantStep, type RoleName, } from "./roles.js";
41
+ export { buildMerkleCampaign, encryptCampaignAmounts, MERKLE_BATCH_LIMIT, planMerkleCampaign, rotateMerkleRoot, validateCampaignRecipients, type BuildMerkleCampaignArgs, type EncryptCampaignAmountsArgs, type EncryptedCampaignLeaf, type PlanMerkleCampaignArgs, type PlannedCampaign, type RotatedCampaign, type RotateMerkleRootArgs, } from "./campaign.js";
42
+ export { encodeInstanceRoleSplit, grantInstanceRoles, planInstanceRoleSplit, type InstanceRoleAssignment, type InstanceRoleCall, type InstanceRoleConstants, type RoleGrantOutcome, type RoleGrantStep, type RoleName, } from "./roles.js";
41
43
  export { encryptUint64, encryptUint64Batch, resolveEncryptor, signClaimAuthorization, type Encryptor, type EncryptorSource, type EncryptUint64Args, type EncryptUint64BatchArgs, type FheValueInput, } from "./encryption.js";
42
- export { preflightClaim, preflightCreate, type ClaimPreflightTarget, type EcdsaClaimPreflightSignature, type PreflightClaimArgs, type PreflightCreateArgs, } from "./guards.js";
44
+ export { preflightClaim, preflightCreate, type AirdropRegistry, type ClaimPreflightTarget, type EcdsaClaimPreflightSignature, type PreflightClaimArgs, type PreflightCreateArgs, type PreflightCreateResult, } from "./guards.js";
43
45
  export { type PreflightResult } from "../core/preflight.js";
44
46
  export { airdropFactoryAbi, complianceRoleManagerAbi, confidentialAirdropBaseAbi, ecdsaConfidentialAirdropAbi, merkleConfidentialAirdropAbi, } from "./abis/index.js";
45
- export { AlreadyClaimedError, ClaimNotStartedError, ClaimWindowClosedError, DedupIdConsumedError, FeeCollectorSelfAdministeredError, MerkleUupsUnsupportedError, NonStockWrapperError, PredictionDriftError, SaltCollisionError, SignatureExpiredError, UnauthorizedRedirectError, UpgradeabilityNotAllowedError, type AirdropVariant, } from "./errors.js";
47
+ export { AlreadyClaimedError, ClaimNotStartedError, ClaimWindowClosedError, ClawbackRequiresPauseError, CreateCommitmentMismatchError, DedupIdConsumedError, FeeCollectorSelfAdministeredError, GasFeeNotAcceptedError, MerkleUupsUnsupportedError, NativeRescueRequiresZeroFeeError, NonStockWrapperError, PredictionDriftError, SaltCollisionError, SignatureExpiredError, UnauthorizedRedirectError, UnrecognisedAirdropError, UpgradeabilityNotAllowedError, type AirdropVariant, } from "./errors.js";
46
48
  export { TokenOpsSdkError, isTokenOpsSdkError, DeploymentAddressUnavailableError, UnsupportedChainError, MissingAccountError, MissingClientError, MissingEncryptorError, MissingPublicClientError, MissingWalletClientError, InvalidArgumentError, ReceiptEventAmbiguousError, ReceiptEventNotFoundError, TokenOpsValidationError, ContractRevertError, TokenOpsContractError, PausedError, AccessDeniedError, OperatorNotApprovedError, InsufficientFeeError, InsufficientBalanceError, BatchTooLargeError, FeatureDisabledError, TransferFailedError, FheHandleNotAllowedError, AlreadyInitializedError, ReentrancyError, InvalidSignatureError, WalletRejectedError, WalletChainMismatchError, NetworkError, InsufficientGasFundsError, UnknownWriteFailureError, UserRejectedSignatureError, SigningFailedError, RelayerUnreachableError, EncryptionFailedError, DecryptionFailedError, UserDecryptNotAllowedError, type DeploymentAddressUnavailableReason, type TokenOpsSdkErrorCode, } from "../core/errors.js";
47
49
  export { ERC7984_OPERATOR_MAX_DEADLINE, revokeOperator, setOperator, type RevokeOperatorArgs, type SetOperatorArgs, } from "../fhe/operators.js";
48
50
  export { erc7984OperatorAbi } from "../fhe/erc7984-abi.js";