"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.evmLikeChains = exports.networkChainToChannels = exports.cosmwasmNetworkChainToRestUrls = exports.nativeDenomToChain = exports.chainToNativeDenoms = exports.addressPrefixToChain = exports.chainToAddressPrefix = exports.IBC_TIMEOUT_MILLIS = exports.IBC_PACKET_CONN = exports.IBC_PACKET_DATA = exports.IBC_PACKET_SEQ = exports.IBC_PACKET_DST_PORT = exports.IBC_PACKET_SRC_PORT = exports.IBC_PACKET_SRC = exports.IBC_PACKET_DST = exports.IBC_PACKET_RECEIVE = exports.IBC_PACKET_SEND = exports.IBC_TRANSFER_PORT = exports.IBC_MSG_TYPE = exports.MSG_EXECUTE_CONTRACT_TYPE_URL = exports.DEFAULT_FEE = void 0;
const connect_sdk_1 = require("@wormhole-foundation/connect-sdk");
exports.DEFAULT_FEE = 1000000;
exports.MSG_EXECUTE_CONTRACT_TYPE_URL = "/cosmwasm.wasm.v1.MsgExecuteContract";
exports.IBC_MSG_TYPE = "/ibc.applications.transfer.v1.MsgTransfer";
exports.IBC_TRANSFER_PORT = "transfer";
// IBC Message Event type
exports.IBC_PACKET_SEND = "send_packet";
exports.IBC_PACKET_RECEIVE = "recv_packet";
// Attributes for IBC Packet Event
exports.IBC_PACKET_DST = "packet_dst_channel";
exports.IBC_PACKET_SRC = "packet_src_channel";
exports.IBC_PACKET_SRC_PORT = "packet_src_port";
exports.IBC_PACKET_DST_PORT = "packet_dst_port";
exports.IBC_PACKET_SEQ = "packet_sequence";
exports.IBC_PACKET_DATA = "packet_data";
exports.IBC_PACKET_CONN = "packet_connection";
exports.IBC_TIMEOUT_MILLIS = 10 * 60 * 1000; // 10 minutes
const cosmwasmAddressPrefix = [
    ["Cosmoshub", "cosmos"],
    ["Evmos", "evmos"],
    ["Injective", "inj"],
    ["Kujira", "kuji"],
    ["Osmosis", "osmo"],
    ["Sei", "sei"],
    ["Terra", "terra"],
    ["Terra2", "terra"],
    ["Wormchain", "wormhole"],
    ["Xpla", "xpla"],
];
exports.chainToAddressPrefix = (0, connect_sdk_1.constMap)(cosmwasmAddressPrefix);
exports.addressPrefixToChain = (0, connect_sdk_1.constMap)(cosmwasmAddressPrefix, [1, [0]]);
const cosmwasmNativeDenom = [
    [
        "Mainnet",
        [
            ["Cosmoshub", "uatom"],
            ["Evmos", "aevmos"],
            ["Injective", "inj"],
            ["Kujira", "kuji"],
            ["Osmosis", "uosmo"],
            ["Sei", "usei"],
            ["Terra", "luna"],
            ["Terra2", "uluna"],
            ["Wormchain", "uworm"],
            ["Xpla", "uxpla"],
        ],
    ],
    [
        "Testnet",
        [
            ["Cosmoshub", "uatom"],
            ["Evmos", "atevmos"],
            ["Injective", "inj"],
            ["Kujira", "kuji"],
            ["Osmosis", "uosmo"],
            ["Sei", "usei"],
            ["Terra", "luna"],
            ["Terra2", "uluna"],
            ["Wormchain", "uworm"],
            ["Xpla", "uxpla"],
        ],
    ],
    [
        "Devnet",
        [
            ["Cosmoshub", "uatom"],
            ["Evmos", "atevmos"],
            ["Injective", "inj"],
            ["Kujira", "kuji"],
            ["Osmosis", "uosmo"],
            ["Sei", "usei"],
            ["Terra", "luna"],
            ["Terra2", "uluna"],
            ["Wormchain", "uworm"],
            ["Xpla", "uxpla"],
        ],
    ],
];
exports.chainToNativeDenoms = (0, connect_sdk_1.constMap)(cosmwasmNativeDenom);
exports.nativeDenomToChain = (0, connect_sdk_1.constMap)(cosmwasmNativeDenom, [[0, 2], [1]]);
const cosmwasmNetworkChainRestUrl = [
    [
        "Mainnet",
        [
            ["Injective", "https://lcd.injective.network"],
            ["Evmos", "https://rest.bd.evmos.org:1317"],
        ],
    ],
    [
        "Testnet",
        [
            ["Injective", "https://k8s.testnet.lcd.injective.network"],
            ["Evmos", "https://rest.bd.evmos.dev:1317"],
        ],
    ],
    [
        "Devnet",
        [
            ["Injective", "https://localhost:1234"],
            ["Evmos", "https://localhost:1233"],
        ],
    ],
];
exports.cosmwasmNetworkChainToRestUrls = (0, connect_sdk_1.constMap)(cosmwasmNetworkChainRestUrl);
// For each chain, add the channel id for each other chain
const gatewayConnections = [
    [
        "Mainnet",
        [
            [
                "Wormchain",
                {
                    Osmosis: "channel-3",
                    Evmos: "channel-5",
                    Kujira: "channel-9",
                },
            ],
            ["Osmosis", { Wormchain: "channel-2186" }],
            ["Evmos", { Wormchain: "channel-94" }],
            ["Kujira", { Wormchain: "channel-113" }],
        ],
    ],
    [
        "Testnet",
        [
            ["Wormchain", { Cosmoshub: "channel-5", Osmosis: "channel-9" }],
            ["Cosmoshub", { Wormchain: "channel-3086" }],
            ["Osmosis", { Wormchain: "channel-3906" }],
        ],
    ],
    [
        "Devnet",
        [
            ["Wormchain", { Cosmoshub: "channel-1", Osmosis: "channel-2" }],
            ["Cosmoshub", { Wormchain: "channel-1" }],
            ["Osmosis", { Wormchain: "channel-1" }],
        ],
    ],
];
exports.networkChainToChannels = (0, connect_sdk_1.constMap)(gatewayConnections);
exports.evmLikeChains = ["Evmos", "Injective"];
//# sourceMappingURL=constants.js.map