UNPKG

blocklock-js

Version:

A library for encrypting and decrypting data for the future

1,073 lines 55.9 kB
import type { BaseContract, BigNumberish, BytesLike, FunctionFragment, Result, Interface, EventFragment, AddressLike, ContractRunner, ContractMethod, Listener } from "ethers"; import type { TypedContractEvent, TypedDeferredTopicFilter, TypedEventLog, TypedLogDescription, TypedListener, TypedContractMethod } from "./common"; export declare namespace BLS { type PointG2Struct = { x: [BigNumberish, BigNumberish]; y: [BigNumberish, BigNumberish]; }; type PointG2StructOutput = [ x: [bigint, bigint], y: [bigint, bigint] ] & { x: [bigint, bigint]; y: [bigint, bigint]; }; } export declare namespace TypesLib { type CiphertextStruct = { u: BLS.PointG2Struct; v: BytesLike; w: BytesLike; }; type CiphertextStructOutput = [ u: BLS.PointG2StructOutput, v: string, w: string ] & { u: BLS.PointG2StructOutput; v: string; w: string; }; type BlocklockRequestStruct = { subId: BigNumberish; directFundingFeePaid: BigNumberish; callbackGasLimit: BigNumberish; decryptionRequestID: BigNumberish; condition: BytesLike; ciphertext: TypesLib.CiphertextStruct; signature: BytesLike; decryptionKey: BytesLike; callback: AddressLike; }; type BlocklockRequestStructOutput = [ subId: bigint, directFundingFeePaid: bigint, callbackGasLimit: bigint, decryptionRequestID: bigint, condition: string, ciphertext: TypesLib.CiphertextStructOutput, signature: string, decryptionKey: string, callback: string ] & { subId: bigint; directFundingFeePaid: bigint; callbackGasLimit: bigint; decryptionRequestID: bigint; condition: string; ciphertext: TypesLib.CiphertextStructOutput; signature: string; decryptionKey: string; callback: string; }; } export interface BlocklockSenderInterface extends Interface { getFunction(nameOrSignature: "ADMIN_ROLE" | "DEFAULT_ADMIN_ROLE" | "DST_H1_G1" | "DST_H2" | "DST_H3" | "DST_H4" | "MAX_CONSUMERS" | "SCHEME_ID" | "UPGRADE_INTERFACE_VERSION" | "acceptSubscriptionOwnerTransfer" | "addConsumer" | "blocklockRequestsWithDecryptionKey" | "calculateRequestPriceNative" | "cancelSubscription" | "createSubscription" | "decrypt" | "decryptionSender" | "disable" | "enable" | "estimateRequestPriceNative" | "fundSubscriptionWithNative" | "getActiveSubscriptionIds" | "getChainId" | "getConfig" | "getRequest" | "getRoleAdmin" | "getRoleMember" | "getRoleMemberCount" | "getRoleMembers" | "getSubscription" | "grantRole" | "hasRole" | "initialize" | "isInFlight" | "ownerCancelSubscription" | "pendingRequestExists" | "proxiableUUID" | "receiveDecryptionData" | "removeConsumer" | "renounceRole" | "requestBlocklock" | "requestBlocklockWithSubscription" | "requestSubscriptionOwnerTransfer" | "revokeRole" | "s_config" | "s_configured" | "s_currentSubNonce" | "s_disabled" | "s_totalNativeBalance" | "s_withdrawableDirectFundingFeeNative" | "s_withdrawableSubscriptionFeeNative" | "setConfig" | "setDecryptionSender" | "supportsInterface" | "upgradeToAndCall" | "version" | "withdrawDirectFundingFeesNative" | "withdrawSubscriptionFeesNative"): FunctionFragment; getEvent(nameOrSignatureOrTopic: "BlocklockCallbackFailed" | "BlocklockCallbackSuccess" | "BlocklockRequested" | "ConfigSet" | "DecryptionSenderUpdated" | "Disabled" | "Enabled" | "Initialized" | "L1GasFee" | "RoleAdminChanged" | "RoleGranted" | "RoleRevoked" | "SubscriptionCanceled" | "SubscriptionConsumerAdded" | "SubscriptionConsumerRemoved" | "SubscriptionCreated" | "SubscriptionFundedWithNative" | "SubscriptionOwnerTransferRequested" | "SubscriptionOwnerTransferred" | "Upgraded"): EventFragment; encodeFunctionData(functionFragment: "ADMIN_ROLE", values?: undefined): string; encodeFunctionData(functionFragment: "DEFAULT_ADMIN_ROLE", values?: undefined): string; encodeFunctionData(functionFragment: "DST_H1_G1", values?: undefined): string; encodeFunctionData(functionFragment: "DST_H2", values?: undefined): string; encodeFunctionData(functionFragment: "DST_H3", values?: undefined): string; encodeFunctionData(functionFragment: "DST_H4", values?: undefined): string; encodeFunctionData(functionFragment: "MAX_CONSUMERS", values?: undefined): string; encodeFunctionData(functionFragment: "SCHEME_ID", values?: undefined): string; encodeFunctionData(functionFragment: "UPGRADE_INTERFACE_VERSION", values?: undefined): string; encodeFunctionData(functionFragment: "acceptSubscriptionOwnerTransfer", values: [BigNumberish]): string; encodeFunctionData(functionFragment: "addConsumer", values: [BigNumberish, AddressLike]): string; encodeFunctionData(functionFragment: "blocklockRequestsWithDecryptionKey", values: [BigNumberish]): string; encodeFunctionData(functionFragment: "calculateRequestPriceNative", values: [BigNumberish]): string; encodeFunctionData(functionFragment: "cancelSubscription", values: [BigNumberish, AddressLike]): string; encodeFunctionData(functionFragment: "createSubscription", values?: undefined): string; encodeFunctionData(functionFragment: "decrypt", values: [TypesLib.CiphertextStruct, BytesLike]): string; encodeFunctionData(functionFragment: "decryptionSender", values?: undefined): string; encodeFunctionData(functionFragment: "disable", values?: undefined): string; encodeFunctionData(functionFragment: "enable", values?: undefined): string; encodeFunctionData(functionFragment: "estimateRequestPriceNative", values: [BigNumberish, BigNumberish]): string; encodeFunctionData(functionFragment: "fundSubscriptionWithNative", values: [BigNumberish]): string; encodeFunctionData(functionFragment: "getActiveSubscriptionIds", values: [BigNumberish, BigNumberish]): string; encodeFunctionData(functionFragment: "getChainId", values?: undefined): string; encodeFunctionData(functionFragment: "getConfig", values?: undefined): string; encodeFunctionData(functionFragment: "getRequest", values: [BigNumberish]): string; encodeFunctionData(functionFragment: "getRoleAdmin", values: [BytesLike]): string; encodeFunctionData(functionFragment: "getRoleMember", values: [BytesLike, BigNumberish]): string; encodeFunctionData(functionFragment: "getRoleMemberCount", values: [BytesLike]): string; encodeFunctionData(functionFragment: "getRoleMembers", values: [BytesLike]): string; encodeFunctionData(functionFragment: "getSubscription", values: [BigNumberish]): string; encodeFunctionData(functionFragment: "grantRole", values: [BytesLike, AddressLike]): string; encodeFunctionData(functionFragment: "hasRole", values: [BytesLike, AddressLike]): string; encodeFunctionData(functionFragment: "initialize", values: [AddressLike, AddressLike]): string; encodeFunctionData(functionFragment: "isInFlight", values: [BigNumberish]): string; encodeFunctionData(functionFragment: "ownerCancelSubscription", values: [BigNumberish]): string; encodeFunctionData(functionFragment: "pendingRequestExists", values: [BigNumberish]): string; encodeFunctionData(functionFragment: "proxiableUUID", values?: undefined): string; encodeFunctionData(functionFragment: "receiveDecryptionData", values: [BigNumberish, BytesLike, BytesLike]): string; encodeFunctionData(functionFragment: "removeConsumer", values: [BigNumberish, AddressLike]): string; encodeFunctionData(functionFragment: "renounceRole", values: [BytesLike, AddressLike]): string; encodeFunctionData(functionFragment: "requestBlocklock", values: [BigNumberish, BytesLike, TypesLib.CiphertextStruct]): string; encodeFunctionData(functionFragment: "requestBlocklockWithSubscription", values: [BigNumberish, BigNumberish, BytesLike, TypesLib.CiphertextStruct]): string; encodeFunctionData(functionFragment: "requestSubscriptionOwnerTransfer", values: [BigNumberish, AddressLike]): string; encodeFunctionData(functionFragment: "revokeRole", values: [BytesLike, AddressLike]): string; encodeFunctionData(functionFragment: "s_config", values?: undefined): string; encodeFunctionData(functionFragment: "s_configured", values?: undefined): string; encodeFunctionData(functionFragment: "s_currentSubNonce", values?: undefined): string; encodeFunctionData(functionFragment: "s_disabled", values?: undefined): string; encodeFunctionData(functionFragment: "s_totalNativeBalance", values?: undefined): string; encodeFunctionData(functionFragment: "s_withdrawableDirectFundingFeeNative", values?: undefined): string; encodeFunctionData(functionFragment: "s_withdrawableSubscriptionFeeNative", values?: undefined): string; encodeFunctionData(functionFragment: "setConfig", values: [ BigNumberish, BigNumberish, BigNumberish, BigNumberish, BigNumberish, BigNumberish, BigNumberish ]): string; encodeFunctionData(functionFragment: "setDecryptionSender", values: [AddressLike]): string; encodeFunctionData(functionFragment: "supportsInterface", values: [BytesLike]): string; encodeFunctionData(functionFragment: "upgradeToAndCall", values: [AddressLike, BytesLike]): string; encodeFunctionData(functionFragment: "version", values?: undefined): string; encodeFunctionData(functionFragment: "withdrawDirectFundingFeesNative", values: [AddressLike]): string; encodeFunctionData(functionFragment: "withdrawSubscriptionFeesNative", values: [AddressLike]): string; decodeFunctionResult(functionFragment: "ADMIN_ROLE", data: BytesLike): Result; decodeFunctionResult(functionFragment: "DEFAULT_ADMIN_ROLE", data: BytesLike): Result; decodeFunctionResult(functionFragment: "DST_H1_G1", data: BytesLike): Result; decodeFunctionResult(functionFragment: "DST_H2", data: BytesLike): Result; decodeFunctionResult(functionFragment: "DST_H3", data: BytesLike): Result; decodeFunctionResult(functionFragment: "DST_H4", data: BytesLike): Result; decodeFunctionResult(functionFragment: "MAX_CONSUMERS", data: BytesLike): Result; decodeFunctionResult(functionFragment: "SCHEME_ID", data: BytesLike): Result; decodeFunctionResult(functionFragment: "UPGRADE_INTERFACE_VERSION", data: BytesLike): Result; decodeFunctionResult(functionFragment: "acceptSubscriptionOwnerTransfer", data: BytesLike): Result; decodeFunctionResult(functionFragment: "addConsumer", data: BytesLike): Result; decodeFunctionResult(functionFragment: "blocklockRequestsWithDecryptionKey", data: BytesLike): Result; decodeFunctionResult(functionFragment: "calculateRequestPriceNative", data: BytesLike): Result; decodeFunctionResult(functionFragment: "cancelSubscription", data: BytesLike): Result; decodeFunctionResult(functionFragment: "createSubscription", data: BytesLike): Result; decodeFunctionResult(functionFragment: "decrypt", data: BytesLike): Result; decodeFunctionResult(functionFragment: "decryptionSender", data: BytesLike): Result; decodeFunctionResult(functionFragment: "disable", data: BytesLike): Result; decodeFunctionResult(functionFragment: "enable", data: BytesLike): Result; decodeFunctionResult(functionFragment: "estimateRequestPriceNative", data: BytesLike): Result; decodeFunctionResult(functionFragment: "fundSubscriptionWithNative", data: BytesLike): Result; decodeFunctionResult(functionFragment: "getActiveSubscriptionIds", data: BytesLike): Result; decodeFunctionResult(functionFragment: "getChainId", data: BytesLike): Result; decodeFunctionResult(functionFragment: "getConfig", data: BytesLike): Result; decodeFunctionResult(functionFragment: "getRequest", data: BytesLike): Result; decodeFunctionResult(functionFragment: "getRoleAdmin", data: BytesLike): Result; decodeFunctionResult(functionFragment: "getRoleMember", data: BytesLike): Result; decodeFunctionResult(functionFragment: "getRoleMemberCount", data: BytesLike): Result; decodeFunctionResult(functionFragment: "getRoleMembers", data: BytesLike): Result; decodeFunctionResult(functionFragment: "getSubscription", data: BytesLike): Result; decodeFunctionResult(functionFragment: "grantRole", data: BytesLike): Result; decodeFunctionResult(functionFragment: "hasRole", data: BytesLike): Result; decodeFunctionResult(functionFragment: "initialize", data: BytesLike): Result; decodeFunctionResult(functionFragment: "isInFlight", data: BytesLike): Result; decodeFunctionResult(functionFragment: "ownerCancelSubscription", data: BytesLike): Result; decodeFunctionResult(functionFragment: "pendingRequestExists", data: BytesLike): Result; decodeFunctionResult(functionFragment: "proxiableUUID", data: BytesLike): Result; decodeFunctionResult(functionFragment: "receiveDecryptionData", data: BytesLike): Result; decodeFunctionResult(functionFragment: "removeConsumer", data: BytesLike): Result; decodeFunctionResult(functionFragment: "renounceRole", data: BytesLike): Result; decodeFunctionResult(functionFragment: "requestBlocklock", data: BytesLike): Result; decodeFunctionResult(functionFragment: "requestBlocklockWithSubscription", data: BytesLike): Result; decodeFunctionResult(functionFragment: "requestSubscriptionOwnerTransfer", data: BytesLike): Result; decodeFunctionResult(functionFragment: "revokeRole", data: BytesLike): Result; decodeFunctionResult(functionFragment: "s_config", data: BytesLike): Result; decodeFunctionResult(functionFragment: "s_configured", data: BytesLike): Result; decodeFunctionResult(functionFragment: "s_currentSubNonce", data: BytesLike): Result; decodeFunctionResult(functionFragment: "s_disabled", data: BytesLike): Result; decodeFunctionResult(functionFragment: "s_totalNativeBalance", data: BytesLike): Result; decodeFunctionResult(functionFragment: "s_withdrawableDirectFundingFeeNative", data: BytesLike): Result; decodeFunctionResult(functionFragment: "s_withdrawableSubscriptionFeeNative", data: BytesLike): Result; decodeFunctionResult(functionFragment: "setConfig", data: BytesLike): Result; decodeFunctionResult(functionFragment: "setDecryptionSender", data: BytesLike): Result; decodeFunctionResult(functionFragment: "supportsInterface", data: BytesLike): Result; decodeFunctionResult(functionFragment: "upgradeToAndCall", data: BytesLike): Result; decodeFunctionResult(functionFragment: "version", data: BytesLike): Result; decodeFunctionResult(functionFragment: "withdrawDirectFundingFeesNative", data: BytesLike): Result; decodeFunctionResult(functionFragment: "withdrawSubscriptionFeesNative", data: BytesLike): Result; } export declare namespace BlocklockCallbackFailedEvent { type InputTuple = [requestID: BigNumberish]; type OutputTuple = [requestID: bigint]; interface OutputObject { requestID: bigint; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace BlocklockCallbackSuccessEvent { type InputTuple = [ requestID: BigNumberish, condition: BytesLike, ciphertext: TypesLib.CiphertextStruct, decryptionKey: BytesLike ]; type OutputTuple = [ requestID: bigint, condition: string, ciphertext: TypesLib.CiphertextStructOutput, decryptionKey: string ]; interface OutputObject { requestID: bigint; condition: string; ciphertext: TypesLib.CiphertextStructOutput; decryptionKey: string; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace BlocklockRequestedEvent { type InputTuple = [ requestID: BigNumberish, condition: BytesLike, ciphertext: TypesLib.CiphertextStruct, requester: AddressLike, requestedAt: BigNumberish ]; type OutputTuple = [ requestID: bigint, condition: string, ciphertext: TypesLib.CiphertextStructOutput, requester: string, requestedAt: bigint ]; interface OutputObject { requestID: bigint; condition: string; ciphertext: TypesLib.CiphertextStructOutput; requester: string; requestedAt: bigint; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace ConfigSetEvent { type InputTuple = [ maxGasLimit: BigNumberish, gasAfterPaymentCalculation: BigNumberish, fulfillmentFlatFeeNativePPM: BigNumberish, weiPerUnitGas: BigNumberish, blsPairingCheckOverhead: BigNumberish, nativePremiumPercentage: BigNumberish, gasForCallExactCheck: BigNumberish ]; type OutputTuple = [ maxGasLimit: bigint, gasAfterPaymentCalculation: bigint, fulfillmentFlatFeeNativePPM: bigint, weiPerUnitGas: bigint, blsPairingCheckOverhead: bigint, nativePremiumPercentage: bigint, gasForCallExactCheck: bigint ]; interface OutputObject { maxGasLimit: bigint; gasAfterPaymentCalculation: bigint; fulfillmentFlatFeeNativePPM: bigint; weiPerUnitGas: bigint; blsPairingCheckOverhead: bigint; nativePremiumPercentage: bigint; gasForCallExactCheck: bigint; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace DecryptionSenderUpdatedEvent { type InputTuple = [decryptionSender: AddressLike]; type OutputTuple = [decryptionSender: string]; interface OutputObject { decryptionSender: string; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace DisabledEvent { type InputTuple = []; type OutputTuple = []; interface OutputObject { } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace EnabledEvent { type InputTuple = []; type OutputTuple = []; interface OutputObject { } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace InitializedEvent { type InputTuple = [version: BigNumberish]; type OutputTuple = [version: bigint]; interface OutputObject { version: bigint; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace L1GasFeeEvent { type InputTuple = [fee: BigNumberish]; type OutputTuple = [fee: bigint]; interface OutputObject { fee: bigint; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace RoleAdminChangedEvent { type InputTuple = [ role: BytesLike, previousAdminRole: BytesLike, newAdminRole: BytesLike ]; type OutputTuple = [ role: string, previousAdminRole: string, newAdminRole: string ]; interface OutputObject { role: string; previousAdminRole: string; newAdminRole: string; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace RoleGrantedEvent { type InputTuple = [ role: BytesLike, account: AddressLike, sender: AddressLike ]; type OutputTuple = [role: string, account: string, sender: string]; interface OutputObject { role: string; account: string; sender: string; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace RoleRevokedEvent { type InputTuple = [ role: BytesLike, account: AddressLike, sender: AddressLike ]; type OutputTuple = [role: string, account: string, sender: string]; interface OutputObject { role: string; account: string; sender: string; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace SubscriptionCanceledEvent { type InputTuple = [ subId: BigNumberish, to: AddressLike, amountNative: BigNumberish ]; type OutputTuple = [subId: bigint, to: string, amountNative: bigint]; interface OutputObject { subId: bigint; to: string; amountNative: bigint; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace SubscriptionConsumerAddedEvent { type InputTuple = [subId: BigNumberish, consumer: AddressLike]; type OutputTuple = [subId: bigint, consumer: string]; interface OutputObject { subId: bigint; consumer: string; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace SubscriptionConsumerRemovedEvent { type InputTuple = [subId: BigNumberish, consumer: AddressLike]; type OutputTuple = [subId: bigint, consumer: string]; interface OutputObject { subId: bigint; consumer: string; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace SubscriptionCreatedEvent { type InputTuple = [subId: BigNumberish, owner: AddressLike]; type OutputTuple = [subId: bigint, owner: string]; interface OutputObject { subId: bigint; owner: string; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace SubscriptionFundedWithNativeEvent { type InputTuple = [ subId: BigNumberish, oldNativeBalance: BigNumberish, newNativeBalance: BigNumberish ]; type OutputTuple = [ subId: bigint, oldNativeBalance: bigint, newNativeBalance: bigint ]; interface OutputObject { subId: bigint; oldNativeBalance: bigint; newNativeBalance: bigint; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace SubscriptionOwnerTransferRequestedEvent { type InputTuple = [ subId: BigNumberish, from: AddressLike, to: AddressLike ]; type OutputTuple = [subId: bigint, from: string, to: string]; interface OutputObject { subId: bigint; from: string; to: string; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace SubscriptionOwnerTransferredEvent { type InputTuple = [ subId: BigNumberish, from: AddressLike, to: AddressLike ]; type OutputTuple = [subId: bigint, from: string, to: string]; interface OutputObject { subId: bigint; from: string; to: string; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export declare namespace UpgradedEvent { type InputTuple = [implementation: AddressLike]; type OutputTuple = [implementation: string]; interface OutputObject { implementation: string; } type Event = TypedContractEvent<InputTuple, OutputTuple, OutputObject>; type Filter = TypedDeferredTopicFilter<Event>; type Log = TypedEventLog<Event>; type LogDescription = TypedLogDescription<Event>; } export interface BlocklockSender extends BaseContract { connect(runner?: ContractRunner | null): BlocklockSender; waitForDeployment(): Promise<this>; interface: BlocklockSenderInterface; queryFilter<TCEvent extends TypedContractEvent>(event: TCEvent, fromBlockOrBlockhash?: string | number | undefined, toBlock?: string | number | undefined): Promise<Array<TypedEventLog<TCEvent>>>; queryFilter<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, fromBlockOrBlockhash?: string | number | undefined, toBlock?: string | number | undefined): Promise<Array<TypedEventLog<TCEvent>>>; on<TCEvent extends TypedContractEvent>(event: TCEvent, listener: TypedListener<TCEvent>): Promise<this>; on<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, listener: TypedListener<TCEvent>): Promise<this>; once<TCEvent extends TypedContractEvent>(event: TCEvent, listener: TypedListener<TCEvent>): Promise<this>; once<TCEvent extends TypedContractEvent>(filter: TypedDeferredTopicFilter<TCEvent>, listener: TypedListener<TCEvent>): Promise<this>; listeners<TCEvent extends TypedContractEvent>(event: TCEvent): Promise<Array<TypedListener<TCEvent>>>; listeners(eventName?: string): Promise<Array<Listener>>; removeAllListeners<TCEvent extends TypedContractEvent>(event?: TCEvent): Promise<this>; ADMIN_ROLE: TypedContractMethod<[], [string], "view">; DEFAULT_ADMIN_ROLE: TypedContractMethod<[], [string], "view">; DST_H1_G1: TypedContractMethod<[], [string], "view">; DST_H2: TypedContractMethod<[], [string], "view">; DST_H3: TypedContractMethod<[], [string], "view">; DST_H4: TypedContractMethod<[], [string], "view">; MAX_CONSUMERS: TypedContractMethod<[], [bigint], "view">; SCHEME_ID: TypedContractMethod<[], [string], "view">; UPGRADE_INTERFACE_VERSION: TypedContractMethod<[], [string], "view">; acceptSubscriptionOwnerTransfer: TypedContractMethod<[ subId: BigNumberish ], [ void ], "nonpayable">; addConsumer: TypedContractMethod<[ subId: BigNumberish, consumer: AddressLike ], [ void ], "nonpayable">; blocklockRequestsWithDecryptionKey: TypedContractMethod<[ arg0: BigNumberish ], [ [ bigint, bigint, bigint, bigint, string, TypesLib.CiphertextStructOutput, string, string, string ] & { subId: bigint; directFundingFeePaid: bigint; callbackGasLimit: bigint; decryptionRequestID: bigint; condition: string; ciphertext: TypesLib.CiphertextStructOutput; signature: string; decryptionKey: string; callback: string; } ], "view">; calculateRequestPriceNative: TypedContractMethod<[ _callbackGasLimit: BigNumberish ], [ bigint ], "view">; cancelSubscription: TypedContractMethod<[ subId: BigNumberish, to: AddressLike ], [ void ], "nonpayable">; createSubscription: TypedContractMethod<[], [bigint], "nonpayable">; decrypt: TypedContractMethod<[ ciphertext: TypesLib.CiphertextStruct, decryptionKey: BytesLike ], [ string ], "view">; decryptionSender: TypedContractMethod<[], [string], "view">; disable: TypedContractMethod<[], [void], "nonpayable">; enable: TypedContractMethod<[], [void], "nonpayable">; estimateRequestPriceNative: TypedContractMethod<[ _callbackGasLimit: BigNumberish, _requestGasPriceWei: BigNumberish ], [ bigint ], "view">; fundSubscriptionWithNative: TypedContractMethod<[ subId: BigNumberish ], [ void ], "payable">; getActiveSubscriptionIds: TypedContractMethod<[ startIndex: BigNumberish, maxCount: BigNumberish ], [ bigint[] ], "view">; getChainId: TypedContractMethod<[], [bigint], "view">; getConfig: TypedContractMethod<[ ], [ [ bigint, bigint, bigint, bigint, bigint, bigint, bigint ] & { maxGasLimit: bigint; gasAfterPaymentCalculation: bigint; fulfillmentFlatFeeNativePPM: bigint; weiPerUnitGas: bigint; blsPairingCheckOverhead: bigint; nativePremiumPercentage: bigint; gasForCallExactCheck: bigint; } ], "view">; getRequest: TypedContractMethod<[ requestID: BigNumberish ], [ TypesLib.BlocklockRequestStructOutput ], "view">; getRoleAdmin: TypedContractMethod<[role: BytesLike], [string], "view">; getRoleMember: TypedContractMethod<[ role: BytesLike, index: BigNumberish ], [ string ], "view">; getRoleMemberCount: TypedContractMethod<[role: BytesLike], [bigint], "view">; getRoleMembers: TypedContractMethod<[role: BytesLike], [string[]], "view">; getSubscription: TypedContractMethod<[ subId: BigNumberish ], [ [ bigint, bigint, string, string[] ] & { nativeBalance: bigint; reqCount: bigint; subOwner: string; consumers: string[]; } ], "view">; grantRole: TypedContractMethod<[ role: BytesLike, account: AddressLike ], [ void ], "nonpayable">; hasRole: TypedContractMethod<[ role: BytesLike, account: AddressLike ], [ boolean ], "view">; initialize: TypedContractMethod<[ owner: AddressLike, _decryptionSender: AddressLike ], [ void ], "nonpayable">; isInFlight: TypedContractMethod<[requestID: BigNumberish], [boolean], "view">; ownerCancelSubscription: TypedContractMethod<[ subId: BigNumberish ], [ void ], "nonpayable">; pendingRequestExists: TypedContractMethod<[ subId: BigNumberish ], [ boolean ], "view">; proxiableUUID: TypedContractMethod<[], [string], "view">; receiveDecryptionData: TypedContractMethod<[ requestID: BigNumberish, decryptionKey: BytesLike, signature: BytesLike ], [ void ], "nonpayable">; removeConsumer: TypedContractMethod<[ subId: BigNumberish, consumer: AddressLike ], [ void ], "nonpayable">; renounceRole: TypedContractMethod<[ role: BytesLike, callerConfirmation: AddressLike ], [ void ], "nonpayable">; requestBlocklock: TypedContractMethod<[ callbackGasLimit: BigNumberish, condition: BytesLike, ciphertext: TypesLib.CiphertextStruct ], [ bigint ], "payable">; requestBlocklockWithSubscription: TypedContractMethod<[ callbackGasLimit: BigNumberish, subId: BigNumberish, condition: BytesLike, ciphertext: TypesLib.CiphertextStruct ], [ bigint ], "payable">; requestSubscriptionOwnerTransfer: TypedContractMethod<[ subId: BigNumberish, newOwner: AddressLike ], [ void ], "nonpayable">; revokeRole: TypedContractMethod<[ role: BytesLike, account: AddressLike ], [ void ], "nonpayable">; s_config: TypedContractMethod<[ ], [ [ bigint, bigint, bigint, bigint, bigint, bigint, bigint ] & { maxGasLimit: bigint; gasAfterPaymentCalculation: bigint; fulfillmentFlatFeeNativePPM: bigint; weiPerUnitGas: bigint; blsPairingCheckOverhead: bigint; nativePremiumPercentage: bigint; gasForCallExactCheck: bigint; } ], "view">; s_configured: TypedContractMethod<[], [boolean], "view">; s_currentSubNonce: TypedContractMethod<[], [bigint], "view">; s_disabled: TypedContractMethod<[], [boolean], "view">; s_totalNativeBalance: TypedContractMethod<[], [bigint], "view">; s_withdrawableDirectFundingFeeNative: TypedContractMethod<[ ], [ bigint ], "view">; s_withdrawableSubscriptionFeeNative: TypedContractMethod<[ ], [ bigint ], "view">; setConfig: TypedContractMethod<[ maxGasLimit: BigNumberish, gasAfterPaymentCalculation: BigNumberish, fulfillmentFlatFeeNativePPM: BigNumberish, weiPerUnitGas: BigNumberish, blsPairingCheckOverhead: BigNumberish, nativePremiumPercentage: BigNumberish, gasForCallExactCheck: BigNumberish ], [ void ], "nonpayable">; setDecryptionSender: TypedContractMethod<[ newDecryptionSender: AddressLike ], [ void ], "nonpayable">; supportsInterface: TypedContractMethod<[ interfaceId: BytesLike ], [ boolean ], "view">; upgradeToAndCall: TypedContractMethod<[ newImplementation: AddressLike, data: BytesLike ], [ void ], "payable">; version: TypedContractMethod<[], [string], "view">; withdrawDirectFundingFeesNative: TypedContractMethod<[ recipient: AddressLike ], [ void ], "nonpayable">; withdrawSubscriptionFeesNative: TypedContractMethod<[ recipient: AddressLike ], [ void ], "nonpayable">; getFunction<T extends ContractMethod = ContractMethod>(key: string | FunctionFragment): T; getFunction(nameOrSignature: "ADMIN_ROLE"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "DEFAULT_ADMIN_ROLE"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "DST_H1_G1"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "DST_H2"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "DST_H3"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "DST_H4"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "MAX_CONSUMERS"): TypedContractMethod<[], [bigint], "view">; getFunction(nameOrSignature: "SCHEME_ID"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "UPGRADE_INTERFACE_VERSION"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "acceptSubscriptionOwnerTransfer"): TypedContractMethod<[subId: BigNumberish], [void], "nonpayable">; getFunction(nameOrSignature: "addConsumer"): TypedContractMethod<[ subId: BigNumberish, consumer: AddressLike ], [ void ], "nonpayable">; getFunction(nameOrSignature: "blocklockRequestsWithDecryptionKey"): TypedContractMethod<[ arg0: BigNumberish ], [ [ bigint, bigint, bigint, bigint, string, TypesLib.CiphertextStructOutput, string, string, string ] & { subId: bigint; directFundingFeePaid: bigint; callbackGasLimit: bigint; decryptionRequestID: bigint; condition: string; ciphertext: TypesLib.CiphertextStructOutput; signature: string; decryptionKey: string; callback: string; } ], "view">; getFunction(nameOrSignature: "calculateRequestPriceNative"): TypedContractMethod<[_callbackGasLimit: BigNumberish], [bigint], "view">; getFunction(nameOrSignature: "cancelSubscription"): TypedContractMethod<[ subId: BigNumberish, to: AddressLike ], [ void ], "nonpayable">; getFunction(nameOrSignature: "createSubscription"): TypedContractMethod<[], [bigint], "nonpayable">; getFunction(nameOrSignature: "decrypt"): TypedContractMethod<[ ciphertext: TypesLib.CiphertextStruct, decryptionKey: BytesLike ], [ string ], "view">; getFunction(nameOrSignature: "decryptionSender"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "disable"): TypedContractMethod<[], [void], "nonpayable">; getFunction(nameOrSignature: "enable"): TypedContractMethod<[], [void], "nonpayable">; getFunction(nameOrSignature: "estimateRequestPriceNative"): TypedContractMethod<[ _callbackGasLimit: BigNumberish, _requestGasPriceWei: BigNumberish ], [ bigint ], "view">; getFunction(nameOrSignature: "fundSubscriptionWithNative"): TypedContractMethod<[subId: BigNumberish], [void], "payable">; getFunction(nameOrSignature: "getActiveSubscriptionIds"): TypedContractMethod<[ startIndex: BigNumberish, maxCount: BigNumberish ], [ bigint[] ], "view">; getFunction(nameOrSignature: "getChainId"): TypedContractMethod<[], [bigint], "view">; getFunction(nameOrSignature: "getConfig"): TypedContractMethod<[ ], [ [ bigint, bigint, bigint, bigint, bigint, bigint, bigint ] & { maxGasLimit: bigint; gasAfterPaymentCalculation: bigint; fulfillmentFlatFeeNativePPM: bigint; weiPerUnitGas: bigint; blsPairingCheckOverhead: bigint; nativePremiumPercentage: bigint; gasForCallExactCheck: bigint; } ], "view">; getFunction(nameOrSignature: "getRequest"): TypedContractMethod<[ requestID: BigNumberish ], [ TypesLib.BlocklockRequestStructOutput ], "view">; getFunction(nameOrSignature: "getRoleAdmin"): TypedContractMethod<[role: BytesLike], [string], "view">; getFunction(nameOrSignature: "getRoleMember"): TypedContractMethod<[ role: BytesLike, index: BigNumberish ], [ string ], "view">; getFunction(nameOrSignature: "getRoleMemberCount"): TypedContractMethod<[role: BytesLike], [bigint], "view">; getFunction(nameOrSignature: "getRoleMembers"): TypedContractMethod<[role: BytesLike], [string[]], "view">; getFunction(nameOrSignature: "getSubscription"): TypedContractMethod<[ subId: BigNumberish ], [ [ bigint, bigint, string, string[] ] & { nativeBalance: bigint; reqCount: bigint; subOwner: string; consumers: string[]; } ], "view">; getFunction(nameOrSignature: "grantRole"): TypedContractMethod<[ role: BytesLike, account: AddressLike ], [ void ], "nonpayable">; getFunction(nameOrSignature: "hasRole"): TypedContractMethod<[ role: BytesLike, account: AddressLike ], [ boolean ], "view">; getFunction(nameOrSignature: "initialize"): TypedContractMethod<[ owner: AddressLike, _decryptionSender: AddressLike ], [ void ], "nonpayable">; getFunction(nameOrSignature: "isInFlight"): TypedContractMethod<[requestID: BigNumberish], [boolean], "view">; getFunction(nameOrSignature: "ownerCancelSubscription"): TypedContractMethod<[subId: BigNumberish], [void], "nonpayable">; getFunction(nameOrSignature: "pendingRequestExists"): TypedContractMethod<[subId: BigNumberish], [boolean], "view">; getFunction(nameOrSignature: "proxiableUUID"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "receiveDecryptionData"): TypedContractMethod<[ requestID: BigNumberish, decryptionKey: BytesLike, signature: BytesLike ], [ void ], "nonpayable">; getFunction(nameOrSignature: "removeConsumer"): TypedContractMethod<[ subId: BigNumberish, consumer: AddressLike ], [ void ], "nonpayable">; getFunction(nameOrSignature: "renounceRole"): TypedContractMethod<[ role: BytesLike, callerConfirmation: AddressLike ], [ void ], "nonpayable">; getFunction(nameOrSignature: "requestBlocklock"): TypedContractMethod<[ callbackGasLimit: BigNumberish, condition: BytesLike, ciphertext: TypesLib.CiphertextStruct ], [ bigint ], "payable">; getFunction(nameOrSignature: "requestBlocklockWithSubscription"): TypedContractMethod<[ callbackGasLimit: BigNumberish, subId: BigNumberish, condition: BytesLike, ciphertext: TypesLib.CiphertextStruct ], [ bigint ], "payable">; getFunction(nameOrSignature: "requestSubscriptionOwnerTransfer"): TypedContractMethod<[ subId: BigNumberish, newOwner: AddressLike ], [ void ], "nonpayable">; getFunction(nameOrSignature: "revokeRole"): TypedContractMethod<[ role: BytesLike, account: AddressLike ], [ void ], "nonpayable">; getFunction(nameOrSignature: "s_config"): TypedContractMethod<[ ], [ [ bigint, bigint, bigint, bigint, bigint, bigint, bigint ] & { maxGasLimit: bigint; gasAfterPaymentCalculation: bigint; fulfillmentFlatFeeNativePPM: bigint; weiPerUnitGas: bigint; blsPairingCheckOverhead: bigint; nativePremiumPercentage: bigint; gasForCallExactCheck: bigint; } ], "view">; getFunction(nameOrSignature: "s_configured"): TypedContractMethod<[], [boolean], "view">; getFunction(nameOrSignature: "s_currentSubNonce"): TypedContractMethod<[], [bigint], "view">; getFunction(nameOrSignature: "s_disabled"): TypedContractMethod<[], [boolean], "view">; getFunction(nameOrSignature: "s_totalNativeBalance"): TypedContractMethod<[], [bigint], "view">; getFunction(nameOrSignature: "s_withdrawableDirectFundingFeeNative"): TypedContractMethod<[], [bigint], "view">; getFunction(nameOrSignature: "s_withdrawableSubscriptionFeeNative"): TypedContractMethod<[], [bigint], "view">; getFunction(nameOrSignature: "setConfig"): TypedContractMethod<[ maxGasLimit: BigNumberish, gasAfterPaymentCalculation: BigNumberish, fulfillmentFlatFeeNativePPM: BigNumberish, weiPerUnitGas: BigNumberish, blsPairingCheckOverhead: BigNumberish, nativePremiumPercentage: BigNumberish, gasForCallExactCheck: BigNumberish ], [ void ], "nonpayable">; getFunction(nameOrSignature: "setDecryptionSender"): TypedContractMethod<[ newDecryptionSender: AddressLike ], [ void ], "nonpayable">; getFunction(nameOrSignature: "supportsInterface"): TypedContractMethod<[interfaceId: BytesLike], [boolean], "view">; getFunction(nameOrSignature: "upgradeToAndCall"): TypedContractMethod<[ newImplementation: AddressLike, data: BytesLike ], [ void ], "payable">; getFunction(nameOrSignature: "version"): TypedContractMethod<[], [string], "view">; getFunction(nameOrSignature: "withdrawDirectFundingFeesNative"): TypedContractMethod<[recipient: AddressLike], [void], "nonpayable">; getFunction(nameOrSignature: "withdrawSubscriptionFeesNative"): TypedContractMethod<[recipient: AddressLike], [void], "nonpayable">; getEvent(key: "BlocklockCallbackFailed"): TypedContractEvent<BlocklockCallbackFailedEvent.InputTuple, BlocklockCallbackFailedEvent.OutputTuple, BlocklockCallbackFailedEvent.OutputObject>; getEvent(key: "BlocklockCallbackSuccess"): TypedContractEvent<BlocklockCallbackSuccessEvent.InputTuple, BlocklockCallbackSuccessEvent.OutputTuple, BlocklockCallbackSuccessEvent.OutputObject>; getEvent(key: "BlocklockRequested"): TypedContractEvent<BlocklockRequestedEvent.InputTuple, BlocklockRequestedEvent.OutputTuple, BlocklockRequestedEvent.OutputObject>; getEvent(key: "ConfigSet"): TypedContractEvent<ConfigSetEvent.InputTuple, ConfigSetEvent.OutputTuple, ConfigSetEvent.OutputObject>; getEvent(key: "DecryptionSenderUpdated"): TypedContractEvent<DecryptionSenderUpdatedEvent.InputTuple, DecryptionSenderUpdatedEvent.OutputTuple, DecryptionSenderUpdatedEvent.OutputObject>; getEvent(key: "Disabled"): TypedContractEvent<DisabledEvent.InputTuple, DisabledEvent.OutputTuple, DisabledEvent.OutputObject>; getEvent(key: "Enabled"): TypedContractEvent<EnabledEvent.InputTuple, EnabledEvent.OutputTuple, EnabledEvent.OutputObject>; getEvent(key: "Initialized"): TypedContractEvent<InitializedEvent.InputTuple, InitializedEvent.OutputTuple, InitializedEvent.OutputObject>; getEvent(key: "L1GasFee"): TypedContractEvent<L1GasFeeEvent.InputTuple, L1GasFeeEvent.OutputTuple, L1GasFeeEvent.OutputObject>; getEvent(key: "RoleAdminChanged"): TypedContractEvent<RoleAdminChangedEvent.InputTuple, RoleAdminChangedEvent.OutputTuple, RoleAdminChangedEvent.OutputObject>; getEvent(key: "RoleGranted"): TypedContractEvent<RoleGrantedEvent.InputTuple, RoleGrantedEvent.OutputTuple, RoleGrantedEvent.OutputObject>; getEvent(key: "RoleRevoked"): TypedContractEvent<RoleRevokedEvent.InputTuple, RoleRevokedEvent.OutputTuple, RoleRevokedEvent.OutputObject>; getEvent(key: "SubscriptionCanceled"): TypedContractEvent<SubscriptionCanceledEvent.InputTuple, SubscriptionCanceledEvent.OutputTuple, SubscriptionCanceledEvent.OutputObject>; getEvent(key: "SubscriptionConsumerAdded"): TypedContractEvent<SubscriptionConsumerAddedEvent.InputTuple, SubscriptionConsumerAddedEvent.OutputTuple, SubscriptionConsumerAddedEvent.OutputObject>; getEvent(key: "SubscriptionConsumerRemoved"): TypedContractEvent<SubscriptionConsumerRemovedEvent.InputTuple, SubscriptionConsumerRemovedEvent.OutputTuple, SubscriptionConsumerRemovedEvent.OutputObject>; getEvent(key: "SubscriptionCreated"): TypedContractEvent<SubscriptionCreatedEvent.InputTuple, SubscriptionCreatedEvent.OutputTuple, SubscriptionCreatedEvent.OutputObject>; getEvent(key: "SubscriptionFundedWithNative"): TypedContractEvent<SubscriptionFundedWithNativeEvent.InputTuple, SubscriptionFundedWithNativeEvent.OutputTuple, SubscriptionFundedWithNativeEvent.OutputObject>; getEvent(key: "SubscriptionOwnerTransferRequested"): TypedContractEvent<SubscriptionOwnerTransferRequestedEvent.InputTuple, SubscriptionOwnerTransferRequestedEvent.OutputTuple, SubscriptionOwnerTransferRequestedEvent.OutputObject>; getEvent(key: "SubscriptionOwnerTransferred"): TypedContractEvent<SubscriptionOwnerTransferredEvent.InputTuple, SubscriptionOwnerTransferredEvent.OutputTuple, SubscriptionOwnerTransferredEvent.OutputObject>; getEvent(key: "Upgraded"): TypedContractEvent<UpgradedEvent.InputTuple, UpgradedEvent.OutputTuple, UpgradedEvent.OutputObject>; filters: { "BlocklockCallbackFailed(uint256)": TypedContractEvent<BlocklockCallbackFailedEvent.InputTuple, BlocklockCallbackFailedEvent.OutputTuple, BlocklockCallbackFailedEvent.OutputObject>; BlocklockCallbackFailed: TypedContractEvent<BlocklockCallbackFailedEvent.InputTuple, BlocklockCallbackFailedEvent.OutputTuple, BlocklockCallbackFailedEvent.OutputObject>; "BlocklockCallbackSuccess(uint256,bytes,tuple,bytes)": TypedContractEvent<BlocklockCallbackSuccessEvent.InputTuple, BlocklockCallbackSuccessEvent.OutputTuple, BlocklockCallbackSuccessEvent.OutputObject>; BlocklockCallbackSuccess: TypedContractEvent<BlocklockCallbackSuccessEvent.InputTuple, BlocklockCallbackSuccessEvent.OutputTuple, BlocklockCallbackSuccessEvent.OutputObject>; "BlocklockRequested(uint256,bytes,tuple,address,uint256)": TypedContractEvent<BlocklockRequestedEvent.InputTuple, BlocklockRequestedEvent.Ou