"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.WormholeRelayer__factory = void 0;
/* Autogenerated file. Do not edit manually. */
/* tslint:disable */
/* eslint-disable */
const ethers_1 = require("ethers");
const _abi = [
    {
        inputs: [
            {
                internalType: "address",
                name: "wormhole",
                type: "address",
            },
        ],
        stateMutability: "nonpayable",
        type: "constructor",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "chainId",
                type: "uint16",
            },
            {
                internalType: "bytes32",
                name: "registeredWormholeRelayerContract",
                type: "bytes32",
            },
        ],
        name: "ChainAlreadyRegistered",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "bytes",
                name: "failure",
                type: "bytes",
            },
        ],
        name: "ContractUpgradeFailed",
        type: "error",
    },
    {
        inputs: [],
        name: "DeliveryProviderCannotReceivePayment",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "uint8",
                name: "keyType",
                type: "uint8",
            },
        ],
        name: "DeliveryProviderDoesNotSupportMessageKeyType",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "address",
                name: "relayer",
                type: "address",
            },
            {
                internalType: "uint16",
                name: "chainId",
                type: "uint16",
            },
        ],
        name: "DeliveryProviderDoesNotSupportTargetChain",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "bytes32",
                name: "hash",
                type: "bytes32",
            },
        ],
        name: "GovernanceActionAlreadyConsumed",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "LocalNative",
                name: "msgValue",
                type: "uint256",
            },
            {
                internalType: "LocalNative",
                name: "minimum",
                type: "uint256",
            },
        ],
        name: "InsufficientRelayerFunds",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "bytes32",
                name: "defaultDeliveryProvider",
                type: "bytes32",
            },
        ],
        name: "InvalidDefaultDeliveryProvider",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "string",
                name: "reason",
                type: "string",
            },
        ],
        name: "InvalidDeliveryVaa",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "bytes32",
                name: "emitter",
                type: "bytes32",
            },
            {
                internalType: "bytes32",
                name: "registered",
                type: "bytes32",
            },
            {
                internalType: "uint16",
                name: "chainId",
                type: "uint16",
            },
        ],
        name: "InvalidEmitter",
        type: "error",
    },
    {
        inputs: [],
        name: "InvalidFork",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "parsed",
                type: "uint16",
            },
            {
                internalType: "uint16",
                name: "expected",
                type: "uint16",
            },
        ],
        name: "InvalidGovernanceChainId",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "bytes32",
                name: "parsed",
                type: "bytes32",
            },
            {
                internalType: "bytes32",
                name: "expected",
                type: "bytes32",
            },
        ],
        name: "InvalidGovernanceContract",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "string",
                name: "reason",
                type: "string",
            },
        ],
        name: "InvalidGovernanceVM",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "LocalNative",
                name: "msgValue",
                type: "uint256",
            },
            {
                internalType: "LocalNative",
                name: "totalFee",
                type: "uint256",
            },
        ],
        name: "InvalidMsgValue",
        type: "error",
    },
    {
        inputs: [],
        name: "InvalidOverrideGasLimit",
        type: "error",
    },
    {
        inputs: [],
        name: "InvalidOverrideReceiverValue",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "uint8",
                name: "parsed",
                type: "uint8",
            },
            {
                internalType: "uint8",
                name: "expected",
                type: "uint8",
            },
        ],
        name: "InvalidPayloadAction",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "parsed",
                type: "uint16",
            },
            {
                internalType: "uint16",
                name: "expected",
                type: "uint16",
            },
        ],
        name: "InvalidPayloadChainId",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "uint8",
                name: "parsed",
                type: "uint8",
            },
            {
                internalType: "uint8",
                name: "expected",
                type: "uint8",
            },
        ],
        name: "InvalidPayloadId",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "received",
                type: "uint256",
            },
            {
                internalType: "uint256",
                name: "expected",
                type: "uint256",
            },
        ],
        name: "InvalidPayloadLength",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "bytes32",
                name: "parsed",
                type: "bytes32",
            },
            {
                internalType: "bytes32",
                name: "expected",
                type: "bytes32",
            },
        ],
        name: "InvalidPayloadModule",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "keys",
                type: "uint256",
            },
            {
                internalType: "uint256",
                name: "vaas",
                type: "uint256",
            },
        ],
        name: "MessageKeysLengthDoesNotMatchMessagesLength",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "bytes32",
                name: "",
                type: "bytes32",
            },
        ],
        name: "NotAnEvmAddress",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "address",
                name: "msgSender",
                type: "address",
            },
            {
                internalType: "address",
                name: "lockedBy",
                type: "address",
            },
        ],
        name: "ReentrantDelivery",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
        ],
        name: "TargetChainIsNotThisChain",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "numMessageKeys",
                type: "uint256",
            },
        ],
        name: "TooManyMessageKeys",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "uint8",
                name: "version",
                type: "uint8",
            },
            {
                internalType: "uint8",
                name: "expectedVersion",
                type: "uint8",
            },
        ],
        name: "UnexpectedExecutionInfoVersion",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "uint8",
                name: "index",
                type: "uint8",
            },
        ],
        name: "VaaKeysDoNotMatchVaas",
        type: "error",
    },
    {
        inputs: [
            {
                internalType: "uint8",
                name: "instructionVersion",
                type: "uint8",
            },
            {
                internalType: "uint8",
                name: "overrideVersion",
                type: "uint8",
            },
        ],
        name: "VersionMismatchOverride",
        type: "error",
    },
    {
        anonymous: false,
        inputs: [
            {
                indexed: false,
                internalType: "address",
                name: "previousAdmin",
                type: "address",
            },
            {
                indexed: false,
                internalType: "address",
                name: "newAdmin",
                type: "address",
            },
        ],
        name: "AdminChanged",
        type: "event",
    },
    {
        anonymous: false,
        inputs: [
            {
                indexed: true,
                internalType: "address",
                name: "beacon",
                type: "address",
            },
        ],
        name: "BeaconUpgraded",
        type: "event",
    },
    {
        anonymous: false,
        inputs: [
            {
                indexed: true,
                internalType: "address",
                name: "oldContract",
                type: "address",
            },
            {
                indexed: true,
                internalType: "address",
                name: "newContract",
                type: "address",
            },
        ],
        name: "ContractUpgraded",
        type: "event",
    },
    {
        anonymous: false,
        inputs: [
            {
                indexed: true,
                internalType: "address",
                name: "recipientContract",
                type: "address",
            },
            {
                indexed: true,
                internalType: "uint16",
                name: "sourceChain",
                type: "uint16",
            },
            {
                indexed: true,
                internalType: "uint64",
                name: "sequence",
                type: "uint64",
            },
            {
                indexed: false,
                internalType: "bytes32",
                name: "deliveryVaaHash",
                type: "bytes32",
            },
            {
                indexed: false,
                internalType: "enum IWormholeRelayerDelivery.DeliveryStatus",
                name: "status",
                type: "uint8",
            },
            {
                indexed: false,
                internalType: "Gas",
                name: "gasUsed",
                type: "uint256",
            },
            {
                indexed: false,
                internalType: "enum IWormholeRelayerDelivery.RefundStatus",
                name: "refundStatus",
                type: "uint8",
            },
            {
                indexed: false,
                internalType: "bytes",
                name: "additionalStatusInfo",
                type: "bytes",
            },
            {
                indexed: false,
                internalType: "bytes",
                name: "overridesInfo",
                type: "bytes",
            },
        ],
        name: "Delivery",
        type: "event",
    },
    {
        anonymous: false,
        inputs: [
            {
                indexed: true,
                internalType: "uint64",
                name: "sequence",
                type: "uint64",
            },
            {
                indexed: false,
                internalType: "LocalNative",
                name: "deliveryQuote",
                type: "uint256",
            },
            {
                indexed: false,
                internalType: "LocalNative",
                name: "paymentForExtraReceiverValue",
                type: "uint256",
            },
        ],
        name: "SendEvent",
        type: "event",
    },
    {
        anonymous: false,
        inputs: [
            {
                indexed: true,
                internalType: "address",
                name: "implementation",
                type: "address",
            },
        ],
        name: "Upgraded",
        type: "event",
    },
    {
        inputs: [],
        name: "checkAndExecuteUpgradeMigration",
        outputs: [],
        stateMutability: "nonpayable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "bytes[]",
                name: "encodedVMs",
                type: "bytes[]",
            },
            {
                internalType: "bytes",
                name: "encodedDeliveryVAA",
                type: "bytes",
            },
            {
                internalType: "address payable",
                name: "relayerRefundAddress",
                type: "address",
            },
            {
                internalType: "bytes",
                name: "deliveryOverrides",
                type: "bytes",
            },
        ],
        name: "deliver",
        outputs: [],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "bytes32",
                name: "deliveryHash",
                type: "bytes32",
            },
        ],
        name: "deliveryAttempted",
        outputs: [
            {
                internalType: "bool",
                name: "attempted",
                type: "bool",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "bytes32",
                name: "deliveryHash",
                type: "bytes32",
            },
        ],
        name: "deliveryFailureBlock",
        outputs: [
            {
                internalType: "uint256",
                name: "blockNumber",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "bytes32",
                name: "deliveryHash",
                type: "bytes32",
            },
        ],
        name: "deliverySuccessBlock",
        outputs: [
            {
                internalType: "uint256",
                name: "blockNumber",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "bytes32",
                name: "targetAddress",
                type: "bytes32",
            },
            {
                internalType: "bytes",
                name: "payload",
                type: "bytes",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "LocalNative",
                name: "",
                type: "uint256",
            },
            {
                internalType: "bytes",
                name: "encodedExecutionParameters",
                type: "bytes",
            },
            {
                internalType: "uint16",
                name: "refundChain",
                type: "uint16",
            },
            {
                internalType: "bytes32",
                name: "refundAddress",
                type: "bytes32",
            },
            {
                internalType: "address",
                name: "deliveryProviderAddress",
                type: "address",
            },
            {
                components: [
                    {
                        internalType: "uint16",
                        name: "chainId",
                        type: "uint16",
                    },
                    {
                        internalType: "bytes32",
                        name: "emitterAddress",
                        type: "bytes32",
                    },
                    {
                        internalType: "uint64",
                        name: "sequence",
                        type: "uint64",
                    },
                ],
                internalType: "struct VaaKey[]",
                name: "vaaKeys",
                type: "tuple[]",
            },
            {
                internalType: "uint8",
                name: "consistencyLevel",
                type: "uint8",
            },
        ],
        name: "forward",
        outputs: [],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "address",
                name: "targetAddress",
                type: "address",
            },
            {
                internalType: "bytes",
                name: "payload",
                type: "bytes",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "Gas",
                name: "gasLimit",
                type: "uint256",
            },
        ],
        name: "forwardPayloadToEvm",
        outputs: [],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "address",
                name: "targetAddress",
                type: "address",
            },
            {
                internalType: "bytes",
                name: "payload",
                type: "bytes",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "LocalNative",
                name: "paymentForExtraReceiverValue",
                type: "uint256",
            },
            {
                internalType: "Gas",
                name: "gasLimit",
                type: "uint256",
            },
            {
                internalType: "uint16",
                name: "refundChain",
                type: "uint16",
            },
            {
                internalType: "address",
                name: "refundAddress",
                type: "address",
            },
            {
                internalType: "address",
                name: "deliveryProviderAddress",
                type: "address",
            },
            {
                components: [
                    {
                        internalType: "uint16",
                        name: "chainId",
                        type: "uint16",
                    },
                    {
                        internalType: "bytes32",
                        name: "emitterAddress",
                        type: "bytes32",
                    },
                    {
                        internalType: "uint64",
                        name: "sequence",
                        type: "uint64",
                    },
                ],
                internalType: "struct VaaKey[]",
                name: "vaaKeys",
                type: "tuple[]",
            },
            {
                internalType: "uint8",
                name: "consistencyLevel",
                type: "uint8",
            },
        ],
        name: "forwardToEvm",
        outputs: [],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "address",
                name: "targetAddress",
                type: "address",
            },
            {
                internalType: "bytes",
                name: "payload",
                type: "bytes",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "Gas",
                name: "gasLimit",
                type: "uint256",
            },
            {
                components: [
                    {
                        internalType: "uint16",
                        name: "chainId",
                        type: "uint16",
                    },
                    {
                        internalType: "bytes32",
                        name: "emitterAddress",
                        type: "bytes32",
                    },
                    {
                        internalType: "uint64",
                        name: "sequence",
                        type: "uint64",
                    },
                ],
                internalType: "struct VaaKey[]",
                name: "vaaKeys",
                type: "tuple[]",
            },
        ],
        name: "forwardVaasToEvm",
        outputs: [],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [],
        name: "getDefaultDeliveryProvider",
        outputs: [
            {
                internalType: "address",
                name: "deliveryProvider",
                type: "address",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "chainId",
                type: "uint16",
            },
        ],
        name: "getRegisteredWormholeRelayerContract",
        outputs: [
            {
                internalType: "bytes32",
                name: "",
                type: "bytes32",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "address",
                name: "defaultDeliveryProvider",
                type: "address",
            },
        ],
        name: "initialize",
        outputs: [],
        stateMutability: "nonpayable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "bytes",
                name: "encodedExecutionParameters",
                type: "bytes",
            },
            {
                internalType: "address",
                name: "deliveryProviderAddress",
                type: "address",
            },
        ],
        name: "quoteDeliveryPrice",
        outputs: [
            {
                internalType: "LocalNative",
                name: "nativePriceQuote",
                type: "uint256",
            },
            {
                internalType: "bytes",
                name: "encodedExecutionInfo",
                type: "bytes",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "Gas",
                name: "gasLimit",
                type: "uint256",
            },
            {
                internalType: "address",
                name: "deliveryProviderAddress",
                type: "address",
            },
        ],
        name: "quoteEVMDeliveryPrice",
        outputs: [
            {
                internalType: "LocalNative",
                name: "nativePriceQuote",
                type: "uint256",
            },
            {
                internalType: "GasPrice",
                name: "targetChainRefundPerGasUnused",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "Gas",
                name: "gasLimit",
                type: "uint256",
            },
        ],
        name: "quoteEVMDeliveryPrice",
        outputs: [
            {
                internalType: "LocalNative",
                name: "nativePriceQuote",
                type: "uint256",
            },
            {
                internalType: "GasPrice",
                name: "targetChainRefundPerGasUnused",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "LocalNative",
                name: "currentChainAmount",
                type: "uint256",
            },
            {
                internalType: "address",
                name: "deliveryProviderAddress",
                type: "address",
            },
        ],
        name: "quoteNativeForChain",
        outputs: [
            {
                internalType: "TargetNative",
                name: "targetChainAmount",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "bytes",
                name: "encodedVm",
                type: "bytes",
            },
        ],
        name: "registerWormholeRelayerContract",
        outputs: [],
        stateMutability: "nonpayable",
        type: "function",
    },
    {
        inputs: [
            {
                components: [
                    {
                        internalType: "uint16",
                        name: "chainId",
                        type: "uint16",
                    },
                    {
                        internalType: "bytes32",
                        name: "emitterAddress",
                        type: "bytes32",
                    },
                    {
                        internalType: "uint64",
                        name: "sequence",
                        type: "uint64",
                    },
                ],
                internalType: "struct VaaKey",
                name: "deliveryVaaKey",
                type: "tuple",
            },
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "TargetNative",
                name: "newReceiverValue",
                type: "uint256",
            },
            {
                internalType: "bytes",
                name: "newEncodedExecutionParameters",
                type: "bytes",
            },
            {
                internalType: "address",
                name: "newDeliveryProviderAddress",
                type: "address",
            },
        ],
        name: "resend",
        outputs: [
            {
                internalType: "uint64",
                name: "sequence",
                type: "uint64",
            },
        ],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [
            {
                components: [
                    {
                        internalType: "uint16",
                        name: "chainId",
                        type: "uint16",
                    },
                    {
                        internalType: "bytes32",
                        name: "emitterAddress",
                        type: "bytes32",
                    },
                    {
                        internalType: "uint64",
                        name: "sequence",
                        type: "uint64",
                    },
                ],
                internalType: "struct VaaKey",
                name: "deliveryVaaKey",
                type: "tuple",
            },
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "TargetNative",
                name: "newReceiverValue",
                type: "uint256",
            },
            {
                internalType: "Gas",
                name: "newGasLimit",
                type: "uint256",
            },
            {
                internalType: "address",
                name: "newDeliveryProviderAddress",
                type: "address",
            },
        ],
        name: "resendToEvm",
        outputs: [
            {
                internalType: "uint64",
                name: "sequence",
                type: "uint64",
            },
        ],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "bytes32",
                name: "targetAddress",
                type: "bytes32",
            },
            {
                internalType: "bytes",
                name: "payload",
                type: "bytes",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "LocalNative",
                name: "paymentForExtraReceiverValue",
                type: "uint256",
            },
            {
                internalType: "bytes",
                name: "encodedExecutionParameters",
                type: "bytes",
            },
            {
                internalType: "uint16",
                name: "refundChain",
                type: "uint16",
            },
            {
                internalType: "bytes32",
                name: "refundAddress",
                type: "bytes32",
            },
            {
                internalType: "address",
                name: "deliveryProviderAddress",
                type: "address",
            },
            {
                components: [
                    {
                        internalType: "uint16",
                        name: "chainId",
                        type: "uint16",
                    },
                    {
                        internalType: "bytes32",
                        name: "emitterAddress",
                        type: "bytes32",
                    },
                    {
                        internalType: "uint64",
                        name: "sequence",
                        type: "uint64",
                    },
                ],
                internalType: "struct VaaKey[]",
                name: "vaaKeys",
                type: "tuple[]",
            },
            {
                internalType: "uint8",
                name: "consistencyLevel",
                type: "uint8",
            },
        ],
        name: "send",
        outputs: [
            {
                internalType: "uint64",
                name: "sequence",
                type: "uint64",
            },
        ],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "bytes32",
                name: "targetAddress",
                type: "bytes32",
            },
            {
                internalType: "bytes",
                name: "payload",
                type: "bytes",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "LocalNative",
                name: "paymentForExtraReceiverValue",
                type: "uint256",
            },
            {
                internalType: "bytes",
                name: "encodedExecutionParameters",
                type: "bytes",
            },
            {
                internalType: "uint16",
                name: "refundChain",
                type: "uint16",
            },
            {
                internalType: "bytes32",
                name: "refundAddress",
                type: "bytes32",
            },
            {
                internalType: "address",
                name: "deliveryProviderAddress",
                type: "address",
            },
            {
                components: [
                    {
                        internalType: "uint8",
                        name: "keyType",
                        type: "uint8",
                    },
                    {
                        internalType: "bytes",
                        name: "encodedKey",
                        type: "bytes",
                    },
                ],
                internalType: "struct MessageKey[]",
                name: "messageKeys",
                type: "tuple[]",
            },
            {
                internalType: "uint8",
                name: "consistencyLevel",
                type: "uint8",
            },
        ],
        name: "send",
        outputs: [
            {
                internalType: "uint64",
                name: "sequence",
                type: "uint64",
            },
        ],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "address",
                name: "targetAddress",
                type: "address",
            },
            {
                internalType: "bytes",
                name: "payload",
                type: "bytes",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "Gas",
                name: "gasLimit",
                type: "uint256",
            },
            {
                internalType: "uint16",
                name: "refundChain",
                type: "uint16",
            },
            {
                internalType: "address",
                name: "refundAddress",
                type: "address",
            },
        ],
        name: "sendPayloadToEvm",
        outputs: [
            {
                internalType: "uint64",
                name: "sequence",
                type: "uint64",
            },
        ],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "address",
                name: "targetAddress",
                type: "address",
            },
            {
                internalType: "bytes",
                name: "payload",
                type: "bytes",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "Gas",
                name: "gasLimit",
                type: "uint256",
            },
        ],
        name: "sendPayloadToEvm",
        outputs: [
            {
                internalType: "uint64",
                name: "sequence",
                type: "uint64",
            },
        ],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "address",
                name: "targetAddress",
                type: "address",
            },
            {
                internalType: "bytes",
                name: "payload",
                type: "bytes",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "LocalNative",
                name: "paymentForExtraReceiverValue",
                type: "uint256",
            },
            {
                internalType: "Gas",
                name: "gasLimit",
                type: "uint256",
            },
            {
                internalType: "uint16",
                name: "refundChain",
                type: "uint16",
            },
            {
                internalType: "address",
                name: "refundAddress",
                type: "address",
            },
            {
                internalType: "address",
                name: "deliveryProviderAddress",
                type: "address",
            },
            {
                components: [
                    {
                        internalType: "uint16",
                        name: "chainId",
                        type: "uint16",
                    },
                    {
                        internalType: "bytes32",
                        name: "emitterAddress",
                        type: "bytes32",
                    },
                    {
                        internalType: "uint64",
                        name: "sequence",
                        type: "uint64",
                    },
                ],
                internalType: "struct VaaKey[]",
                name: "vaaKeys",
                type: "tuple[]",
            },
            {
                internalType: "uint8",
                name: "consistencyLevel",
                type: "uint8",
            },
        ],
        name: "sendToEvm",
        outputs: [
            {
                internalType: "uint64",
                name: "sequence",
                type: "uint64",
            },
        ],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "address",
                name: "targetAddress",
                type: "address",
            },
            {
                internalType: "bytes",
                name: "payload",
                type: "bytes",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "LocalNative",
                name: "paymentForExtraReceiverValue",
                type: "uint256",
            },
            {
                internalType: "Gas",
                name: "gasLimit",
                type: "uint256",
            },
            {
                internalType: "uint16",
                name: "refundChain",
                type: "uint16",
            },
            {
                internalType: "address",
                name: "refundAddress",
                type: "address",
            },
            {
                internalType: "address",
                name: "deliveryProviderAddress",
                type: "address",
            },
            {
                components: [
                    {
                        internalType: "uint8",
                        name: "keyType",
                        type: "uint8",
                    },
                    {
                        internalType: "bytes",
                        name: "encodedKey",
                        type: "bytes",
                    },
                ],
                internalType: "struct MessageKey[]",
                name: "messageKeys",
                type: "tuple[]",
            },
            {
                internalType: "uint8",
                name: "consistencyLevel",
                type: "uint8",
            },
        ],
        name: "sendToEvm",
        outputs: [
            {
                internalType: "uint64",
                name: "sequence",
                type: "uint64",
            },
        ],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "address",
                name: "targetAddress",
                type: "address",
            },
            {
                internalType: "bytes",
                name: "payload",
                type: "bytes",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "Gas",
                name: "gasLimit",
                type: "uint256",
            },
            {
                components: [
                    {
                        internalType: "uint16",
                        name: "chainId",
                        type: "uint16",
                    },
                    {
                        internalType: "bytes32",
                        name: "emitterAddress",
                        type: "bytes32",
                    },
                    {
                        internalType: "uint64",
                        name: "sequence",
                        type: "uint64",
                    },
                ],
                internalType: "struct VaaKey[]",
                name: "vaaKeys",
                type: "tuple[]",
            },
        ],
        name: "sendVaasToEvm",
        outputs: [
            {
                internalType: "uint64",
                name: "sequence",
                type: "uint64",
            },
        ],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint16",
                name: "targetChain",
                type: "uint16",
            },
            {
                internalType: "address",
                name: "targetAddress",
                type: "address",
            },
            {
                internalType: "bytes",
                name: "payload",
                type: "bytes",
            },
            {
                internalType: "TargetNative",
                name: "receiverValue",
                type: "uint256",
            },
            {
                internalType: "Gas",
                name: "gasLimit",
                type: "uint256",
            },
            {
                components: [
                    {
                        internalType: "uint16",
                        name: "chainId",
                        type: "uint16",
                    },
                    {
                        internalType: "bytes32",
                        name: "emitterAddress",
                        type: "bytes32",
                    },
                    {
                        internalType: "uint64",
                        name: "sequence",
                        type: "uint64",
                    },
                ],
                internalType: "struct VaaKey[]",
                name: "vaaKeys",
                type: "tuple[]",
            },
            {
                internalType: "uint16",
                name: "refundChain",
                type: "uint16",
            },
            {
                internalType: "address",
                name: "refundAddress",
                type: "address",
            },
        ],
        name: "sendVaasToEvm",
        outputs: [
            {
                internalType: "uint64",
                name: "sequence",
                type: "uint64",
            },
        ],
        stateMutability: "payable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "bytes",
                name: "encodedVm",
                type: "bytes",
            },
        ],
        name: "setDefaultDeliveryProvider",
        outputs: [],
        stateMutability: "nonpayable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "bytes",
                name: "encodedVm",
                type: "bytes",
            },
        ],
        name: "submitContractUpgrade",
        outputs: [],
        stateMutability: "nonpayable",
        type: "function",
    },
];
const _bytecode = " ";
const isSuperArgs = (xs) => xs.length > 1;
class WormholeRelayer__factory extends ethers_1.ContractFactory {
    constructor(...args) {
        if (isSuperArgs(args)) {
            super(...args);
        }
        else {
            super(_abi, _bytecode, args[0]);
        }
    }
    deploy(wormhole, overrides) {
        return super.deploy(wormhole, overrides || {});
    }
    getDeployTransaction(wormhole, overrides) {
        return super.getDeployTransaction(wormhole, overrides || {});
    }
    attach(address) {
        return super.attach(address);
    }
    connect(signer) {
        return super.connect(signer);
    }
    static createInterface() {
        return new ethers_1.utils.Interface(_abi);
    }
    static connect(address, signerOrProvider) {
        return new ethers_1.Contract(address, _abi, signerOrProvider);
    }
}
exports.WormholeRelayer__factory = WormholeRelayer__factory;
WormholeRelayer__factory.bytecode = _bytecode;
WormholeRelayer__factory.abi = _abi;
