@zama-fhe/react-sdk 3.0.0-alpha.9 → 3.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.
package/dist/index.d.ts CHANGED
@@ -1,10 +1,10 @@
1
1
  "use client";
2
2
 
3
3
  import * as _$_zama_fhe_sdk0 from "@zama-fhe/sdk";
4
- import { Address, BatchBalancesResult, ClearValueType, DelegatedUserDecryptParams, EIP712TypedData, EncryptParams, GenericSigner, GenericStorage, PaginatedResult, PublicKeyData, ReadonlyToken, RelayerSDK, TokenWrapperPair, TokenWrapperPairWithMetadata, TransactionResult, ZKProofLike, ZamaSDK, ZamaSDKEventListener } from "@zama-fhe/sdk";
5
- import { ApproveUnderlyingParams, BatchDecryptBalancesAsParams, ConfidentialApproveParams, ConfidentialTransferFromParams, ConfidentialTransferParams, CreateDelegatedUserDecryptEIP712Params, CreateEIP712Params, DecryptBalanceAsParams, DecryptResult, DelegateDecryptionParams, DelegationStatusData, FinalizeUnwrapParams, ResumeUnshieldParams, RevokeDelegationParams, ShieldParams, TokenMetadata, UnshieldAllParams, UnshieldParams, UnwrapParams, UserDecryptQueryConfig } from "@zama-fhe/sdk/query";
4
+ import { ACL_TOPICS, AclEvent, AclPausedError, ActivityAmount, ActivityDirection, ActivityItem, ActivityItem as ActivityItem$1, ActivityLogMetadata, ActivityLogMetadata as ActivityLogMetadata$1, ActivityType, Address, Address as Address$1, ApprovalFailedError, ApproveSubmittedEvent, ApproveUnderlyingSubmittedEvent, BalanceCheckUnavailableError, BaseEvent, BatchBalancesResult, BatchBalancesResult as BatchBalancesResult$1, BatchDecryptAsOptions, ChromeSessionStorage, ClearValueType, ClearValueType as ClearValueType$1, ConfidentialTransferEvent, ConfigurationError, ContractAbi, CredentialsAllowedEvent, CredentialsCachedEvent, CredentialsCreatedEvent, CredentialsCreatingEvent, CredentialsExpiredEvent, CredentialsLoadingEvent, CredentialsManager, CredentialsManagerConfig, CredentialsRevokedEvent, DecryptEndEvent, DecryptErrorEvent, DecryptStartEvent, DecryptionFailedError, DefaultRegistryAddresses, DelegatedCredentialsManager, DelegatedCredentialsManagerConfig, DelegatedForUserDecryptionEvent, DelegatedStoredCredentials, DelegatedUserDecryptParams, DelegatedUserDecryptParams as DelegatedUserDecryptParams$1, DelegationContractIsSelfError, DelegationCooldownError, DelegationDelegateEqualsContractError, DelegationExpirationTooSoonError, DelegationExpiredError, DelegationExpiryUnchangedError, DelegationNotFoundError, DelegationNotPropagatedError, DelegationSelfNotAllowedError, EIP712TypedData, EIP712TypedData as EIP712TypedData$1, ERC20ReadFailedError, ERC7984_INTERFACE_ID, ERC7984_WRAPPER_INTERFACE_ID, EncryptEndEvent, EncryptErrorEvent, EncryptInput, EncryptParams, EncryptParams as EncryptParams$1, EncryptResult, EncryptResult as EncryptResult$1, EncryptStartEvent, EncryptionFailedError, FheTypeName, FhevmInstanceConfig, FinalizeUnwrapSubmittedEvent, GenericSigner, GenericSigner as GenericSigner$1, GenericStorage, GenericStorage as GenericStorage$1, Handle, HardhatConfig, Hex, IndexedDBStorage, InputProofBytesType, InsufficientConfidentialBalanceError, InsufficientERC20BalanceError, InvalidKeypairError, KeypairExpiredError, KeypairType, KmsDelegatedUserDecryptEIP712Type, ListPairsOptions, MainnetConfig, MemoryStorage, NetworkType, NoCiphertextError, OnChainEvent, PaginatedResult, PaginatedResult as PaginatedResult$1, PublicDecryptResult, PublicDecryptResult as PublicDecryptResult$1, RawLog, RawLog as RawLog$1, ReadContractArgs, ReadContractConfig, ReadContractReturnType, ReadFunctionName, ReadonlyToken, ReadonlyToken as ReadonlyToken$1, RelayerRequestFailedError, RelayerSDK, RelayerSDK as RelayerSDK$1, RelayerSDKStatus, RelayerWeb, RelayerWebConfig, RelayerWebSecurityConfig, RevokedDelegationForUserDecryptionEvent, SepoliaConfig, SessionExpiredEvent, ShieldCallbacks, ShieldSubmittedEvent, SigningFailedError, SigningRejectedError, StoredCredentials, TOKEN_TOPICS, Token, TokenWrapperPair, TokenWrapperPair as TokenWrapperPair$1, TokenWrapperPairWithMetadata, TokenWrapperPairWithMetadata as TokenWrapperPairWithMetadata$1, Topics, TransactionErrorEvent, TransactionReceipt, TransactionResult, TransactionResult as TransactionResult$1, TransactionRevertedError, TransferCallbacks, TransferFromSubmittedEvent, TransferSubmittedEvent, UnshieldCallbacks, UnshieldPhase1SubmittedEvent, UnshieldPhase2StartedEvent, UnshieldPhase2SubmittedEvent, UnwrapRequestedEvent, UnwrapSubmittedEvent, UnwrappedFinalizedEvent, UnwrappedStartedEvent, UserDecryptParams, WrappedEvent, WrappersRegistry, WrappersRegistryConfig, WriteContractArgs, WriteContractConfig, WriteFunctionName, ZERO_HANDLE, ZKProofLike, ZKProofLike as ZKProofLike$1, ZamaError, ZamaErrorCode, ZamaSDK, ZamaSDK as ZamaSDK$1, ZamaSDKConfig, ZamaSDKEvent, ZamaSDKEventInput, ZamaSDKEventListener, ZamaSDKEventListener as ZamaSDKEventListener$1, ZamaSDKEventType, ZamaSDKEvents, allowanceContract, applyDecryptedValues, approveContract, balanceOfContract, chromeSessionStorage, clearPendingUnshield, confidentialBalanceOfContract, confidentialTotalSupplyContract, confidentialTransferContract, confidentialTransferFromContract, decimalsContract, decodeAclEvent, decodeAclEvents, decodeConfidentialTransfer, decodeDelegatedForUserDecryption, decodeOnChainEvent, decodeOnChainEvents, decodeRevokedDelegationForUserDecryption, decodeUnwrapRequested, decodeUnwrappedFinalized, decodeUnwrappedStarted, decodeWrapped, delegateForUserDecryptionContract, extractEncryptedHandles, finalizeUnwrapContract, findDelegatedForUserDecryption, findRevokedDelegationForUserDecryption, findUnwrapRequested, findWrapped, getDelegationExpiryContract, indexedDBStorage, inferredTotalSupplyContract, isConfidentialTokenContract, isConfidentialWrapperContract, isHandleDelegatedContract, isOperatorContract, isZeroHandle, loadPendingUnshield, matchAclRevert, matchZamaError, memoryStorage, nameContract, parseActivityFeed, rateContract, revokeDelegationContract, savePendingUnshield, setOperatorContract, sortByBlockNumber, supportsInterfaceContract, symbolContract, totalSupplyContract, underlyingContract, unwrapContract, unwrapFromBalanceContract, wrapContract } from "@zama-fhe/sdk";
5
+ import { ApproveUnderlyingParams, ApproveUnderlyingParams as ApproveUnderlyingParams$1, BatchDecryptBalancesAsParams, BatchDecryptBalancesAsParams as BatchDecryptBalancesAsParams$1, ConfidentialApproveParams, ConfidentialApproveParams as ConfidentialApproveParams$1, ConfidentialTransferFromParams, ConfidentialTransferFromParams as ConfidentialTransferFromParams$1, ConfidentialTransferParams, ConfidentialTransferParams as ConfidentialTransferParams$1, CreateDelegatedUserDecryptEIP712Params, CreateEIP712Params, DecryptBalanceAsParams, DecryptBalanceAsParams as DecryptBalanceAsParams$1, DecryptHandle, DecryptResult, DecryptResult as DecryptResult$1, DelegateDecryptionParams, DelegateDecryptionParams as DelegateDecryptionParams$1, DelegationStatusData, DelegationStatusData as DelegationStatusData$1, DelegationStatusQueryConfig, FinalizeUnwrapParams, FinalizeUnwrapParams as FinalizeUnwrapParams$1, ListPairsQueryConfig, ResumeUnshieldParams, ResumeUnshieldParams as ResumeUnshieldParams$1, RevokeDelegationParams, RevokeDelegationParams as RevokeDelegationParams$1, ShieldParams, ShieldParams as ShieldParams$1, TokenMetadata, UnshieldAllParams, UnshieldAllParams as UnshieldAllParams$1, UnshieldParams, UnshieldParams as UnshieldParams$1, UnwrapParams, UnwrapParams as UnwrapParams$1, UserDecryptQueryConfig, UserDecryptQueryConfig as UserDecryptQueryConfig$1, activityFeedQueryOptions, allowMutationOptions, approveUnderlyingMutationOptions, batchDecryptBalancesAsMutationOptions, confidentialApproveMutationOptions, confidentialBalanceQueryOptions, confidentialBalancesQueryOptions, confidentialIsApprovedQueryOptions, confidentialTransferFromMutationOptions, confidentialTransferMutationOptions, createDelegatedUserDecryptEIP712MutationOptions, createEIP712MutationOptions, decryptBalanceAsMutationOptions, delegateDecryptionMutationOptions, delegatedUserDecryptMutationOptions, delegationStatusQueryOptions, encryptMutationOptions, filterQueryOptions, finalizeUnwrapMutationOptions, generateKeypairMutationOptions, hashFn, isAllowedQueryOptions, isConfidentialQueryOptions, isWrapperQueryOptions, listPairsQueryOptions, publicDecryptMutationOptions, publicKeyQueryOptions, publicParamsQueryOptions, requestZKProofVerificationMutationOptions, resumeUnshieldMutationOptions, revokeDelegationMutationOptions, revokeMutationOptions, revokeSessionMutationOptions, shieldMutationOptions, signerAddressQueryOptions, tokenMetadataQueryOptions, totalSupplyQueryOptions, underlyingAllowanceQueryOptions, unshieldAllMutationOptions, unshieldMutationOptions, unwrapAllMutationOptions, unwrapMutationOptions, userDecryptQueryOptions, wrapperDiscoveryQueryOptions, zamaQueryKeys } from "@zama-fhe/sdk/query";
6
6
  import * as _$_tanstack_react_query0 from "@tanstack/react-query";
