@metamask-previews/bridge-controller 64.1.0-preview-8cfea65a → 64.1.0-preview-6bed60a6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"version":3,"file":"selectors.d.mts","sourceRoot":"","sources":["../src/selectors.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,iBAAiB,EACjB,oCAAoC,EACpC,yBAAyB,EAC1B,qCAAqC;AACtC,OAAO,KAAK,EAAE,eAAe,EAAE,qCAAqC;AAWpE,OAAO,KAAK,EACV,qBAAqB,EACrB,YAAY,EACZ,mBAAmB,EACnB,aAAa,EACb,aAAa,EACd,oBAAgB;AACjB,OAAO,EAAiB,SAAS,EAAE,oBAAgB;AA0BnD,OAAO,EAAE,4BAA4B,EAAE,6BAAyB;AAEhE;;GAEG;AACH,KAAK,2BAA2B,GAAG,oCAAoC,GACrE,yBAAyB,GACzB,iBAAiB,GACjB,IAAI,CAAC,qBAAqB,EAAE,oBAAoB,CAAC,CAAC;AACpD;;GAEG;AACH,KAAK,gCAAgC,GAAG;IACtC,kBAAkB,EAAE;QAClB,YAAY,EAAE,OAAO,CAAC;KACvB,CAAC;CACH,CAAC;AACF,MAAM,MAAM,cAAc,GAAG,qBAAqB,GAAG;IACnD,eAAe,EAAE,eAAe,CAAC;CAClC,GAAG,2BAA2B,GAAG;IAC9B,wBAAwB,EAAE,OAAO,CAAC;CACnC,GAAG,gCAAgC,CAAC;AAUvC;;GAEG;AACH,KAAK,wBAAwB,GAAG;IAC9B,SAAS,EAAE,SAAS,CAAC;IACrB,aAAa,EAAE,CAAC,aAAa,GAAG,aAAa,CAAC,GAAG,IAAI,CAAC;CACvD,CAAC;AAKF;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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A4Yb,WAAW,mCAAmC,CAAC,CAAC,CAAC,CAAC,6DAElD,WAAW,mCAAmC,CAAC,CAAC,CAAC,CAAC,6DAElD,WAAW,mCAAmC,CAAC,CAAC,CAAC,CAAC,4EAIlD,WAAW,mCAAmC,CAAC,CAAC,CAAC,CAAC;;;;;;;;CAuBzE,CAAC"}
package/dist/types.cjs CHANGED
@@ -28,7 +28,6 @@ var SortOrder;
28
28
  })(SortOrder || (exports.SortOrder = SortOrder = {}));
29
29
  var StatusTypes;
