import { L3Order, Order } from '../order/types';
import { BigNumber, ethers } from 'ethers';
import { TxParams, TxReceipt } from '../rpc/types';
import { NetworkIdT3rn } from '../pricer/types';
import { OrderLifecycle } from '../config/validation';
import { Confirmation } from '../distributor/segmentBook';
type SuccessOrderLifecycle = {
    [K in OrderLifecycle]: `${K}Success`;
};
type FailureOrderLifecycle = {
    [K in OrderLifecycle]: `${K}Fail`;
};
export declare const OrderLifecycleEventSuccess: SuccessOrderLifecycle;
export declare const OrderLifecycleEventFailure: FailureOrderLifecycle;
type SuccessBatchOrderLifecycle = {
    [K in OrderLifecycle]: `${K}BatchSuccess`;
};
type FailureBatchOrderLifecycle = {
    [K in OrderLifecycle]: `${K}BatchFail`;
};
export declare const BatchOrderLifecycleEventSuccess: SuccessBatchOrderLifecycle;
export declare const BatchOrderLifecycleEventFailure: FailureBatchOrderLifecycle;
export type QueueTxArgs = TxArgsAttest | TxArgsAVPAttest | TxArgsAVPClaim | TxArgsAVPBackdoor | TxArgsClaim | TxArgsClaimV2 | TxArgsBid | TxArgsExecute | TxArgsOrdersL3 | TxArgsAttestBatch | TxArgsSingleAttestL3 | TxArgsAttestBatchL3 | TxArgsClaimInsurance | TxArgsOrderL3 | TxArgsAttestL3 | TxArgsAttestBatchPayloadL3 | TxArgsConfirmOrderAttestationL3 | TxArgsConfirmOrderExecutionL3 | TxArgsConfirmClaimedL3 | TxArgsConfirmClaimedRefundL3 | TxArgsLateOrderDLQL3 | TxArgsAVPRefundBatches | TxArgsAnchorEscrowGMPPayloadUnmatchedToL3 | TxArgsOrderId | TxArgsBatchAttestL3 | TxArgsBatchPopulateL3 | TxArgsTryConstructBatchL3 | TxArgsAVPClaimBatches | TxArgsClaimInsuranceBatches | TxArgsSegmentSubmit | TxArgsSegmentBookMark | TxArgsSegmentBookFinalizeBatch | TxArgsRemoteOrder | TxArgsClaimRefundV2OfBatch | TxArgsClaimRefundV2OfBatchEmergency;
export interface QueueItem {
    order: Order;
    lifecycle: OrderLifecycle;
    txArgs: QueueTxArgs;
    networkId: NetworkIdT3rn;
    retries: number;
    nonceAssigned?: number;
    backoffSec: number;
    txReceipt: {
        txHash?: string;
        lastTryDone?: boolean;
        startTimestamp?: number;
        prevAttemptTimestamp?: number;
    };
    isBatch: boolean;
    gasData?: {
        txReceipt: TxReceipt;
        txParams: TxParams;
    };
    error?: string;
    count?: number;
}
export interface BatchQueueItem extends Omit<QueueItem, 'order' | 'txArgs'> {
    orders: Order[];
    sourceNetwork: NetworkIdT3rn;
    txArgs: (TxArgsAttest | TxArgsClaim | TxArgsBid | TxArgsExecute | TxArgsOrdersL3 | TxArgsAttestBatch | TxArgsSingleAttestL3 | TxArgsAttestBatchL3 | TxArgsAVPBackdoor | TxArgsAVPClaim | TxArgsAVPAttest | TxArgsClaimInsurance | TxArgsBatchAttestL3 | TxArgsOrderIds | TxArgsAVPRefundBatches | TxArgsClaimInsuranceBatches | TxArgsBidBatch | TxArgsFormRevertBatchL3 | TxArgsAVPClaimBatches | TxArgsSegmentSubmit | TxArgsSegmentBookMark | TxArgsSegmentBookFinalizeBatch | TxArgsRemoteOrder | TxArgsClaimRefundV2OfBatch | TxArgsClaimRefundV2OfBatchEmergency)[];
    creationTimestamp: number;
    count?: number;
}
export interface AttestationBatch {
    isHalted: boolean;
    currentCommitteeHash: string;
    nextCommitteeHash: string;
    maybeNextCommittee: string[];
    bannedCommittee: string[];
    encodedGMPPayload: string;
    index: BigNumber;
    encodedBatchPayload: string;
    deliveredL3?: boolean;
    networkId?: NetworkIdT3rn;
}
export interface L3BatchAttestation {
    attestationBatchMessageHash: string;
    attester: string;
    signature: string;
}
export interface TxArgsAttest {
    attestationMessagePayload: string;
    source4Bytes: string;
    sourceHeight: number;
    attestations: string[];
    attestationProof: string[];
    attestationProofFlags: boolean[];
}
export interface TxArgsAVPAttest {
    batchPayload: string[];
    messageGMPPayload: string[];
    signatures: string[][];
    attestationProof: string[][];
    attestationProofFlags: boolean[][];
}
export interface TxArgsAVPRefundBatches {
    orderNonce: number[][];
    rewardAsset: string[][];
    maxReward: BigNumber[][];
    orderTimestamp: BigNumber[][];
    beneficiary: string[];
}
export interface TxArgsAVPBackdoor {
    batchHashes: string[];
    batchIndices: number[];
    batcherVersions: number[];
}
export interface TxArgsAVPBackdoorSQS {
    networkId: NetworkIdT3rn;
    batchPayloadHash: string;
    batchPayload?: string;
    batchIndex: number;
    bookVersion: string;
}
export interface TxArgsProduceSegmentsSQS {
    bookVersion: string;
    forAccount: string;
}
export interface TxArgsBatchAttestL3 {
    orderIds: string[];
    beneficiaries: string[];
    signatures: string[];
    messagePayloads: string[];
    sourceNetworks: string[];
}
export interface TxArgsFormRevertBatchL3 {
    size: number;
    network: string;
}
export interface TxArgsOrderIds {
    orderIds: string[];
}
export interface TxArgsOrderId {
    orderId: string;
}
export interface TxArgsBatchPopulateL3 {
    orderIds: string[];
    executors: string[];
    orders: L3Order[];
    txHashes: string[];
}
export interface TxArgsOrderL3 {
    order: L3Order;
    sender: string;
    orderId: string;
    orderTxHash: string;
}
export interface TxArgsOrdersL3 {
    orders: L3Order[];
    orderIds: string[];
    orderTxHashes: string[];
    timestamps: BigNumber[];
}
export interface TxArgsAttestL3 {
    orderId: string;
    beneficiary: string;
    signature: string;
    sourceNetwork: string;
}
export interface TxArgsSingleAttestL3 {
    orderId: string;
    beneficiary: string;
    signature: string;
    messagePayload: string;
    sourceNetwork: string;
}
export interface TxArgsAttestBatchPayloadL3 {
    batchPayload: string;
    signature: string;
    sourceNetwork: string;
}
export interface TxArgsClaimRefundV2OfBatch {
    beneficiaries: string[];
    orderNonce: number[];
    rewardAsset: string[];
    maxReward: BigNumber[];
    batchPayloadHash: string;
    batchPayload: string;
}
export interface TxArgsClaimRefundV2OfBatchEmergency {
    beneficiaries: string[];
    orderIds: string[];
    orderNonce: number[];
    rewardAsset: string[];
    maxReward: BigNumber[];
}
export interface TxArgsRemoteOrder {
    destination: string;
    asset: number;
    targetAccount: string;
    amountWei: BigNumber;
    rewardAsset: string;
    insurance: string;
    maxRewardWei: BigNumber;
}
export interface TxArgsTryConstructBatchL3 {
    network: string;
}
export interface TxArgsConfirmOrderAttestationL3 {
    networkId: string;
    orderId: string;
    attestationBatchHash: string;
}
export interface TxArgsConfirmOrderExecutionL3 {
    networkId: string;
    orderId: string;
    target: string;
    amount: BigNumber;
    asset: number;
    sender: string;
    txHash: string;
}
export interface TxArgsConfirmClaimedL3 {
    networkId: string;
    orderId: string;
    amount: BigNumber;
    assetAddress: string;
    sender: string;
}
export interface TxArgsAnchorEscrowGMPPayloadUnmatchedToL3 {
    networkId: string;
    orderId: string;
    escrowPayload: string;
}
export interface TxArgsLateOrderDLQL3 {
    orderId: string;
    networkId: string;
}
export interface TxArgsConfirmClaimedRefundL3 {
    networkId: string;
    orderId: string;
    amount: BigNumber;
    assetAddress: string;
    sender: string;
}
export interface TxArgsAttestBatchL3 {
    orderIdArray: string[];
    beneficiaryArray: string[];
    batchPayload: string;
    signature: string;
    sourceNetwork: string;
}
export interface TxArgsAttestBatch {
    encodedBatchPayload: string;
    messageGMPPayload: string;
    signatures: string[];
    attestationProof: string[];
    attestationProofFlags: boolean[];
}
export interface TxArgsClaim {
    orderId: string;
    rewardAsset: string;
    maxReward: BigNumber;
    settledAmount: BigNumber;
    orderTimestamp: BigNumber;
}
export interface TxArgsAVPClaim {
    orderId: string[];
    rewardAsset: string[];
    maxReward: BigNumber[];
    orderTimestamp: BigNumber[];
    batchPayload: string;
    batchPayloadHash: string;
}
export interface TxArgsClaimV2 {
    orderId: string;
    rewardAsset: string;
    maxReward: BigNumber;
    settledAmount: BigNumber;
    orderTimestamp: BigNumber;
    batchPayload: string;
    batchPayloadHash: string;
}
export interface TxArgsAVPClaimBatches {
    orderId: string[][];
    rewardAsset: string[][];
    maxReward: BigNumber[][];
    orderTimestamp: BigNumber[][];
    batchPayload: string;
    batchHash: string;
}
export interface TxArgsClaimInsuranceBatches {
    orderIds: string[][];
    claimer: string[];
}
export interface TxArgsClaimInsuranceBatch {
    orderIds: string[];
    claimer: string;
}
export interface TxArgsClaimInsurance {
    orderId: string;
    claimer: string;
}
export interface TxArgsSegmentSubmit {
    confirmations: Confirmation[];
    executors: string[];
}
export interface TxArgsSegmentBookMark {
    batchHash: string;
}
export interface TxArgsSegmentBookFinalizeBatch {
    index: number[];
    networks: string[][];
    batchPayloads: string[][];
    orderIds: string[][][];
}
export interface TxArgsBid {
    orderId: string;
    bidAmount: BigNumber;
    bidder: string;
    insurance: BigNumber;
}
export interface TxArgsBidBatch {
    orderId: string[];
    bidAmount: BigNumber[];
    bidder: string;
    insurance: BigNumber;
}
export interface TxArgsExecute {
    orderId: string;
    targetAccount: string;
    amount: BigNumber;
    assetAddress: string;
    nonce: BigNumber;
    sourceAccount: string;
    sourceNetwork: string;
}
export interface FeeData extends ethers.providers.FeeData {
    maxFeePerGas: BigNumber;
    maxPriorityFeePerGas: BigNumber;
    gasPrice: BigNumber;
    lastBaseFeePerGas: BigNumber;
}
export {};
//# sourceMappingURL=types.d.ts.map