7
- import { UseMutationOptions, UseMutationResult, UseQueryOptions } from "@tanstack/react-query";
7
+ import { QueryKey, UseMutationOptions, UseMutationResult, UseQueryOptions } from "@tanstack/react-query";
8
8
  import { PropsWithChildren } from "react";
9
9
  import * as _$react_jsx_runtime0 from "react/jsx-runtime";
10
10
  import * as _$_zama_fhe_relayer_sdk_web0 from "@zama-fhe/relayer-sdk/web";
@@ -13,16 +13,16 @@ import * as _$_zama_fhe_relayer_sdk_web0 from "@zama-fhe/relayer-sdk/web";
13
13
  /** Props for {@link ZamaProvider}. */
14
14
  interface ZamaProviderProps extends PropsWithChildren {
15
15
  /** FHE relayer backend (RelayerWeb for browser, RelayerNode for server). */
16
- relayer: RelayerSDK;
16
+ relayer: RelayerSDK$1;
17
17
  /** Wallet signer (`ViemSigner`, `EthersSigner`, or custom {@link GenericSigner}). */
18
- signer: GenericSigner;
18
+ signer: GenericSigner$1;
19
19
  /** Credential storage backend (IndexedDBStorage for browser, MemoryStorage for tests). */
20
- storage: GenericStorage;
20
+ storage: GenericStorage$1;
21
21
  /**
22
22
  * Session storage for wallet signatures. Defaults to in-memory (lost on reload).
23
23
  * Pass a `chrome.storage.session`-backed store for web extensions.
24
24
  */
25
- sessionStorage?: GenericStorage;
25
+ sessionStorage?: GenericStorage$1;
26
26
  /**
27
27
  * How long the ML-KEM re-encryption keypair remains valid, in seconds.
28
28
  * Default: `86400` (1 day). Must be positive — `0` is rejected.
@@ -39,14 +39,14 @@ interface ZamaProviderProps extends PropsWithChildren {
39
39
  * Per-chain wrappers registry address overrides, merged on top of built-in defaults.
40
40
  * Use this for custom or local chains (e.g. Hardhat) where no default registry exists.
41
41
  */
42
- registryAddresses?: Record<number, Address>;
42
+ registryAddresses?: Record<number, Address$1>;
43
43
  /**
44
44
  * How long cached registry results remain valid, in seconds.
45
45
  * Default: `86400` (24 hours).
46
46
  */
47
47
  registryTTL?: number;
48
48
  /** Callback invoked on SDK lifecycle events. */
49
- onEvent?: ZamaSDKEventListener;
49
+ onEvent?: ZamaSDKEventListener$1;
50
50
  }
51
51
  /**
52
52
  * Provides a {@link ZamaSDK} instance to all descendant hooks.
@@ -80,7 +80,7 @@ declare function ZamaProvider({
80
80
  * const token = sdk.createReadonlyToken("0x...");
81
81
  * ```
82
82
  */
83
- declare function useZamaSDK(): ZamaSDK;
83
+ declare function useZamaSDK(): ZamaSDK$1;
84
84
  //#endregion
85
85
  //#region src/relayer/use-encrypt.d.ts
86
86
  /**
@@ -98,17 +98,14 @@ declare function useZamaSDK(): ZamaSDK;
98
98
  * encrypt.mutate({ values: [{ value: 1000n, type: "euint64" }], contractAddress: "0x...", userAddress: "0x..." });
99
99
  * ```
100
100
  */
101
- declare function useEncrypt(): _$_tanstack_react_query0.UseMutationResult<Readonly<{
102
- handles: Uint8Array[];
103
- inputProof: Uint8Array;
104
- }>, Error, EncryptParams, unknown>;
101
+ declare function useEncrypt(): _$_tanstack_react_query0.UseMutationResult<EncryptResult$1, Error, EncryptParams$1, unknown>;
105
102
  //#endregion
106
103
  //#region src/relayer/use-user-decrypt.d.ts
107
104
  /**
108
105
  * React hook for FHE user decryption. Thin wrapper around
109
106
  * `userDecryptQueryOptions` with `useQuery` semantics.
110
107
  */
111
- declare function useUserDecrypt(config: UserDecryptQueryConfig, options?: Omit<UseQueryOptions<DecryptResult>, "queryKey" | "queryFn">): _$_tanstack_react_query0.UseQueryResult<Readonly<Record<`0x${string}`, _$_zama_fhe_sdk0.ClearValueType>>, Error>;
108
+ declare function useUserDecrypt(config: UserDecryptQueryConfig$1, options?: Omit<UseQueryOptions<DecryptResult$1>, "queryKey" | "queryFn">): _$_tanstack_react_query0.UseQueryResult<DecryptResult$1, Error>;
112
109
  /** Return type of {@link useUserDecrypt}. */
113
110
  type UseUserDecryptResult = ReturnType<typeof useUserDecrypt>;
114
111
  //#endregion
@@ -127,11 +124,7 @@ type UseUserDecryptResult = ReturnType<typeof useUserDecrypt>;
127
124
  * // publicDecrypt.data?.clearValues => { "0xHandle1": 500n, ... }
128
125
  * ```
129
126
  */
130
- declare function usePublicDecrypt(): _$_tanstack_react_query0.UseMutationResult<Readonly<{
131
- clearValues: _$_zama_fhe_relayer_sdk_web0.ClearValues;
132
- abiEncodedClearValues: `0x${string}`;
133
- decryptionProof: `0x${string}`;
134
- }>, Error, `0x${string}`[], unknown>;
127
+ declare function usePublicDecrypt(): _$_tanstack_react_query0.UseMutationResult<PublicDecryptResult$1, Error, `0x${string}`[], unknown>;
135
128
  //#endregion
136
129
  //#region src/relayer/use-generate-keypair.d.ts
137
130
  /**
@@ -169,7 +162,7 @@ declare function useGenerateKeypair(): _$_tanstack_react_query0.UseMutationResul
169
162
  * });
170
163
  * ```
171
164
  */
172
- declare function useCreateEIP712(): _$_tanstack_react_query0.UseMutationResult<EIP712TypedData, Error, CreateEIP712Params, unknown>;
165
+ declare function useCreateEIP712(): _$_tanstack_react_query0.UseMutationResult<EIP712TypedData$1, Error, CreateEIP712Params, unknown>;
173
166
  //#endregion
174
167
  //#region src/relayer/use-create-delegated-user-decrypt-eip712.d.ts