30
30
  (function (StatusTypes) {
31
- StatusTypes["SUBMITTED"] = "SUBMITTED";
32
31
  StatusTypes["UNKNOWN"] = "UNKNOWN";
33
32
  StatusTypes["FAILED"] = "FAILED";
34
33
  StatusTypes["PENDING"] = "PENDING";
@@ -1 +1 @@
1
- {"version":3,"file":"types.cjs","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":";;;AAkDA;;GAEG;AACH,IAAY,SAYX;AAZD,WAAY,SAAS;IACnB,4DAA4D;IAC5D,8BAAiB,CAAA;IACjB,qBAAqB;IACrB,4BAAe,CAAA;IACf,kCAAkC;IAClC,wBAAW,CAAA;IACX;;;OAGG;IACH,gCAAmB,CAAA;AACrB,CAAC,EAZW,SAAS,yBAAT,SAAS,QAYpB;AAiFD;;GAEG;AACH,IAAY,SAGX;AAHD,WAAY,SAAS;IACnB,wCAA2B,CAAA;IAC3B,wCAA2B,CAAA;AAC7B,CAAC,EAHW,SAAS,yBAAT,SAAS,QAGpB;AAyED,IAAY,WAMX;AAND,WAAY,WAAW;IACrB,sCAAuB,CAAA;IACvB,kCAAmB,CAAA;IACnB,gCAAiB,CAAA;IACjB,kCAAmB,CAAA;IACnB,oCAAqB,CAAA;AACvB,CAAC,EANW,WAAW,2BAAX,WAAW,QAMtB;AAoDD,IAAY,OAeX;AAfD,WAAY,OAAO;IACjB,mCAAO,CAAA;IACP,8CAAa,CAAA;IACb,oCAAQ,CAAA;IACR,6CAAa,CAAA;IACb,2CAAY,CAAA;IACZ,wCAAW,CAAA;IACX,iDAAgB,CAAA;IAChB,mDAAiB,CAAA;IACjB,2CAAa,CAAA;IACb,wDAAyB,CAAA;IACzB,gDAAoB,CAAA;IACpB,6CAAgB,CAAA;IAChB,sCAAU,CAAA;IACV,yCAAW,CAAA;AACb,CAAC,EAfW,OAAO,uBAAP,OAAO,QAelB;AAID,IAAY,aAIX;AAJD,WAAY,aAAa;IACvB,uDAAO,CAAA;IACP,uDAAO,CAAA;IACP,mDAAK,CAAA;AACP,CAAC,EAJW,aAAa,6BAAb,aAAa,QAIxB;AACD,IAAY,gBAGX;AAHD,WAAY,gBAAgB;IAC1B,6DAAyC,CAAA;IACzC,0EAAsD,CAAA;AACxD,CAAC,EAHW,gBAAgB,gCAAhB,gBAAgB,QAG3B;AACD,IAAY,sBAMX;AAND,WAAY,sBAAsB;IAChC,8EAAoD,CAAA;IACpD,oDAA0B,CAAA;IAC1B,iFAAuD,CAAA;IACvD,0EAAgD,CAAA;IAChD,sDAA4B,CAAA;AAC9B,CAAC,EANW,sBAAsB,sCAAtB,sBAAsB,QAMjC","sourcesContent":["import type { AccountsControllerGetAccountByAddressAction } from '@metamask/accounts-controller';\nimport type {\n GetCurrencyRateState,\n MultichainAssetsRatesControllerGetStateAction,\n TokenRatesControllerGetStateAction,\n} from '@metamask/assets-controllers';\nimport type {\n ControllerGetStateAction,\n ControllerStateChangeEvent,\n} from '@metamask/base-controller';\nimport type { Messenger } from '@metamask/messenger';\nimport type {\n NetworkControllerFindNetworkClientIdByChainIdAction,\n NetworkControllerGetNetworkClientByIdAction,\n} from '@metamask/network-controller';\nimport type { RemoteFeatureFlagControllerGetStateAction } from '@metamask/remote-feature-flag-controller';\nimport type { HandleSnapRequest } from '@metamask/snaps-controllers';\nimport type { Infer } from '@metamask/superstruct';\nimport type {\n CaipAccountId,\n CaipAssetId,\n CaipAssetType,\n CaipChainId,\n Hex,\n} from '@metamask/utils';\n\nimport type { BridgeController } from './bridge-controller';\nimport type { BRIDGE_CONTROLLER_NAME } from './constants/bridge';\nimport type {\n BitcoinTradeDataSchema,\n BridgeAssetSchema,\n ChainConfigurationSchema,\n FeatureId,\n FeeDataSchema,\n IntentSchema,\n PlatformConfigSchema,\n ProtocolSchema,\n QuoteResponseSchema,\n QuoteSchema,\n StepSchema,\n TronTradeDataSchema,\n TxDataSchema,\n} from './utils/validators';\n\nexport type FetchFunction = (\n input: RequestInfo | URL | string,\n init?: RequestInit,\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n) => Promise<any>;\n\n/**\n * The types of assets that a user can send\n */\nexport enum AssetType {\n /** The native asset for the current network, such as ETH */\n native = 'NATIVE',\n /** An ERC20 token */\n token = 'TOKEN',\n /** An ERC721 or ERC1155 token. */\n NFT = 'NFT',\n /**\n * A transaction interacting with a contract that isn't a token method\n * interaction will be marked as dealing with an unknown asset type.\n */\n unknown = 'UNKNOWN',\n}\n\nexport type ChainConfiguration = Infer<typeof ChainConfigurationSchema>;\n\nexport type L1GasFees = {\n l1GasFeesInHexWei?: string; // l1 fees for approval and trade in hex wei, appended by BridgeController.#appendL1GasFees\n};\n\nexport type NonEvmFees = {\n nonEvmFeesInNative?: string; // Non-EVM chain fees in native units (SOL for Solana, BTC for Bitcoin)\n};\n\n/**\n * The types of values for the token amount and its values when converted to the user's selected currency and USD\n */\nexport type TokenAmountValues = {\n /**\n * The amount of the token\n *\n * @example \"1000000000000000000\"\n */\n amount: string;\n /**\n * The amount of the token in the user's selected currency\n *\n * @example \"4.55\"\n */\n valueInCurrency: string | null;\n /**\n * The amount of the token in USD\n *\n * @example \"1.234\"\n */\n usd: string | null;\n};\n\n/**\n * Asset exchange rate values for a given chain and address\n */\nexport type ExchangeRate = { exchangeRate?: string; usdExchangeRate?: string };\n\n/**\n * Values derived from the quote response\n */\nexport type QuoteMetadata = {\n /**\n * If gas is included, this is the value of the src or dest token that was used to pay for the gas\n */\n includedTxFees?: TokenAmountValues | null;\n /**\n * The gas fee for the bridge transaction.\n * effective is the gas fee that is shown to the user. If this value is not\n * included in the trade, the calculation falls back to the gasLimit (total)\n * total is the gas fee that is spent by the user, including refunds.\n * max is the max gas fee that will be used by the transaction.\n */\n gasFee: Record<'effective' | 'total' | 'max', TokenAmountValues>;\n totalNetworkFee: TokenAmountValues; // estimatedGasFees + relayerFees\n totalMaxNetworkFee: TokenAmountValues; // maxGasFees + relayerFees\n /**\n * The amount that the user will receive (destTokenAmount)\n */\n toTokenAmount: TokenAmountValues;\n /**\n * The minimum amount that the user will receive (minDestTokenAmount)\n */\n minToTokenAmount: TokenAmountValues;\n /**\n * If gas is included: toTokenAmount\n * Otherwise: toTokenAmount - totalNetworkFee\n */\n adjustedReturn: Omit<TokenAmountValues, 'amount'>;\n /**\n * The amount that the user will send, including fees\n * srcTokenAmount + metabridgeFee + txFee\n */\n sentAmount: TokenAmountValues;\n swapRate: string; // destTokenAmount / sentAmount\n cost: Omit<TokenAmountValues, 'amount'>; // sentAmount - adjustedReturn\n};\n\n/**\n * Sort order set by the user\n */\nexport enum SortOrder {\n COST_ASC = 'cost_ascending',\n ETA_ASC = 'time_descending',\n}\n\n/**\n * This is the interface for the asset object returned by the bridge-api\n * This type is used in the QuoteResponse and in the fetchBridgeTokens response\n */\nexport type BridgeAsset = Infer<typeof BridgeAssetSchema>;\n\n/**\n * This is the interface for the token object used in the extension client\n * In addition to the {@link BridgeAsset} fields, it includes balance information\n */\nexport type BridgeToken = {\n address: string;\n symbol: string;\n image: string;\n decimals: number;\n chainId: number | Hex | ChainId | CaipChainId;\n balance: string; // raw balance\n // TODO deprecate this field and use balance instead\n string: string | undefined; // normalized balance as a stringified number\n tokenFiatAmount?: number | null;\n occurrences?: number;\n};\n\ntype DecimalChainId = string;\nexport type GasMultiplierByChainId = Record<DecimalChainId, number>;\n\nexport type FeatureFlagResponse = Infer<typeof PlatformConfigSchema>;\n\n// TODO move definition to validators.ts\n/**\n * This is the interface for the quote request sent to the bridge-api\n * and should only be used by the fetchBridgeQuotes utility function\n * Components and redux stores should use the {@link GenericQuoteRequest} type\n */\nexport type QuoteRequest<\n ChainIdType = ChainId | number,\n TokenAddressType = string,\n WalletAddressType = string,\n> = {\n walletAddress: WalletAddressType;\n destWalletAddress?: WalletAddressType;\n srcChainId: ChainIdType;\n destChainId: ChainIdType;\n srcTokenAddress: TokenAddressType;\n destTokenAddress: TokenAddressType;\n /**\n * This is the amount sent, in atomic amount\n */\n srcTokenAmount: string;\n slippage?: number;\n aggIds?: string[];\n bridgeIds?: string[];\n insufficientBal?: boolean;\n resetApproval?: boolean;\n refuel?: boolean;\n /**\n * Whether the response should include gasless swap quotes\n * This should be true if the user has opted in to STX on the client\n * and the current network has STX support\n */\n gasIncluded: boolean;\n /**\n * Whether to request quotes that use EIP-7702 delegated gasless execution\n */\n gasIncluded7702: boolean;\n /**\n * The fee that will be charged by MetaMask\n */\n fee?: number;\n};\n\nexport enum StatusTypes {\n SUBMITTED = 'SUBMITTED',\n UNKNOWN = 'UNKNOWN',\n FAILED = 'FAILED',\n PENDING = 'PENDING',\n COMPLETE = 'COMPLETE',\n}\n\n/**\n * These are types that components pass in. Since data is a mix of types when coming from the redux store, we need to use a generic type that can cover all the types.\n * Payloads with this type are transformed into QuoteRequest by fetchBridgeQuotes right before fetching quotes\n */\nexport type GenericQuoteRequest = QuoteRequest<\n Hex | CaipChainId | string | number, // chainIds\n Hex | CaipAssetId | string, // assetIds/addresses\n Hex | CaipAccountId | string // accountIds/addresses\n>;\n\nexport type Protocol = Infer<typeof ProtocolSchema>;\n\nexport type Step = Infer<typeof StepSchema>;\n\nexport type RefuelData = Step;\n\nexport type FeeData = Infer<typeof FeeDataSchema>;\n\nexport type Quote = Infer<typeof QuoteSchema>;\n\nexport type TxData = Infer<typeof TxDataSchema>;\n\nexport type Intent = Infer<typeof IntentSchema>;\nexport type IntentOrderLike = Intent['order'];\n\nexport type BitcoinTradeData = Infer<typeof BitcoinTradeDataSchema>;\n\nexport type TronTradeData = Infer<typeof TronTradeDataSchema>;\n/**\n * This is the type for the quote response from the bridge-api\n * TxDataType can be overriden to be a string when the quote is non-evm\n * ApprovalType can be overriden when you know the specific approval type (e.g., TxData for EVM-only contexts)\n */\nexport type QuoteResponse<\n TxDataType = TxData | string | BitcoinTradeData | TronTradeData,\n ApprovalType = TxData | TronTradeData,\n> = Infer<typeof QuoteResponseSchema> & {\n trade: TxDataType;\n approval?: ApprovalType;\n /**\n * Appended to the quote response based on the quote request\n */\n featureId?: FeatureId;\n /**\n * Appended to the quote response based on the quote request resetApproval flag\n * If defined, the quote's total network fee will include the reset approval's gas limit.\n */\n resetApproval?: TxData;\n};\n\nexport enum ChainId {\n ETH = 1,\n OPTIMISM = 10,\n BSC = 56,\n POLYGON = 137,\n ZKSYNC = 324,\n BASE = 8453,\n ARBITRUM = 42161,\n AVALANCHE = 43114,\n LINEA = 59144,\n SOLANA = 1151111081099710,\n BTC = 20000000000001,\n TRON = 728126428,\n SEI = 1329,\n MONAD = 143,\n}\n\nexport type FeatureFlagsPlatformConfig = Infer<typeof PlatformConfigSchema>;\n\nexport enum RequestStatus {\n LOADING,\n FETCHED,\n ERROR,\n}\nexport enum BridgeUserAction {\n SELECT_DEST_NETWORK = 'selectDestNetwork',\n UPDATE_QUOTE_PARAMS = 'updateBridgeQuoteRequestParams',\n}\nexport enum BridgeBackgroundAction {\n SET_CHAIN_INTERVAL_LENGTH = 'setChainIntervalLength',\n RESET_STATE = 'resetState',\n TRACK_METAMETRICS_EVENT = 'trackUnifiedSwapBridgeEvent',\n STOP_POLLING_FOR_QUOTES = 'stopPollingForQuotes',\n FETCH_QUOTES = 'fetchQuotes',\n}\n\nexport type BridgeControllerState = {\n quoteRequest: Partial<GenericQuoteRequest>;\n quotes: (QuoteResponse & L1GasFees & NonEvmFees)[];\n /**\n * The time elapsed between the initial quote fetch and when the first valid quote was received\n */\n quotesInitialLoadTime: number | null;\n /**\n * The timestamp of when the latest quote fetch started\n */\n quotesLastFetched: number | null;\n /**\n * The status of the quote fetch, including fee calculations and validations\n * This is set to\n * - LOADING when the quote fetch starts\n * - FETCHED when the process completes successfully, including when quotes are empty\n * - ERROR when any errors occur\n *\n * When SSE is enabled, this is set to LOADING even when a quote is available. It is only\n * set to FETCHED when the stream is closed and all quotes have been received\n */\n quotesLoadingStatus: RequestStatus | null;\n quoteFetchError: string | null;\n /**\n * The number of times the quotes have been refreshed, starts at 0 and is\n * incremented at the end of each quote fetch\n */\n quotesRefreshCount: number;\n /**\n * Asset exchange rates for EVM and multichain assets that are not indexed by the assets controllers\n */\n assetExchangeRates: Record<CaipAssetType, ExchangeRate>;\n /**\n * When the src token is SOL, this needs to be subtracted from their balance to determine\n * the max amount that can be sent.\n */\n minimumBalanceForRentExemptionInLamports: string | null;\n};\n\nexport type BridgeControllerAction<\n FunctionName extends keyof BridgeController,\n> = {\n type: `${typeof BRIDGE_CONTROLLER_NAME}:${FunctionName}`;\n handler: BridgeController[FunctionName];\n};\n\nexport type BridgeControllerGetStateAction = ControllerGetStateAction<\n typeof BRIDGE_CONTROLLER_NAME,\n BridgeControllerState\n>;\n\nexport type BridgeControllerStateChangeEvent = ControllerStateChangeEvent<\n typeof BRIDGE_CONTROLLER_NAME,\n BridgeControllerState\n>;\n\n// Maps to BridgeController function names\nexport type BridgeControllerActions =\n | BridgeControllerGetStateAction\n | BridgeControllerAction<BridgeBackgroundAction.SET_CHAIN_INTERVAL_LENGTH>\n | BridgeControllerAction<BridgeBackgroundAction.RESET_STATE>\n | BridgeControllerAction<BridgeBackgroundAction.TRACK_METAMETRICS_EVENT>\n | BridgeControllerAction<BridgeBackgroundAction.STOP_POLLING_FOR_QUOTES>\n | BridgeControllerAction<BridgeBackgroundAction.FETCH_QUOTES>\n | BridgeControllerAction<BridgeUserAction.UPDATE_QUOTE_PARAMS>;\n\nexport type BridgeControllerEvents = BridgeControllerStateChangeEvent;\n\nexport type AllowedActions =\n | AccountsControllerGetAccountByAddressAction\n | GetCurrencyRateState\n | TokenRatesControllerGetStateAction\n | MultichainAssetsRatesControllerGetStateAction\n | HandleSnapRequest\n | NetworkControllerFindNetworkClientIdByChainIdAction\n | NetworkControllerGetNetworkClientByIdAction\n | RemoteFeatureFlagControllerGetStateAction;\nexport type AllowedEvents = never;\n\n/**\n * The messenger for the BridgeController.\n */\nexport type BridgeControllerMessenger = Messenger<\n typeof BRIDGE_CONTROLLER_NAME,\n BridgeControllerActions | AllowedActions,\n BridgeControllerEvents | AllowedEvents\n>;\n"]}
1
+ {"version":3,"file":"types.cjs","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":";;;AAiDA;;GAEG;AACH,IAAY,SAYX;AAZD,WAAY,SAAS;IACnB,4DAA4D;IAC5D,8BAAiB,CAAA;IACjB,qBAAqB;IACrB,4BAAe,CAAA;IACf,kCAAkC;IAClC,wBAAW,CAAA;IACX;;;OAGG;IACH,gCAAmB,CAAA;AACrB,CAAC,EAZW,SAAS,yBAAT,SAAS,QAYpB;AAiFD;;GAEG;AACH,IAAY,SAGX;AAHD,WAAY,SAAS;IACnB,wCAA2B,CAAA;IAC3B,wCAA2B,CAAA;AAC7B,CAAC,EAHW,SAAS,yBAAT,SAAS,QAGpB;AAyED,IAAY,WAKX;AALD,WAAY,WAAW;IACrB,kCAAmB,CAAA;IACnB,gCAAiB,CAAA;IACjB,kCAAmB,CAAA;IACnB,oCAAqB,CAAA;AACvB,CAAC,EALW,WAAW,2BAAX,WAAW,QAKtB;AAiDD,IAAY,OAeX;AAfD,WAAY,OAAO;IACjB,mCAAO,CAAA;IACP,8CAAa,CAAA;IACb,oCAAQ,CAAA;IACR,6CAAa,CAAA;IACb,2CAAY,CAAA;IACZ,wCAAW,CAAA;IACX,iDAAgB,CAAA;IAChB,mDAAiB,CAAA;IACjB,2CAAa,CAAA;IACb,wDAAyB,CAAA;IACzB,gDAAoB,CAAA;IACpB,6CAAgB,CAAA;IAChB,sCAAU,CAAA;IACV,yCAAW,CAAA;AACb,CAAC,EAfW,OAAO,uBAAP,OAAO,QAelB;AAID,IAAY,aAIX;AAJD,WAAY,aAAa;IACvB,uDAAO,CAAA;IACP,uDAAO,CAAA;IACP,mDAAK,CAAA;AACP,CAAC,EAJW,aAAa,6BAAb,aAAa,QAIxB;AACD,IAAY,gBAGX;AAHD,WAAY,gBAAgB;IAC1B,6DAAyC,CAAA;IACzC,0EAAsD,CAAA;AACxD,CAAC,EAHW,gBAAgB,gCAAhB,gBAAgB,QAG3B;AACD,IAAY,sBAMX;AAND,WAAY,sBAAsB;IAChC,8EAAoD,CAAA;IACpD,oDAA0B,CAAA;IAC1B,iFAAuD,CAAA;IACvD,0EAAgD,CAAA;IAChD,sDAA4B,CAAA;AAC9B,CAAC,EANW,sBAAsB,sCAAtB,sBAAsB,QAMjC","sourcesContent":["import type { AccountsControllerGetAccountByAddressAction } from '@metamask/accounts-controller';\nimport type {\n GetCurrencyRateState,\n MultichainAssetsRatesControllerGetStateAction,\n TokenRatesControllerGetStateAction,\n} from '@metamask/assets-controllers';\nimport type {\n ControllerGetStateAction,\n ControllerStateChangeEvent,\n} from '@metamask/base-controller';\nimport type { Messenger } from '@metamask/messenger';\nimport type {\n NetworkControllerFindNetworkClientIdByChainIdAction,\n NetworkControllerGetNetworkClientByIdAction,\n} from '@metamask/network-controller';\nimport type { RemoteFeatureFlagControllerGetStateAction } from '@metamask/remote-feature-flag-controller';\nimport type { HandleSnapRequest } from '@metamask/snaps-controllers';\nimport type { Infer } from '@metamask/superstruct';\nimport type {\n CaipAccountId,\n CaipAssetId,\n CaipAssetType,\n CaipChainId,\n Hex,\n} from '@metamask/utils';\n\nimport type { BridgeController } from './bridge-controller';\nimport type { BRIDGE_CONTROLLER_NAME } from './constants/bridge';\nimport type {\n BitcoinTradeDataSchema,\n BridgeAssetSchema,\n ChainConfigurationSchema,\n FeatureId,\n FeeDataSchema,\n PlatformConfigSchema,\n ProtocolSchema,\n QuoteResponseSchema,\n QuoteSchema,\n StepSchema,\n TronTradeDataSchema,\n TxDataSchema,\n} from './utils/validators';\n\nexport type FetchFunction = (\n input: RequestInfo | URL | string,\n init?: RequestInit,\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n) => Promise<any>;\n\n/**\n * The types of assets that a user can send\n */\nexport enum AssetType {\n /** The native asset for the current network, such as ETH */\n native = 'NATIVE',\n /** An ERC20 token */\n token = 'TOKEN',\n /** An ERC721 or ERC1155 token. */\n NFT = 'NFT',\n /**\n * A transaction interacting with a contract that isn't a token method\n * interaction will be marked as dealing with an unknown asset type.\n */\n unknown = 'UNKNOWN',\n}\n\nexport type ChainConfiguration = Infer<typeof ChainConfigurationSchema>;\n\nexport type L1GasFees = {\n l1GasFeesInHexWei?: string; // l1 fees for approval and trade in hex wei, appended by BridgeController.#appendL1GasFees\n};\n\nexport type NonEvmFees = {\n nonEvmFeesInNative?: string; // Non-EVM chain fees in native units (SOL for Solana, BTC for Bitcoin)\n};\n\n/**\n * The types of values for the token amount and its values when converted to the user's selected currency and USD\n */\nexport type TokenAmountValues = {\n /**\n * The amount of the token\n *\n * @example \"1000000000000000000\"\n */\n amount: string;\n /**\n * The amount of the token in the user's selected currency\n *\n * @example \"4.55\"\n */\n valueInCurrency: string | null;\n /**\n * The amount of the token in USD\n *\n * @example \"1.234\"\n */\n usd: string | null;\n};\n\n/**\n * Asset exchange rate values for a given chain and address\n */\nexport type ExchangeRate = { exchangeRate?: string; usdExchangeRate?: string };\n\n/**\n * Values derived from the quote response\n */\nexport type QuoteMetadata = {\n /**\n * If gas is included, this is the value of the src or dest token that was used to pay for the gas\n */\n includedTxFees?: TokenAmountValues | null;\n /**\n * The gas fee for the bridge transaction.\n * effective is the gas fee that is shown to the user. If this value is not\n * included in the trade, the calculation falls back to the gasLimit (total)\n * total is the gas fee that is spent by the user, including refunds.\n * max is the max gas fee that will be used by the transaction.\n */\n gasFee: Record<'effective' | 'total' | 'max', TokenAmountValues>;\n totalNetworkFee: TokenAmountValues; // estimatedGasFees + relayerFees\n totalMaxNetworkFee: TokenAmountValues; // maxGasFees + relayerFees\n /**\n * The amount that the user will receive (destTokenAmount)\n */\n toTokenAmount: TokenAmountValues;\n /**\n * The minimum amount that the user will receive (minDestTokenAmount)\n */\n minToTokenAmount: TokenAmountValues;\n /**\n * If gas is included: toTokenAmount\n * Otherwise: toTokenAmount - totalNetworkFee\n */\n adjustedReturn: Omit<TokenAmountValues, 'amount'>;\n /**\n * The amount that the user will send, including fees\n * srcTokenAmount + metabridgeFee + txFee\n */\n sentAmount: TokenAmountValues;\n swapRate: string; // destTokenAmount / sentAmount\n cost: Omit<TokenAmountValues, 'amount'>; // sentAmount - adjustedReturn\n};\n\n/**\n * Sort order set by the user\n */\nexport enum SortOrder {\n COST_ASC = 'cost_ascending',\n ETA_ASC = 'time_descending',\n}\n\n/**\n * This is the interface for the asset object returned by the bridge-api\n * This type is used in the QuoteResponse and in the fetchBridgeTokens response\n */\nexport type BridgeAsset = Infer<typeof BridgeAssetSchema>;\n\n/**\n * This is the interface for the token object used in the extension client\n * In addition to the {@link BridgeAsset} fields, it includes balance information\n */\nexport type BridgeToken = {\n address: string;\n symbol: string;\n image: string;\n decimals: number;\n chainId: number | Hex | ChainId | CaipChainId;\n balance: string; // raw balance\n // TODO deprecate this field and use balance instead\n string: string | undefined; // normalized balance as a stringified number\n tokenFiatAmount?: number | null;\n occurrences?: number;\n};\n\ntype DecimalChainId = string;\nexport type GasMultiplierByChainId = Record<DecimalChainId, number>;\n\nexport type FeatureFlagResponse = Infer<typeof PlatformConfigSchema>;\n\n// TODO move definition to validators.ts\n/**\n * This is the interface for the quote request sent to the bridge-api\n * and should only be used by the fetchBridgeQuotes utility function\n * Components and redux stores should use the {@link GenericQuoteRequest} type\n */\nexport type QuoteRequest<\n ChainIdType = ChainId | number,\n TokenAddressType = string,\n WalletAddressType = string,\n> = {\n walletAddress: WalletAddressType;\n destWalletAddress?: WalletAddressType;\n srcChainId: ChainIdType;\n destChainId: ChainIdType;\n srcTokenAddress: TokenAddressType;\n destTokenAddress: TokenAddressType;\n /**\n * This is the amount sent, in atomic amount\n */\n srcTokenAmount: string;\n slippage?: number;\n aggIds?: string[];\n bridgeIds?: string[];\n insufficientBal?: boolean;\n resetApproval?: boolean;\n refuel?: boolean;\n /**\n * Whether the response should include gasless swap quotes\n * This should be true if the user has opted in to STX on the client\n * and the current network has STX support\n */\n gasIncluded: boolean;\n /**\n * Whether to request quotes that use EIP-7702 delegated gasless execution\n */\n gasIncluded7702: boolean;\n /**\n * The fee that will be charged by MetaMask\n */\n fee?: number;\n};\n\nexport enum StatusTypes {\n UNKNOWN = 'UNKNOWN',\n FAILED = 'FAILED',\n PENDING = 'PENDING',\n COMPLETE = 'COMPLETE',\n}\n\n/**\n * These are types that components pass in. Since data is a mix of types when coming from the redux store, we need to use a generic type that can cover all the types.\n * Payloads with this type are transformed into QuoteRequest by fetchBridgeQuotes right before fetching quotes\n */\nexport type GenericQuoteRequest = QuoteRequest<\n Hex | CaipChainId | string | number, // chainIds\n Hex | CaipAssetId | string, // assetIds/addresses\n Hex | CaipAccountId | string // accountIds/addresses\n>;\n\nexport type Protocol = Infer<typeof ProtocolSchema>;\n\nexport type Step = Infer<typeof StepSchema>;\n\nexport type RefuelData = Step;\n\nexport type FeeData = Infer<typeof FeeDataSchema>;\n\nexport type Quote = Infer<typeof QuoteSchema>;\n\nexport type TxData = Infer<typeof TxDataSchema>;\n\nexport type BitcoinTradeData = Infer<typeof BitcoinTradeDataSchema>;\n\nexport type TronTradeData = Infer<typeof TronTradeDataSchema>;\n/**\n * This is the type for the quote response from the bridge-api\n * TxDataType can be overriden to be a string when the quote is non-evm\n * ApprovalType can be overriden when you know the specific approval type (e.g., TxData for EVM-only contexts)\n */\nexport type QuoteResponse<\n TxDataType = TxData | string | BitcoinTradeData | TronTradeData,\n ApprovalType = TxData | TronTradeData,\n> = Infer<typeof QuoteResponseSchema> & {\n trade: TxDataType;\n approval?: ApprovalType;\n /**\n * Appended to the quote response based on the quote request\n */\n featureId?: FeatureId;\n /**\n * Appended to the quote response based on the quote request resetApproval flag\n * If defined, the quote's total network fee will include the reset approval's gas limit.\n */\n resetApproval?: TxData;\n};\n\nexport enum ChainId {\n ETH = 1,\n OPTIMISM = 10,\n BSC = 56,\n POLYGON = 137,\n ZKSYNC = 324,\n BASE = 8453,\n ARBITRUM = 42161,\n AVALANCHE = 43114,\n LINEA = 59144,\n SOLANA = 1151111081099710,\n BTC = 20000000000001,\n TRON = 728126428,\n SEI = 1329,\n MONAD = 143,\n}\n\nexport type FeatureFlagsPlatformConfig = Infer<typeof PlatformConfigSchema>;\n\nexport enum RequestStatus {\n LOADING,\n FETCHED,\n ERROR,\n}\nexport enum BridgeUserAction {\n SELECT_DEST_NETWORK = 'selectDestNetwork',\n UPDATE_QUOTE_PARAMS = 'updateBridgeQuoteRequestParams',\n}\nexport enum BridgeBackgroundAction {\n SET_CHAIN_INTERVAL_LENGTH = 'setChainIntervalLength',\n RESET_STATE = 'resetState',\n TRACK_METAMETRICS_EVENT = 'trackUnifiedSwapBridgeEvent',\n STOP_POLLING_FOR_QUOTES = 'stopPollingForQuotes',\n FETCH_QUOTES = 'fetchQuotes',\n}\n\nexport type BridgeControllerState = {\n quoteRequest: Partial<GenericQuoteRequest>;\n quotes: (QuoteResponse & L1GasFees & NonEvmFees)[];\n /**\n * The time elapsed between the initial quote fetch and when the first valid quote was received\n */\n quotesInitialLoadTime: number | null;\n /**\n * The timestamp of when the latest quote fetch started\n */\n quotesLastFetched: number | null;\n /**\n * The status of the quote fetch, including fee calculations and validations\n * This is set to\n * - LOADING when the quote fetch starts\n * - FETCHED when the process completes successfully, including when quotes are empty\n * - ERROR when any errors occur\n *\n * When SSE is enabled, this is set to LOADING even when a quote is available. It is only\n * set to FETCHED when the stream is closed and all quotes have been received\n */\n quotesLoadingStatus: RequestStatus | null;\n quoteFetchError: string | null;\n /**\n * The number of times the quotes have been refreshed, starts at 0 and is\n * incremented at the end of each quote fetch\n */\n quotesRefreshCount: number;\n /**\n * Asset exchange rates for EVM and multichain assets that are not indexed by the assets controllers\n */\n assetExchangeRates: Record<CaipAssetType, ExchangeRate>;\n /**\n * When the src token is SOL, this needs to be subtracted from their balance to determine\n * the max amount that can be sent.\n */\n minimumBalanceForRentExemptionInLamports: string | null;\n};\n\nexport type BridgeControllerAction<\n FunctionName extends keyof BridgeController,\n> = {\n type: `${typeof BRIDGE_CONTROLLER_NAME}:${FunctionName}`;\n handler: BridgeController[FunctionName];\n};\n\nexport type BridgeControllerGetStateAction = ControllerGetStateAction<\n typeof BRIDGE_CONTROLLER_NAME,\n BridgeControllerState\n>;\n\nexport type BridgeControllerStateChangeEvent = ControllerStateChangeEvent<\n typeof BRIDGE_CONTROLLER_NAME,\n BridgeControllerState\n>;\n\n// Maps to BridgeController function names\nexport type BridgeControllerActions =\n | BridgeControllerGetStateAction\n | BridgeControllerAction<BridgeBackgroundAction.SET_CHAIN_INTERVAL_LENGTH>\n | BridgeControllerAction<BridgeBackgroundAction.RESET_STATE>\n | BridgeControllerAction<BridgeBackgroundAction.TRACK_METAMETRICS_EVENT>\n | BridgeControllerAction<BridgeBackgroundAction.STOP_POLLING_FOR_QUOTES>\n | BridgeControllerAction<BridgeBackgroundAction.FETCH_QUOTES>\n | BridgeControllerAction<BridgeUserAction.UPDATE_QUOTE_PARAMS>;\n\nexport type BridgeControllerEvents = BridgeControllerStateChangeEvent;\n\nexport type AllowedActions =\n | AccountsControllerGetAccountByAddressAction\n | GetCurrencyRateState\n | TokenRatesControllerGetStateAction\n | MultichainAssetsRatesControllerGetStateAction\n | HandleSnapRequest\n | NetworkControllerFindNetworkClientIdByChainIdAction\n | NetworkControllerGetNetworkClientByIdAction\n | RemoteFeatureFlagControllerGetStateAction;\nexport type AllowedEvents = never;\n\n/**\n * The messenger for the BridgeController.\n */\nexport type BridgeControllerMessenger = Messenger<\n typeof BRIDGE_CONTROLLER_NAME,\n BridgeControllerActions | AllowedActions,\n BridgeControllerEvents | AllowedEvents\n>;\n"]}
package/dist/types.d.cts CHANGED
@@ -9,7 +9,7 @@ import type { Infer } from "@metamask/superstruct";
9
9
  import type { CaipAccountId, CaipAssetId, CaipAssetType, CaipChainId, Hex } from "@metamask/utils";
10
10
  import type { BridgeController } from "./bridge-controller.cjs";
11
11
  import type { BRIDGE_CONTROLLER_NAME } from "./constants/bridge.cjs";
12
- import type { BitcoinTradeDataSchema, BridgeAssetSchema, ChainConfigurationSchema, FeatureId, FeeDataSchema, IntentSchema, PlatformConfigSchema, ProtocolSchema, QuoteResponseSchema, QuoteSchema, StepSchema, TronTradeDataSchema, TxDataSchema } from "./utils/validators.cjs";
12
+ import type { BitcoinTradeDataSchema, BridgeAssetSchema, ChainConfigurationSchema, FeatureId, FeeDataSchema, PlatformConfigSchema, ProtocolSchema, QuoteResponseSchema, QuoteSchema, StepSchema, TronTradeDataSchema, TxDataSchema } from "./utils/validators.cjs";
13
13
  export type FetchFunction = (input: RequestInfo | URL | string, init?: RequestInit) => Promise<any>;
14
14
  /**
15
15
  * The types of assets that a user can send
@@ -171,7 +171,6 @@ export type QuoteRequest<ChainIdType = ChainId | number, TokenAddressType = stri
171
171
  fee?: number;
172
172
  };
173
173
  export declare enum StatusTypes {
174
- SUBMITTED = "SUBMITTED",
175
174
  UNKNOWN = "UNKNOWN",
176
175
  FAILED = "FAILED",
177
176
  PENDING = "PENDING",
@@ -192,8 +191,6 @@ export type RefuelData = Step;
192
191
  export type FeeData = Infer<typeof FeeDataSchema>;
193
192
  export type Quote = Infer<typeof QuoteSchema>;
194
193
  export type TxData = Infer<typeof TxDataSchema>;
195
- export type Intent = Infer<typeof IntentSchema>;
196
- export type IntentOrderLike = Intent['order'];
197
194
  export type BitcoinTradeData = Infer<typeof BitcoinTradeDataSchema>;
198
195
  export type TronTradeData = Infer<typeof TronTradeDataSchema>;
199
196
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.cts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2CAA2C,EAAE,sCAAsC;AACjG,OAAO,KAAK,EACV,oBAAoB,EACpB,6CAA6C,EAC7C,kCAAkC,EACnC,qCAAqC;AAC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ask/superstruct";
9
9
  import type { CaipAccountId, CaipAssetId, CaipAssetType, CaipChainId, Hex } from "@metamask/utils";
10
10
  import type { BridgeController } from "./bridge-controller.mjs";
11
11
  import type { BRIDGE_CONTROLLER_NAME } from "./constants/bridge.mjs";
12
- import type { BitcoinTradeDataSchema, BridgeAssetSchema, ChainConfigurationSchema, FeatureId, FeeDataSchema, IntentSchema, PlatformConfigSchema, ProtocolSchema, QuoteResponseSchema, QuoteSchema, StepSchema, TronTradeDataSchema, TxDataSchema } from "./utils/validators.mjs";
12
+ import type { BitcoinTradeDataSchema, BridgeAssetSchema, ChainConfigurationSchema, FeatureId, FeeDataSchema, PlatformConfigSchema, ProtocolSchema, QuoteResponseSchema, QuoteSchema, StepSchema, TronTradeDataSchema, TxDataSchema } from "./utils/validators.mjs";
13
13
  export type FetchFunction = (input: RequestInfo | URL | string, init?: RequestInit) => Promise<any>;
14
14
  /**
15
15
  * The types of assets that a user can send
@@ -171,7 +171,6 @@ export type QuoteRequest<ChainIdType = ChainId | number, TokenAddressType = stri
171
171
  fee?: number;
172
172
  };
173
173
  export declare enum StatusTypes {
174
- SUBMITTED = "SUBMITTED",
175
174
  UNKNOWN = "UNKNOWN",
176
175
  FAILED = "FAILED",
177
176
  PENDING = "PENDING",
@@ -192,8 +191,6 @@ export type RefuelData = Step;
192
191
  export type FeeData = Infer<typeof FeeDataSchema>;
193
192
  export type Quote = Infer<typeof QuoteSchema>;
194
193
  export type TxData = Infer<typeof TxDataSchema>;
195
- export type Intent = Infer<typeof IntentSchema>;
196
- export type IntentOrderLike = Intent['order'];
197
194
  export type BitcoinTradeData = Infer<typeof BitcoinTradeDataSchema>;
198
195
  export type TronTradeData = Infer<typeof TronTradeDataSchema>;
199
196
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.mts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2CAA2C,EAAE,sCAAsC;AACjG,OAAO,KAAK,EACV,oBAAoB,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.mjs CHANGED
@@ -25,7 +25,6 @@ export var SortOrder;
25
25
  })(SortOrder || (SortOrder = {}));
26
26
  export var StatusTypes;
27
27
  (function (StatusTypes) {
28
- StatusTypes["SUBMITTED"] = "SUBMITTED";
29
28
  StatusTypes["UNKNOWN"] = "UNKNOWN";
30
29
  StatusTypes["FAILED"] = "FAILED";
31
30
  StatusTypes["PENDING"] = "PENDING";
@@ -1 +1 @@
1
- {"version":3,"file":"types.mjs","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAkDA;;GAEG;AACH,MAAM,CAAN,IAAY,SAYX;AAZD,WAAY,SAAS;IACnB,4DAA4D;IAC5D,8BAAiB,CAAA;IACjB,qBAAqB;IACrB,4BAAe,CAAA;IACf,kCAAkC;IAClC,wBAAW,CAAA;IACX;;;OAGG;IACH,gCAAmB,CAAA;AACrB,CAAC,EAZW,SAAS,KAAT,SAAS,QAYpB;AAiFD;;GAEG;AACH,MAAM,CAAN,IAAY,SAGX;AAHD,WAAY,SAAS;IACnB,wCAA2B,CAAA;IAC3B,wCAA2B,CAAA;AAC7B,CAAC,EAHW,SAAS,KAAT,SAAS,QAGpB;AAyED,MAAM,CAAN,IAAY,WAMX;AAND,WAAY,WAAW;IACrB,sCAAuB,CAAA;IACvB,kCAAmB,CAAA;IACnB,gCAAiB,CAAA;IACjB,kCAAmB,CAAA;IACnB,oCAAqB,CAAA;AACvB,CAAC,EANW,WAAW,KAAX,WAAW,QAMtB;AAoDD,MAAM,CAAN,IAAY,OAeX;AAfD,WAAY,OAAO;IACjB,mCAAO,CAAA;IACP,8CAAa,CAAA;IACb,oCAAQ,CAAA;IACR,6CAAa,CAAA;IACb,2CAAY,CAAA;IACZ,wCAAW,CAAA;IACX,iDAAgB,CAAA;IAChB,mDAAiB,CAAA;IACjB,2CAAa,CAAA;IACb,wDAAyB,CAAA;IACzB,gDAAoB,CAAA;IACpB,6CAAgB,CAAA;IAChB,sCAAU,CAAA;IACV,yCAAW,CAAA;AACb,CAAC,EAfW,OAAO,KAAP,OAAO,QAelB;AAID,MAAM,CAAN,IAAY,aAIX;AAJD,WAAY,aAAa;IACvB,uDAAO,CAAA;IACP,uDAAO,CAAA;IACP,mDAAK,CAAA;AACP,CAAC,EAJW,aAAa,KAAb,aAAa,QAIxB;AACD,MAAM,CAAN,IAAY,gBAGX;AAHD,WAAY,gBAAgB;IAC1B,6DAAyC,CAAA;IACzC,0EAAsD,CAAA;AACxD,CAAC,EAHW,gBAAgB,KAAhB,gBAAgB,QAG3B;AACD,MAAM,CAAN,IAAY,sBAMX;AAND,WAAY,sBAAsB;IAChC,8EAAoD,CAAA;IACpD,oDAA0B,CAAA;IAC1B,iFAAuD,CAAA;IACvD,0EAAgD,CAAA;IAChD,sDAA4B,CAAA;AAC9B,CAAC,EANW,sBAAsB,KAAtB,sBAAsB,QAMjC","sourcesContent":["import type { AccountsControllerGetAccountByAddressAction } from '@metamask/accounts-controller';\nimport type {\n GetCurrencyRateState,\n MultichainAssetsRatesControllerGetStateAction,\n TokenRatesControllerGetStateAction,\n} from '@metamask/assets-controllers';\nimport type {\n ControllerGetStateAction,\n ControllerStateChangeEvent,\n} from '@metamask/base-controller';\nimport type { Messenger } from '@metamask/messenger';\nimport type {\n NetworkControllerFindNetworkClientIdByChainIdAction,\n NetworkControllerGetNetworkClientByIdAction,\n} from '@metamask/network-controller';\nimport type { RemoteFeatureFlagControllerGetStateAction } from '@metamask/remote-feature-flag-controller';\nimport type { HandleSnapRequest } from '@metamask/snaps-controllers';\nimport type { Infer } from '@metamask/superstruct';\nimport type {\n CaipAccountId,\n CaipAssetId,\n CaipAssetType,\n CaipChainId,\n Hex,\n} from '@metamask/utils';\n\nimport type { BridgeController } from './bridge-controller';\nimport type { BRIDGE_CONTROLLER_NAME } from './constants/bridge';\nimport type {\n BitcoinTradeDataSchema,\n BridgeAssetSchema,\n ChainConfigurationSchema,\n FeatureId,\n FeeDataSchema,\n IntentSchema,\n PlatformConfigSchema,\n ProtocolSchema,\n QuoteResponseSchema,\n QuoteSchema,\n StepSchema,\n TronTradeDataSchema,\n TxDataSchema,\n} from './utils/validators';\n\nexport type FetchFunction = (\n input: RequestInfo | URL | string,\n init?: RequestInit,\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n) => Promise<any>;\n\n/**\n * The types of assets that a user can send\n */\nexport enum AssetType {\n /** The native asset for the current network, such as ETH */\n native = 'NATIVE',\n /** An ERC20 token */\n token = 'TOKEN',\n /** An ERC721 or ERC1155 token. */\n NFT = 'NFT',\n /**\n * A transaction interacting with a contract that isn't a token method\n * interaction will be marked as dealing with an unknown asset type.\n */\n unknown = 'UNKNOWN',\n}\n\nexport type ChainConfiguration = Infer<typeof ChainConfigurationSchema>;\n\nexport type L1GasFees = {\n l1GasFeesInHexWei?: string; // l1 fees for approval and trade in hex wei, appended by BridgeController.#appendL1GasFees\n};\n\nexport type NonEvmFees = {\n nonEvmFeesInNative?: string; // Non-EVM chain fees in native units (SOL for Solana, BTC for Bitcoin)\n};\n\n/**\n * The types of values for the token amount and its values when converted to the user's selected currency and USD\n */\nexport type TokenAmountValues = {\n /**\n * The amount of the token\n *\n * @example \"1000000000000000000\"\n */\n amount: string;\n /**\n * The amount of the token in the user's selected currency\n *\n * @example \"4.55\"\n */\n valueInCurrency: string | null;\n /**\n * The amount of the token in USD\n *\n * @example \"1.234\"\n */\n usd: string | null;\n};\n\n/**\n * Asset exchange rate values for a given chain and address\n */\nexport type ExchangeRate = { exchangeRate?: string; usdExchangeRate?: string };\n\n/**\n * Values derived from the quote response\n */\nexport type QuoteMetadata = {\n /**\n * If gas is included, this is the value of the src or dest token that was used to pay for the gas\n */\n includedTxFees?: TokenAmountValues | null;\n /**\n * The gas fee for the bridge transaction.\n * effective is the gas fee that is shown to the user. If this value is not\n * included in the trade, the calculation falls back to the gasLimit (total)\n * total is the gas fee that is spent by the user, including refunds.\n * max is the max gas fee that will be used by the transaction.\n */\n gasFee: Record<'effective' | 'total' | 'max', TokenAmountValues>;\n totalNetworkFee: TokenAmountValues; // estimatedGasFees + relayerFees\n totalMaxNetworkFee: TokenAmountValues; // maxGasFees + relayerFees\n /**\n * The amount that the user will receive (destTokenAmount)\n */\n toTokenAmount: TokenAmountValues;\n /**\n * The minimum amount that the user will receive (minDestTokenAmount)\n */\n minToTokenAmount: TokenAmountValues;\n /**\n * If gas is included: toTokenAmount\n * Otherwise: toTokenAmount - totalNetworkFee\n */\n adjustedReturn: Omit<TokenAmountValues, 'amount'>;\n /**\n * The amount that the user will send, including fees\n * srcTokenAmount + metabridgeFee + txFee\n */\n sentAmount: TokenAmountValues;\n swapRate: string; // destTokenAmount / sentAmount\n cost: Omit<TokenAmountValues, 'amount'>; // sentAmount - adjustedReturn\n};\n\n/**\n * Sort order set by the user\n */\nexport enum SortOrder {\n COST_ASC = 'cost_ascending',\n ETA_ASC = 'time_descending',\n}\n\n/**\n * This is the interface for the asset object returned by the bridge-api\n * This type is used in the QuoteResponse and in the fetchBridgeTokens response\n */\nexport type BridgeAsset = Infer<typeof BridgeAssetSchema>;\n\n/**\n * This is the interface for the token object used in the extension client\n * In addition to the {@link BridgeAsset} fields, it includes balance information\n */\nexport type BridgeToken = {\n address: string;\n symbol: string;\n image: string;\n decimals: number;\n chainId: number | Hex | ChainId | CaipChainId;\n balance: string; // raw balance\n // TODO deprecate this field and use balance instead\n string: string | undefined; // normalized balance as a stringified number\n tokenFiatAmount?: number | null;\n occurrences?: number;\n};\n\ntype DecimalChainId = string;\nexport type GasMultiplierByChainId = Record<DecimalChainId, number>;\n\nexport type FeatureFlagResponse = Infer<typeof PlatformConfigSchema>;\n\n// TODO move definition to validators.ts\n/**\n * This is the interface for the quote request sent to the bridge-api\n * and should only be used by the fetchBridgeQuotes utility function\n * Components and redux stores should use the {@link GenericQuoteRequest} type\n */\nexport type QuoteRequest<\n ChainIdType = ChainId | number,\n TokenAddressType = string,\n WalletAddressType = string,\n> = {\n walletAddress: WalletAddressType;\n destWalletAddress?: WalletAddressType;\n srcChainId: ChainIdType;\n destChainId: ChainIdType;\n srcTokenAddress: TokenAddressType;\n destTokenAddress: TokenAddressType;\n /**\n * This is the amount sent, in atomic amount\n */\n srcTokenAmount: string;\n slippage?: number;\n aggIds?: string[];\n bridgeIds?: string[];\n insufficientBal?: boolean;\n resetApproval?: boolean;\n refuel?: boolean;\n /**\n * Whether the response should include gasless swap quotes\n * This should be true if the user has opted in to STX on the client\n * and the current network has STX support\n */\n gasIncluded: boolean;\n /**\n * Whether to request quotes that use EIP-7702 delegated gasless execution\n */\n gasIncluded7702: boolean;\n /**\n * The fee that will be charged by MetaMask\n */\n fee?: number;\n};\n\nexport enum StatusTypes {\n SUBMITTED = 'SUBMITTED',\n UNKNOWN = 'UNKNOWN',\n FAILED = 'FAILED',\n PENDING = 'PENDING',\n COMPLETE = 'COMPLETE',\n}\n\n/**\n * These are types that components pass in. Since data is a mix of types when coming from the redux store, we need to use a generic type that can cover all the types.\n * Payloads with this type are transformed into QuoteRequest by fetchBridgeQuotes right before fetching quotes\n */\nexport type GenericQuoteRequest = QuoteRequest<\n Hex | CaipChainId | string | number, // chainIds\n Hex | CaipAssetId | string, // assetIds/addresses\n Hex | CaipAccountId | string // accountIds/addresses\n>;\n\nexport type Protocol = Infer<typeof ProtocolSchema>;\n\nexport type Step = Infer<typeof StepSchema>;\n\nexport type RefuelData = Step;\n\nexport type FeeData = Infer<typeof FeeDataSchema>;\n\nexport type Quote = Infer<typeof QuoteSchema>;\n\nexport type TxData = Infer<typeof TxDataSchema>;\n\nexport type Intent = Infer<typeof IntentSchema>;\nexport type IntentOrderLike = Intent['order'];\n\nexport type BitcoinTradeData = Infer<typeof BitcoinTradeDataSchema>;\n\nexport type TronTradeData = Infer<typeof TronTradeDataSchema>;\n/**\n * This is the type for the quote response from the bridge-api\n * TxDataType can be overriden to be a string when the quote is non-evm\n * ApprovalType can be overriden when you know the specific approval type (e.g., TxData for EVM-only contexts)\n */\nexport type QuoteResponse<\n TxDataType = TxData | string | BitcoinTradeData | TronTradeData,\n ApprovalType = TxData | TronTradeData,\n> = Infer<typeof QuoteResponseSchema> & {\n trade: TxDataType;\n approval?: ApprovalType;\n /**\n * Appended to the quote response based on the quote request\n */\n featureId?: FeatureId;\n /**\n * Appended to the quote response based on the quote request resetApproval flag\n * If defined, the quote's total network fee will include the reset approval's gas limit.\n */\n resetApproval?: TxData;\n};\n\nexport enum ChainId {\n ETH = 1,\n OPTIMISM = 10,\n BSC = 56,\n POLYGON = 137,\n ZKSYNC = 324,\n BASE = 8453,\n ARBITRUM = 42161,\n AVALANCHE = 43114,\n LINEA = 59144,\n SOLANA = 1151111081099710,\n BTC = 20000000000001,\n TRON = 728126428,\n SEI = 1329,\n MONAD = 143,\n}\n\nexport type FeatureFlagsPlatformConfig = Infer<typeof PlatformConfigSchema>;\n\nexport enum RequestStatus {\n LOADING,\n FETCHED,\n ERROR,\n}\nexport enum BridgeUserAction {\n SELECT_DEST_NETWORK = 'selectDestNetwork',\n UPDATE_QUOTE_PARAMS = 'updateBridgeQuoteRequestParams',\n}\nexport enum BridgeBackgroundAction {\n SET_CHAIN_INTERVAL_LENGTH = 'setChainIntervalLength',\n RESET_STATE = 'resetState',\n TRACK_METAMETRICS_EVENT = 'trackUnifiedSwapBridgeEvent',\n STOP_POLLING_FOR_QUOTES = 'stopPollingForQuotes',\n FETCH_QUOTES = 'fetchQuotes',\n}\n\nexport type BridgeControllerState = {\n quoteRequest: Partial<GenericQuoteRequest>;\n quotes: (QuoteResponse & L1GasFees & NonEvmFees)[];\n /**\n * The time elapsed between the initial quote fetch and when the first valid quote was received\n */\n quotesInitialLoadTime: number | null;\n /**\n * The timestamp of when the latest quote fetch started\n */\n quotesLastFetched: number | null;\n /**\n * The status of the quote fetch, including fee calculations and validations\n * This is set to\n * - LOADING when the quote fetch starts\n * - FETCHED when the process completes successfully, including when quotes are empty\n * - ERROR when any errors occur\n *\n * When SSE is enabled, this is set to LOADING even when a quote is available. It is only\n * set to FETCHED when the stream is closed and all quotes have been received\n */\n quotesLoadingStatus: RequestStatus | null;\n quoteFetchError: string | null;\n /**\n * The number of times the quotes have been refreshed, starts at 0 and is\n * incremented at the end of each quote fetch\n */\n quotesRefreshCount: number;\n /**\n * Asset exchange rates for EVM and multichain assets that are not indexed by the assets controllers\n */\n assetExchangeRates: Record<CaipAssetType, ExchangeRate>;\n /**\n * When the src token is SOL, this needs to be subtracted from their balance to determine\n * the max amount that can be sent.\n */\n minimumBalanceForRentExemptionInLamports: string | null;\n};\n\nexport type BridgeControllerAction<\n FunctionName extends keyof BridgeController,\n> = {\n type: `${typeof BRIDGE_CONTROLLER_NAME}:${FunctionName}`;\n handler: BridgeController[FunctionName];\n};\n\nexport type BridgeControllerGetStateAction = ControllerGetStateAction<\n typeof BRIDGE_CONTROLLER_NAME,\n BridgeControllerState\n>;\n\nexport type BridgeControllerStateChangeEvent = ControllerStateChangeEvent<\n typeof BRIDGE_CONTROLLER_NAME,\n BridgeControllerState\n>;\n\n// Maps to BridgeController function names\nexport type BridgeControllerActions =\n | BridgeControllerGetStateAction\n | BridgeControllerAction<BridgeBackgroundAction.SET_CHAIN_INTERVAL_LENGTH>\n | BridgeControllerAction<BridgeBackgroundAction.RESET_STATE>\n | BridgeControllerAction<BridgeBackgroundAction.TRACK_METAMETRICS_EVENT>\n | BridgeControllerAction<BridgeBackgroundAction.STOP_POLLING_FOR_QUOTES>\n | BridgeControllerAction<BridgeBackgroundAction.FETCH_QUOTES>\n | BridgeControllerAction<BridgeUserAction.UPDATE_QUOTE_PARAMS>;\n\nexport type BridgeControllerEvents = BridgeControllerStateChangeEvent;\n\nexport type AllowedActions =\n | AccountsControllerGetAccountByAddressAction\n | GetCurrencyRateState\n | TokenRatesControllerGetStateAction\n | MultichainAssetsRatesControllerGetStateAction\n | HandleSnapRequest\n | NetworkControllerFindNetworkClientIdByChainIdAction\n | NetworkControllerGetNetworkClientByIdAction\n | RemoteFeatureFlagControllerGetStateAction;\nexport type AllowedEvents = never;\n\n/**\n * The messenger for the BridgeController.\n */\nexport type BridgeControllerMessenger = Messenger<\n typeof BRIDGE_CONTROLLER_NAME,\n BridgeControllerActions | AllowedActions,\n BridgeControllerEvents | AllowedEvents\n>;\n"]}
1
+ {"version":3,"file":"types.mjs","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAiDA;;GAEG;AACH,MAAM,CAAN,IAAY,SAYX;AAZD,WAAY,SAAS;IACnB,4DAA4D;IAC5D,8BAAiB,CAAA;IACjB,qBAAqB;IACrB,4BAAe,CAAA;IACf,kCAAkC;IAClC,wBAAW,CAAA;IACX;;;OAGG;IACH,gCAAmB,CAAA;AACrB,CAAC,EAZW,SAAS,KAAT,SAAS,QAYpB;AAiFD;;GAEG;AACH,MAAM,CAAN,IAAY,SAGX;AAHD,WAAY,SAAS;IACnB,wCAA2B,CAAA;IAC3B,wCAA2B,CAAA;AAC7B,CAAC,EAHW,SAAS,KAAT,SAAS,QAGpB;AAyED,MAAM,CAAN,IAAY,WAKX;AALD,WAAY,WAAW;IACrB,kCAAmB,CAAA;IACnB,gCAAiB,CAAA;IACjB,kCAAmB,CAAA;IACnB,oCAAqB,CAAA;AACvB,CAAC,EALW,WAAW,KAAX,WAAW,QAKtB;AAiDD,MAAM,CAAN,IAAY,OAeX;AAfD,WAAY,OAAO;IACjB,mCAAO,CAAA;IACP,8CAAa,CAAA;IACb,oCAAQ,CAAA;IACR,6CAAa,CAAA;IACb,2CAAY,CAAA;IACZ,wCAAW,CAAA;IACX,iDAAgB,CAAA;IAChB,mDAAiB,CAAA;IACjB,2CAAa,CAAA;IACb,wDAAyB,CAAA;IACzB,gDAAoB,CAAA;IACpB,6CAAgB,CAAA;IAChB,sCAAU,CAAA;IACV,yCAAW,CAAA;AACb,CAAC,EAfW,OAAO,KAAP,OAAO,QAelB;AAID,MAAM,CAAN,IAAY,aAIX;AAJD,WAAY,aAAa;IACvB,uDAAO,CAAA;IACP,uDAAO,CAAA;IACP,mDAAK,CAAA;AACP,CAAC,EAJW,aAAa,KAAb,aAAa,QAIxB;AACD,MAAM,CAAN,IAAY,gBAGX;AAHD,WAAY,gBAAgB;IAC1B,6DAAyC,CAAA;IACzC,0EAAsD,CAAA;AACxD,CAAC,EAHW,gBAAgB,KAAhB,gBAAgB,QAG3B;AACD,MAAM,CAAN,IAAY,sBAMX;AAND,WAAY,sBAAsB;IAChC,8EAAoD,CAAA;IACpD,oDAA0B,CAAA;IAC1B,iFAAuD,CAAA;IACvD,0EAAgD,CAAA;IAChD,sDAA4B,CAAA;AAC9B,CAAC,EANW,sBAAsB,KAAtB,sBAAsB,QAMjC","sourcesContent":["import type { AccountsControllerGetAccountByAddressAction } from '@metamask/accounts-controller';\nimport type {\n GetCurrencyRateState,\n MultichainAssetsRatesControllerGetStateAction,\n TokenRatesControllerGetStateAction,\n} from '@metamask/assets-controllers';\nimport type {\n ControllerGetStateAction,\n ControllerStateChangeEvent,\n} from '@metamask/base-controller';\nimport type { Messenger } from '@metamask/messenger';\nimport type {\n NetworkControllerFindNetworkClientIdByChainIdAction,\n NetworkControllerGetNetworkClientByIdAction,\n} from '@metamask/network-controller';\nimport type { RemoteFeatureFlagControllerGetStateAction } from '@metamask/remote-feature-flag-controller';\nimport type { HandleSnapRequest } from '@metamask/snaps-controllers';\nimport type { Infer } from '@metamask/superstruct';\nimport type {\n CaipAccountId,\n CaipAssetId,\n CaipAssetType,\n CaipChainId,\n Hex,\n} from '@metamask/utils';\n\nimport type { BridgeController } from './bridge-controller';\nimport type { BRIDGE_CONTROLLER_NAME } from './constants/bridge';\nimport type {\n BitcoinTradeDataSchema,\n BridgeAssetSchema,\n ChainConfigurationSchema,\n FeatureId,\n FeeDataSchema,\n PlatformConfigSchema,\n ProtocolSchema,\n QuoteResponseSchema,\n QuoteSchema,\n StepSchema,\n TronTradeDataSchema,\n TxDataSchema,\n} from './utils/validators';\n\nexport type FetchFunction = (\n input: RequestInfo | URL | string,\n init?: RequestInit,\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n) => Promise<any>;\n\n/**\n * The types of assets that a user can send\n */\nexport enum AssetType {\n /** The native asset for the current network, such as ETH */\n native = 'NATIVE',\n /** An ERC20 token */\n token = 'TOKEN',\n /** An ERC721 or ERC1155 token. */\n NFT = 'NFT',\n /**\n * A transaction interacting with a contract that isn't a token method\n * interaction will be marked as dealing with an unknown asset type.\n */\n unknown = 'UNKNOWN',\n}\n\nexport type ChainConfiguration = Infer<typeof ChainConfigurationSchema>;\n\nexport type L1GasFees = {\n l1GasFeesInHexWei?: string; // l1 fees for approval and trade in hex wei, appended by BridgeController.#appendL1GasFees\n};\n\nexport type NonEvmFees = {\n nonEvmFeesInNative?: string; // Non-EVM chain fees in native units (SOL for Solana, BTC for Bitcoin)\n};\n\n/**\n * The types of values for the token amount and its values when converted to the user's selected currency and USD\n */\nexport type TokenAmountValues = {\n /**\n * The amount of the token\n *\n * @example \"1000000000000000000\"\n */\n amount: string;\n /**\n * The amount of the token in the user's selected currency\n *\n * @example \"4.55\"\n */\n valueInCurrency: string | null;\n /**\n * The amount of the token in USD\n *\n * @example \"1.234\"\n */\n usd: string | null;\n};\n\n/**\n * Asset exchange rate values for a given chain and address\n */\nexport type ExchangeRate = { exchangeRate?: string; usdExchangeRate?: string };\n\n/**\n * Values derived from the quote response\n */\nexport type QuoteMetadata = {\n /**\n * If gas is included, this is the value of the src or dest token that was used to pay for the gas\n */\n includedTxFees?: TokenAmountValues | null;\n /**\n * The gas fee for the bridge transaction.\n * effective is the gas fee that is shown to the user. If this value is not\n * included in the trade, the calculation falls back to the gasLimit (total)\n * total is the gas fee that is spent by the user, including refunds.\n * max is the max gas fee that will be used by the transaction.\n */\n gasFee: Record<'effective' | 'total' | 'max', TokenAmountValues>;\n totalNetworkFee: TokenAmountValues; // estimatedGasFees + relayerFees\n totalMaxNetworkFee: TokenAmountValues; // maxGasFees + relayerFees\n /**\n * The amount that the user will receive (destTokenAmount)\n */\n toTokenAmount: TokenAmountValues;\n /**\n * The minimum amount that the user will receive (minDestTokenAmount)\n */\n minToTokenAmount: TokenAmountValues;\n /**\n * If gas is included: toTokenAmount\n * Otherwise: toTokenAmount - totalNetworkFee\n */\n adjustedReturn: Omit<TokenAmountValues, 'amount'>;\n /**\n * The amount that the user will send, including fees\n * srcTokenAmount + metabridgeFee + txFee\n */\n sentAmount: TokenAmountValues;\n swapRate: string; // destTokenAmount / sentAmount\n cost: Omit<TokenAmountValues, 'amount'>; // sentAmount - adjustedReturn\n};\n\n/**\n * Sort order set by the user\n */\nexport enum SortOrder {\n COST_ASC = 'cost_ascending',\n ETA_ASC = 'time_descending',\n}\n\n/**\n * This is the interface for the asset object returned by the bridge-api\n * This type is used in the QuoteResponse and in the fetchBridgeTokens response\n */\nexport type BridgeAsset = Infer<typeof BridgeAssetSchema>;\n\n/**\n * This is the interface for the token object used in the extension client\n * In addition to the {@link BridgeAsset} fields, it includes balance information\n */\nexport type BridgeToken = {\n address: string;\n symbol: string;\n image: string;\n decimals: number;\n chainId: number | Hex | ChainId | CaipChainId;\n balance: string; // raw balance\n // TODO deprecate this field and use balance instead\n string: string | undefined; // normalized balance as a stringified number\n tokenFiatAmount?: number | null;\n occurrences?: number;\n};\n\ntype DecimalChainId = string;\nexport type GasMultiplierByChainId = Record<DecimalChainId, number>;\n\nexport type FeatureFlagResponse = Infer<typeof PlatformConfigSchema>;\n\n// TODO move definition to validators.ts\n/**\n * This is the interface for the quote request sent to the bridge-api\n * and should only be used by the fetchBridgeQuotes utility function\n * Components and redux stores should use the {@link GenericQuoteRequest} type\n */\nexport type QuoteRequest<\n ChainIdType = ChainId | number,\n TokenAddressType = string,\n WalletAddressType = string,\n> = {\n walletAddress: WalletAddressType;\n destWalletAddress?: WalletAddressType;\n srcChainId: ChainIdType;\n destChainId: ChainIdType;\n srcTokenAddress: TokenAddressType;\n destTokenAddress: TokenAddressType;\n /**\n * This is the amount sent, in atomic amount\n */\n srcTokenAmount: string;\n slippage?: number;\n aggIds?: string[];\n bridgeIds?: string[];\n insufficientBal?: boolean;\n resetApproval?: boolean;\n refuel?: boolean;\n /**\n * Whether the response should include gasless swap quotes\n * This should be true if the user has opted in to STX on the client\n * and the current network has STX support\n */\n gasIncluded: boolean;\n /**\n * Whether to request quotes that use EIP-7702 delegated gasless execution\n */\n gasIncluded7702: boolean;\n /**\n * The fee that will be charged by MetaMask\n */\n fee?: number;\n};\n\nexport enum StatusTypes {\n UNKNOWN = 'UNKNOWN',\n FAILED = 'FAILED',\n PENDING = 'PENDING',\n COMPLETE = 'COMPLETE',\n}\n\n/**\n * These are types that components pass in. Since data is a mix of types when coming from the redux store, we need to use a generic type that can cover all the types.\n * Payloads with this type are transformed into QuoteRequest by fetchBridgeQuotes right before fetching quotes\n */\nexport type GenericQuoteRequest = QuoteRequest<\n Hex | CaipChainId | string | number, // chainIds\n Hex | CaipAssetId | string, // assetIds/addresses\n Hex | CaipAccountId | string // accountIds/addresses\n>;\n\nexport type Protocol = Infer<typeof ProtocolSchema>;\n\nexport type Step = Infer<typeof StepSchema>;\n\nexport type RefuelData = Step;\n\nexport type FeeData = Infer<typeof FeeDataSchema>;\n\nexport type Quote = Infer<typeof QuoteSchema>;\n\nexport type TxData = Infer<typeof TxDataSchema>;\n\nexport type BitcoinTradeData = Infer<typeof BitcoinTradeDataSchema>;\n\nexport type TronTradeData = Infer<typeof TronTradeDataSchema>;\n/**\n * This is the type for the quote response from the bridge-api\n * TxDataType can be overriden to be a string when the quote is non-evm\n * ApprovalType can be overriden when you know the specific approval type (e.g., TxData for EVM-only contexts)\n */\nexport type QuoteResponse<\n TxDataType = TxData | string | BitcoinTradeData | TronTradeData,\n ApprovalType = TxData | TronTradeData,\n> = Infer<typeof QuoteResponseSchema> & {\n trade: TxDataType;\n approval?: ApprovalType;\n /**\n * Appended to the quote response based on the quote request\n */\n featureId?: FeatureId;\n /**\n * Appended to the quote response based on the quote request resetApproval flag\n * If defined, the quote's total network fee will include the reset approval's gas limit.\n */\n resetApproval?: TxData;\n};\n\nexport enum ChainId {\n ETH = 1,\n OPTIMISM = 10,\n BSC = 56,\n POLYGON = 137,\n ZKSYNC = 324,\n BASE = 8453,\n ARBITRUM = 42161,\n AVALANCHE = 43114,\n LINEA = 59144,\n SOLANA = 1151111081099710,\n BTC = 20000000000001,\n TRON = 728126428,\n SEI = 1329,\n MONAD = 143,\n}\n\nexport type FeatureFlagsPlatformConfig = Infer<typeof PlatformConfigSchema>;\n\nexport enum RequestStatus {\n LOADING,\n FETCHED,\n ERROR,\n}\nexport enum BridgeUserAction {\n SELECT_DEST_NETWORK = 'selectDestNetwork',\n UPDATE_QUOTE_PARAMS = 'updateBridgeQuoteRequestParams',\n}\nexport enum BridgeBackgroundAction {\n SET_CHAIN_INTERVAL_LENGTH = 'setChainIntervalLength',\n RESET_STATE = 'resetState',\n TRACK_METAMETRICS_EVENT = 'trackUnifiedSwapBridgeEvent',\n STOP_POLLING_FOR_QUOTES = 'stopPollingForQuotes',\n FETCH_QUOTES = 'fetchQuotes',\n}\n\nexport type BridgeControllerState = {\n quoteRequest: Partial<GenericQuoteRequest>;\n quotes: (QuoteResponse & L1GasFees & NonEvmFees)[];\n /**\n * The time elapsed between the initial quote fetch and when the first valid quote was received\n */\n quotesInitialLoadTime: number | null;\n /**\n * The timestamp of when the latest quote fetch started\n */\n quotesLastFetched: number | null;\n /**\n * The status of the quote fetch, including fee calculations and validations\n * This is set to\n * - LOADING when the quote fetch starts\n * - FETCHED when the process completes successfully, including when quotes are empty\n * - ERROR when any errors occur\n *\n * When SSE is enabled, this is set to LOADING even when a quote is available. It is only\n * set to FETCHED when the stream is closed and all quotes have been received\n */\n quotesLoadingStatus: RequestStatus | null;\n quoteFetchError: string | null;\n /**\n * The number of times the quotes have been refreshed, starts at 0 and is\n * incremented at the end of each quote fetch\n */\n quotesRefreshCount: number;\n /**\n * Asset exchange rates for EVM and multichain assets that are not indexed by the assets controllers\n */\n assetExchangeRates: Record<CaipAssetType, ExchangeRate>;\n /**\n * When the src token is SOL, this needs to be subtracted from their balance to determine\n * the max amount that can be sent.\n */\n minimumBalanceForRentExemptionInLamports: string | null;\n};\n\nexport type BridgeControllerAction<\n FunctionName extends keyof BridgeController,\n> = {\n type: `${typeof BRIDGE_CONTROLLER_NAME}:${FunctionName}`;\n handler: BridgeController[FunctionName];\n};\n\nexport type BridgeControllerGetStateAction = ControllerGetStateAction<\n typeof BRIDGE_CONTROLLER_NAME,\n BridgeControllerState\n>;\n\nexport type BridgeControllerStateChangeEvent = ControllerStateChangeEvent<\n typeof BRIDGE_CONTROLLER_NAME,\n BridgeControllerState\n>;\n\n// Maps to BridgeController function names\nexport type BridgeControllerActions =\n | BridgeControllerGetStateAction\n | BridgeControllerAction<BridgeBackgroundAction.SET_CHAIN_INTERVAL_LENGTH>\n | BridgeControllerAction<BridgeBackgroundAction.RESET_STATE>\n | BridgeControllerAction<BridgeBackgroundAction.TRACK_METAMETRICS_EVENT>\n | BridgeControllerAction<BridgeBackgroundAction.STOP_POLLING_FOR_QUOTES>\n | BridgeControllerAction<BridgeBackgroundAction.FETCH_QUOTES>\n | BridgeControllerAction<BridgeUserAction.UPDATE_QUOTE_PARAMS>;\n\nexport type BridgeControllerEvents = BridgeControllerStateChangeEvent;\n\nexport type AllowedActions =\n | AccountsControllerGetAccountByAddressAction\n | GetCurrencyRateState\n | TokenRatesControllerGetStateAction\n | MultichainAssetsRatesControllerGetStateAction\n | HandleSnapRequest\n | NetworkControllerFindNetworkClientIdByChainIdAction\n | NetworkControllerGetNetworkClientByIdAction\n | RemoteFeatureFlagControllerGetStateAction;\nexport type AllowedEvents = never;\n\n/**\n * The messenger for the BridgeController.\n */\nexport type BridgeControllerMessenger = Messenger<\n typeof BRIDGE_CONTROLLER_NAME,\n BridgeControllerActions | AllowedActions,\n BridgeControllerEvents | AllowedEvents\n>;\n"]}
@@ -70,16 +70,16 @@ export declare const isTronChainId: (chainId: Hex | number | CaipChainId | strin
70
70
  export declare const isNonEvmChainId: (chainId: GenericQuoteRequest['srcChainId']) => boolean;
71
71
  export declare const isEvmQuoteResponse: (quoteResponse: QuoteResponse) => quoteResponse is QuoteResponse<{
72
72
  chainId: number;
73
- from: string;
74
73
  to: string;
74
+ from: string;
75
75
  value: string;
76
76
  data: string;
77
77
  gasLimit: number | null;
78
78
  effectiveGas?: number | undefined;
79
79
  }, {
80
80
  chainId: number;
81
- from: string;
82
81
  to: string;
82
+ from: string;
83
83
  value: string;
84
84
  data: string;
85
85
  gasLimit: number | null;
@@ -70,16 +70,16 @@ export declare const isTronChainId: (chainId: Hex | number | CaipChainId | strin
70
70
  export declare const isNonEvmChainId: (chainId: GenericQuoteRequest['srcChainId']) => boolean;
71
71
  export declare const isEvmQuoteResponse: (quoteResponse: QuoteResponse) => quoteResponse is QuoteResponse<{
72
72
  chainId: number;
73
- from: string;
74
73
  to: string;
74
+ from: string;
75
75
  value: string;
76
76
  data: string;
77
77
  gasLimit: number | null;
78
78
  effectiveGas?: number | undefined;
79
79
  }, {
80
80
  chainId: number;
81
- from: string;
82
81
  to: string;
82
+ from: string;
83
83
  value: string;
84
84
  data: string;
85
85
  gasLimit: number | null;
@@ -8,8 +8,8 @@ export type Trade = TxData | string | BitcoinTradeData | TronTradeData;
8
8
  */
9
9
  export declare const isEvmTxData: (trade: Trade) => trade is {
10
10
  chainId: number;
11
- from: string;
12
11
  to: string;
12
+ from: string;
13
13
  value: string;
14
14
  data: string;
15
15
  gasLimit: number | null;
@@ -8,8 +8,8 @@ export type Trade = TxData | string | BitcoinTradeData | TronTradeData;
8
8
  */
9
9
  export declare const isEvmTxData: (trade: Trade) => trade is {
10
10
  chainId: number;
11
- from: string;
12
11
  to: string;
12
+ from: string;
13
13
  value: string;
14
14
  data: string;
15
15
  gasLimit: number | null;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.validateQuoteResponse = exports.QuoteResponseSchema = exports.TronTradeDataSchema = exports.BitcoinTradeDataSchema = exports.TxDataSchema = exports.QuoteSchema = exports.IntentSchema = exports.IntentOrderSchema = exports.StepSchema = exports.ProtocolSchema = exports.FeeDataSchema = exports.validateSwapsTokenObject = exports.validateFeatureFlagsResponse = exports.PlatformConfigSchema = exports.PriceImpactThresholdSchema = exports.ChainConfigurationSchema = exports.BridgeAssetSchema = exports.truthyString = exports.ActionTypes = exports.FeatureId = exports.FeeType = void 0;
3
+ exports.validateQuoteResponse = exports.QuoteResponseSchema = exports.TronTradeDataSchema = exports.BitcoinTradeDataSchema = exports.TxDataSchema = exports.QuoteSchema = exports.StepSchema = exports.ProtocolSchema = exports.FeeDataSchema = exports.validateSwapsTokenObject = exports.validateFeatureFlagsResponse = exports.PlatformConfigSchema = exports.PriceImpactThresholdSchema = exports.ChainConfigurationSchema = exports.BridgeAssetSchema = exports.truthyString = exports.ActionTypes = exports.FeatureId = exports.FeeType = void 0;
4
4
  const controller_utils_1 = require("@metamask/controller-utils");
5
5
  const superstruct_1 = require("@metamask/superstruct");
6
6
  const utils_1 = require("@metamask/utils");
@@ -146,34 +146,6 @@ exports.StepSchema = (0, superstruct_1.type)({
146
146
  protocol: exports.ProtocolSchema,
147
147
  });
148
148
  const RefuelDataSchema = exports.StepSchema;
149
- // Allow digit strings for amounts/validTo for flexibility across providers
150
- const DigitStringOrNumberSchema = (0, superstruct_1.union)([TruthyDigitStringSchema, (0, superstruct_1.number)()]);
151
- // Intent support (e.g., CoW Swap EIP-712 order signing)
152
- const IntentProtocolSchema = (0, superstruct_1.enums)(['cowswap']);
153
- exports.IntentOrderSchema = (0, superstruct_1.type)({
154
- // EIP-712 Order fields (subset required for signing/submission)
155
- sellToken: HexAddressSchema,
156
- buyToken: HexAddressSchema,
157
- receiver: (0, superstruct_1.optional)(HexAddressSchema),
158
- validTo: DigitStringOrNumberSchema,
159
- appData: (0, superstruct_1.string)(),
160
- appDataHash: HexStringSchema,
161
- feeAmount: TruthyDigitStringSchema,
162
- kind: (0, superstruct_1.enums)(['sell', 'buy']),
163
- partiallyFillable: (0, superstruct_1.boolean)(),
164
- // One of these is required by CoW depending on kind; we keep both optional here and rely on backend validation
165
- sellAmount: (0, superstruct_1.optional)(TruthyDigitStringSchema),
166
- buyAmount: (0, superstruct_1.optional)(TruthyDigitStringSchema),
167
- // Optional owner/from for convenience when building domain/message
168
- from: (0, superstruct_1.optional)(HexAddressSchema),
169
- });
170
- exports.IntentSchema = (0, superstruct_1.type)({
171
- protocol: IntentProtocolSchema,
172
- order: exports.IntentOrderSchema,
173
- // Optional metadata to aid submission/routing
174
- settlementContract: (0, superstruct_1.optional)(HexAddressSchema),
175
- relayer: (0, superstruct_1.optional)(HexAddressSchema),
176
- });
177
149
  exports.QuoteSchema = (0, superstruct_1.type)({
178
150
  requestId: (0, superstruct_1.string)(),
179
151
  srcChainId: ChainIdSchema,
@@ -222,7 +194,6 @@ exports.QuoteSchema = (0, superstruct_1.type)({
222
194
  priceImpact: (0, superstruct_1.optional)((0, superstruct_1.string)()),
223
195
  totalFeeAmountUsd: (0, superstruct_1.optional)((0, superstruct_1.string)()),
224
196
  })),
225
- intent: (0, superstruct_1.optional)(exports.IntentSchema),
226
197
  /**
227
198
  * A third party sponsors the gas. If true, then gasIncluded7702 is also true.
228
199
  */
@@ -1 +1 @@
1
- {"version":3,"file":"validators.cjs","sourceRoot":"","sources":["../../src/utils/validators.ts"],"names":[],"mappings":";;;AAAA,iEAA+D;AAE/D,uDAgB+B;AAC/B,2CAAyE;AAEzE,IAAY,OAIX;AAJD,WAAY,OAAO;IACjB,oCAAyB,CAAA;IACzB,4BAAiB,CAAA;IACjB,2BAAgB,CAAA;AAClB,CAAC,EAJW,OAAO,uBAAP,OAAO,QAIlB;AAED,IAAY,SAEX;AAFD,WAAY,SAAS;IACnB,4BAAe,CAAA;AACjB,CAAC,EAFW,SAAS,yBAAT,SAAS,QAEpB;AAED,IAAY,WAIX;AAJD,WAAY,WAAW;IACrB,gCAAiB,CAAA;IACjB,4BAAa,CAAA;IACb,gCAAiB,CAAA;AACnB,CAAC,EAJW,WAAW,2BAAX,WAAW,QAItB;AAED,MAAM,gBAAgB,GAAG,IAAA,oBAAM,EAAS,YAA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qBAAqB,GAAG,CACnC,IAAa,EAC8B,EAAE;IAC7C,IAAA,oBAAM,EAAC,IAAI,EAAE,2BAAmB,CAAC,CAAC;IAClC,OAAO,IAAI,CAAC;AACd,CAAC,CAAC;AALW,QAAA,qBAAqB,yBAKhC","sourcesContent":["import { isValidHexAddress } from '@metamask/controller-utils';\nimport type { Infer } from '@metamask/superstruct';\nimport {\n string,\n boolean,\n number,\n type,\n is,\n record,\n array,\n nullable,\n optional,\n enums,\n define,\n union,\n assert,\n pattern,\n intersection,\n} from '@metamask/superstruct';\nimport { CaipAssetTypeStruct, isStrictHexString } from '@metamask/utils';\n\nexport enum FeeType {\n METABRIDGE = 'metabridge',\n REFUEL = 'refuel',\n TX_FEE = 'txFee',\n}\n\nexport enum FeatureId {\n PERPS = 'perps',\n}\n\nexport enum ActionTypes {\n BRIDGE = 'bridge',\n SWAP = 'swap',\n REFUEL = 'refuel',\n}\n\nconst HexAddressSchema = define<string>('HexAddress', (v: unknown) =>\n isValidHexAddress(v as string, { allowNonPrefixed: false }),\n);\n\nconst HexStringSchema = define<string>('HexString', (v: unknown) =>\n isStrictHexString(v as string),\n);\n\nconst VersionStringSchema = define<string>(\n 'VersionString',\n (v: unknown) =>\n typeof v === 'string' &&\n /^(\\d+\\.*){2}\\d+$/u.test(v) &&\n v.split('.').length === 3,\n);\n\nexport const truthyString = (s: string) => Boolean(s?.length);\nconst TruthyDigitStringSchema = pattern(string(), /^\\d+$/u);\n\nconst ChainIdSchema = number();\n\nexport const BridgeAssetSchema = type({\n /**\n * The chainId of the token\n */\n chainId: ChainIdSchema,\n /**\n * An address that the metaswap-api recognizes as the default token\n */\n address: string(),\n /**\n * The assetId of the token\n */\n assetId: CaipAssetTypeStruct,\n /**\n * The symbol of token object\n */\n symbol: string(),\n /**\n * The name for the network\n */\n name: string(),\n decimals: number(),\n /**\n * URL for token icon\n */\n icon: optional(nullable(string())),\n /**\n * URL for token icon\n */\n iconUrl: optional(nullable(string())),\n});\n\nconst DefaultPairSchema = type({\n /**\n * The standard default pairs. Use this if the pair is only set once.\n * The key is the CAIP asset type of the src token and the value is the CAIP asset type of the dest token.\n */\n standard: record(string(), string()),\n /**\n * The other default pairs. Use this if the dest token depends on the src token and can be set multiple times.\n * The key is the CAIP asset type of the src token and the value is the CAIP asset type of the dest token.\n */\n other: record(string(), string()),\n});\n\nexport const ChainConfigurationSchema = type({\n isActiveSrc: boolean(),\n isActiveDest: boolean(),\n refreshRate: optional(number()),\n topAssets: optional(array(string())),\n stablecoins: optional(array(string())),\n isUnifiedUIEnabled: optional(boolean()),\n isSingleSwapBridgeButtonEnabled: optional(boolean()),\n isGaslessSwapEnabled: optional(boolean()),\n noFeeAssets: optional(array(string())),\n defaultPairs: optional(DefaultPairSchema),\n});\n\nexport const PriceImpactThresholdSchema = type({\n gasless: number(),\n normal: number(),\n});\n\nconst GenericQuoteRequestSchema = type({\n aggIds: optional(array(string())),\n bridgeIds: optional(array(string())),\n fee: optional(number()),\n});\n\nconst FeatureIdSchema = enums(Object.values(FeatureId));\n\n/**\n * This is the schema for the feature flags response from the RemoteFeatureFlagController\n */\nexport const PlatformConfigSchema = type({\n priceImpactThreshold: optional(PriceImpactThresholdSchema),\n quoteRequestOverrides: optional(\n record(FeatureIdSchema, optional(GenericQuoteRequestSchema)),\n ),\n minimumVersion: string(),\n refreshRate: number(),\n maxRefreshCount: number(),\n support: boolean(),\n chains: record(string(), ChainConfigurationSchema),\n /**\n * The bip44 default pairs for the chains\n * Key is the CAIP chainId namespace\n */\n bip44DefaultPairs: optional(record(string(), optional(DefaultPairSchema))),\n sse: optional(\n type({\n enabled: boolean(),\n /**\n * The minimum version of the client required to enable SSE, for example 13.8.0\n */\n minimumVersion: VersionStringSchema,\n }),\n ),\n});\n\nexport const validateFeatureFlagsResponse = (\n data: unknown,\n): data is Infer<typeof PlatformConfigSchema> => {\n return is(data, PlatformConfigSchema);\n};\n\nexport const validateSwapsTokenObject = (\n data: unknown,\n): data is Infer<typeof BridgeAssetSchema> => {\n return is(data, BridgeAssetSchema);\n};\n\nexport const FeeDataSchema = type({\n amount: TruthyDigitStringSchema,\n asset: BridgeAssetSchema,\n});\n\nexport const ProtocolSchema = type({\n name: string(),\n displayName: optional(string()),\n icon: optional(string()),\n});\n\nexport const StepSchema = type({\n action: enums(Object.values(ActionTypes)),\n srcChainId: ChainIdSchema,\n destChainId: optional(ChainIdSchema),\n srcAsset: BridgeAssetSchema,\n destAsset: BridgeAssetSchema,\n srcAmount: string(),\n destAmount: string(),\n protocol: ProtocolSchema,\n});\n\nconst RefuelDataSchema = StepSchema;\n\n// Allow digit strings for amounts/validTo for flexibility across providers\nconst DigitStringOrNumberSchema = union([TruthyDigitStringSchema, number()]);\n\n// Intent support (e.g., CoW Swap EIP-712 order signing)\nconst IntentProtocolSchema = enums(['cowswap']);\n\nexport const IntentOrderSchema = type({\n // EIP-712 Order fields (subset required for signing/submission)\n sellToken: HexAddressSchema,\n buyToken: HexAddressSchema,\n receiver: optional(HexAddressSchema),\n validTo: DigitStringOrNumberSchema,\n appData: string(),\n appDataHash: HexStringSchema,\n feeAmount: TruthyDigitStringSchema,\n kind: enums(['sell', 'buy']),\n partiallyFillable: boolean(),\n // One of these is required by CoW depending on kind; we keep both optional here and rely on backend validation\n sellAmount: optional(TruthyDigitStringSchema),\n buyAmount: optional(TruthyDigitStringSchema),\n // Optional owner/from for convenience when building domain/message\n from: optional(HexAddressSchema),\n});\n\nexport const IntentSchema = type({\n protocol: IntentProtocolSchema,\n order: IntentOrderSchema,\n // Optional metadata to aid submission/routing\n settlementContract: optional(HexAddressSchema),\n relayer: optional(HexAddressSchema),\n});\n\n// Export types for use in other modules\nexport type IntentOrder = Infer<typeof IntentOrderSchema>;\nexport type Intent = Infer<typeof IntentSchema>;\n\nexport const QuoteSchema = type({\n requestId: string(),\n srcChainId: ChainIdSchema,\n srcAsset: BridgeAssetSchema,\n /**\n * The amount sent, in atomic amount: amount sent - fees\n * Some tokens have a fee of 0, so sometimes it's equal to amount sent\n */\n srcTokenAmount: string(),\n destChainId: ChainIdSchema,\n destAsset: BridgeAssetSchema,\n /**\n * The amount received, in atomic amount\n */\n destTokenAmount: string(),\n /**\n * The minimum amount that will be received, in atomic amount\n */\n minDestTokenAmount: string(),\n feeData: type({\n [FeeType.METABRIDGE]: FeeDataSchema,\n /**\n * This is the fee for the swap transaction taken from either the\n * src or dest token if the quote has gas fees included or \"gasless\"\n */\n [FeeType.TX_FEE]: optional(\n intersection([\n FeeDataSchema,\n type({\n maxFeePerGas: string(),\n maxPriorityFeePerGas: string(),\n }),\n ]),\n ),\n }),\n gasIncluded: optional(boolean()),\n /**\n * Whether the quote can use EIP-7702 delegated gasless execution\n */\n gasIncluded7702: optional(boolean()),\n bridgeId: string(),\n bridges: array(string()),\n steps: array(StepSchema),\n refuel: optional(RefuelDataSchema),\n priceData: optional(\n type({\n totalFromAmountUsd: optional(string()),\n totalToAmountUsd: optional(string()),\n priceImpact: optional(string()),\n totalFeeAmountUsd: optional(string()),\n }),\n ),\n intent: optional(IntentSchema),\n /**\n * A third party sponsors the gas. If true, then gasIncluded7702 is also true.\n */\n gasSponsored: optional(boolean()),\n});\n\nexport const TxDataSchema = type({\n chainId: number(),\n to: HexAddressSchema,\n from: HexAddressSchema,\n value: HexStringSchema,\n data: HexStringSchema,\n gasLimit: nullable(number()),\n effectiveGas: optional(number()),\n});\n\nexport const BitcoinTradeDataSchema = type({\n unsignedPsbtBase64: string(),\n inputsToSign: nullable(array(type({}))),\n});\n\nexport const TronTradeDataSchema = type({\n raw_data_hex: string(),\n visible: optional(boolean()),\n raw_data: optional(\n nullable(\n type({\n contract: optional(\n array(\n type({\n type: optional(string()),\n }),\n ),\n ),\n fee_limit: optional(number()),\n }),\n ),\n ),\n});\n\nexport const QuoteResponseSchema = type({\n quote: QuoteSchema,\n estimatedProcessingTimeInSeconds: number(),\n approval: optional(union([TxDataSchema, TronTradeDataSchema])),\n trade: union([\n TxDataSchema,\n BitcoinTradeDataSchema,\n TronTradeDataSchema,\n string(),\n ]),\n});\n\nexport const validateQuoteResponse = (\n data: unknown,\n): data is Infer<typeof QuoteResponseSchema> => {\n assert(data, QuoteResponseSchema);\n return true;\n};\n"]}
1
+ {"version":3,"file":"validators.cjs","sourceRoot":"","sources":["../../src/utils/validators.ts"],"names":[],"mappings":";;;AAAA,iEAA+D;AAE/D,uDAgB+B;AAC/B,2CAAyE;AAEzE,IAAY,OAIX;AAJD,WAAY,OAAO;IACjB,oCAAyB,CAAA;IACzB,4BAAiB,CAAA;IACjB,2BAAgB,CAAA;AAClB,CAAC,EAJW,OAAO,uBAAP,OAAO,QAIlB;AAED,IAAY,SAEX;AAFD,WAAY,SAAS;IACnB,4BAAe,CAAA;AACjB,CAAC,EAFW,SAAS,yBAAT,SAAS,QAEpB;AAED,IAAY,WAIX;AAJD,WAAY,WAAW;IACrB,gCAAiB,CAAA;IACjB,4BAAa,CAAA;IACb,gCAAiB,CAAA;AACnB,CAAC,EAJW,WAAW,2BAAX,WAAW,QAItB;AAED,MAAM,gBAAgB,GAAG,IAAA,oBAAM,EAAS,YAAY,EAAE,CAAC,CAAU,EAAE,EAAE,CACnE,IAAA,oCAAiB,EAAC,CAAW,EAAE,EAAE,gBAAgB,EAAE,KAAK,EAAE,CAAC,CAC5D,CAAC;AAEF,MAAM,eAAe,GAAG,IAAA,oBAAM,EAAS,WAAW,EAAE,CAAC,CAAU,EAAE,EAAE,CACjE,IAAA,yBAAiB,EAAC,CAAW,CAAC,CAC/B,CAAC;AAEF,MAAM,mBAAmB,GAAG,IAAA,oBAAM,EAChC,eAAe,EACf,CAAC,CAAU,EAAE,EAAE,CACb,OAAO,CAAC,KAAK,QAAQ;IACrB,mBAAmB,CAAC,IAAI,CAAC,CAAC,CAAC;IAC3B,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,MAAM,KAAK,CAAC,CAC5B,CAAC;AAEK,MAAM,YAAY,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,OAAO,CAAC,CAAC,EAAE,MA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M,GAAE;IACtB,OAAO,EAAE,IAAA,sBAAQ,EAAC,IAAA,qBAAO,GAAE,CAAC;IAC5B,QAAQ,EAAE,IAAA,sBAAQ,EAChB,IAAA,sBAAQ,EACN,IAAA,kBAAI,EAAC;QACH,QAAQ,EAAE,IAAA,sBAAQ,EAChB,IAAA,mBAAK,EACH,IAAA,kBAAI,EAAC;YACH,IAAI,EAAE,IAAA,sBAAQ,EAAC,IAAA,oBAAM,GAAE,CAAC;SACzB,CAAC,CACH,CACF;QACD,SAAS,EAAE,IAAA,sBAAQ,EAAC,IAAA,oBAAM,GAAE,CAAC;KAC9B,CAAC,CACH,CACF;CACF,CAAC,CAAC;AAEU,QAAA,mBAAmB,GAAG,IAAA,kBAAI,EAAC;IACtC,KAAK,EAAE,mBAAW;IAClB,gCAAgC,EAAE,IAAA,oBAAM,GAAE;IAC1C,QAAQ,EAAE,IAAA,sBAAQ,EAAC,IAAA,mBAAK,EAAC,CAAC,oBAAY,EAAE,2BAAmB,CAAC,CAAC,CAAC;IAC9D,KAAK,EAAE,IAAA,mBAAK,EAAC;QACX,oBAAY;QACZ,8BAAsB;QACtB,2BAAmB;QACnB,IAAA,oBAAM,GAAE;KACT,CAAC;CACH,CAAC,CAAC;AAEI,MAAM,qBAAqB,GAAG,CACnC,IAAa,EAC8B,EAAE;IAC7C,IAAA,oBAAM,EAAC,IAAI,EAAE,2BAAmB,CAAC,CAAC;IAClC,OAAO,IAAI,CAAC;AACd,CAAC,CAAC;AALW,QAAA,qBAAqB,yBAKhC","sourcesContent":["import { isValidHexAddress } from '@metamask/controller-utils';\nimport type { Infer } from '@metamask/superstruct';\nimport {\n string,\n boolean,\n number,\n type,\n is,\n record,\n array,\n nullable,\n optional,\n enums,\n define,\n union,\n assert,\n pattern,\n intersection,\n} from '@metamask/superstruct';\nimport { CaipAssetTypeStruct, isStrictHexString } from '@metamask/utils';\n\nexport enum FeeType {\n METABRIDGE = 'metabridge',\n REFUEL = 'refuel',\n TX_FEE = 'txFee',\n}\n\nexport enum FeatureId {\n PERPS = 'perps',\n}\n\nexport enum ActionTypes {\n BRIDGE = 'bridge',\n SWAP = 'swap',\n REFUEL = 'refuel',\n}\n\nconst HexAddressSchema = define<string>('HexAddress', (v: unknown) =>\n isValidHexAddress(v as string, { allowNonPrefixed: false }),\n);\n\nconst HexStringSchema = define<string>('HexString', (v: unknown) =>\n isStrictHexString(v as string),\n);\n\nconst VersionStringSchema = define<string>(\n 'VersionString',\n (v: unknown) =>\n typeof v === 'string' &&\n /^(\\d+\\.*){2}\\d+$/u.test(v) &&\n v.split('.').length === 3,\n);\n\nexport const truthyString = (s: string) => Boolean(s?.length);\nconst TruthyDigitStringSchema = pattern(string(), /^\\d+$/u);\n\nconst ChainIdSchema = number();\n\nexport const BridgeAssetSchema = type({\n /**\n * The chainId of the token\n */\n chainId: ChainIdSchema,\n /**\n * An address that the metaswap-api recognizes as the default token\n */\n address: string(),\n /**\n * The assetId of the token\n */\n assetId: CaipAssetTypeStruct,\n /**\n * The symbol of token object\n */\n symbol: string(),\n /**\n * The name for the network\n */\n name: string(),\n decimals: number(),\n /**\n * URL for token icon\n */\n icon: optional(nullable(string())),\n /**\n * URL for token icon\n */\n iconUrl: optional(nullable(string())),\n});\n\nconst DefaultPairSchema = type({\n /**\n * The standard default pairs. Use this if the pair is only set once.\n * The key is the CAIP asset type of the src token and the value is the CAIP asset type of the dest token.\n */\n standard: record(string(), string()),\n /**\n * The other default pairs. Use this if the dest token depends on the src token and can be set multiple times.\n * The key is the CAIP asset type of the src token and the value is the CAIP asset type of the dest token.\n */\n other: record(string(), string()),\n});\n\nexport const ChainConfigurationSchema = type({\n isActiveSrc: boolean(),\n isActiveDest: boolean(),\n refreshRate: optional(number()),\n topAssets: optional(array(string())),\n stablecoins: optional(array(string())),\n isUnifiedUIEnabled: optional(boolean()),\n isSingleSwapBridgeButtonEnabled: optional(boolean()),\n isGaslessSwapEnabled: optional(boolean()),\n noFeeAssets: optional(array(string())),\n defaultPairs: optional(DefaultPairSchema),\n});\n\nexport const PriceImpactThresholdSchema = type({\n gasless: number(),\n normal: number(),\n});\n\nconst GenericQuoteRequestSchema = type({\n aggIds: optional(array(string())),\n bridgeIds: optional(array(string())),\n fee: optional(number()),\n});\n\nconst FeatureIdSchema = enums(Object.values(FeatureId));\n\n/**\n * This is the schema for the feature flags response from the RemoteFeatureFlagController\n */\nexport const PlatformConfigSchema = type({\n priceImpactThreshold: optional(PriceImpactThresholdSchema),\n quoteRequestOverrides: optional(\n record(FeatureIdSchema, optional(GenericQuoteRequestSchema)),\n ),\n minimumVersion: string(),\n refreshRate: number(),\n maxRefreshCount: number(),\n support: boolean(),\n chains: record(string(), ChainConfigurationSchema),\n /**\n * The bip44 default pairs for the chains\n * Key is the CAIP chainId namespace\n */\n bip44DefaultPairs: optional(record(string(), optional(DefaultPairSchema))),\n sse: optional(\n type({\n enabled: boolean(),\n /**\n * The minimum version of the client required to enable SSE, for example 13.8.0\n */\n minimumVersion: VersionStringSchema,\n }),\n ),\n});\n\nexport const validateFeatureFlagsResponse = (\n data: unknown,\n): data is Infer<typeof PlatformConfigSchema> => {\n return is(data, PlatformConfigSchema);\n};\n\nexport const validateSwapsTokenObject = (\n data: unknown,\n): data is Infer<typeof BridgeAssetSchema> => {\n return is(data, BridgeAssetSchema);\n};\n\nexport const FeeDataSchema = type({\n amount: TruthyDigitStringSchema,\n asset: BridgeAssetSchema,\n});\n\nexport const ProtocolSchema = type({\n name: string(),\n displayName: optional(string()),\n icon: optional(string()),\n});\n\nexport const StepSchema = type({\n action: enums(Object.values(ActionTypes)),\n srcChainId: ChainIdSchema,\n destChainId: optional(ChainIdSchema),\n srcAsset: BridgeAssetSchema,\n destAsset: BridgeAssetSchema,\n srcAmount: string(),\n destAmount: string(),\n protocol: ProtocolSchema,\n});\n\nconst RefuelDataSchema = StepSchema;\n\nexport const QuoteSchema = type({\n requestId: string(),\n srcChainId: ChainIdSchema,\n srcAsset: BridgeAssetSchema,\n /**\n * The amount sent, in atomic amount: amount sent - fees\n * Some tokens have a fee of 0, so sometimes it's equal to amount sent\n */\n srcTokenAmount: string(),\n destChainId: ChainIdSchema,\n destAsset: BridgeAssetSchema,\n /**\n * The amount received, in atomic amount\n */\n destTokenAmount: string(),\n /**\n * The minimum amount that will be received, in atomic amount\n */\n minDestTokenAmount: string(),\n feeData: type({\n [FeeType.METABRIDGE]: FeeDataSchema,\n /**\n * This is the fee for the swap transaction taken from either the\n * src or dest token if the quote has gas fees included or \"gasless\"\n */\n [FeeType.TX_FEE]: optional(\n intersection([\n FeeDataSchema,\n type({\n maxFeePerGas: string(),\n maxPriorityFeePerGas: string(),\n }),\n ]),\n ),\n }),\n gasIncluded: optional(boolean()),\n /**\n * Whether the quote can use EIP-7702 delegated gasless execution\n */\n gasIncluded7702: optional(boolean()),\n bridgeId: string(),\n bridges: array(string()),\n steps: array(StepSchema),\n refuel: optional(RefuelDataSchema),\n priceData: optional(\n type({\n totalFromAmountUsd: optional(string()),\n totalToAmountUsd: optional(string()),\n priceImpact: optional(string()),\n totalFeeAmountUsd: optional(string()),\n }),\n ),\n /**\n * A third party sponsors the gas. If true, then gasIncluded7702 is also true.\n */\n gasSponsored: optional(boolean()),\n});\n\nexport const TxDataSchema = type({\n chainId: number(),\n to: HexAddressSchema,\n from: HexAddressSchema,\n value: HexStringSchema,\n data: HexStringSchema,\n gasLimit: nullable(number()),\n effectiveGas: optional(number()),\n});\n\nexport const BitcoinTradeDataSchema = type({\n unsignedPsbtBase64: string(),\n inputsToSign: nullable(array(type({}))),\n});\n\nexport const TronTradeDataSchema = type({\n raw_data_hex: string(),\n visible: optional(boolean()),\n raw_data: optional(\n nullable(\n type({\n contract: optional(\n array(\n type({\n type: optional(string()),\n }),\n ),\n ),\n fee_limit: optional(number()),\n }),\n ),\n ),\n});\n\nexport const QuoteResponseSchema = type({\n quote: QuoteSchema,\n estimatedProcessingTimeInSeconds: number(),\n approval: optional(union([TxDataSchema, TronTradeDataSchema])),\n trade: union([\n TxDataSchema,\n BitcoinTradeDataSchema,\n TronTradeDataSchema,\n string(),\n ]),\n});\n\nexport const validateQuoteResponse = (\n data: unknown,\n): data is Infer<typeof QuoteResponseSchema> => {\n assert(data, QuoteResponseSchema);\n return true;\n};\n"]}