@allbridge/bridge-core-sdk 3.31.0-alpha.1 → 3.31.0-alpha.2

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":"tokens-info.model.js","sourceRoot":"","sources":["../../../src/tokens-info/tokens-info.model.ts"],"names":[],"mappings":"","sourcesContent":["import { BasicChainProperties } from \"../chains/models\";\nimport { Messenger } from \"../client/core-api/core-api.model\";\n\n/**\n * Type representing a map of blockchain chain symbols to their corresponding details, including token information.\n *\n * @typedef {Record<string, ChainDetailsWithTokens>} ChainDetailsMap\n * @property {string} chainSymbol - The symbol of the chain representing one of the supported blockchain networks (e.g., \"ETH\" for Ethereum). For more details, see: {@link ChainSymbol}.\n * @property {ChainDetailsWithTokens} chainDetails - The detailed information of the specified chain, including token information.\n */\nexport type ChainDetailsMap = Record<string, ChainDetailsWithTokens>;\n\nexport type ChainDetailsMapWithFlags = Record<string, ChainDetailsWithTokensWithFlags>;\n\nexport interface AbrPayerChainInfo {\n /**\n * ABR proxy for paying fees with ABR\n */\n payerAddress: string;\n abrToken: TokenCoreFields;\n /**\n * Availability to pay by abr\n */\n payerAvailability: AbrPayerAvailability;\n}\n\n/**\n * Contains some blockchain details\n */\nexport interface ChainDetails extends BasicChainProperties {\n /**\n * Allbridge's Id\n */\n allbridgeChainId: number;\n /**\n * Algo Bridge appId\n */\n bridgeId?: string;\n /**\n * Algo Padding appId\n */\n paddingUtilId?: string;\n /**\n * Bridge contract address\n */\n bridgeAddress: string;\n /**\n * OFT Bridge contract address\n * Optional. Defined if the chain supports OFT\n */\n oftBridgeAddress?: string;\n /**\n * Yield contract address\n */\n yieldAddress?: string;\n /**\n * ABR payer chain info\n */\n abrPayer?: AbrPayerChainInfo;\n /**\n * Average transfer time to other blockchains\n */\n transferTime: TransferTime;\n /**\n * Transfers costs\n */\n txCostAmount: TxCostAmount;\n /**\n * Number of confirmations required\n */\n confirmations: number;\n /**\n * Sui addresses\n * Optional. Defined for SUI\n */\n suiAddresses?: SuiAddresses;\n}\n\n/**\n * Contains tokens list\n */\nexport interface ChainDetailsWithTokens extends ChainDetails {\n /**\n * Tokens\n */\n tokens: TokenWithChainDetails[];\n}\n\n/**\n * Contains tokens list\n */\nexport interface ChainDetailsWithTokensWithFlags extends ChainDetails {\n /**\n * Tokens\n */\n tokens: TokenWithChainDetailsWithFlags[];\n}\n\n/**\n * Contains token information\n */\nexport interface Token {\n /**\n * Token symbol\n */\n symbol: string;\n /**\n * Token name\n */\n name: string;\n /**\n * Token decimals\n */\n decimals: number;\n /**\n * Token pool address\n */\n poolAddress: string;\n /**\n * Token address\n */\n tokenAddress: string;\n /**\n * Token origin address\n */\n originTokenAddress?: string;\n /**\n * Token CCTP address</br>\n * Optional. Defined if CCTP supported by token\n */\n cctpAddress?: string;\n /**\n * Token CCTP V2 address</br>\n * Optional. Defined if CCTP supported by token\n */\n cctpFeeShare?: string;\n /**\n * Token CCTP address</br>\n * Optional. Defined if CCTP supported by token\n */\n cctpV2Address?: string;\n /**\n * Token CCTP V2 address</br>\n * Optional. Defined if CCTP supported by token\n */\n cctpV2FeeShare?: string;\n /**\n * XReserve bridge configuration for token.\n * Optional. Defined if XReserve supported by token\n */\n xReserve?: XReserveTokenInfo;\n /**\n * Internal identifier for the same token across different chains.\n *\n * Used to link representations of a token deployed on multiple networks (e.g., Ethereum, BSC).\n * Tokens with the same `oftId` are considered to be equivalent.\n *\n * Optional. Defined if OFT supported by token\n */\n oftId?: string;\n /**\n * Token fee share\n */\n feeShare: string;\n /**\n * @Deprecated use {@link apr7d}</br>\n * Token APR\n */\n apr: string;\n /**\n * Token APR based on last 7 days\n */\n apr7d: string;\n /**\n * Token APR based on last 30 days\n */\n apr30d: string;\n /**\n * Token LP rate\n */\n lpRate: string;\n\n yieldId?: number;\n /**\n * Sui addresses\n * Optional. Defined for SUI\n */\n suiAddresses?: SuiAddresses;\n}\n\nexport interface XReserveTokenInfo {\n bridgeAddress: string;\n feeConst: string;\n feeShare: string;\n protocolAddress?: string;\n}\n\nexport interface SuiAddresses {\n bridgeAddress: string;\n bridgeAddressOrigin?: string;\n bridgeObjectAddress: string;\n\n allbridgeMessengerAddress: string;\n allbridgeMessengerAddressOrigin?: string;\n allbridgeMessengerObjectAddress: string;\n\n gasOracleAddress: string;\n gasOracleAddressOrigin?: string;\n gasOracleObjectAddress: string;\n\n utilsAddress: string;\n\n wormholeMessengerAddress: string;\n wormholeMessengerAddressOrigin?: string;\n wormholeMessengerObjectAddress: string;\n wormholeStateObjectAddress: string;\n\n cctpAddress: string;\n cctpAddressOrigin?: string;\n cctpObjectAddress: string;\n\n cctpDenyListObjectAddress: string;\n cctpMessageTransmitterStateObjectAddress: string;\n cctpTokenMessengerMinterStateObjectAddress: string;\n cctpTreasuryObjectAddress: string;\n}\n\n/**\n * General Token Interface\n */\nexport interface TokenWithChainDetails extends Token, Omit<ChainDetails, \"name\"> {\n /**\n * Blockchain network name\n */\n chainName: string;\n}\n\nexport type TokenCoreFields = Pick<\n TokenWithChainDetails,\n \"tokenAddress\" | \"chainSymbol\" | \"decimals\" | \"originTokenAddress\"\n>;\n\nexport interface TokenWithChainDetailsWithFlags extends TokenWithChainDetails {\n flags: { swap: boolean; pool: boolean };\n}\n\n/**\n * General Pool Interface\n */\nexport interface PoolInfo {\n /**\n * Pool A value\n */\n aValue: string;\n /**\n * Pool D value\n */\n dValue: string;\n /**\n * Pool token balance\n */\n tokenBalance: string;\n /**\n * Pool virtual USD balance\n */\n vUsdBalance: string;\n /**\n * Pool total liquidity amount\n */\n totalLpAmount: string;\n /**\n * Current accumulated reward per share shifted by P bits\n */\n accRewardPerShareP: string;\n /**\n * P value, needed for accRewardPerShareP\n */\n p: number;\n /**\n * Pool imbalance\n */\n imbalance: string;\n}\n\nexport type AbrPayerAvailability = Partial<Record<Messenger, boolean>>;\n\n/**\n * Type representing transfer times for various blockchain chains.\n *\n * @typedef {Record<string, MessengerTransferTime>} TransferTime\n * @property {string} chainSymbol - The symbol of the chain representing one of the supported blockchain networks (e.g., \"ETH\" for Ethereum). For more details, see: {@link ChainSymbol}.\n * @property {MessengerTransferTime} transferTime - The average transfer time details for the specified chain.\n */\nexport type TransferTime = Record<string, MessengerTransferTime>;\n\n/**\n * Contains Avg transaction time withing different messenger protocols\n */\nexport type MessengerTransferTime = {\n [messenger in Messenger]?: number;\n};\n\nexport interface PoolKeyObject {\n chainSymbol: string;\n poolAddress: string;\n}\n\n/**\n * Contains transfer costs\n */\nexport interface TxCostAmount {\n /**\n * The maximum gas amount that can be received as extra gas for one transfer\n */\n maxAmount: string;\n /**\n * Swap cost\n */\n swap: string;\n /**\n * Transfer cost\n */\n transfer: string;\n}\n\nexport type PoolInfoMap = Record<string, PoolInfo>;\n"]}
1
+ {"version":3,"file":"tokens-info.model.js","sourceRoot":"","sources":["../../../src/tokens-info/tokens-info.model.ts"],"names":[],"mappings":"","sourcesContent":["import { BasicChainProperties } from \"../chains/models\";\nimport { Messenger } from \"../client/core-api/core-api.model\";\n\n/**\n * Type representing a map of blockchain chain symbols to their corresponding details, including token information.\n *\n * @typedef {Record<string, ChainDetailsWithTokens>} ChainDetailsMap\n * @property {string} chainSymbol - The symbol of the chain representing one of the supported blockchain networks (e.g., \"ETH\" for Ethereum). For more details, see: {@link ChainSymbol}.\n * @property {ChainDetailsWithTokens} chainDetails - The detailed information of the specified chain, including token information.\n */\nexport type ChainDetailsMap = Record<string, ChainDetailsWithTokens>;\n\nexport type ChainDetailsMapWithFlags = Record<string, ChainDetailsWithTokensWithFlags>;\n\nexport interface AbrPayerChainInfo {\n /**\n * ABR proxy for paying fees with ABR\n */\n payerAddress: string;\n abrToken: TokenCoreFields;\n /**\n * Availability to pay by abr\n */\n payerAvailability: AbrPayerAvailability;\n}\n\n/**\n * Contains some blockchain details\n */\nexport interface ChainDetails extends BasicChainProperties {\n /**\n * Allbridge's Id\n */\n allbridgeChainId: number;\n /**\n * Algo Bridge appId\n */\n bridgeId?: string;\n /**\n * Algo Padding appId\n */\n paddingUtilId?: string;\n /**\n * Bridge contract address\n */\n bridgeAddress: string;\n /**\n * OFT Bridge contract address\n * Optional. Defined if the chain supports OFT\n */\n oftBridgeAddress?: string;\n /**\n * Yield contract address\n */\n yieldAddress?: string;\n /**\n * ABR payer chain info\n */\n abrPayer?: AbrPayerChainInfo;\n /**\n * Average transfer time to other blockchains\n */\n transferTime: TransferTime;\n /**\n * Transfers costs\n */\n txCostAmount: TxCostAmount;\n /**\n * Number of confirmations required\n */\n confirmations: number;\n /**\n * Sui addresses\n * Optional. Defined for SUI\n */\n suiAddresses?: SuiAddresses;\n}\n\n/**\n * Contains tokens list\n */\nexport interface ChainDetailsWithTokens extends ChainDetails {\n /**\n * Tokens\n */\n tokens: TokenWithChainDetails[];\n}\n\n/**\n * Contains tokens list\n */\nexport interface ChainDetailsWithTokensWithFlags extends ChainDetails {\n /**\n * Tokens\n */\n tokens: TokenWithChainDetailsWithFlags[];\n}\n\n/**\n * Contains token information\n */\nexport interface Token {\n /**\n * Token symbol\n */\n symbol: string;\n /**\n * Token name\n */\n name: string;\n /**\n * Token decimals\n */\n decimals: number;\n /**\n * Token pool address\n */\n poolAddress: string;\n /**\n * Token address\n */\n tokenAddress: string;\n /**\n * Token origin address\n */\n originTokenAddress?: string;\n /**\n * Token CCTP address</br>\n * Optional. Defined if the token is supported by CCTP\n */\n cctpAddress?: string;\n /**\n * Token fee share for CCTP</br>\n * Optional. Defined if the token is supported by CCTP\n */\n cctpFeeShare?: string;\n /**\n * Token CCTP address</br>\n * Optional. Defined if the token is supported by CCTP\n */\n cctpV2Address?: string;\n /**\n * Token fee share for CCTP V2</br>\n * Optional. Defined if the token is supported by CCTP\n */\n cctpV2FeeShare?: string;\n /**\n * XReserve bridge configuration for token.\n * Optional. Defined if the token is supported by XReserve\n */\n xReserve?: XReserveTokenInfo;\n /**\n * Internal identifier for the same token across different chains.\n *\n * Used to link representations of a token deployed on multiple networks (e.g., Ethereum, BSC).\n * Tokens with the same `oftId` are considered to be equivalent.\n *\n * Optional. Defined if the token is supported by OFT\n */\n oftId?: string;\n /**\n * Token fee share\n */\n feeShare: string;\n /**\n * @Deprecated use {@link apr7d}</br>\n * Token APR\n */\n apr: string;\n /**\n * Token APR based on last 7 days\n */\n apr7d: string;\n /**\n * Token APR based on last 30 days\n */\n apr30d: string;\n /**\n * Token LP rate\n */\n lpRate: string;\n\n yieldId?: number;\n /**\n * Sui addresses\n * Optional. Defined for SUI\n */\n suiAddresses?: SuiAddresses;\n}\n\nexport interface XReserveTokenInfo {\n bridgeAddress: string;\n feeConst: string;\n feeShare: string;\n protocolAddress?: string;\n}\n\nexport interface SuiAddresses {\n bridgeAddress: string;\n bridgeAddressOrigin?: string;\n bridgeObjectAddress: string;\n\n allbridgeMessengerAddress: string;\n allbridgeMessengerAddressOrigin?: string;\n allbridgeMessengerObjectAddress: string;\n\n gasOracleAddress: string;\n gasOracleAddressOrigin?: string;\n gasOracleObjectAddress: string;\n\n utilsAddress: string;\n\n wormholeMessengerAddress: string;\n wormholeMessengerAddressOrigin?: string;\n wormholeMessengerObjectAddress: string;\n wormholeStateObjectAddress: string;\n\n cctpAddress: string;\n cctpAddressOrigin?: string;\n cctpObjectAddress: string;\n\n cctpDenyListObjectAddress: string;\n cctpMessageTransmitterStateObjectAddress: string;\n cctpTokenMessengerMinterStateObjectAddress: string;\n cctpTreasuryObjectAddress: string;\n}\n\n/**\n * General Token Interface\n */\nexport interface TokenWithChainDetails extends Token, Omit<ChainDetails, \"name\"> {\n /**\n * Blockchain network name\n */\n chainName: string;\n}\n\nexport type TokenCoreFields = Pick<\n TokenWithChainDetails,\n \"tokenAddress\" | \"chainSymbol\" | \"decimals\" | \"originTokenAddress\"\n>;\n\nexport interface TokenWithChainDetailsWithFlags extends TokenWithChainDetails {\n flags: { swap: boolean; pool: boolean };\n}\n\n/**\n * General Pool Interface\n */\nexport interface PoolInfo {\n /**\n * Pool A value\n */\n aValue: string;\n /**\n * Pool D value\n */\n dValue: string;\n /**\n * Pool token balance\n */\n tokenBalance: string;\n /**\n * Pool virtual USD balance\n */\n vUsdBalance: string;\n /**\n * Pool total liquidity amount\n */\n totalLpAmount: string;\n /**\n * Current accumulated reward per share shifted by P bits\n */\n accRewardPerShareP: string;\n /**\n * P value, needed for accRewardPerShareP\n */\n p: number;\n /**\n * Pool imbalance\n */\n imbalance: string;\n}\n\nexport type AbrPayerAvailability = Partial<Record<Messenger, boolean>>;\n\n/**\n * Type representing transfer times for various blockchain chains.\n *\n * @typedef {Record<string, MessengerTransferTime>} TransferTime\n * @property {string} chainSymbol - The symbol of the chain representing one of the supported blockchain networks (e.g., \"ETH\" for Ethereum). For more details, see: {@link ChainSymbol}.\n * @property {MessengerTransferTime} transferTime - The average transfer time details for the specified chain.\n */\nexport type TransferTime = Record<string, MessengerTransferTime>;\n\n/**\n * Contains Avg transaction time withing different messenger protocols\n */\nexport type MessengerTransferTime = {\n [messenger in Messenger]?: number;\n};\n\nexport interface PoolKeyObject {\n chainSymbol: string;\n poolAddress: string;\n}\n\n/**\n * Contains transfer costs\n */\nexport interface TxCostAmount {\n /**\n * The maximum gas amount that can be received as extra gas for one transfer\n */\n maxAmount: string;\n /**\n * Swap cost\n */\n swap: string;\n /**\n * Transfer cost\n */\n transfer: string;\n}\n\nexport type PoolInfoMap = Record<string, PoolInfo>;\n"]}
@@ -1 +1 @@
1
- export declare const VERSION = "3.31.0-alpha.1";
1
+ export declare const VERSION = "3.31.0-alpha.2";
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = "3.31.0-alpha.1";
4
+ exports.VERSION = "3.31.0-alpha.2";
5
5
  //# sourceMappingURL=version.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"version.js","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":";;;AAAa,QAAA,OAAO,GAAG,gBAAgB,CAAC","sourcesContent":["export const VERSION = \"3.31.0-alpha.1\";\n"]}
1
+ {"version":3,"file":"version.js","sourceRoot":"","sources":["../../src/version.ts"],"names":[],"mappings":";;;AAAa,QAAA,OAAO,GAAG,gBAAgB,CAAC","sourcesContent":["export const VERSION = \"3.31.0-alpha.2\";\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@allbridge/bridge-core-sdk",
3
- "version": "3.31.0-alpha.1",
3
+ "version": "3.31.0-alpha.2",
4
4
  "main": "./dist/cjs/index.js",
5
5
  "module": "./dist/esm/index.js",
6
6
  "types": "./dist/src/index.d.ts",