175
168
  /**
@@ -210,7 +203,7 @@ declare function useCreateDelegatedUserDecryptEIP712(): _$_tanstack_react_query0
210
203
  * // decrypt.data => { "0xHandle1": 1000n }
211
204
  * ```
212
205
  */
213
- declare function useDelegatedUserDecrypt(): _$_tanstack_react_query0.UseMutationResult<Record<`0x${string}`, ClearValueType>, Error, DelegatedUserDecryptParams, unknown>;
206
+ declare function useDelegatedUserDecrypt(): _$_tanstack_react_query0.UseMutationResult<Record<`0x${string}`, ClearValueType$1>, Error, DelegatedUserDecryptParams$1, unknown>;
214
207
  //#endregion
215
208
  //#region src/relayer/use-request-zk-proof-verification.d.ts
216
209
  /**
@@ -229,9 +222,16 @@ declare function useDelegatedUserDecrypt(): _$_tanstack_react_query0.UseMutation
229
222
  declare function useRequestZKProofVerification(): _$_tanstack_react_query0.UseMutationResult<Readonly<{
230
223
  handles: Uint8Array[];
231
224
  inputProof: Uint8Array;
232
- }>, Error, ZKProofLike, unknown>;
225
+ }>, Error, ZKProofLike$1, unknown>;
233
226
  //#endregion
234
227
  //#region src/relayer/use-public-key.d.ts
228
+ /** Shape of the FHE public key data returned by the relayer. */
229
+ interface PublicKeyData {
230
+ /** Unique identifier for this public key version. */
231
+ publicKeyId: string;
232
+ /** The raw FHE public key bytes. */
233
+ publicKey: Uint8Array;
234
+ }
235
235
  /**
236
236
  * Fetch the FHE network public key from the relayer.
237
237
  * Cached indefinitely since the key does not change during a session.
@@ -247,6 +247,13 @@ declare function useRequestZKProofVerification(): _$_tanstack_react_query0.UseMu
247
247
  declare function usePublicKey(): _$_tanstack_react_query0.UseQueryResult<PublicKeyData | null, Error>;
248
248
  //#endregion
249
249
  //#region src/relayer/use-public-params.d.ts
250
+ /** Shape of the FHE public parameters returned by the relayer. */
251
+ interface PublicParamsData {
252
+ /** The raw public parameters bytes (WASM-ready). */
253
+ publicParams: Uint8Array;
254
+ /** Unique identifier for this public params version. */
255
+ publicParamsId: string;
256
+ }
250
257
  /**
251
258
  * Fetch FHE public parameters for a given bit size from the relayer.
252
259
  * Cached indefinitely since parameters do not change during a session.
@@ -260,10 +267,7 @@ declare function usePublicKey(): _$_tanstack_react_query0.UseQueryResult<PublicK
260
267
  * // params?.publicParams, params?.publicParamsId
261
268
  * ```
262
269
  */
263
- declare function usePublicParams(bits: number): _$_tanstack_react_query0.UseQueryResult<{
264
- publicParams: Uint8Array<ArrayBufferLike>;
265
- publicParamsId: string;
266
- } | null, Error>;
270
+ declare function usePublicParams(bits: number): _$_tanstack_react_query0.UseQueryResult<PublicParamsData | null, Error>;
267
271
  //#endregion
268
272
  //#region src/authorization/use-allow.d.ts
269
273
  /**
@@ -286,13 +290,13 @@ declare function usePublicParams(bits: number): _$_tanstack_react_query0.UseQuer
286
290
  * await allow([tokenAddress, auctionAddress, governanceAddress]);
287
291
  * ```
288
292
  */
289
- declare function useAllow(options?: UseMutationOptions<void, Error, Address[]>): _$_tanstack_react_query0.UseMutationResult<void, Error, `0x${string}`[], unknown>;
293
+ declare function useAllow(options?: UseMutationOptions<void, Error, Address$1[]>): _$_tanstack_react_query0.UseMutationResult<void, Error, `0x${string}`[], unknown>;
290
294
  //#endregion
291
295
  //#region src/authorization/use-is-allowed.d.ts
292
296
  /** Configuration for {@link useIsAllowed}. */
293
297
  interface UseIsAllowedConfig {
294
298
  /** Contract addresses to check credentials against (at least one required). */
295
- contractAddresses: [Address, ...Address[]];
299
+ contractAddresses: [Address$1, ...Address$1[]];
296
300
  }
297
301
  /**
298
302
  * Check whether a session signature is cached for the connected wallet
@@ -321,7 +325,7 @@ declare function useIsAllowed(config: UseIsAllowedConfig): _$_tanstack_react_que
321
325
  * revoke([tokenAddress, auctionAddress]);
322
326
  * ```
323
327
  */
324
- declare function useRevoke(options?: UseMutationOptions<void, Error, Address[]>): _$_tanstack_react_query0.UseMutationResult<void, Error, `0x${string}`[], unknown>;
328
+ declare function useRevoke(options?: UseMutationOptions<void, Error, Address$1[]>): _$_tanstack_react_query0.UseMutationResult<void, Error, `0x${string}`[], unknown>;
325
329
  //#endregion
326
330
  //#region src/authorization/use-revoke-session.d.ts
327
331
  /**
@@ -340,9 +344,9 @@ declare function useRevokeSession(options?: UseMutationOptions<void>): _$_tansta
340
344
  /** Base configuration shared by all mutation hooks that need a Token instance. */
341
345
  interface UseZamaConfig {
342
346
  /** Address of the confidential token contract. */
343
- tokenAddress: Address;
347
+ tokenAddress: Address$1;
344
348
  /** Address of the wrapper contract (required for shield/unshield operations). */
345
- wrapperAddress?: Address;
349
+ wrapperAddress?: Address$1;
346
350
  }
347
351
  /**
348
352
  * Get a {@link Token} instance, memoized by address pair.
@@ -373,13 +377,13 @@ declare function useToken(config: UseZamaConfig): _$_zama_fhe_sdk0.Token;
373
377
  * // token.balanceOf(), token.isConfidential(), etc.
374
378
  * ```
375
379
  */
376
- declare function useReadonlyToken(address: Address): _$_zama_fhe_sdk0.ReadonlyToken;
380
+ declare function useReadonlyToken(address: Address$1): _$_zama_fhe_sdk0.ReadonlyToken;
377
381
  //#endregion
378
382
  //#region src/balance/use-confidential-balance.d.ts
379
383
  /** Configuration for {@link useConfidentialBalance}. */
380
384
  interface UseConfidentialBalanceConfig {
381
385
  /** Address of the confidential token contract. */
382
- tokenAddress: Address;
386
+ tokenAddress: Address$1;
383
387
  }
384
388
  /** Query options for {@link useConfidentialBalance}. */
385
389
  interface UseConfidentialBalanceOptions extends Omit<UseQueryOptions<bigint>, "queryKey" | "queryFn" | "enabled"> {
@@ -409,10 +413,10 @@ declare function useConfidentialBalance(config: UseConfidentialBalanceConfig, op
409
413
  /** Configuration for {@link useConfidentialBalances}. */
410
414
  interface UseConfidentialBalancesConfig {
411
415
  /** Addresses of the confidential token contracts to batch-query. */
412
- tokenAddresses: Address[];
416
+ tokenAddresses: Address$1[];
413
417
  }
414
418
  /** Query options for {@link useConfidentialBalances}. */
415
- interface UseConfidentialBalancesOptions extends Omit<UseQueryOptions<BatchBalancesResult>, "queryKey" | "queryFn" | "enabled"> {
419
+ interface UseConfidentialBalancesOptions extends Omit<UseQueryOptions<BatchBalancesResult$1>, "queryKey" | "queryFn" | "enabled"> {
416
420
  /** Whether the query is enabled. Callback form is not supported in composite hooks. */
417
421
  enabled?: boolean;
418
422
  }
@@ -440,7 +444,7 @@ interface UseConfidentialBalancesOptions extends Omit<UseQueryOptions<BatchBalan
440
444
  * }
441
445
  * ```
442
446
  */
443
- declare function useConfidentialBalances(config: UseConfidentialBalancesConfig, options?: UseConfidentialBalancesOptions): _$_tanstack_react_query0.UseQueryResult<BatchBalancesResult, Error>;
447
+ declare function useConfidentialBalances(config: UseConfidentialBalancesConfig, options?: UseConfidentialBalancesOptions): _$_tanstack_react_query0.UseQueryResult<BatchBalancesResult$1, Error>;
444
448
  //#endregion
445
449
  //#region src/transfer/use-confidential-transfer.d.ts
446
450
  /** Configuration for {@link useConfidentialTransfer}. */
@@ -482,7 +486,7 @@ interface UseConfidentialTransferConfig extends UseZamaConfig {
482
486
  * );
483
487
  * ```
484
488
  */
485
- declare function useConfidentialTransfer<TContext = unknown>(config: UseConfidentialTransferConfig, options?: UseMutationOptions<TransactionResult, Error, ConfidentialTransferParams, TContext>): UseMutationResult<TransactionResult, Error, ConfidentialTransferParams, TContext>;
489
+ declare function useConfidentialTransfer<TContext = unknown>(config: UseConfidentialTransferConfig, options?: UseMutationOptions<TransactionResult$1, Error, ConfidentialTransferParams$1, TContext>): UseMutationResult<TransactionResult$1, Error, ConfidentialTransferParams$1, TContext>;
486
490
  //#endregion
487
491
  //#region src/transfer/use-confidential-transfer-from.d.ts
488
492
  /**
@@ -503,7 +507,7 @@ declare function useConfidentialTransfer<TContext = unknown>(config: UseConfiden
503
507
  * transferFrom.mutate({ from: "0xOwner", to: "0xRecipient", amount: 500n });
504
508
  * ```
505
509
  */
506
- declare function useConfidentialTransferFrom(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult, Error, ConfidentialTransferFromParams, Address>): _$_tanstack_react_query0.UseMutationResult<TransactionResult, Error, ConfidentialTransferFromParams, `0x${string}`>;
510
+ declare function useConfidentialTransferFrom(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult$1, Error, ConfidentialTransferFromParams$1, Address$1>): _$_tanstack_react_query0.UseMutationResult<TransactionResult$1, Error, ConfidentialTransferFromParams$1, `0x${string}`>;
507
511
  //#endregion
508
512
  //#region src/transfer/use-confidential-approve.d.ts
509
513
  /**
@@ -522,24 +526,24 @@ declare function useConfidentialTransferFrom(config: UseZamaConfig, options?: Us
522
526
  * approve.mutate({ spender: "0xOperator" });
523
527
  * ```
524
528
  */
525
- declare function useConfidentialApprove(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult, Error, ConfidentialApproveParams, Address>): _$_tanstack_react_query0.UseMutationResult<TransactionResult, Error, ConfidentialApproveParams, `0x${string}`>;
529
+ declare function useConfidentialApprove(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult$1, Error, ConfidentialApproveParams$1, Address$1>): _$_tanstack_react_query0.UseMutationResult<TransactionResult$1, Error, ConfidentialApproveParams$1, `0x${string}`>;
526
530
  //#endregion
527
531
  //#region src/transfer/use-confidential-is-approved.d.ts
528
532
  /** Configuration for {@link useConfidentialIsApproved}. */
529
533
  interface UseConfidentialIsApprovedConfig {
530
534
  /** Address of the confidential token contract. Pass `undefined` to disable the query. */
531
- tokenAddress: Address | undefined;
535
+ tokenAddress: Address$1 | undefined;
532
536
  /** Address to check approval for. Pass `undefined` to disable the query. */
533
- spender: Address | undefined;
537
+ spender: Address$1 | undefined;
534
538
  /** Token holder address. Defaults to the connected wallet. */
535
- holder?: Address;
539
+ holder?: Address$1;
536
540
  }
537
541
  /** Configuration for {@link useConfidentialIsApprovedSuspense}. */
538
542
  interface UseConfidentialIsApprovedSuspenseConfig extends UseZamaConfig {
539
543
  /** Address to check approval for. */
540
- spender: Address;
544
+ spender: Address$1;
541
545
  /** Token holder address. Defaults to the connected wallet. */
542
- holder?: Address;
546
+ holder?: Address$1;
543
547
  }
544
548
  /**
545
549
  * Check if a spender is an approved operator for a given holder (defaults to connected wallet).
@@ -605,7 +609,7 @@ interface UseShieldConfig extends UseZamaConfig {
605
609
  * shield.mutate({ amount: 1000n });
606
610
  * ```
607
611
  */
608
- declare function useShield<TContext = unknown>(config: UseShieldConfig, options?: UseMutationOptions<TransactionResult, Error, ShieldParams, TContext>): UseMutationResult<TransactionResult, Error, ShieldParams, TContext>;
612
+ declare function useShield<TContext = unknown>(config: UseShieldConfig, options?: UseMutationOptions<TransactionResult$1, Error, ShieldParams$1, TContext>): UseMutationResult<TransactionResult$1, Error, ShieldParams$1, TContext>;
609
613
  //#endregion
610
614
  //#region src/unwrap/use-unwrap.d.ts
611
615
  /**
@@ -627,7 +631,7 @@ declare function useShield<TContext = unknown>(config: UseShieldConfig, options?
627
631
  * unwrap.mutate({ amount: 500n });
628
632
  * ```
629
633
  */
630
- declare function useUnwrap(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult, Error, UnwrapParams, Address>): _$_tanstack_react_query0.UseMutationResult<TransactionResult, Error, UnwrapParams, `0x${string}`>;
634
+ declare function useUnwrap(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult$1, Error, UnwrapParams$1, Address$1>): _$_tanstack_react_query0.UseMutationResult<TransactionResult$1, Error, UnwrapParams$1, `0x${string}`>;
631
635
  //#endregion
632
636
  //#region src/unwrap/use-unwrap-all.d.ts
633
637
  /**
@@ -648,7 +652,7 @@ declare function useUnwrap(config: UseZamaConfig, options?: UseMutationOptions<T
648
652
  * unwrapAll.mutate();
649
653
  * ```
650
654
  */
651
- declare function useUnwrapAll(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult, Error, void, Address>): _$_tanstack_react_query0.UseMutationResult<TransactionResult, Error, void, `0x${string}`>;
655
+ declare function useUnwrapAll(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult$1, Error, void, Address$1>): _$_tanstack_react_query0.UseMutationResult<TransactionResult$1, Error, void, `0x${string}`>;
652
656
  //#endregion
653
657
  //#region src/unwrap/use-finalize-unwrap.d.ts
654
658
  /**
@@ -666,10 +670,10 @@ declare function useUnwrapAll(config: UseZamaConfig, options?: UseMutationOption
666
670
  * @example
667
671
  * ```tsx
668
672
  * const finalize = useFinalizeUnwrap({ tokenAddress: "0x..." });
669
- * finalize.mutate({ unwrapRequestId: event.unwrapRequestId });
673
+ * finalize.mutate({ burnAmountHandle: event.encryptedAmount });
670
674
  * ```
671
675
  */
672
- declare function useFinalizeUnwrap(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult, Error, FinalizeUnwrapParams, Address>): _$_tanstack_react_query0.UseMutationResult<TransactionResult, Error, FinalizeUnwrapParams, `0x${string}`>;
676
+ declare function useFinalizeUnwrap(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult$1, Error, FinalizeUnwrapParams$1, Address$1>): _$_tanstack_react_query0.UseMutationResult<TransactionResult$1, Error, FinalizeUnwrapParams$1, `0x${string}`>;
673
677
  //#endregion
674
678
  //#region src/unshield/use-unshield.d.ts
675
679
  /**
@@ -691,7 +695,7 @@ declare function useFinalizeUnwrap(config: UseZamaConfig, options?: UseMutationO
691
695
  * unshield.mutate({ amount: 500n });
692
696
  * ```
693
697
  */
694
- declare function useUnshield(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult, Error, UnshieldParams, Address>): _$_tanstack_react_query0.UseMutationResult<TransactionResult, Error, UnshieldParams, `0x${string}`>;
698
+ declare function useUnshield(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult$1, Error, UnshieldParams$1, Address$1>): _$_tanstack_react_query0.UseMutationResult<TransactionResult$1, Error, UnshieldParams$1, `0x${string}`>;
695
699
  //#endregion
696
700
  //#region src/unshield/use-unshield-all.d.ts
697
701
  /**
@@ -712,7 +716,7 @@ declare function useUnshield(config: UseZamaConfig, options?: UseMutationOptions
712
716
  * unshieldAll.mutate();
713
717
  * ```
714
718
  */
715
- declare function useUnshieldAll(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult, Error, UnshieldAllParams | void, Address>): _$_tanstack_react_query0.UseMutationResult<TransactionResult, Error, void | UnshieldAllParams, `0x${string}`>;
719
+ declare function useUnshieldAll(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult$1, Error, UnshieldAllParams$1 | void, Address$1>): _$_tanstack_react_query0.UseMutationResult<TransactionResult$1, Error, void | UnshieldAllParams$1, `0x${string}`>;
716
720
  //#endregion
717
721
  //#region src/unshield/use-resume-unshield.d.ts
718
722
  /**
@@ -733,15 +737,15 @@ declare function useUnshieldAll(config: UseZamaConfig, options?: UseMutationOpti
733
737
  * resumeUnshield.mutate({ unwrapTxHash: "0xabc..." });
734
738
  * ```
735
739
  */
736
- declare function useResumeUnshield(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult, Error, ResumeUnshieldParams, Address>): _$_tanstack_react_query0.UseMutationResult<TransactionResult, Error, ResumeUnshieldParams, `0x${string}`>;
740
+ declare function useResumeUnshield(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult$1, Error, ResumeUnshieldParams$1, Address$1>): _$_tanstack_react_query0.UseMutationResult<TransactionResult$1, Error, ResumeUnshieldParams$1, `0x${string}`>;
737
741
  //#endregion
738
742
  //#region src/shield/use-underlying-allowance.d.ts
739
743
  /** Configuration for {@link useUnderlyingAllowance}. */
740
744
  interface UseUnderlyingAllowanceConfig {
741
745
  /** Address of the confidential token contract used to scope the query cache. */
742
- tokenAddress: Address;
746
+ tokenAddress: Address$1;
743
747
  /** Address of the wrapper contract whose underlying ERC-20 allowance is checked. */
744
- wrapperAddress: Address;
748
+ wrapperAddress: Address$1;
745
749
  }
746
750
  /**
747
751
  * Read the underlying ERC-20 allowance granted to the wrapper contract.
@@ -785,9 +789,9 @@ interface UseWrapperDiscoveryConfig {
785
789
  * Used only to derive the signer context and to scope the query cache key —
786
790
  * it does not affect which wrapper the registry returns.
787
791
  */
788
- tokenAddress: Address;
792
+ tokenAddress: Address$1;
789
793
  /** ERC-20 address to discover the wrapper for. Pass `undefined` to disable the query. */
790
- erc20Address: Address | undefined;
794
+ erc20Address: Address$1 | undefined;
791
795
  }
792
796
  /** Configuration for {@link useWrapperDiscoverySuspense}. */
793
797
  interface UseWrapperDiscoverySuspenseConfig {
@@ -796,9 +800,9 @@ interface UseWrapperDiscoverySuspenseConfig {
796
800
  * Used only to derive the signer context and to scope the query cache key —
797
801
  * it does not affect which wrapper the registry returns.
798
802
  */
799
- tokenAddress: Address;
803
+ tokenAddress: Address$1;
800
804
  /** ERC-20 address to discover the wrapper for. */
801
- erc20Address: Address;
805
+ erc20Address: Address$1;
802
806
  }
803
807
  /**
804
808
  * Discover the confidential wrapper for an ERC-20 token via the on-chain registry.
@@ -817,7 +821,7 @@ interface UseWrapperDiscoverySuspenseConfig {
817
821
  * });
818
822
  * ```
819
823
  */
820
- declare function useWrapperDiscovery(config: UseWrapperDiscoveryConfig, options?: Omit<UseQueryOptions<Address | null>, "queryKey" | "queryFn">): _$_tanstack_react_query0.UseQueryResult<`0x${string}` | null, Error>;
824
+ declare function useWrapperDiscovery(config: UseWrapperDiscoveryConfig, options?: Omit<UseQueryOptions<Address$1 | null>, "queryKey" | "queryFn">): _$_tanstack_react_query0.UseQueryResult<`0x${string}` | null, Error>;
821
825
  /**
822
826
  * Suspense variant of {@link useWrapperDiscovery}.
823
827
  * Suspends rendering until the wrapper address is resolved.
@@ -850,7 +854,7 @@ declare function useWrapperDiscoverySuspense(config: UseWrapperDiscoverySuspense
850
854
  * // metadata?.name, metadata?.symbol, metadata?.decimals
851
855
  * ```
852
856
  */
853
- declare function useMetadata(tokenAddress: Address, options?: Omit<UseQueryOptions<TokenMetadata>, "queryKey" | "queryFn">): _$_tanstack_react_query0.UseQueryResult<TokenMetadata, Error>;
857
+ declare function useMetadata(tokenAddress: Address$1, options?: Omit<UseQueryOptions<TokenMetadata>, "queryKey" | "queryFn">): _$_tanstack_react_query0.UseQueryResult<TokenMetadata, Error>;
854
858
  /**
855
859
  * Suspense variant of {@link useMetadata}.
856
860
  * Suspends rendering until metadata is loaded.
@@ -863,7 +867,41 @@ declare function useMetadata(tokenAddress: Address, options?: Omit<UseQueryOptio
863
867
  * const { data: metadata } = useMetadataSuspense("0xToken");
864
868
  * ```
865
869
  */
866
- declare function useMetadataSuspense(tokenAddress: Address): _$_tanstack_react_query0.UseSuspenseQueryResult<TokenMetadata, Error>;
870
+ declare function useMetadataSuspense(tokenAddress: Address$1): _$_tanstack_react_query0.UseSuspenseQueryResult<TokenMetadata, Error>;
871
+ //#endregion
872
+ //#region src/balance/use-activity-feed.d.ts
873
+ /** Configuration for {@link useActivityFeed}. */
874
+ interface UseActivityFeedConfig {
875
+ /** Address of the confidential token contract. */
876
+ tokenAddress: Address$1;
877
+ /** Connected wallet address. Pass `undefined` to disable the query. */
878
+ userAddress: Address$1 | undefined;
879
+ /** Raw event logs from the provider (viem, ethers, etc.). Pass `undefined` to disable. */
880
+ logs: readonly (RawLog$1 & Partial<ActivityLogMetadata$1>)[] | undefined;
881
+ /** Whether to batch-decrypt encrypted transfer amounts. Default: `true`. */
882
+ decrypt?: boolean;
883
+ }
884
+ /**
885
+ * Two-phase activity feed hook.
886
+ * Phase 1: Instantly parses raw logs into classified {@link ActivityItem}s (sync, cheap).
887
+ * Phase 2: Batch-decrypts encrypted transfer amounts via the relayer (async).
888
+ *
889
+ * The wallet provides logs (from its own provider — viem, ethers, etc.)
890
+ * and this hook normalizes + decrypts them.
891
+ *
892
+ * @param config - Token address, user address, raw logs, and decrypt option.
893
+ * @returns Query result with `data: ActivityItem[]`.
894
+ *
895
+ * @example
896
+ * ```tsx
897
+ * const { data: activity } = useActivityFeed({
898
+ * tokenAddress: "0xToken",
899
+ * userAddress: "0xUser",
900
+ * logs: rawLogs,
901
+ * });
902
+ * ```
903
+ */
904
+ declare function useActivityFeed(config: UseActivityFeedConfig): _$_tanstack_react_query0.UseQueryResult<ActivityItem$1[], Error>;
867
905
  //#endregion
868
906
  //#region src/delegation/use-delegate-decryption.d.ts
869
907
  /**
@@ -878,7 +916,7 @@ declare function useMetadataSuspense(tokenAddress: Address): _$_tanstack_react_q
878
916
  * delegate.mutate({ delegateAddress: "0xDelegate" });
879
917
  * ```
880
918
  */
881
- declare function useDelegateDecryption(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult, Error, DelegateDecryptionParams>): _$_tanstack_react_query0.UseMutationResult<TransactionResult, Error, DelegateDecryptionParams, unknown>;
919
+ declare function useDelegateDecryption(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult$1, Error, DelegateDecryptionParams$1>): _$_tanstack_react_query0.UseMutationResult<TransactionResult$1, Error, DelegateDecryptionParams$1, unknown>;
882
920
  //#endregion
883
921
  //#region src/delegation/use-revoke-delegation.d.ts
884
922
  /**
@@ -893,16 +931,16 @@ declare function useDelegateDecryption(config: UseZamaConfig, options?: UseMutat
893
931
  * revoke.mutate({ delegateAddress: "0xDelegate" });
894
932
  * ```
895
933
  */
896
- declare function useRevokeDelegation(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult, Error, RevokeDelegationParams>): _$_tanstack_react_query0.UseMutationResult<TransactionResult, Error, RevokeDelegationParams, unknown>;
934
+ declare function useRevokeDelegation(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult$1, Error, RevokeDelegationParams$1>): _$_tanstack_react_query0.UseMutationResult<TransactionResult$1, Error, RevokeDelegationParams$1, unknown>;
897
935
  //#endregion
898
936
  //#region src/delegation/use-delegation-status.d.ts
899
937
  interface UseDelegationStatusConfig {
900
938
  /** Address of the confidential token contract. Pass `undefined` to disable the query. */
901
- tokenAddress: Address | undefined;
939
+ tokenAddress: Address$1 | undefined;
902
940
  /** The address that granted the delegation. */
903
- delegatorAddress?: Address;
941
+ delegatorAddress?: Address$1;
904
942
  /** The address that received delegation rights. */
905
- delegateAddress?: Address;
943
+ delegateAddress?: Address$1;
906
944
  }
907
945
  /**
908
946
  * Query delegation status between a delegator and delegate for a token.
@@ -921,7 +959,7 @@ interface UseDelegationStatusConfig {
921
959
  * // data?.isDelegated, data?.expiryTimestamp
922
960
  * ```
923
961
  */
924
- declare function useDelegationStatus(config: UseDelegationStatusConfig, options?: Omit<UseQueryOptions<DelegationStatusData>, "queryKey" | "queryFn">): _$_tanstack_react_query0.UseQueryResult<DelegationStatusData, Error>;
962
+ declare function useDelegationStatus(config: UseDelegationStatusConfig, options?: Omit<UseQueryOptions<DelegationStatusData$1>, "queryKey" | "queryFn">): _$_tanstack_react_query0.UseQueryResult<DelegationStatusData$1, Error>;
925
963
  //#endregion
926
964
  //#region src/delegation/use-decrypt-balance-as.d.ts
927
965
  /**
@@ -937,7 +975,7 @@ declare function useDelegationStatus(config: UseDelegationStatusConfig, options?
937
975
  * // decryptAs.data => 1000n
938
976
  * ```
939
977
  */
940
- declare function useDecryptBalanceAs(tokenAddress: Address, options?: UseMutationOptions<bigint, Error, DecryptBalanceAsParams>): _$_tanstack_react_query0.UseMutationResult<bigint, Error, DecryptBalanceAsParams, unknown>;
978
+ declare function useDecryptBalanceAs(tokenAddress: Address$1, options?: UseMutationOptions<bigint, Error, DecryptBalanceAsParams$1>): _$_tanstack_react_query0.UseMutationResult<bigint, Error, DecryptBalanceAsParams$1, unknown>;
941
979
  //#endregion
942
980
  //#region src/delegation/use-batch-decrypt-balances-as.d.ts
943
981
  /**
@@ -955,7 +993,7 @@ declare function useDecryptBalanceAs(tokenAddress: Address, options?: UseMutatio
955
993
  * // batchDecryptAs.data => Map { "0xTokenA" => 100n, "0xTokenB" => 200n }
956
994
  * ```
957
995
  */
958
- declare function useBatchDecryptBalancesAs(tokens: ReadonlyToken[], options?: UseMutationOptions<Map<Address, bigint>, Error, BatchDecryptBalancesAsParams>): _$_tanstack_react_query0.UseMutationResult<Map<`0x${string}`, bigint>, Error, _$_zama_fhe_sdk0.BatchDecryptAsOptions, unknown>;
996
+ declare function useBatchDecryptBalancesAs(tokens: ReadonlyToken$1[], options?: UseMutationOptions<Map<Address$1, bigint>, Error, BatchDecryptBalancesAsParams$1>): _$_tanstack_react_query0.UseMutationResult<Map<`0x${string}`, bigint>, Error, _$_zama_fhe_sdk0.BatchDecryptAsOptions, unknown>;
959
997
  //#endregion
960
998
  //#region src/shield/use-approve-underlying.d.ts
961
999
  /**
@@ -977,7 +1015,7 @@ declare function useBatchDecryptBalancesAs(tokens: ReadonlyToken[], options?: Us
977
1015
  * approve.mutate({ amount: 1000n }); // exact amount
978
1016
  * ```
979
1017
  */
980
- declare function useApproveUnderlying(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult, Error, ApproveUnderlyingParams, Address>): _$_tanstack_react_query0.UseMutationResult<TransactionResult, Error, ApproveUnderlyingParams, `0x${string}`>;
1018
+ declare function useApproveUnderlying(config: UseZamaConfig, options?: UseMutationOptions<TransactionResult$1, Error, ApproveUnderlyingParams$1, Address$1>): _$_tanstack_react_query0.UseMutationResult<TransactionResult$1, Error, ApproveUnderlyingParams$1, `0x${string}`>;
981
1019
  //#endregion
982
1020
  //#region src/token/use-is-confidential.d.ts
983
1021
  /**
@@ -993,7 +1031,7 @@ declare function useApproveUnderlying(config: UseZamaConfig, options?: UseMutati
993
1031
  * const { data: isConfidential } = useIsConfidential("0xToken");
994
1032
  * ```
995
1033
  */
996
- declare function useIsConfidential(tokenAddress: Address, options?: Omit<UseQueryOptions<boolean>, "queryKey" | "queryFn">): _$_tanstack_react_query0.UseQueryResult<boolean, Error>;
1034
+ declare function useIsConfidential(tokenAddress: Address$1, options?: Omit<UseQueryOptions<boolean>, "queryKey" | "queryFn">): _$_tanstack_react_query0.UseQueryResult<boolean, Error>;
997
1035
  /**
998
1036
  * Suspense variant of {@link useIsConfidential}.
999
1037
  * Suspends rendering until the ERC-165 check resolves.
@@ -1006,7 +1044,7 @@ declare function useIsConfidential(tokenAddress: Address, options?: Omit<UseQuer
1006
1044
  * const { data: isConfidential } = useIsConfidentialSuspense("0xToken");
1007
1045
  * ```
1008
1046
  */
1009
- declare function useIsConfidentialSuspense(tokenAddress: Address): _$_tanstack_react_query0.UseSuspenseQueryResult<boolean, Error>;
1047
+ declare function useIsConfidentialSuspense(tokenAddress: Address$1): _$_tanstack_react_query0.UseSuspenseQueryResult<boolean, Error>;
1010
1048
  /**
1011
1049
  * Check if a token supports the ERC-7984 wrapper interface via ERC-165.
1012
1050
  * Result is cached indefinitely since interface support does not change.
@@ -1020,7 +1058,7 @@ declare function useIsConfidentialSuspense(tokenAddress: Address): _$_tanstack_r
1020
1058
  * const { data: isWrapper } = useIsWrapper("0xToken");
1021
1059
  * ```
1022
1060
  */
1023
- declare function useIsWrapper(tokenAddress: Address, options?: Omit<UseQueryOptions<boolean>, "queryKey" | "queryFn">): _$_tanstack_react_query0.UseQueryResult<boolean, Error>;
1061
+ declare function useIsWrapper(tokenAddress: Address$1, options?: Omit<UseQueryOptions<boolean>, "queryKey" | "queryFn">): _$_tanstack_react_query0.UseQueryResult<boolean, Error>;
1024
1062
  /**
1025
1063
  * Suspense variant of {@link useIsWrapper}.
1026
1064
  * Suspends rendering until the ERC-165 check resolves.
@@ -1033,7 +1071,7 @@ declare function useIsWrapper(tokenAddress: Address, options?: Omit<UseQueryOpti
1033
1071
  * const { data: isWrapper } = useIsWrapperSuspense("0xToken");
1034
1072
  * ```
1035
1073
  */
1036
- declare function useIsWrapperSuspense(tokenAddress: Address): _$_tanstack_react_query0.UseSuspenseQueryResult<boolean, Error>;
1074
+ declare function useIsWrapperSuspense(tokenAddress: Address$1): _$_tanstack_react_query0.UseSuspenseQueryResult<boolean, Error>;
1037
1075
  //#endregion
1038
1076
  //#region src/token/use-total-supply.d.ts
1039
1077
  /**
@@ -1049,7 +1087,7 @@ declare function useIsWrapperSuspense(tokenAddress: Address): _$_tanstack_react_
1049
1087
  * const { data: totalSupply } = useTotalSupply("0xToken");
1050
1088
  * ```
1051
1089
  */
1052
- declare function useTotalSupply(tokenAddress: Address, options?: Omit<UseQueryOptions<bigint>, "queryKey" | "queryFn">): _$_tanstack_react_query0.UseQueryResult<bigint, Error>;
1090
+ declare function useTotalSupply(tokenAddress: Address$1, options?: Omit<UseQueryOptions<bigint>, "queryKey" | "queryFn">): _$_tanstack_react_query0.UseQueryResult<bigint, Error>;
1053
1091
  /**
1054
1092
  * Suspense variant of {@link useTotalSupply}.
1055
1093
  * Suspends rendering until the total supply is loaded.
@@ -1062,7 +1100,7 @@ declare function useTotalSupply(tokenAddress: Address, options?: Omit<UseQueryOp
1062
1100
  * const { data: totalSupply } = useTotalSupplySuspense("0xToken");
1063
1101
  * ```
1064
1102
  */
1065
- declare function useTotalSupplySuspense(tokenAddress: Address): _$_tanstack_react_query0.UseSuspenseQueryResult<bigint, Error>;
1103
+ declare function useTotalSupplySuspense(tokenAddress: Address$1): _$_tanstack_react_query0.UseSuspenseQueryResult<bigint, Error>;
1066
1104
  //#endregion
1067
1105
  //#region src/wrappers-registry/use-wrappers-registry-address.d.ts
1068
1106
  /**
@@ -1076,14 +1114,14 @@ declare function useTotalSupplySuspense(tokenAddress: Address): _$_tanstack_reac
1076
1114
  * The chain ID is cached for 30 seconds (`staleTime`), so chain
1077
1115
  * switches may take up to 30s to reflect.
1078
1116
  */
1079
- declare function useWrappersRegistryAddress(): Address | undefined;
1117
+ declare function useWrappersRegistryAddress(): Address$1 | undefined;
1080
1118
  //#endregion
1081
1119
  //#region src/wrappers-registry/use-token-pairs-registry.d.ts
1082
1120
  /**
1083
1121
  * Fetches all token wrapper pairs from the ConfidentialTokenWrappersRegistry
1084
1122
  * contract on the current chain.
1085
1123
  */
1086
- declare function useTokenPairsRegistry(): _$_tanstack_react_query0.UseQueryResult<readonly TokenWrapperPair[], Error>;
1124
+ declare function useTokenPairsRegistry(): _$_tanstack_react_query0.UseQueryResult<readonly TokenWrapperPair$1[], Error>;
1087
1125
  //#endregion
1088
1126
  //#region src/wrappers-registry/use-token-pairs-length.d.ts
1089
1127
  /**
@@ -1104,7 +1142,7 @@ declare function useTokenPairsSlice({
1104
1142
  }: {
1105
1143
  fromIndex: bigint | undefined;
1106
1144
  toIndex: bigint | undefined;
1107
- }): _$_tanstack_react_query0.UseQueryResult<readonly TokenWrapperPair[], Error>;
1145
+ }): _$_tanstack_react_query0.UseQueryResult<readonly TokenWrapperPair$1[], Error>;
1108
1146
  //#endregion
1109
1147
  //#region src/wrappers-registry/use-token-pair.d.ts
1110
1148
  /**
@@ -1116,7 +1154,7 @@ declare function useTokenPair({
1116
1154
  index
1117
1155
  }: {
1118
1156
  index: bigint | undefined;
1119
- }): _$_tanstack_react_query0.UseQueryResult<TokenWrapperPair, Error>;
1157
+ }): _$_tanstack_react_query0.UseQueryResult<TokenWrapperPair$1, Error>;
1120
1158
  //#endregion
1121
1159
  //#region src/wrappers-registry/use-confidential-token-address.d.ts
1122
1160
  /**
@@ -1125,7 +1163,7 @@ declare function useTokenPair({
1125
1163
  declare function useConfidentialTokenAddress({
1126
1164
  tokenAddress
1127
1165
  }: {
1128
- tokenAddress: Address | undefined;
1166
+ tokenAddress: Address$1 | undefined;
1129
1167
  }): _$_tanstack_react_query0.UseQueryResult<readonly [boolean, `0x${string}`], Error>;
1130
1168
  //#endregion
1131
1169
  //#region src/wrappers-registry/use-token-address.d.ts
@@ -1135,7 +1173,7 @@ declare function useConfidentialTokenAddress({
1135
1173
  declare function useTokenAddress({
1136
1174
  confidentialTokenAddress
1137
1175
  }: {
1138
- confidentialTokenAddress: Address | undefined;
1176
+ confidentialTokenAddress: Address$1 | undefined;
1139
1177
  }): _$_tanstack_react_query0.UseQueryResult<readonly [boolean, `0x${string}`], Error>;
1140
1178
  //#endregion
1141
1179
  //#region src/wrappers-registry/use-is-confidential-token-valid.d.ts
@@ -1148,7 +1186,7 @@ declare function useTokenAddress({
1148
1186
  declare function useIsConfidentialTokenValid({
1149
1187
  confidentialTokenAddress
1150
1188
  }: {
1151
- confidentialTokenAddress: Address | undefined;
1189
+ confidentialTokenAddress: Address$1 | undefined;
1152
1190
  }): _$_tanstack_react_query0.UseQueryResult<boolean, Error>;
1153
1191
  //#endregion
1154
1192
  //#region src/wrappers-registry/use-list-pairs.d.ts
@@ -1173,7 +1211,15 @@ declare function useListPairs({
1173
1211
  page?: number;
1174
1212
  pageSize?: number;
1175
1213
  metadata?: boolean;
1176
- }): _$_tanstack_react_query0.UseQueryResult<PaginatedResult<TokenWrapperPair | TokenWrapperPairWithMetadata>, Error>;
1214
+ }): _$_tanstack_react_query0.UseQueryResult<PaginatedResult$1<TokenWrapperPair$1 | TokenWrapperPairWithMetadata$1>, Error>;
1215
+ //#endregion
1216
+ //#region src/balance/optimistic-balance-update.d.ts
1217
+ type OptimisticBalanceSnapshot = [QueryKey, bigint | undefined][];
1218
+ /** Combined context returned by optimistic `onMutate`. */
1219
+ interface OptimisticMutateContext {
1220
+ snapshot: OptimisticBalanceSnapshot;
1221
+ callerContext?: unknown;
1222
+ }
1177
1223
  //#endregion
1178
- export { type UseConfidentialBalanceConfig, type UseConfidentialBalanceOptions, type UseConfidentialBalancesConfig, type UseConfidentialBalancesOptions, type UseConfidentialIsApprovedConfig, type UseConfidentialIsApprovedSuspenseConfig, type UseConfidentialTransferConfig, type UseDelegationStatusConfig, type UseIsAllowedConfig, type UseShieldConfig, type UseUnderlyingAllowanceConfig, type UseUserDecryptResult, type UseWrapperDiscoveryConfig, type UseWrapperDiscoverySuspenseConfig, type UseZamaConfig, ZamaProvider, type ZamaProviderProps, useAllow, useApproveUnderlying, useBatchDecryptBalancesAs, useConfidentialApprove, useConfidentialBalance, useConfidentialBalances, useConfidentialIsApproved, useConfidentialIsApprovedSuspense, useConfidentialTokenAddress, useConfidentialTransfer, useConfidentialTransferFrom, useCreateDelegatedUserDecryptEIP712, useCreateEIP712, useDecryptBalanceAs, useDelegateDecryption, useDelegatedUserDecrypt, useDelegationStatus, useEncrypt, useFinalizeUnwrap, useGenerateKeypair, useIsAllowed, useIsConfidential, useIsConfidentialSuspense, useIsConfidentialTokenValid, useIsWrapper, useIsWrapperSuspense, useListPairs, useMetadata, useMetadataSuspense, usePublicDecrypt, usePublicKey, usePublicParams, useReadonlyToken, useRequestZKProofVerification, useResumeUnshield, useRevoke, useRevokeDelegation, useRevokeSession, useShield, useToken, useTokenAddress, useTokenPair, useTokenPairsLength, useTokenPairsRegistry, useTokenPairsSlice, useTotalSupply, useTotalSupplySuspense, useUnderlyingAllowance, useUnderlyingAllowanceSuspense, useUnshield, useUnshieldAll, useUnwrap, useUnwrapAll, useUserDecrypt, useWrapperDiscovery, useWrapperDiscoverySuspense, useWrappersRegistryAddress, useZamaSDK };
1224
+ export { ACL_TOPICS, type AclEvent, AclPausedError, type ActivityAmount, type ActivityDirection, type ActivityItem, type ActivityLogMetadata, type ActivityType, type Address, ApprovalFailedError, type ApproveSubmittedEvent, type ApproveUnderlyingParams, type ApproveUnderlyingSubmittedEvent, BalanceCheckUnavailableError, type BaseEvent, type BatchBalancesResult, type BatchDecryptAsOptions, type BatchDecryptBalancesAsParams, ChromeSessionStorage, type ClearValueType, type ConfidentialApproveParams, type ConfidentialTransferEvent, type ConfidentialTransferFromParams, type ConfidentialTransferParams, ConfigurationError, type ContractAbi, type CreateDelegatedUserDecryptEIP712Params, type CreateEIP712Params, type CredentialsAllowedEvent, type CredentialsCachedEvent, type CredentialsCreatedEvent, type CredentialsCreatingEvent, type CredentialsExpiredEvent, type CredentialsLoadingEvent, CredentialsManager, type CredentialsManagerConfig, type CredentialsRevokedEvent, type DecryptBalanceAsParams, type DecryptEndEvent, type DecryptErrorEvent, type DecryptHandle, type DecryptResult, type DecryptStartEvent, DecryptionFailedError, DefaultRegistryAddresses, type DelegateDecryptionParams, DelegatedCredentialsManager, type DelegatedCredentialsManagerConfig, type DelegatedForUserDecryptionEvent, type DelegatedStoredCredentials, type DelegatedUserDecryptParams, DelegationContractIsSelfError, DelegationCooldownError, DelegationDelegateEqualsContractError, DelegationExpirationTooSoonError, DelegationExpiredError, DelegationExpiryUnchangedError, DelegationNotFoundError, DelegationNotPropagatedError, DelegationSelfNotAllowedError, type DelegationStatusData, type DelegationStatusQueryConfig, type EIP712TypedData, ERC20ReadFailedError, ERC7984_INTERFACE_ID, ERC7984_WRAPPER_INTERFACE_ID, type EncryptEndEvent, type EncryptErrorEvent, type EncryptInput, type EncryptParams, type EncryptResult, type EncryptStartEvent, EncryptionFailedError, type FheTypeName, type FhevmInstanceConfig, type FinalizeUnwrapParams, type FinalizeUnwrapSubmittedEvent, type GenericSigner, type GenericStorage, type Handle, HardhatConfig, type Hex, IndexedDBStorage, type InputProofBytesType, InsufficientConfidentialBalanceError, InsufficientERC20BalanceError, InvalidKeypairError, KeypairExpiredError, type KeypairType, type KmsDelegatedUserDecryptEIP712Type, type ListPairsOptions, type ListPairsQueryConfig, MainnetConfig, MemoryStorage, type NetworkType, NoCiphertextError, type OnChainEvent, type OptimisticBalanceSnapshot, type OptimisticMutateContext, type PaginatedResult, type PublicDecryptResult, type PublicKeyData, type PublicParamsData, type RawLog, type ReadContractArgs, type ReadContractConfig, type ReadContractReturnType, type ReadFunctionName, ReadonlyToken, RelayerRequestFailedError, type RelayerSDK, type RelayerSDKStatus, RelayerWeb, type RelayerWebConfig, type RelayerWebSecurityConfig, type ResumeUnshieldParams, type RevokeDelegationParams, type RevokedDelegationForUserDecryptionEvent, SepoliaConfig, type SessionExpiredEvent, type ShieldCallbacks, type ShieldParams, type ShieldSubmittedEvent, SigningFailedError, SigningRejectedError, type StoredCredentials, TOKEN_TOPICS, Token, type TokenMetadata, type TokenWrapperPair, type TokenWrapperPairWithMetadata, Topics, type TransactionErrorEvent, type TransactionReceipt, type TransactionResult, TransactionRevertedError, type TransferCallbacks, type TransferFromSubmittedEvent, type TransferSubmittedEvent, type UnshieldAllParams, type UnshieldCallbacks, type UnshieldParams, type UnshieldPhase1SubmittedEvent, type UnshieldPhase2StartedEvent, type UnshieldPhase2SubmittedEvent, type UnwrapParams, type UnwrapRequestedEvent, type UnwrapSubmittedEvent, type UnwrappedFinalizedEvent, type UnwrappedStartedEvent, type UseActivityFeedConfig, type UseConfidentialBalanceConfig, type UseConfidentialBalanceOptions, type UseConfidentialBalancesConfig, type UseConfidentialBalancesOptions, type UseConfidentialIsApprovedConfig, type UseConfidentialIsApprovedSuspenseConfig, type UseConfidentialTransferConfig, type UseDelegationStatusConfig, type UseIsAllowedConfig, type UseShieldConfig, type UseUnderlyingAllowanceConfig, type UseUserDecryptResult, type UseWrapperDiscoveryConfig, type UseWrapperDiscoverySuspenseConfig, type UseZamaConfig, type UserDecryptParams, type UserDecryptQueryConfig, type WrappedEvent, WrappersRegistry, type WrappersRegistryConfig, type WriteContractArgs, type WriteContractConfig, type WriteFunctionName, ZERO_HANDLE, type ZKProofLike, ZamaError, ZamaErrorCode, ZamaProvider, type ZamaProviderProps, ZamaSDK, type ZamaSDKConfig, type ZamaSDKEvent, type ZamaSDKEventInput, type ZamaSDKEventListener, type ZamaSDKEventType, ZamaSDKEvents, activityFeedQueryOptions, allowMutationOptions, allowanceContract, applyDecryptedValues, approveContract, approveUnderlyingMutationOptions, balanceOfContract, batchDecryptBalancesAsMutationOptions, chromeSessionStorage, clearPendingUnshield, confidentialApproveMutationOptions, confidentialBalanceOfContract, confidentialBalanceQueryOptions, confidentialBalancesQueryOptions, confidentialIsApprovedQueryOptions, confidentialTotalSupplyContract, confidentialTransferContract, confidentialTransferFromContract, confidentialTransferFromMutationOptions, confidentialTransferMutationOptions, createDelegatedUserDecryptEIP712MutationOptions, createEIP712MutationOptions, decimalsContract, decodeAclEvent, decodeAclEvents, decodeConfidentialTransfer, decodeDelegatedForUserDecryption, decodeOnChainEvent, decodeOnChainEvents, decodeRevokedDelegationForUserDecryption, decodeUnwrapRequested, decodeUnwrappedFinalized, decodeUnwrappedStarted, decodeWrapped, decryptBalanceAsMutationOptions, delegateDecryptionMutationOptions, delegateForUserDecryptionContract, delegatedUserDecryptMutationOptions, delegationStatusQueryOptions, encryptMutationOptions, extractEncryptedHandles, filterQueryOptions, finalizeUnwrapContract, finalizeUnwrapMutationOptions, findDelegatedForUserDecryption, findRevokedDelegationForUserDecryption, findUnwrapRequested, findWrapped, generateKeypairMutationOptions, getDelegationExpiryContract, hashFn, indexedDBStorage, inferredTotalSupplyContract, isAllowedQueryOptions, isConfidentialQueryOptions, isConfidentialTokenContract, isConfidentialWrapperContract, isHandleDelegatedContract, isOperatorContract, isWrapperQueryOptions, isZeroHandle, listPairsQueryOptions, loadPendingUnshield, matchAclRevert, matchZamaError, memoryStorage, nameContract, parseActivityFeed, publicDecryptMutationOptions, publicKeyQueryOptions, publicParamsQueryOptions, rateContract, requestZKProofVerificationMutationOptions, resumeUnshieldMutationOptions, revokeDelegationContract, revokeDelegationMutationOptions, revokeMutationOptions, revokeSessionMutationOptions, savePendingUnshield, setOperatorContract, shieldMutationOptions, signerAddressQueryOptions, sortByBlockNumber, supportsInterfaceContract, symbolContract, tokenMetadataQueryOptions, totalSupplyContract, totalSupplyQueryOptions, underlyingAllowanceQueryOptions, underlyingContract, unshieldAllMutationOptions, unshieldMutationOptions, unwrapAllMutationOptions, unwrapContract, unwrapFromBalanceContract, unwrapMutationOptions, useActivityFeed, useAllow, useApproveUnderlying, useBatchDecryptBalancesAs, useConfidentialApprove, useConfidentialBalance, useConfidentialBalances, useConfidentialIsApproved, useConfidentialIsApprovedSuspense, useConfidentialTokenAddress, useConfidentialTransfer, useConfidentialTransferFrom, useCreateDelegatedUserDecryptEIP712, useCreateEIP712, useDecryptBalanceAs, useDelegateDecryption, useDelegatedUserDecrypt, useDelegationStatus, useEncrypt, useFinalizeUnwrap, useGenerateKeypair, useIsAllowed, useIsConfidential, useIsConfidentialSuspense, useIsConfidentialTokenValid, useIsWrapper, useIsWrapperSuspense, useListPairs, useMetadata, useMetadataSuspense, usePublicDecrypt, usePublicKey, usePublicParams, useReadonlyToken, useRequestZKProofVerification, useResumeUnshield, useRevoke, useRevokeDelegation, useRevokeSession, useShield, useToken, useTokenAddress, useTokenPair, useTokenPairsLength, useTokenPairsRegistry, useTokenPairsSlice, useTotalSupply, useTotalSupplySuspense, useUnderlyingAllowance, useUnderlyingAllowanceSuspense, useUnshield, useUnshieldAll, useUnwrap, useUnwrapAll, useUserDecrypt, useWrapperDiscovery, useWrapperDiscoverySuspense, useWrappersRegistryAddress, useZamaSDK, userDecryptQueryOptions, wrapContract, wrapperDiscoveryQueryOptions, zamaQueryKeys };
1179
1225
  //# sourceMappingURL=index.d.ts.map