@gmx-io/sdk 1.4.2 → 1.5.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.
- package/build/cjs/scripts/generate-platform-tokens.js +200 -0
- package/build/cjs/scripts/prebuild/index.js +6 -1
- package/build/cjs/scripts/prebuild/prebuildKinkModelMarketRatesKeys.js +2 -28
- package/build/cjs/scripts/prebuild/prebuildMarketConfigKeys.js +2 -2
- package/build/cjs/scripts/prebuild/prebuildMarketValuesKeys.js +2 -2
- package/build/cjs/scripts/subsquid-codegen.js +26 -0
- package/build/cjs/src/{utils → clients/v1}/callContract.js +4 -6
- package/build/cjs/src/{index.js → clients/v1/index.js} +4 -4
- package/build/cjs/src/{modules → clients/v1/modules}/accounts/accounts.js +1 -1
- package/build/cjs/src/{modules → clients/v1/modules}/accounts/accounts.spec.js +1 -1
- package/build/cjs/src/clients/v1/modules/markets/index.js +227 -0
- package/build/cjs/src/{modules → clients/v1/modules}/markets/markets.spec.js +3 -3
- package/build/cjs/src/{modules → clients/v1/modules}/oracle.js +1 -1
- package/build/cjs/src/{modules → clients/v1/modules}/orders/helpers.js +9 -9
- package/build/cjs/src/{modules → clients/v1/modules}/orders/helpers.spec.js +5 -5
- package/build/cjs/src/{modules → clients/v1/modules}/orders/orders.js +14 -14
- package/build/cjs/src/{modules → clients/v1/modules}/orders/orders.spec.js +1 -1
- package/build/cjs/src/{modules → clients/v1/modules}/orders/transactions/cancelOrdersTxn.js +2 -2
- package/build/cjs/src/{modules → clients/v1/modules}/orders/transactions/createDecreaseOrderTxn.js +7 -7
- package/build/cjs/src/{modules → clients/v1/modules}/orders/transactions/createIncreaseOrderTxn.js +11 -11
- package/build/cjs/src/{modules → clients/v1/modules}/orders/transactions/createSwapOrderTxn.js +10 -10
- package/build/cjs/src/{modules → clients/v1/modules}/orders/transactions/createWrapOrUnwrapTxn.js +2 -2
- package/build/cjs/src/{modules → clients/v1/modules}/orders/transactions/updateOrderTxn.js +3 -3
- package/build/cjs/src/{modules → clients/v1/modules}/orders/utils.js +7 -7
- package/build/cjs/src/{modules → clients/v1/modules}/positions/positions.js +16 -158
- package/build/cjs/src/{modules → clients/v1/modules}/positions/positions.spec.js +1 -1
- package/build/cjs/src/{modules → clients/v1/modules}/tokens/tokens.js +3 -3
- package/build/cjs/src/{modules → clients/v1/modules}/tokens/tokens.spec.js +3 -3
- package/build/cjs/src/{modules → clients/v1/modules}/trades/trades.js +19 -19
- package/build/cjs/src/{modules → clients/v1/modules}/trades/trades.spec.js +1 -1
- package/build/cjs/src/{modules → clients/v1/modules}/utils/utils.js +8 -8
- package/build/cjs/src/{utils → clients/v1}/multicall.js +2 -2
- package/build/cjs/src/{utils → clients/v1}/simulateExecuteOrder.js +5 -5
- package/build/cjs/src/{utils → clients/v1}/testUtil.js +2 -2
- package/build/cjs/src/clients/v2/index.js +29 -0
- package/build/cjs/src/codegen/platformTokens.json +134 -0
- package/build/cjs/src/{prebuilt → codegen/prebuilt}/hashedKinkModelMarketRatesKeys.json +24 -0
- package/build/cjs/src/{prebuilt → codegen/prebuilt}/hashedMarketConfigKeys.json +171 -0
- package/build/cjs/src/{prebuilt → codegen/prebuilt}/hashedMarketValuesKeys.json +45 -0
- package/build/cjs/src/codegen/prebuilt/index.js +16 -0
- package/build/cjs/src/{types → codegen}/subsquid.js +142 -22
- package/build/cjs/src/configs/api.js +15 -0
- package/build/cjs/src/configs/chains.js +29 -1
- package/build/cjs/src/configs/dataStore.js +6 -2
- package/build/cjs/src/configs/markets.js +21 -0
- package/build/cjs/src/configs/multichain.js +29 -19
- package/build/cjs/src/configs/tokens.js +36 -0
- package/build/cjs/src/test/mock.js +5 -122
- package/build/cjs/src/utils/24h/index.js +17 -0
- package/build/cjs/src/utils/LruCache/index.js +17 -0
- package/build/cjs/src/utils/__tests__/fees.spec.js +2 -2
- package/build/cjs/src/utils/__tests__/numbers.spec.js +1 -1
- package/build/cjs/src/utils/__tests__/orderTransactions/batchUtils.spec.js +3 -3
- package/build/cjs/src/utils/__tests__/orderTransactions/decreaseOrders.spec.js +34 -34
- package/build/cjs/src/utils/__tests__/orderTransactions/exchangeRouterMulticall.spec.js +5 -5
- package/build/cjs/src/utils/__tests__/orderTransactions/externalCalls.spec.js +1 -1
- package/build/cjs/src/utils/__tests__/orderTransactions/increaseOrders.spec.js +29 -29
- package/build/cjs/src/utils/__tests__/orderTransactions/swapOrders.spec.js +21 -21
- package/build/cjs/src/utils/__tests__/orderTransactions/updateOrder.spec.js +4 -4
- package/build/cjs/src/utils/__tests__/parseError.spec.js +40 -0
- package/build/cjs/src/utils/__tests__/positions.spec.js +1 -1
- package/build/cjs/src/utils/__tests__/prices.spec.js +18 -18
- package/build/cjs/src/utils/__tests__/tokens.spec.js +191 -4
- package/build/cjs/src/utils/abort/index.js +17 -0
- package/build/cjs/src/utils/bigmath/index.js +17 -0
- package/build/cjs/src/utils/buildUrl/index.js +17 -0
- package/build/cjs/src/utils/chains/index.js +17 -0
- package/build/cjs/src/utils/common/index.js +17 -0
- package/build/cjs/src/utils/{common.js → common/utils.js} +1 -2
- package/build/cjs/src/utils/errors/parseError.js +67 -25
- package/build/cjs/src/utils/fees/executionFee.js +2 -2
- package/build/cjs/src/utils/fees/index.js +9 -9
- package/build/cjs/src/utils/fees/priceImpact.js +6 -1
- package/build/cjs/src/utils/gelatoRelay/index.js +17 -0
- package/build/cjs/src/utils/graphqlFetcher/index.js +8 -0
- package/build/cjs/src/utils/hash/index.js +17 -0
- package/build/cjs/src/utils/{hash.js → hash/utils.js} +1 -1
- package/build/cjs/src/utils/http/http.js +33 -0
- package/build/cjs/src/utils/indexers/index.js +17 -0
- package/build/cjs/src/utils/{indexers.js → indexers/utils.js} +1 -1
- package/build/cjs/src/utils/markets/__tests__/mockMarkets.js +129 -0
- package/build/cjs/src/utils/markets/api.js +14 -0
- package/build/cjs/src/utils/{marketKeysAndConfigs.js → markets/hashKeys.js} +32 -3
- package/build/cjs/src/utils/markets/index.js +21 -0
- package/build/cjs/src/{modules/markets/query-builders.js → utils/markets/multicall.js} +149 -42
- package/build/cjs/src/utils/markets/utils.js +398 -0
- package/build/cjs/src/utils/numbers/index.js +17 -0
- package/build/cjs/src/utils/{numbers.js → numbers/utils.js} +12 -5
- package/build/cjs/src/utils/objects/index.js +17 -0
- package/build/cjs/src/utils/{objects.js → objects/utils.js} +9 -1
- package/build/cjs/src/utils/orderTransactions/index.js +17 -0
- package/build/cjs/src/utils/{orderTransactions.js → orderTransactions/utils.js} +22 -22
- package/build/cjs/src/utils/orders/api.js +13 -0
- package/build/cjs/src/utils/orders/index.js +19 -0
- package/build/cjs/src/utils/{orders.js → orders/utils.js} +22 -22
- package/build/cjs/src/utils/positions/api.js +14 -0
- package/build/cjs/src/utils/positions/index.js +19 -0
- package/build/cjs/src/utils/positions/utils.js +425 -0
- package/build/cjs/src/utils/prices/index.js +17 -0
- package/build/cjs/src/utils/{prices.js → prices/utils.js} +15 -15
- package/build/cjs/src/utils/referrals/index.js +18 -0
- package/build/cjs/src/utils/sidecarOrders/index.js +17 -0
- package/build/cjs/src/utils/swap/__tests__/mockRouting.spec.js +15 -15
- package/build/cjs/src/utils/swap/__tests__/swapRouting.spec.js +6 -6
- package/build/cjs/src/utils/swap/__tests__/swapStats.spec.js +10 -10
- package/build/cjs/src/utils/swap/botanixStaking.js +3 -3
- package/build/cjs/src/utils/swap/buildSwapStrategy.js +2 -2
- package/build/cjs/src/utils/swap/externalSwapPath.js +2 -2
- package/build/cjs/src/utils/swap/externalSwapQuoteByPath.js +2 -2
- package/build/cjs/src/utils/swap/index.js +12 -0
- package/build/cjs/src/utils/swap/swapPath.js +3 -3
- package/build/cjs/src/utils/swap/swapValues.js +4 -4
- package/build/cjs/src/utils/time/index.js +17 -0
- package/build/cjs/src/utils/tokens/index.js +18 -0
- package/build/cjs/src/utils/{tokens.js → tokens/utils.js} +27 -7
- package/build/cjs/src/utils/trade/decrease.js +8 -8
- package/build/cjs/src/utils/trade/increase.js +2 -2
- package/build/cjs/src/utils/trade/index.js +3 -0
- package/build/cjs/src/utils/trade/trade.js +10 -10
- package/build/cjs/src/utils/tradeHistory/index.js +18 -0
- package/build/cjs/src/utils/{tradeHistory.js → tradeHistory/utils.js} +4 -4
- package/build/cjs/src/utils/twap/index.js +15 -0
- package/build/cjs/src/utils/types/index.js +7 -0
- package/build/esm/scripts/generate-platform-tokens.js +195 -0
- package/build/esm/scripts/prebuild/index.js +3 -1
- package/build/esm/scripts/prebuild/prebuildKinkModelMarketRatesKeys.js +2 -28
- package/build/esm/scripts/prebuild/prebuildMarketConfigKeys.js +1 -1
- package/build/esm/scripts/prebuild/prebuildMarketValuesKeys.js +1 -1
- package/build/esm/scripts/subsquid-codegen.js +24 -0
- package/build/esm/src/{utils → clients/v1}/callContract.js +5 -5
- package/build/esm/src/{index.js → clients/v1/index.js} +4 -4
- package/build/esm/src/{modules → clients/v1/modules}/accounts/accounts.js +1 -1
- package/build/esm/src/{modules → clients/v1/modules}/accounts/accounts.spec.js +1 -1
- package/build/esm/src/clients/v1/modules/markets/index.js +220 -0
- package/build/esm/src/{modules → clients/v1/modules}/markets/markets.spec.js +2 -2
- package/build/esm/src/{modules → clients/v1/modules}/oracle.js +1 -1
- package/build/esm/src/{modules → clients/v1/modules}/orders/helpers.js +6 -6
- package/build/esm/src/{modules → clients/v1/modules}/orders/helpers.spec.js +5 -5
- package/build/esm/src/{modules → clients/v1/modules}/orders/orders.js +7 -7
- package/build/esm/src/{modules → clients/v1/modules}/orders/orders.spec.js +1 -1
- package/build/esm/src/{modules → clients/v1/modules}/orders/transactions/cancelOrdersTxn.js +2 -2
- package/build/esm/src/{modules → clients/v1/modules}/orders/transactions/createDecreaseOrderTxn.js +7 -7
- package/build/esm/src/{modules → clients/v1/modules}/orders/transactions/createIncreaseOrderTxn.js +8 -8
- package/build/esm/src/{modules → clients/v1/modules}/orders/transactions/createSwapOrderTxn.js +7 -7
- package/build/esm/src/{modules → clients/v1/modules}/orders/transactions/createWrapOrUnwrapTxn.js +2 -2
- package/build/esm/src/{modules → clients/v1/modules}/orders/transactions/updateOrderTxn.js +3 -3
- package/build/esm/src/{modules → clients/v1/modules}/orders/utils.js +7 -7
- package/build/esm/src/{modules → clients/v1/modules}/positions/positions.js +16 -158
- package/build/esm/src/{modules → clients/v1/modules}/positions/positions.spec.js +1 -1
- package/build/esm/src/{modules → clients/v1/modules}/tokens/tokens.js +3 -3
- package/build/esm/src/{modules → clients/v1/modules}/tokens/tokens.spec.js +1 -1
- package/build/esm/src/{modules → clients/v1/modules}/trades/trades.js +8 -8
- package/build/esm/src/{modules → clients/v1/modules}/trades/trades.spec.js +1 -1
- package/build/esm/src/{modules → clients/v1/modules}/utils/utils.js +8 -8
- package/build/esm/src/{utils → clients/v1}/multicall.js +2 -2
- package/build/esm/src/{utils → clients/v1}/simulateExecuteOrder.js +5 -5
- package/build/esm/src/{utils → clients/v1}/testUtil.js +2 -2
- package/build/esm/src/clients/v2/index.js +25 -0
- package/build/esm/src/codegen/platformTokens.json +134 -0
- package/build/esm/src/{prebuilt → codegen/prebuilt}/hashedKinkModelMarketRatesKeys.json +24 -0
- package/build/esm/src/{prebuilt → codegen/prebuilt}/hashedMarketConfigKeys.json +171 -0
- package/build/esm/src/{prebuilt → codegen/prebuilt}/hashedMarketValuesKeys.json +45 -0
- package/build/esm/src/codegen/prebuilt/index.js +10 -0
- package/build/esm/src/{types → codegen}/subsquid.js +141 -21
- package/build/esm/src/configs/api.js +11 -0
- package/build/esm/src/configs/chains.js +29 -1
- package/build/esm/src/configs/dataStore.js +3 -0
- package/build/esm/src/configs/markets.js +21 -0
- package/build/esm/src/configs/multichain.js +28 -19
- package/build/esm/src/configs/tokens.js +36 -0
- package/build/esm/src/test/mock.js +3 -120
- package/build/esm/src/utils/24h/index.js +1 -0
- package/build/esm/src/utils/LruCache/index.js +1 -0
- package/build/esm/src/utils/__tests__/fees.spec.js +2 -2
- package/build/esm/src/utils/__tests__/numbers.spec.js +1 -1
- package/build/esm/src/utils/__tests__/orderTransactions/batchUtils.spec.js +2 -2
- package/build/esm/src/utils/__tests__/orderTransactions/decreaseOrders.spec.js +2 -2
- package/build/esm/src/utils/__tests__/orderTransactions/exchangeRouterMulticall.spec.js +2 -2
- package/build/esm/src/utils/__tests__/orderTransactions/externalCalls.spec.js +1 -1
- package/build/esm/src/utils/__tests__/orderTransactions/increaseOrders.spec.js +2 -2
- package/build/esm/src/utils/__tests__/orderTransactions/swapOrders.spec.js +2 -2
- package/build/esm/src/utils/__tests__/orderTransactions/updateOrder.spec.js +2 -2
- package/build/esm/src/utils/__tests__/parseError.spec.js +40 -0
- package/build/esm/src/utils/__tests__/positions.spec.js +1 -1
- package/build/esm/src/utils/__tests__/prices.spec.js +2 -2
- package/build/esm/src/utils/__tests__/tokens.spec.js +192 -5
- package/build/esm/src/utils/abort/index.js +1 -0
- package/build/esm/src/utils/bigmath/index.js +1 -0
- package/build/esm/src/utils/buildUrl/index.js +1 -0
- package/build/esm/src/utils/chains/index.js +1 -0
- package/build/esm/src/utils/common/index.js +1 -0
- package/build/esm/src/utils/{common.js → common/utils.js} +0 -1
- package/build/esm/src/utils/errors/parseError.js +64 -24
- package/build/esm/src/utils/fees/executionFee.js +1 -1
- package/build/esm/src/utils/fees/index.js +7 -7
- package/build/esm/src/utils/fees/priceImpact.js +5 -1
- package/build/esm/src/utils/gelatoRelay/index.js +1 -0
- package/build/esm/src/utils/graphqlFetcher/index.js +1 -0
- package/build/esm/src/utils/hash/index.js +1 -0
- package/build/esm/src/utils/{hash.js → hash/utils.js} +1 -1
- package/build/esm/src/utils/http/http.js +26 -0
- package/build/esm/src/utils/indexers/index.js +1 -0
- package/build/esm/src/utils/{indexers.js → indexers/utils.js} +1 -1
- package/build/esm/src/utils/markets/__tests__/mockMarkets.js +124 -0
- package/build/esm/src/utils/markets/api.js +9 -0
- package/build/esm/src/utils/{marketKeysAndConfigs.js → markets/hashKeys.js} +30 -2
- package/build/esm/src/utils/markets/index.js +5 -0
- package/build/esm/src/{modules/markets/query-builders.js → utils/markets/multicall.js} +146 -41
- package/build/esm/src/utils/markets/utils.js +364 -0
- package/build/esm/src/utils/numbers/index.js +1 -0
- package/build/esm/src/utils/{numbers.js → numbers/utils.js} +10 -3
- package/build/esm/src/utils/objects/index.js +1 -0
- package/build/esm/src/utils/{objects.js → objects/utils.js} +7 -0
- package/build/esm/src/utils/orderTransactions/index.js +1 -0
- package/build/esm/src/utils/{orderTransactions.js → orderTransactions/utils.js} +14 -14
- package/build/esm/src/utils/orders/api.js +9 -0
- package/build/esm/src/utils/orders/index.js +3 -0
- package/build/esm/src/utils/{orders.js → orders/utils.js} +8 -8
- package/build/esm/src/utils/positions/api.js +10 -0
- package/build/esm/src/utils/positions/index.js +3 -0
- package/build/esm/src/utils/positions/utils.js +407 -0
- package/build/esm/src/utils/prices/index.js +1 -0
- package/build/esm/src/utils/{prices.js → prices/utils.js} +7 -7
- package/build/esm/src/utils/referrals/index.js +2 -0
- package/build/esm/src/utils/sidecarOrders/index.js +1 -0
- package/build/esm/src/utils/swap/__tests__/mockRouting.spec.js +2 -2
- package/build/esm/src/utils/swap/__tests__/swapRouting.spec.js +2 -2
- package/build/esm/src/utils/swap/__tests__/swapStats.spec.js +1 -1
- package/build/esm/src/utils/swap/botanixStaking.js +1 -1
- package/build/esm/src/utils/swap/buildSwapStrategy.js +1 -1
- package/build/esm/src/utils/swap/externalSwapPath.js +1 -1
- package/build/esm/src/utils/swap/externalSwapQuoteByPath.js +1 -1
- package/build/esm/src/utils/swap/index.js +12 -0
- package/build/esm/src/utils/swap/swapPath.js +1 -1
- package/build/esm/src/utils/swap/swapValues.js +1 -1
- package/build/esm/src/utils/time/index.js +1 -0
- package/build/esm/src/utils/tokens/index.js +2 -0
- package/build/esm/src/utils/{tokens.js → tokens/utils.js} +27 -7
- package/build/esm/src/utils/trade/decrease.js +1 -1
- package/build/esm/src/utils/trade/increase.js +1 -1
- package/build/esm/src/utils/trade/index.js +3 -0
- package/build/esm/src/utils/trade/trade.js +2 -2
- package/build/esm/src/utils/tradeHistory/index.js +2 -0
- package/build/esm/src/utils/{tradeHistory.js → tradeHistory/utils.js} +4 -4
- package/build/esm/src/utils/twap/index.js +1 -0
- package/build/esm/src/utils/types/index.js +3 -0
- package/build/types/scripts/generate-platform-tokens.d.ts +27 -0
- package/build/types/scripts/subsquid-codegen.d.ts +3 -0
- package/build/types/src/clients/v1/callContract.d.ts +7 -0
- package/build/types/src/{index.d.ts → clients/v1/index.d.ts} +3 -3
- package/build/types/src/{modules → clients/v1/modules}/markets/index.d.ts +12 -1
- package/build/types/src/{modules → clients/v1/modules}/oracle.d.ts +2 -2
- package/build/types/src/{modules → clients/v1/modules}/orders/helpers.d.ts +3 -3
- package/build/types/src/{modules → clients/v1/modules}/orders/orders.d.ts +6 -6
- package/build/types/src/{modules → clients/v1/modules}/orders/transactions/cancelOrdersTxn.d.ts +1 -1
- package/build/types/src/{modules → clients/v1/modules}/orders/transactions/createDecreaseOrderTxn.d.ts +3 -3
- package/build/types/src/{modules → clients/v1/modules}/orders/transactions/createIncreaseOrderTxn.d.ts +4 -4
- package/build/types/src/{modules → clients/v1/modules}/orders/transactions/createSwapOrderTxn.d.ts +2 -2
- package/build/types/src/{modules → clients/v1/modules}/orders/transactions/createWrapOrUnwrapTxn.d.ts +1 -1
- package/build/types/src/{modules → clients/v1/modules}/orders/transactions/updateOrderTxn.d.ts +2 -2
- package/build/types/src/{modules → clients/v1/modules}/orders/utils.d.ts +9 -9
- package/build/types/src/{modules → clients/v1/modules}/positions/positions.d.ts +4 -4
- package/build/types/src/{modules → clients/v1/modules}/tokens/tokens.d.ts +1 -1
- package/build/types/src/{modules → clients/v1/modules}/trades/trades.d.ts +4 -4
- package/build/types/src/{modules → clients/v1/modules}/utils/utils.d.ts +4 -4
- package/build/types/src/{utils → clients/v1}/multicall.d.ts +2 -2
- package/build/types/src/{utils → clients/v1}/simulateExecuteOrder.d.ts +3 -3
- package/build/types/src/{utils → clients/v1}/testUtil.d.ts +2 -2
- package/build/types/src/{types/sdk.d.ts → clients/v1/types.d.ts} +3 -3
- package/build/types/src/clients/v2/index.d.ts +20 -0
- package/build/types/src/codegen/prebuilt/index.d.ts +13876 -0
- package/build/types/src/{types → codegen}/subsquid.d.ts +505 -60
- package/build/types/src/configs/api.d.ts +1 -0
- package/build/types/src/configs/chains.d.ts +26 -2
- package/build/types/src/configs/dataStore.d.ts +1 -0
- package/build/types/src/configs/express.d.ts +1 -1
- package/build/types/src/configs/gasLimits.d.ts +1 -1
- package/build/types/src/configs/markets.d.ts +1 -1
- package/build/types/src/configs/multichain.d.ts +6 -3
- package/build/types/src/configs/tokens.d.ts +1 -1
- package/build/types/src/test/mock.d.ts +3 -7
- package/build/types/src/utils/24h/index.d.ts +1 -0
- package/build/types/src/utils/24h/types.d.ts +7 -0
- package/build/types/src/utils/LruCache/index.d.ts +1 -0
- package/build/types/src/utils/abort/index.d.ts +1 -0
- package/build/types/src/utils/bigmath/index.d.ts +1 -0
- package/build/types/src/utils/buildUrl/index.d.ts +1 -0
- package/build/types/src/utils/chains/index.d.ts +1 -0
- package/build/types/src/utils/common/index.d.ts +1 -0
- package/build/types/src/utils/{common.d.ts → common/utils.d.ts} +0 -1
- package/build/types/src/utils/errors/parseError.d.ts +13 -1
- package/build/types/src/utils/fees/executionFee.d.ts +3 -3
- package/build/types/src/utils/fees/getNaiveEstimatedGasBySwapCount.d.ts +1 -1
- package/build/types/src/utils/fees/index.d.ts +10 -13
- package/build/types/src/utils/fees/priceImpact.d.ts +4 -3
- package/build/types/src/{types/fees.d.ts → utils/fees/types.d.ts} +2 -2
- package/build/types/src/utils/gelatoRelay/index.d.ts +1 -0
- package/build/types/src/utils/graphqlFetcher/index.d.ts +1 -0
- package/build/types/src/utils/hash/index.d.ts +1 -0
- package/build/types/src/utils/http/http.d.ts +9 -0
- package/build/types/src/utils/http/types.d.ts +7 -0
- package/build/types/src/utils/indexers/index.d.ts +1 -0
- package/build/types/src/utils/markets/__tests__/mockMarkets.d.ts +9 -0
- package/build/types/src/utils/markets/api.d.ts +9 -0
- package/build/types/src/utils/markets/hashKeys.d.ts +23 -0
- package/build/types/src/utils/markets/index.d.ts +5 -0
- package/build/types/src/utils/markets/multicall.d.ts +25 -0
- package/build/types/src/{types/markets.d.ts → utils/markets/types.d.ts} +64 -1
- package/build/types/src/utils/markets/utils.d.ts +122 -0
- package/build/types/src/utils/numbers/index.d.ts +1 -0
- package/build/types/src/utils/{numbers.d.ts → numbers/utils.d.ts} +5 -1
- package/build/types/src/utils/objects/index.d.ts +1 -0
- package/build/types/src/utils/{objects.d.ts → objects/utils.d.ts} +1 -0
- package/build/types/src/utils/orderTransactions/index.d.ts +1 -0
- package/build/types/src/utils/{orderTransactions.d.ts → orderTransactions/utils.d.ts} +6 -6
- package/build/types/src/utils/orders/api.d.ts +7 -0
- package/build/types/src/utils/orders/index.d.ts +3 -0
- package/build/types/src/{types/orders.d.ts → utils/orders/types.d.ts} +30 -3
- package/build/types/src/utils/{orders.d.ts → orders/utils.d.ts} +3 -3
- package/build/types/src/utils/positions/api.d.ts +8 -0
- package/build/types/src/utils/positions/index.d.ts +3 -0
- package/build/types/src/{types/positions.d.ts → utils/positions/types.d.ts} +7 -18
- package/build/types/src/utils/{positions.d.ts → positions/utils.d.ts} +45 -4
- package/build/types/src/utils/prices/index.d.ts +1 -0
- package/build/types/src/utils/{prices.d.ts → prices/utils.d.ts} +4 -4
- package/build/types/src/utils/referrals/index.d.ts +2 -0
- package/build/types/src/utils/sidecarOrders/index.d.ts +1 -0
- package/build/types/src/{types/sidecarOrders.d.ts → utils/sidecarOrders/types.d.ts} +2 -2
- package/build/types/src/utils/swap/botanixStaking.d.ts +2 -2
- package/build/types/src/utils/swap/buildSwapStrategy.d.ts +5 -5
- package/build/types/src/utils/swap/externalSwapPath.d.ts +1 -1
- package/build/types/src/utils/swap/externalSwapQuoteByPath.d.ts +1 -1
- package/build/types/src/utils/swap/findSwapPathsBetweenTokens.d.ts +1 -1
- package/build/types/src/utils/swap/index.d.ts +12 -0
- package/build/types/src/utils/swap/preparedSwapData.d.ts +1 -1
- package/build/types/src/utils/swap/swapPath.d.ts +6 -6
- package/build/types/src/utils/swap/swapRouting.d.ts +5 -5
- package/build/types/src/utils/swap/swapStats.d.ts +3 -3
- package/build/types/src/utils/swap/swapValues.d.ts +4 -4
- package/build/types/src/{types/swapStrategy.d.ts → utils/swap/types.d.ts} +1 -1
- package/build/types/src/utils/time/index.d.ts +1 -0
- package/build/types/src/utils/tokens/index.d.ts +2 -0
- package/build/types/src/{types/tokens.d.ts → utils/tokens/types.d.ts} +1 -1
- package/build/types/src/utils/{tokens.d.ts → tokens/utils.d.ts} +2 -2
- package/build/types/src/utils/trade/decrease.d.ts +5 -5
- package/build/types/src/utils/trade/increase.d.ts +5 -5
- package/build/types/src/utils/trade/index.d.ts +3 -0
- package/build/types/src/utils/trade/trade.d.ts +1 -1
- package/build/types/src/{types/trade.d.ts → utils/trade/types.d.ts} +4 -4
- package/build/types/src/utils/tradeHistory/index.d.ts +2 -0
- package/build/types/src/{types/tradeHistory.d.ts → utils/tradeHistory/types.d.ts} +5 -5
- package/build/types/src/utils/{tradeHistory.d.ts → tradeHistory/utils.d.ts} +4 -4
- package/build/types/src/utils/twap/index.d.ts +3 -2
- package/build/types/src/utils/{types.d.ts → types/index.d.ts} +0 -1
- package/package.json +280 -31
- package/build/cjs/src/modules/markets/index.js +0 -366
- package/build/cjs/src/prebuilt/index.js +0 -15
- package/build/cjs/src/utils/markets.js +0 -195
- package/build/cjs/src/utils/positions.js +0 -213
- package/build/cjs/src/utils/types.js +0 -13
- package/build/esm/src/modules/markets/index.js +0 -359
- package/build/esm/src/prebuilt/index.js +0 -7
- package/build/esm/src/utils/markets.js +0 -171
- package/build/esm/src/utils/positions.js +0 -197
- package/build/esm/src/utils/types.js +0 -8
- package/build/types/src/modules/markets/query-builders.d.ts +0 -42
- package/build/types/src/modules/markets/types.d.ts +0 -51
- package/build/types/src/prebuilt/index.d.ts +0 -24
- package/build/types/src/types/common.d.ts +0 -1
- package/build/types/src/utils/callContract.d.ts +0 -17
- package/build/types/src/utils/marketKeysAndConfigs.d.ts +0 -73
- package/build/types/src/utils/markets.d.ts +0 -58
- /package/build/cjs/src/{modules → clients/v1/modules}/base.js +0 -0
- /package/build/cjs/src/{modules/markets → clients/v1}/types.js +0 -0
- /package/build/cjs/src/{types/chains.js → utils/24h/types.js} +0 -0
- /package/build/cjs/src/utils/{LruCache.js → LruCache/utils.js} +0 -0
- /package/build/cjs/src/utils/{abort.js → abort/utils.js} +0 -0
- /package/build/cjs/src/utils/{bigmath.js → bigmath/utils.js} +0 -0
- /package/build/cjs/src/utils/{buildUrl.js → buildUrl/utils.js} +0 -0
- /package/build/cjs/src/{types/common.js → utils/chains/types.js} +0 -0
- /package/build/cjs/src/{types/fees.js → utils/fees/types.js} +0 -0
- /package/build/cjs/src/utils/{gelatoRelay.js → gelatoRelay/utils.js} +0 -0
- /package/build/cjs/src/utils/{graphqlFetcher.js → graphqlFetcher/utils.js} +0 -0
- /package/build/cjs/src/{types/markets.js → utils/http/types.js} +0 -0
- /package/build/cjs/src/{types/positions.js → utils/markets/types.js} +0 -0
- /package/build/cjs/src/{types/orders.js → utils/orders/types.js} +0 -0
- /package/build/cjs/src/{types/sdk.js → utils/positions/types.js} +0 -0
- /package/build/cjs/src/{types/referrals.js → utils/referrals/types.js} +0 -0
- /package/build/cjs/src/utils/{referrals.js → referrals/utils.js} +0 -0
- /package/build/cjs/src/{types/sidecarOrders.js → utils/sidecarOrders/types.js} +0 -0
- /package/build/cjs/src/{types/swapStrategy.js → utils/swap/types.js} +0 -0
- /package/build/cjs/src/utils/{time.js → time/utils.js} +0 -0
- /package/build/cjs/src/{types/tokens.js → utils/tokens/types.js} +0 -0
- /package/build/cjs/src/{types/trade.js → utils/trade/types.js} +0 -0
- /package/build/cjs/src/{types/tradeHistory.js → utils/tradeHistory/types.js} +0 -0
- /package/build/cjs/src/{types/twap.js → utils/twap/types.js} +0 -0
- /package/build/esm/src/{modules → clients/v1/modules}/base.js +0 -0
- /package/build/esm/src/{modules/markets → clients/v1}/types.js +0 -0
- /package/build/esm/src/{types/chains.js → utils/24h/types.js} +0 -0
- /package/build/esm/src/utils/{LruCache.js → LruCache/utils.js} +0 -0
- /package/build/esm/src/utils/{abort.js → abort/utils.js} +0 -0
- /package/build/esm/src/utils/{bigmath.js → bigmath/utils.js} +0 -0
- /package/build/esm/src/utils/{buildUrl.js → buildUrl/utils.js} +0 -0
- /package/build/esm/src/{types/common.js → utils/chains/types.js} +0 -0
- /package/build/esm/src/{types/fees.js → utils/fees/types.js} +0 -0
- /package/build/esm/src/utils/{gelatoRelay.js → gelatoRelay/utils.js} +0 -0
- /package/build/esm/src/utils/{graphqlFetcher.js → graphqlFetcher/utils.js} +0 -0
- /package/build/esm/src/{types/markets.js → utils/http/types.js} +0 -0
- /package/build/esm/src/{types/positions.js → utils/markets/types.js} +0 -0
- /package/build/esm/src/{types/orders.js → utils/orders/types.js} +0 -0
- /package/build/esm/src/{types/sdk.js → utils/positions/types.js} +0 -0
- /package/build/esm/src/{types/referrals.js → utils/referrals/types.js} +0 -0
- /package/build/esm/src/utils/{referrals.js → referrals/utils.js} +0 -0
- /package/build/esm/src/{types/sidecarOrders.js → utils/sidecarOrders/types.js} +0 -0
- /package/build/esm/src/{types/swapStrategy.js → utils/swap/types.js} +0 -0
- /package/build/esm/src/utils/{time.js → time/utils.js} +0 -0
- /package/build/esm/src/{types/tokens.js → utils/tokens/types.js} +0 -0
- /package/build/esm/src/{types/trade.js → utils/trade/types.js} +0 -0
- /package/build/esm/src/{types/tradeHistory.js → utils/tradeHistory/types.js} +0 -0
- /package/build/esm/src/{types/twap.js → utils/twap/types.js} +0 -0
- /package/build/types/src/{modules → clients/v1/modules}/accounts/accounts.d.ts +0 -0
- /package/build/types/src/{modules → clients/v1/modules}/accounts/accounts.spec.d.ts +0 -0
- /package/build/types/src/{modules → clients/v1/modules}/base.d.ts +0 -0
- /package/build/types/src/{modules → clients/v1/modules}/markets/markets.spec.d.ts +0 -0
- /package/build/types/src/{modules → clients/v1/modules}/orders/helpers.spec.d.ts +0 -0
- /package/build/types/src/{modules → clients/v1/modules}/orders/orders.spec.d.ts +0 -0
- /package/build/types/src/{modules → clients/v1/modules}/positions/positions.spec.d.ts +0 -0
- /package/build/types/src/{modules → clients/v1/modules}/tokens/tokens.spec.d.ts +0 -0
- /package/build/types/src/{modules → clients/v1/modules}/trades/trades.spec.d.ts +0 -0
- /package/build/types/src/utils/{LruCache.d.ts → LruCache/utils.d.ts} +0 -0
- /package/build/types/src/utils/{abort.d.ts → abort/utils.d.ts} +0 -0
- /package/build/types/src/utils/{bigmath.d.ts → bigmath/utils.d.ts} +0 -0
- /package/build/types/src/utils/{buildUrl.d.ts → buildUrl/utils.d.ts} +0 -0
- /package/build/types/src/{types/chains.d.ts → utils/chains/types.d.ts} +0 -0
- /package/build/types/src/utils/{gelatoRelay.d.ts → gelatoRelay/utils.d.ts} +0 -0
- /package/build/types/src/utils/{graphqlFetcher.d.ts → graphqlFetcher/utils.d.ts} +0 -0
- /package/build/types/src/utils/{hash.d.ts → hash/utils.d.ts} +0 -0
- /package/build/types/src/utils/{indexers.d.ts → indexers/utils.d.ts} +0 -0
- /package/build/types/src/{types/referrals.d.ts → utils/referrals/types.d.ts} +0 -0
- /package/build/types/src/utils/{referrals.d.ts → referrals/utils.d.ts} +0 -0
- /package/build/types/src/utils/{time.d.ts → time/utils.d.ts} +0 -0
- /package/build/types/src/{types/twap.d.ts → utils/twap/types.d.ts} +0 -0
|
@@ -1876,6 +1876,51 @@
|
|
|
1876
1876
|
"longInterestInTokensUsingShortToken": "0x2dc01b3b85d756baf87d00c973daa5407d890d823b6d0c3e3319969af87c09a7",
|
|
1877
1877
|
"shortInterestInTokensUsingLongToken": "0xbdc14076a36f44c7f3a721b002fbe90479cef53c30049cf42365a196f962978d",
|
|
1878
1878
|
"shortInterestInTokensUsingShortToken": "0x4807b52cfdf6c2cebdc1e028aa6e5ea81dc95ff2d40ac3888f859c3973fdfe1b"
|
|
1879
|
+
},
|
|
1880
|
+
"0xeb28aD1a2e497F4Acc5D9b87e7B496623C93061E": {
|
|
1881
|
+
"longPoolAmount": "0x1467a0ca58bd033427ce20475cdd2146a5b6ff299485de5b886c5db5ae11c172",
|
|
1882
|
+
"shortPoolAmount": "0x9e3a74fda2c49d91656ffb331d11776658be447bdd883306084d57f3f739da94",
|
|
1883
|
+
"positionImpactPoolAmount": "0xc5954c357d418e28002101792d9a99234c6ae88afebfc922507234421fc3104b",
|
|
1884
|
+
"swapImpactPoolAmountLong": "0x934171c5620e093fec4bb7008a9ee50d5a79ebfd3730fde986199b89522f8bf5",
|
|
1885
|
+
"swapImpactPoolAmountShort": "0x1543ac5644aff1a908e3ae693aa1c76b2b6673aa0598c84caa952f6e098eaef3",
|
|
1886
|
+
"longInterestUsingLongToken": "0xf2c3a8eaadecd1ac537e33bb22ac14c127706d1281136582159e58225d4c076a",
|
|
1887
|
+
"longInterestUsingShortToken": "0xa8350cf5bb79a9d49a5fb395930259ffd1a236eac5d89440261732d65a25f392",
|
|
1888
|
+
"shortInterestUsingLongToken": "0xc3fea30bbfa4bb8a15e8887f0b68439fbafe3417447f581d7e8bbda0e6ba880e",
|
|
1889
|
+
"shortInterestUsingShortToken": "0x3b6af920eddbd59ac4bca4bb9a7d3f91bd4c4dc7a83ec88b366a22cdc20cd426",
|
|
1890
|
+
"longInterestInTokensUsingLongToken": "0x271a29586b96afa08a1bfe937e41f0ec9d0f62b5823fc8f7f4227f706f6eed24",
|
|
1891
|
+
"longInterestInTokensUsingShortToken": "0x8f706aef2d39b6b65a9d992f3b6adade9daf5439bfda4887908c2312464ec306",
|
|
1892
|
+
"shortInterestInTokensUsingLongToken": "0xdd9cde1c272d7e80a5c53b13616c3e43754b5024c66933be1cfef9a6e74993ff",
|
|
1893
|
+
"shortInterestInTokensUsingShortToken": "0x0caa9990d4ecfd4edf1098046d4b06baa46490ffc2f4951089ddb412bc7a75f3"
|
|
1894
|
+
},
|
|
1895
|
+
"0x044dFE01863CE85f9ECd5639eE5485c90AC320FC": {
|
|
1896
|
+
"longPoolAmount": "0x4bf0992c5d2cf541db66d59b36ffb1e883c1cc602d029e0973c9c14622c84c07",
|
|
1897
|
+
"shortPoolAmount": "0xd2a8ce3c15aaad24a2efe6772e953c911b80f2e1fff256df0522ff73a0194d01",
|
|
1898
|
+
"positionImpactPoolAmount": "0x12c40a0e5e407ac30f70437ec9031c3151b81735188a53988a88339fecc428a4",
|
|
1899
|
+
"swapImpactPoolAmountLong": "0x1432126a23273a829380ed2e00b947b6f570505a7cca6d02d087503336ecd456",
|
|
1900
|
+
"swapImpactPoolAmountShort": "0xeec716206ddc3fac7ced2379a78d106fc52951ac85946bca98092b3e935e149e",
|
|
1901
|
+
"longInterestUsingLongToken": "0x647d62333bd375890ce5799e7e7d47f78fe9388a48add9cafa65dda86515b393",
|
|
1902
|
+
"longInterestUsingShortToken": "0x4c9f65dced667d3cc59b53ae23d0734190e0f7abf8c70d5638a07e550b7f3f19",
|
|
1903
|
+
"shortInterestUsingLongToken": "0x85a241124f20f03eb0a265a995565484e0d6110c5e6ec4ca854280a9e11255ff",
|
|
1904
|
+
"shortInterestUsingShortToken": "0xf72dec4a533fb6a594ed7e4347e70a215ca20501881962a44149dfce9b20a2d5",
|
|
1905
|
+
"longInterestInTokensUsingLongToken": "0x976de6ccbb8dc799cd340b2d4373da665a4d0270ca67dee880ddcbcbe5374c13",
|
|
1906
|
+
"longInterestInTokensUsingShortToken": "0x3d1b3cb5f532caa312552f39dd9daeca0045f3ce7f79cb10a816dee3857f5c97",
|
|
1907
|
+
"shortInterestInTokensUsingLongToken": "0x6ab7a7ae8ef78d66eb7a6ca76d7ff649371dc62c54b8f508b3500300b7b32092",
|
|
1908
|
+
"shortInterestInTokensUsingShortToken": "0x8e1c3bfa64049ac133fea2eb5087a2e924d3631243fa4cadfbe29fe8eadb6514"
|
|
1909
|
+
},
|
|
1910
|
+
"0x5ff52BE1968107D7886a8E9A64874A45c8F5D96a": {
|
|
1911
|
+
"longPoolAmount": "0x024907819809cd43c72a6a4833f33b1869840bd76bec0e31ab2cf08d0f19ff0b",
|
|
1912
|
+
"shortPoolAmount": "0x8e42ed2ba273e13d3c8e6c11381728642b01d4ab62f37acf94ea3ebdb57740e8",
|
|
1913
|
+
"positionImpactPoolAmount": "0xc33c916b124dbf517fb0bfb710757c27dc6ec1e4b03efc2bcde5c1b4aa1c3b72",
|
|
1914
|
+
"swapImpactPoolAmountLong": "0x83665ca0edbf1565f2f133280f5c73934f00433c57f6d6c304e9c16832d1f772",
|
|
1915
|
+
"swapImpactPoolAmountShort": "0xaf9bfce6eb82448e84e37277210d83e0fc1524db9c0a03531acf7728f1c18e85",
|
|
1916
|
+
"longInterestUsingLongToken": "0xd940c419b28f864e3b162fc087831785096ba12b653181637f8d8dc0830242fe",
|
|
1917
|
+
"longInterestUsingShortToken": "0x5f8c26d4bcc28b308b2443fba71efb9b72184934393fefe650bbadd6618f4b67",
|
|
1918
|
+
"shortInterestUsingLongToken": "0x34270c9a363217c8a4b0cc117207b58fd0bd2aa08d39a6c5fbc2497ae7c75877",
|
|
1919
|
+
"shortInterestUsingShortToken": "0xe27ef4a387cd77b6830adf276ef939af126a4a2366f827e6d29c547bcd4b318b",
|
|
1920
|
+
"longInterestInTokensUsingLongToken": "0x7eff661f177aca8caa364bfa03b55ac5ba27df637f2fd4d8c066d575e1c8849f",
|
|
1921
|
+
"longInterestInTokensUsingShortToken": "0x304a988d2a21904b0de78f1e71fb803b4a070e4072eba7a2b7ca9c0e4f99bcbd",
|
|
1922
|
+
"shortInterestInTokensUsingLongToken": "0x529852b72b88323b98314e361c5fb21846b2c64fc5f9cf7ab9b92cd6d23a9f36",
|
|
1923
|
+
"shortInterestInTokensUsingShortToken": "0xd8b7ef7743b28c9a6b650fc6015d93312c5030d7b96cc8ee073e3ada0d08cab4"
|
|
1879
1924
|
}
|
|
1880
1925
|
},
|
|
1881
1926
|
"43113": {
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.HASHED_KINK_MODEL_MARKET_RATES_KEYS = exports.HASHED_MARKET_CONFIG_KEYS = exports.HASHED_MARKET_VALUES_KEYS = void 0;
|
|
7
|
+
/**
|
|
8
|
+
* Json files in this directory are prebuild by scripts from the `scripts/prebuild` directory.
|
|
9
|
+
* No need to edit them manually, use `yarn run prebuild` command instead.
|
|
10
|
+
*/
|
|
11
|
+
const hashedKinkModelMarketRatesKeys_json_1 = __importDefault(require("./hashedKinkModelMarketRatesKeys.json"));
|
|
12
|
+
const hashedMarketConfigKeys_json_1 = __importDefault(require("./hashedMarketConfigKeys.json"));
|
|
13
|
+
const hashedMarketValuesKeys_json_1 = __importDefault(require("./hashedMarketValuesKeys.json"));
|
|
14
|
+
exports.HASHED_MARKET_VALUES_KEYS = hashedMarketValuesKeys_json_1.default;
|
|
15
|
+
exports.HASHED_MARKET_CONFIG_KEYS = hashedMarketConfigKeys_json_1.default;
|
|
16
|
+
exports.HASHED_KINK_MODEL_MARKET_RATES_KEYS = hashedKinkModelMarketRatesKeys_json_1.default;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.VolumeInfoOrderByInput = exports.TransactionOrderByInput = exports.TradeActionOrderByInput = exports.SwapVolumeInfoOrderByInput = exports.SwapInfoOrderByInput = exports.SwapFeesInfoOrderByInput = exports.ProcessorStatusOrderByInput = exports.PriceType = exports.PriceOrderByInput = exports.PositionVolumeInfoOrderByInput = exports.PositionOrderByInput = exports.PositionFeesEntityType = exports.PositionFeesEntityOrderByInput = exports.PositionChangeType = exports.PositionChangeOrderByInput = exports.PnlAprSnapshotOrderByInput = exports.PlatformStatsOrderByInput = exports.OrderStatus = exports.OrderOrderByInput = exports.OnChainSettingType = exports.OnChainSettingOrderByInput = exports.
|
|
3
|
+
exports.VolumeInfoOrderByInput = exports.TransactionOrderByInput = exports.TradeActionOrderByInput = exports.SwapVolumeInfoOrderByInput = exports.SwapInfoOrderByInput = exports.SwapFeesInfoWithPeriodOrderByInput = exports.SwapFeesInfoOrderByInput = exports.ProcessorStatusOrderByInput = exports.PriceType = exports.PriceOrderByInput = exports.PositionVolumeInfoOrderByInput = exports.PositionOrderByInput = exports.PositionFeesInfoWithPeriodOrderByInput = exports.PositionFeesEntityType = exports.PositionFeesEntityOrderByInput = exports.PositionChangeType = exports.PositionChangeOrderByInput = exports.PnlAprSnapshotOrderByInput = exports.PlatformStatsOrderByInput = exports.OrderStatus = exports.OrderOrderByInput = exports.OnChainSettingType = exports.OnChainSettingOrderByInput = exports.MultichainSamechainFundingEventOrderByInput = exports.MultichainFundingSendEventOrderByInput = exports.MultichainFundingReceiveEventOrderByInput = exports.MultichainFundingOperation = exports.MarketOrderByInput = exports.MarketInfoOrderByInput = exports.GlvOrderByInput = exports.EntityType = exports.DistributionOrderByInput = exports.CumulativePoolValueOrderByInput = exports.CumulativePnlOrderByInput = exports.CollectedFeesInfoOrderByInput = exports.ClaimableFundingFeeInfoOrderByInput = exports.ClaimableCollateralOrderByInput = exports.ClaimableCollateralGroupOrderByInput = exports.ClaimableAmountOrderByInput = exports.ClaimRefOrderByInput = exports.ClaimActionType = exports.ClaimActionOrderByInput = exports.BorrowingRateSnapshotOrderByInput = exports.AprSnapshotOrderByInput = exports.AccountStatOrderByInput = void 0;
|
|
4
4
|
var AccountStatOrderByInput;
|
|
5
5
|
(function (AccountStatOrderByInput) {
|
|
6
6
|
AccountStatOrderByInput["closedCount_ASC"] = "closedCount_ASC";
|
|
@@ -1471,27 +1471,51 @@ var MultichainFundingSendEventOrderByInput;
|
|
|
1471
1471
|
MultichainFundingSendEventOrderByInput["txn_DESC_NULLS_FIRST"] = "txn_DESC_NULLS_FIRST";
|
|
1472
1472
|
MultichainFundingSendEventOrderByInput["txn_DESC_NULLS_LAST"] = "txn_DESC_NULLS_LAST";
|
|
1473
1473
|
})(MultichainFundingSendEventOrderByInput || (exports.MultichainFundingSendEventOrderByInput = MultichainFundingSendEventOrderByInput = {}));
|
|
1474
|
-
var
|
|
1475
|
-
(function (
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1474
|
+
var MultichainSamechainFundingEventOrderByInput;
|
|
1475
|
+
(function (MultichainSamechainFundingEventOrderByInput) {
|
|
1476
|
+
MultichainSamechainFundingEventOrderByInput["account_ASC"] = "account_ASC";
|
|
1477
|
+
MultichainSamechainFundingEventOrderByInput["account_ASC_NULLS_FIRST"] = "account_ASC_NULLS_FIRST";
|
|
1478
|
+
MultichainSamechainFundingEventOrderByInput["account_ASC_NULLS_LAST"] = "account_ASC_NULLS_LAST";
|
|
1479
|
+
MultichainSamechainFundingEventOrderByInput["account_DESC"] = "account_DESC";
|
|
1480
|
+
MultichainSamechainFundingEventOrderByInput["account_DESC_NULLS_FIRST"] = "account_DESC_NULLS_FIRST";
|
|
1481
|
+
MultichainSamechainFundingEventOrderByInput["account_DESC_NULLS_LAST"] = "account_DESC_NULLS_LAST";
|
|
1482
|
+
MultichainSamechainFundingEventOrderByInput["amount_ASC"] = "amount_ASC";
|
|
1483
|
+
MultichainSamechainFundingEventOrderByInput["amount_ASC_NULLS_FIRST"] = "amount_ASC_NULLS_FIRST";
|
|
1484
|
+
MultichainSamechainFundingEventOrderByInput["amount_ASC_NULLS_LAST"] = "amount_ASC_NULLS_LAST";
|
|
1485
|
+
MultichainSamechainFundingEventOrderByInput["amount_DESC"] = "amount_DESC";
|
|
1486
|
+
MultichainSamechainFundingEventOrderByInput["amount_DESC_NULLS_FIRST"] = "amount_DESC_NULLS_FIRST";
|
|
1487
|
+
MultichainSamechainFundingEventOrderByInput["amount_DESC_NULLS_LAST"] = "amount_DESC_NULLS_LAST";
|
|
1488
|
+
MultichainSamechainFundingEventOrderByInput["id_ASC"] = "id_ASC";
|
|
1489
|
+
MultichainSamechainFundingEventOrderByInput["id_ASC_NULLS_FIRST"] = "id_ASC_NULLS_FIRST";
|
|
1490
|
+
MultichainSamechainFundingEventOrderByInput["id_ASC_NULLS_LAST"] = "id_ASC_NULLS_LAST";
|
|
1491
|
+
MultichainSamechainFundingEventOrderByInput["id_DESC"] = "id_DESC";
|
|
1492
|
+
MultichainSamechainFundingEventOrderByInput["id_DESC_NULLS_FIRST"] = "id_DESC_NULLS_FIRST";
|
|
1493
|
+
MultichainSamechainFundingEventOrderByInput["id_DESC_NULLS_LAST"] = "id_DESC_NULLS_LAST";
|
|
1494
|
+
MultichainSamechainFundingEventOrderByInput["operation_ASC"] = "operation_ASC";
|
|
1495
|
+
MultichainSamechainFundingEventOrderByInput["operation_ASC_NULLS_FIRST"] = "operation_ASC_NULLS_FIRST";
|
|
1496
|
+
MultichainSamechainFundingEventOrderByInput["operation_ASC_NULLS_LAST"] = "operation_ASC_NULLS_LAST";
|
|
1497
|
+
MultichainSamechainFundingEventOrderByInput["operation_DESC"] = "operation_DESC";
|
|
1498
|
+
MultichainSamechainFundingEventOrderByInput["operation_DESC_NULLS_FIRST"] = "operation_DESC_NULLS_FIRST";
|
|
1499
|
+
MultichainSamechainFundingEventOrderByInput["operation_DESC_NULLS_LAST"] = "operation_DESC_NULLS_LAST";
|
|
1500
|
+
MultichainSamechainFundingEventOrderByInput["timestamp_ASC"] = "timestamp_ASC";
|
|
1501
|
+
MultichainSamechainFundingEventOrderByInput["timestamp_ASC_NULLS_FIRST"] = "timestamp_ASC_NULLS_FIRST";
|
|
1502
|
+
MultichainSamechainFundingEventOrderByInput["timestamp_ASC_NULLS_LAST"] = "timestamp_ASC_NULLS_LAST";
|
|
1503
|
+
MultichainSamechainFundingEventOrderByInput["timestamp_DESC"] = "timestamp_DESC";
|
|
1504
|
+
MultichainSamechainFundingEventOrderByInput["timestamp_DESC_NULLS_FIRST"] = "timestamp_DESC_NULLS_FIRST";
|
|
1505
|
+
MultichainSamechainFundingEventOrderByInput["timestamp_DESC_NULLS_LAST"] = "timestamp_DESC_NULLS_LAST";
|
|
1506
|
+
MultichainSamechainFundingEventOrderByInput["token_ASC"] = "token_ASC";
|
|
1507
|
+
MultichainSamechainFundingEventOrderByInput["token_ASC_NULLS_FIRST"] = "token_ASC_NULLS_FIRST";
|
|
1508
|
+
MultichainSamechainFundingEventOrderByInput["token_ASC_NULLS_LAST"] = "token_ASC_NULLS_LAST";
|
|
1509
|
+
MultichainSamechainFundingEventOrderByInput["token_DESC"] = "token_DESC";
|
|
1510
|
+
MultichainSamechainFundingEventOrderByInput["token_DESC_NULLS_FIRST"] = "token_DESC_NULLS_FIRST";
|
|
1511
|
+
MultichainSamechainFundingEventOrderByInput["token_DESC_NULLS_LAST"] = "token_DESC_NULLS_LAST";
|
|
1512
|
+
MultichainSamechainFundingEventOrderByInput["txHash_ASC"] = "txHash_ASC";
|
|
1513
|
+
MultichainSamechainFundingEventOrderByInput["txHash_ASC_NULLS_FIRST"] = "txHash_ASC_NULLS_FIRST";
|
|
1514
|
+
MultichainSamechainFundingEventOrderByInput["txHash_ASC_NULLS_LAST"] = "txHash_ASC_NULLS_LAST";
|
|
1515
|
+
MultichainSamechainFundingEventOrderByInput["txHash_DESC"] = "txHash_DESC";
|
|
1516
|
+
MultichainSamechainFundingEventOrderByInput["txHash_DESC_NULLS_FIRST"] = "txHash_DESC_NULLS_FIRST";
|
|
1517
|
+
MultichainSamechainFundingEventOrderByInput["txHash_DESC_NULLS_LAST"] = "txHash_DESC_NULLS_LAST";
|
|
1518
|
+
})(MultichainSamechainFundingEventOrderByInput || (exports.MultichainSamechainFundingEventOrderByInput = MultichainSamechainFundingEventOrderByInput = {}));
|
|
1495
1519
|
var OnChainSettingOrderByInput;
|
|
1496
1520
|
(function (OnChainSettingOrderByInput) {
|
|
1497
1521
|
OnChainSettingOrderByInput["id_ASC"] = "id_ASC";
|
|
@@ -2224,6 +2248,69 @@ var PositionFeesEntityType;
|
|
|
2224
2248
|
PositionFeesEntityType["PositionFeesCollected"] = "PositionFeesCollected";
|
|
2225
2249
|
PositionFeesEntityType["PositionFeesInfo"] = "PositionFeesInfo";
|
|
2226
2250
|
})(PositionFeesEntityType || (exports.PositionFeesEntityType = PositionFeesEntityType = {}));
|
|
2251
|
+
var PositionFeesInfoWithPeriodOrderByInput;
|
|
2252
|
+
(function (PositionFeesInfoWithPeriodOrderByInput) {
|
|
2253
|
+
PositionFeesInfoWithPeriodOrderByInput["id_ASC"] = "id_ASC";
|
|
2254
|
+
PositionFeesInfoWithPeriodOrderByInput["id_ASC_NULLS_FIRST"] = "id_ASC_NULLS_FIRST";
|
|
2255
|
+
PositionFeesInfoWithPeriodOrderByInput["id_ASC_NULLS_LAST"] = "id_ASC_NULLS_LAST";
|
|
2256
|
+
PositionFeesInfoWithPeriodOrderByInput["id_DESC"] = "id_DESC";
|
|
2257
|
+
PositionFeesInfoWithPeriodOrderByInput["id_DESC_NULLS_FIRST"] = "id_DESC_NULLS_FIRST";
|
|
2258
|
+
PositionFeesInfoWithPeriodOrderByInput["id_DESC_NULLS_LAST"] = "id_DESC_NULLS_LAST";
|
|
2259
|
+
PositionFeesInfoWithPeriodOrderByInput["period_ASC"] = "period_ASC";
|
|
2260
|
+
PositionFeesInfoWithPeriodOrderByInput["period_ASC_NULLS_FIRST"] = "period_ASC_NULLS_FIRST";
|
|
2261
|
+
PositionFeesInfoWithPeriodOrderByInput["period_ASC_NULLS_LAST"] = "period_ASC_NULLS_LAST";
|
|
2262
|
+
PositionFeesInfoWithPeriodOrderByInput["period_DESC"] = "period_DESC";
|
|
2263
|
+
PositionFeesInfoWithPeriodOrderByInput["period_DESC_NULLS_FIRST"] = "period_DESC_NULLS_FIRST";
|
|
2264
|
+
PositionFeesInfoWithPeriodOrderByInput["period_DESC_NULLS_LAST"] = "period_DESC_NULLS_LAST";
|
|
2265
|
+
PositionFeesInfoWithPeriodOrderByInput["timestamp_ASC"] = "timestamp_ASC";
|
|
2266
|
+
PositionFeesInfoWithPeriodOrderByInput["timestamp_ASC_NULLS_FIRST"] = "timestamp_ASC_NULLS_FIRST";
|
|
2267
|
+
PositionFeesInfoWithPeriodOrderByInput["timestamp_ASC_NULLS_LAST"] = "timestamp_ASC_NULLS_LAST";
|
|
2268
|
+
PositionFeesInfoWithPeriodOrderByInput["timestamp_DESC"] = "timestamp_DESC";
|
|
2269
|
+
PositionFeesInfoWithPeriodOrderByInput["timestamp_DESC_NULLS_FIRST"] = "timestamp_DESC_NULLS_FIRST";
|
|
2270
|
+
PositionFeesInfoWithPeriodOrderByInput["timestamp_DESC_NULLS_LAST"] = "timestamp_DESC_NULLS_LAST";
|
|
2271
|
+
PositionFeesInfoWithPeriodOrderByInput["totalBorrowingFeeUsd_ASC"] = "totalBorrowingFeeUsd_ASC";
|
|
2272
|
+
PositionFeesInfoWithPeriodOrderByInput["totalBorrowingFeeUsd_ASC_NULLS_FIRST"] = "totalBorrowingFeeUsd_ASC_NULLS_FIRST";
|
|
2273
|
+
PositionFeesInfoWithPeriodOrderByInput["totalBorrowingFeeUsd_ASC_NULLS_LAST"] = "totalBorrowingFeeUsd_ASC_NULLS_LAST";
|
|
2274
|
+
PositionFeesInfoWithPeriodOrderByInput["totalBorrowingFeeUsd_DESC"] = "totalBorrowingFeeUsd_DESC";
|
|
2275
|
+
PositionFeesInfoWithPeriodOrderByInput["totalBorrowingFeeUsd_DESC_NULLS_FIRST"] = "totalBorrowingFeeUsd_DESC_NULLS_FIRST";
|
|
2276
|
+
PositionFeesInfoWithPeriodOrderByInput["totalBorrowingFeeUsd_DESC_NULLS_LAST"] = "totalBorrowingFeeUsd_DESC_NULLS_LAST";
|
|
2277
|
+
PositionFeesInfoWithPeriodOrderByInput["totalLiquidationFeeAmount_ASC"] = "totalLiquidationFeeAmount_ASC";
|
|
2278
|
+
PositionFeesInfoWithPeriodOrderByInput["totalLiquidationFeeAmount_ASC_NULLS_FIRST"] = "totalLiquidationFeeAmount_ASC_NULLS_FIRST";
|
|
2279
|
+
PositionFeesInfoWithPeriodOrderByInput["totalLiquidationFeeAmount_ASC_NULLS_LAST"] = "totalLiquidationFeeAmount_ASC_NULLS_LAST";
|
|
2280
|
+
PositionFeesInfoWithPeriodOrderByInput["totalLiquidationFeeAmount_DESC"] = "totalLiquidationFeeAmount_DESC";
|
|
2281
|
+
PositionFeesInfoWithPeriodOrderByInput["totalLiquidationFeeAmount_DESC_NULLS_FIRST"] = "totalLiquidationFeeAmount_DESC_NULLS_FIRST";
|
|
2282
|
+
PositionFeesInfoWithPeriodOrderByInput["totalLiquidationFeeAmount_DESC_NULLS_LAST"] = "totalLiquidationFeeAmount_DESC_NULLS_LAST";
|
|
2283
|
+
PositionFeesInfoWithPeriodOrderByInput["totalLiquidationFeeUsd_ASC"] = "totalLiquidationFeeUsd_ASC";
|
|
2284
|
+
PositionFeesInfoWithPeriodOrderByInput["totalLiquidationFeeUsd_ASC_NULLS_FIRST"] = "totalLiquidationFeeUsd_ASC_NULLS_FIRST";
|
|
2285
|
+
PositionFeesInfoWithPeriodOrderByInput["totalLiquidationFeeUsd_ASC_NULLS_LAST"] = "totalLiquidationFeeUsd_ASC_NULLS_LAST";
|
|
2286
|
+
PositionFeesInfoWithPeriodOrderByInput["totalLiquidationFeeUsd_DESC"] = "totalLiquidationFeeUsd_DESC";
|
|
2287
|
+
PositionFeesInfoWithPeriodOrderByInput["totalLiquidationFeeUsd_DESC_NULLS_FIRST"] = "totalLiquidationFeeUsd_DESC_NULLS_FIRST";
|
|
2288
|
+
PositionFeesInfoWithPeriodOrderByInput["totalLiquidationFeeUsd_DESC_NULLS_LAST"] = "totalLiquidationFeeUsd_DESC_NULLS_LAST";
|
|
2289
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeAmountForPool_ASC"] = "totalPositionFeeAmountForPool_ASC";
|
|
2290
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeAmountForPool_ASC_NULLS_FIRST"] = "totalPositionFeeAmountForPool_ASC_NULLS_FIRST";
|
|
2291
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeAmountForPool_ASC_NULLS_LAST"] = "totalPositionFeeAmountForPool_ASC_NULLS_LAST";
|
|
2292
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeAmountForPool_DESC"] = "totalPositionFeeAmountForPool_DESC";
|
|
2293
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeAmountForPool_DESC_NULLS_FIRST"] = "totalPositionFeeAmountForPool_DESC_NULLS_FIRST";
|
|
2294
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeAmountForPool_DESC_NULLS_LAST"] = "totalPositionFeeAmountForPool_DESC_NULLS_LAST";
|
|
2295
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeAmount_ASC"] = "totalPositionFeeAmount_ASC";
|
|
2296
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeAmount_ASC_NULLS_FIRST"] = "totalPositionFeeAmount_ASC_NULLS_FIRST";
|
|
2297
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeAmount_ASC_NULLS_LAST"] = "totalPositionFeeAmount_ASC_NULLS_LAST";
|
|
2298
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeAmount_DESC"] = "totalPositionFeeAmount_DESC";
|
|
2299
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeAmount_DESC_NULLS_FIRST"] = "totalPositionFeeAmount_DESC_NULLS_FIRST";
|
|
2300
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeAmount_DESC_NULLS_LAST"] = "totalPositionFeeAmount_DESC_NULLS_LAST";
|
|
2301
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeUsdForPool_ASC"] = "totalPositionFeeUsdForPool_ASC";
|
|
2302
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeUsdForPool_ASC_NULLS_FIRST"] = "totalPositionFeeUsdForPool_ASC_NULLS_FIRST";
|
|
2303
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeUsdForPool_ASC_NULLS_LAST"] = "totalPositionFeeUsdForPool_ASC_NULLS_LAST";
|
|
2304
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeUsdForPool_DESC"] = "totalPositionFeeUsdForPool_DESC";
|
|
2305
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeUsdForPool_DESC_NULLS_FIRST"] = "totalPositionFeeUsdForPool_DESC_NULLS_FIRST";
|
|
2306
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeUsdForPool_DESC_NULLS_LAST"] = "totalPositionFeeUsdForPool_DESC_NULLS_LAST";
|
|
2307
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeUsd_ASC"] = "totalPositionFeeUsd_ASC";
|
|
2308
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeUsd_ASC_NULLS_FIRST"] = "totalPositionFeeUsd_ASC_NULLS_FIRST";
|
|
2309
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeUsd_ASC_NULLS_LAST"] = "totalPositionFeeUsd_ASC_NULLS_LAST";
|
|
2310
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeUsd_DESC"] = "totalPositionFeeUsd_DESC";
|
|
2311
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeUsd_DESC_NULLS_FIRST"] = "totalPositionFeeUsd_DESC_NULLS_FIRST";
|
|
2312
|
+
PositionFeesInfoWithPeriodOrderByInput["totalPositionFeeUsd_DESC_NULLS_LAST"] = "totalPositionFeeUsd_DESC_NULLS_LAST";
|
|
2313
|
+
})(PositionFeesInfoWithPeriodOrderByInput || (exports.PositionFeesInfoWithPeriodOrderByInput = PositionFeesInfoWithPeriodOrderByInput = {}));
|
|
2227
2314
|
var PositionOrderByInput;
|
|
2228
2315
|
(function (PositionOrderByInput) {
|
|
2229
2316
|
PositionOrderByInput["accountStat_closedCount_ASC"] = "accountStat_closedCount_ASC";
|
|
@@ -2660,6 +2747,39 @@ var SwapFeesInfoOrderByInput;
|
|
|
2660
2747
|
SwapFeesInfoOrderByInput["transaction_transactionIndex_DESC_NULLS_FIRST"] = "transaction_transactionIndex_DESC_NULLS_FIRST";
|
|
2661
2748
|
SwapFeesInfoOrderByInput["transaction_transactionIndex_DESC_NULLS_LAST"] = "transaction_transactionIndex_DESC_NULLS_LAST";
|
|
2662
2749
|
})(SwapFeesInfoOrderByInput || (exports.SwapFeesInfoOrderByInput = SwapFeesInfoOrderByInput = {}));
|
|
2750
|
+
var SwapFeesInfoWithPeriodOrderByInput;
|
|
2751
|
+
(function (SwapFeesInfoWithPeriodOrderByInput) {
|
|
2752
|
+
SwapFeesInfoWithPeriodOrderByInput["id_ASC"] = "id_ASC";
|
|
2753
|
+
SwapFeesInfoWithPeriodOrderByInput["id_ASC_NULLS_FIRST"] = "id_ASC_NULLS_FIRST";
|
|
2754
|
+
SwapFeesInfoWithPeriodOrderByInput["id_ASC_NULLS_LAST"] = "id_ASC_NULLS_LAST";
|
|
2755
|
+
SwapFeesInfoWithPeriodOrderByInput["id_DESC"] = "id_DESC";
|
|
2756
|
+
SwapFeesInfoWithPeriodOrderByInput["id_DESC_NULLS_FIRST"] = "id_DESC_NULLS_FIRST";
|
|
2757
|
+
SwapFeesInfoWithPeriodOrderByInput["id_DESC_NULLS_LAST"] = "id_DESC_NULLS_LAST";
|
|
2758
|
+
SwapFeesInfoWithPeriodOrderByInput["period_ASC"] = "period_ASC";
|
|
2759
|
+
SwapFeesInfoWithPeriodOrderByInput["period_ASC_NULLS_FIRST"] = "period_ASC_NULLS_FIRST";
|
|
2760
|
+
SwapFeesInfoWithPeriodOrderByInput["period_ASC_NULLS_LAST"] = "period_ASC_NULLS_LAST";
|
|
2761
|
+
SwapFeesInfoWithPeriodOrderByInput["period_DESC"] = "period_DESC";
|
|
2762
|
+
SwapFeesInfoWithPeriodOrderByInput["period_DESC_NULLS_FIRST"] = "period_DESC_NULLS_FIRST";
|
|
2763
|
+
SwapFeesInfoWithPeriodOrderByInput["period_DESC_NULLS_LAST"] = "period_DESC_NULLS_LAST";
|
|
2764
|
+
SwapFeesInfoWithPeriodOrderByInput["timestamp_ASC"] = "timestamp_ASC";
|
|
2765
|
+
SwapFeesInfoWithPeriodOrderByInput["timestamp_ASC_NULLS_FIRST"] = "timestamp_ASC_NULLS_FIRST";
|
|
2766
|
+
SwapFeesInfoWithPeriodOrderByInput["timestamp_ASC_NULLS_LAST"] = "timestamp_ASC_NULLS_LAST";
|
|
2767
|
+
SwapFeesInfoWithPeriodOrderByInput["timestamp_DESC"] = "timestamp_DESC";
|
|
2768
|
+
SwapFeesInfoWithPeriodOrderByInput["timestamp_DESC_NULLS_FIRST"] = "timestamp_DESC_NULLS_FIRST";
|
|
2769
|
+
SwapFeesInfoWithPeriodOrderByInput["timestamp_DESC_NULLS_LAST"] = "timestamp_DESC_NULLS_LAST";
|
|
2770
|
+
SwapFeesInfoWithPeriodOrderByInput["totalFeeReceiverUsd_ASC"] = "totalFeeReceiverUsd_ASC";
|
|
2771
|
+
SwapFeesInfoWithPeriodOrderByInput["totalFeeReceiverUsd_ASC_NULLS_FIRST"] = "totalFeeReceiverUsd_ASC_NULLS_FIRST";
|
|
2772
|
+
SwapFeesInfoWithPeriodOrderByInput["totalFeeReceiverUsd_ASC_NULLS_LAST"] = "totalFeeReceiverUsd_ASC_NULLS_LAST";
|
|
2773
|
+
SwapFeesInfoWithPeriodOrderByInput["totalFeeReceiverUsd_DESC"] = "totalFeeReceiverUsd_DESC";
|
|
2774
|
+
SwapFeesInfoWithPeriodOrderByInput["totalFeeReceiverUsd_DESC_NULLS_FIRST"] = "totalFeeReceiverUsd_DESC_NULLS_FIRST";
|
|
2775
|
+
SwapFeesInfoWithPeriodOrderByInput["totalFeeReceiverUsd_DESC_NULLS_LAST"] = "totalFeeReceiverUsd_DESC_NULLS_LAST";
|
|
2776
|
+
SwapFeesInfoWithPeriodOrderByInput["totalFeeUsdForPool_ASC"] = "totalFeeUsdForPool_ASC";
|
|
2777
|
+
SwapFeesInfoWithPeriodOrderByInput["totalFeeUsdForPool_ASC_NULLS_FIRST"] = "totalFeeUsdForPool_ASC_NULLS_FIRST";
|
|
2778
|
+
SwapFeesInfoWithPeriodOrderByInput["totalFeeUsdForPool_ASC_NULLS_LAST"] = "totalFeeUsdForPool_ASC_NULLS_LAST";
|
|
2779
|
+
SwapFeesInfoWithPeriodOrderByInput["totalFeeUsdForPool_DESC"] = "totalFeeUsdForPool_DESC";
|
|
2780
|
+
SwapFeesInfoWithPeriodOrderByInput["totalFeeUsdForPool_DESC_NULLS_FIRST"] = "totalFeeUsdForPool_DESC_NULLS_FIRST";
|
|
2781
|
+
SwapFeesInfoWithPeriodOrderByInput["totalFeeUsdForPool_DESC_NULLS_LAST"] = "totalFeeUsdForPool_DESC_NULLS_LAST";
|
|
2782
|
+
})(SwapFeesInfoWithPeriodOrderByInput || (exports.SwapFeesInfoWithPeriodOrderByInput = SwapFeesInfoWithPeriodOrderByInput = {}));
|
|
2663
2783
|
var SwapInfoOrderByInput;
|
|
2664
2784
|
(function (SwapInfoOrderByInput) {
|
|
2665
2785
|
SwapInfoOrderByInput["amountInAfterFees_ASC"] = "amountInAfterFees_ASC";
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getApiUrl = void 0;
|
|
4
|
+
const chains_1 = require("./chains");
|
|
5
|
+
const API_URLS = {
|
|
6
|
+
[chains_1.ARBITRUM]: "https://gmx-api-arbitrum-dev-ikpem.ondigitalocean.app/api/v1",
|
|
7
|
+
[chains_1.AVALANCHE]: "",
|
|
8
|
+
[chains_1.AVALANCHE_FUJI]: "",
|
|
9
|
+
[chains_1.BOTANIX]: "",
|
|
10
|
+
[chains_1.ARBITRUM_SEPOLIA]: "",
|
|
11
|
+
};
|
|
12
|
+
function getApiUrl(chainId) {
|
|
13
|
+
return API_URLS[chainId];
|
|
14
|
+
}
|
|
15
|
+
exports.getApiUrl = getApiUrl;
|
|
@@ -17,13 +17,17 @@ Object.defineProperty(exports, "SOURCE_SEPOLIA", { enumerable: true, get: functi
|
|
|
17
17
|
exports.CONTRACTS_CHAIN_IDS = [chainIds_1.ARBITRUM, chainIds_1.AVALANCHE, chainIds_1.BOTANIX];
|
|
18
18
|
exports.CONTRACTS_CHAIN_IDS_DEV = [...exports.CONTRACTS_CHAIN_IDS, chainIds_1.AVALANCHE_FUJI, chainIds_1.ARBITRUM_SEPOLIA];
|
|
19
19
|
exports.SETTLEMENT_CHAIN_IDS = [chainIds_1.ARBITRUM, chainIds_1.AVALANCHE];
|
|
20
|
-
exports.SETTLEMENT_CHAIN_IDS_DEV = [...exports.SETTLEMENT_CHAIN_IDS, chainIds_1.ARBITRUM_SEPOLIA];
|
|
20
|
+
exports.SETTLEMENT_CHAIN_IDS_DEV = [...exports.SETTLEMENT_CHAIN_IDS, chainIds_1.ARBITRUM_SEPOLIA, chainIds_1.AVALANCHE_FUJI];
|
|
21
21
|
exports.SOURCE_CHAIN_IDS = [
|
|
22
22
|
chainIds_1.SOURCE_OPTIMISM_SEPOLIA,
|
|
23
23
|
chainIds_1.SOURCE_SEPOLIA,
|
|
24
24
|
chainIds_1.SOURCE_BASE_MAINNET,
|
|
25
25
|
chainIds_1.SOURCE_BSC_MAINNET,
|
|
26
26
|
chainIds_1.SOURCE_ETHEREUM_MAINNET,
|
|
27
|
+
chainIds_1.ARBITRUM_SEPOLIA,
|
|
28
|
+
chainIds_1.ARBITRUM,
|
|
29
|
+
chainIds_1.AVALANCHE,
|
|
30
|
+
chainIds_1.AVALANCHE_FUJI,
|
|
27
31
|
];
|
|
28
32
|
exports.GMX_ACCOUNT_PSEUDO_CHAIN_ID = 0;
|
|
29
33
|
const CONTRACTS_CHAIN_CONFIGS = {
|
|
@@ -159,6 +163,30 @@ const SOURCE_CHAIN_CONFIGS = {
|
|
|
159
163
|
slug: "ethereum-mainnet",
|
|
160
164
|
explorerUrl: "https://etherscan.io/",
|
|
161
165
|
},
|
|
166
|
+
[chainIds_1.ARBITRUM]: {
|
|
167
|
+
chainId: chainIds_1.ARBITRUM,
|
|
168
|
+
name: "Arbitrum",
|
|
169
|
+
slug: "arbitrum",
|
|
170
|
+
explorerUrl: "https://arbiscan.io/",
|
|
171
|
+
},
|
|
172
|
+
[chainIds_1.AVALANCHE]: {
|
|
173
|
+
chainId: chainIds_1.AVALANCHE,
|
|
174
|
+
name: "Avalanche",
|
|
175
|
+
slug: "avalanche",
|
|
176
|
+
explorerUrl: "https://snowtrace.io/",
|
|
177
|
+
},
|
|
178
|
+
[chainIds_1.ARBITRUM_SEPOLIA]: {
|
|
179
|
+
chainId: chainIds_1.ARBITRUM_SEPOLIA,
|
|
180
|
+
name: "Arbitrum Sepolia",
|
|
181
|
+
slug: "arbitrum-sepolia",
|
|
182
|
+
explorerUrl: "https://sepolia.arbiscan.io/",
|
|
183
|
+
},
|
|
184
|
+
[chainIds_1.AVALANCHE_FUJI]: {
|
|
185
|
+
chainId: chainIds_1.AVALANCHE_FUJI,
|
|
186
|
+
name: "Avalanche Fuji",
|
|
187
|
+
slug: "avalanche-fuji",
|
|
188
|
+
explorerUrl: "https://testnet.snowtrace.io/",
|
|
189
|
+
},
|
|
162
190
|
// Use this notation to correctly infer chain names, etc. from config
|
|
163
191
|
};
|
|
164
192
|
const ALL_CHAIN_CONFIGS = {
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.POSITION_IMPACT_POOL_DISTRIBUTION_RATE_KEY = exports.MIN_POSITION_IMPACT_POOL_AMOUNT_KEY = exports.POSITION_IMPACT_POOL_AMOUNT_KEY = exports.LENT_POSITION_IMPACT_POOL_AMOUNT_KEY = exports.MAX_LENDABLE_IMPACT_FACTOR_FOR_WITHDRAWALS_KEY = exports.MAX_LENDABLE_IMPACT_USD_KEY = exports.MAX_LENDABLE_IMPACT_FACTOR_KEY = exports.CLAIMABLE_COLLATERAL_TIME_DIVISOR_KEY = exports.CLAIMABLE_COLLATERAL_REDUCTION_FACTOR_KEY = exports.CLAIMABLE_COLLATERAL_DELAY_KEY = exports.MAX_POSITION_IMPACT_FACTOR_FOR_LIQUIDATIONS_KEY = exports.MAX_PNL_FACTOR_FOR_TRADERS_KEY = exports.MAX_PNL_FACTOR_FOR_DEPOSITS_KEY = exports.MAX_PNL_FACTOR_FOR_WITHDRAWALS_KEY = exports.MAX_PNL_FACTOR_KEY = exports.THRESHOLD_FOR_DECREASE_FUNDING = exports.THRESHOLD_FOR_STABLE_FUNDING = exports.MAX_FUNDING_FACTOR_PER_SECOND = exports.MIN_FUNDING_FACTOR_PER_SECOND = exports.FUNDING_DECREASE_FACTOR_PER_SECOND = exports.FUNDING_INCREASE_FACTOR_PER_SECOND = exports.FUNDING_EXPONENT_FACTOR_KEY = exports.FUNDING_FACTOR_KEY = exports.TOTAL_BORROWING_KEY = exports.CUMULATIVE_BORROWING_FACTOR_KEY = exports.BORROWING_EXPONENT_FACTOR_KEY = exports.BORROWING_FACTOR_KEY = exports.NONCE_KEY = exports.MAX_OPEN_INTEREST_KEY = exports.OPEN_INTEREST_RESERVE_FACTOR_KEY = exports.RESERVE_FACTOR_KEY = exports.MAX_POOL_AMOUNT_KEY = exports.MAX_POOL_USD_FOR_DEPOSIT_KEY = exports.POOL_AMOUNT_KEY = exports.OPEN_INTEREST_IN_TOKENS_KEY = exports.OPEN_INTEREST_KEY = exports.FEE_RECEIVER_POSITION_FACTOR_KEY = exports.FEE_RECEIVER_SWAP_FACTOR_KEY = exports.FEE_RECEIVER_WITHDRAWAL_FACTOR_KEY = exports.BORROWING_FEE_RECEIVER_FACTOR_KEY = exports.FEE_RECEIVER_DEPOSIT_FACTOR_KEY = exports.WITHDRAWAL_FEE_FACTOR_KEY = exports.ATOMIC_SWAP_FEE_FACTOR_KEY = exports.SWAP_FEE_FACTOR_KEY = exports.SWAP_IMPACT_EXPONENT_FACTOR_KEY = exports.SWAP_IMPACT_FACTOR_KEY = exports.POSITION_FEE_FACTOR_KEY = exports.POSITION_IMPACT_EXPONENT_FACTOR_KEY = exports.MAX_POSITION_IMPACT_FACTOR_KEY = exports.POSITION_IMPACT_FACTOR_KEY = void 0;
|
|
4
4
|
exports.SUBACCOUNT_EXPIRES_AT = exports.ABOVE_OPTIMAL_USAGE_BORROWING_FACTOR = exports.BASE_BORROWING_FACTOR = exports.OPTIMAL_USAGE_FACTOR = exports.MAX_AUTO_CANCEL_ORDERS_KEY = exports.GLV_PER_MARKET_GAS_LIMIT = exports.GLV_WITHDRAWAL_GAS_LIMIT = exports.GLV_DEPOSIT_GAS_LIMIT = exports.GLV_SHIFT_MIN_INTERVAL = exports.GLV_SHIFT_LAST_EXECUTED_AT = exports.IS_GLV_MARKET_DISABLED = exports.GLV_MAX_MARKET_TOKEN_BALANCE_AMOUNT = exports.MIN_COLLATERAL_FACTOR_FOR_LIQUIDATION_KEY = exports.GLV_MAX_MARKET_TOKEN_BALANCE_USD = exports.SUBACCOUNT_AUTO_TOP_UP_AMOUNT = exports.SUBACCOUNT_INTEGRATION_ID = exports.SUBACCOUNT_ORDER_ACTION = exports.SUBACCOUNT_ACTION_COUNT = exports.MAX_ALLOWED_SUBACCOUNT_ACTION_COUNT = exports.SUBACCOUNT_LIST_KEY = exports.UI_FEE_FACTOR = exports.IS_MARKET_DISABLED_KEY = exports.AFFILIATE_REWARD_KEY = exports.VIRTUAL_INVENTORY_FOR_SWAPS_KEY = exports.VIRTUAL_INVENTORY_FOR_POSITIONS_KEY = exports.VIRTUAL_MARKET_ID_KEY = exports.VIRTUAL_TOKEN_ID_KEY = exports.CLAIMABLE_FUNDING_AMOUNT = exports.ACCOUNT_ORDER_LIST_KEY = exports.ORDER_LIST_KEY = exports.POSITION_LIST_KEY = exports.MARKET_LIST_KEY = exports.ESTIMATED_GAS_FEE_MULTIPLIER_FACTOR = exports.ESTIMATED_GAS_FEE_PER_ORACLE_PRICE = exports.ESTIMATED_GAS_FEE_BASE_AMOUNT_V2_1 = exports.NATIVE_TOKEN_TRANSFER_GAS_LIMIT_KEY = exports.TOKEN_TRANSFER_GAS_LIMIT_KEY = exports.SINGLE_SWAP_GAS_LIMIT_KEY = exports.SHIFT_GAS_LIMIT_KEY = exports.SWAP_ORDER_GAS_LIMIT_KEY = exports.DECREASE_ORDER_GAS_LIMIT_KEY = exports.INCREASE_ORDER_GAS_LIMIT_KEY = exports.WITHDRAWAL_GAS_LIMIT_KEY = exports.DEPOSIT_GAS_LIMIT_KEY = exports.MAX_LEVERAGE_KEY = exports.MIN_POSITION_SIZE_USD_KEY = exports.MIN_COLLATERAL_FACTOR_FOR_OPEN_INTEREST_MULTIPLIER_KEY = exports.MIN_COLLATERAL_FACTOR_KEY = exports.MIN_COLLATERAL_USD_KEY = exports.SWAP_IMPACT_POOL_AMOUNT_KEY = void 0;
|
|
5
|
-
exports.
|
|
6
|
-
exports.claimsDisabledKey = exports.claimTermsKey = exports.gaslessFeatureDisabledKey = exports.priceFeedKey = exports.multichainBalanceKey = exports.subaccountAutoTopUpAmountKey = exports.subaccountIntegrationIdKey = exports.maxLendableImpactUsdKey = exports.maxLendableImpactFactorForWithdrawalsKey = exports.maxLendableImpactFactorKey = exports.subaccountActionCountKey = exports.maxAllowedSubaccountActionCountKey = exports.subaccountListKey = exports.uiFeeFactorKey = exports.maxPoolAmountKey = exports.maxPoolUsdForDepositKey = exports.isMarketDisabledKey = exports.affiliateRewardKey = exports.virtualInventoryForPositionsKey = exports.virtualInventoryForSwapsKey = exports.virtualMarketIdKey = exports.virtualTokenIdKey = exports.claimableFundingAmountKey = exports.hashedPositionKey = exports.minCollateralFactorForOpenInterest = exports.minCollateralFactorForLiquidationKey = exports.minCollateralFactorKey = exports.accountOrderListKey = exports.swapOrderGasLimitKey = exports.decreaseOrderGasLimitKey = exports.increaseOrderGasLimitKey = exports.singleSwapGasLimitKey = exports.shiftGasLimitKey = void 0;
|
|
5
|
+
exports.depositGasLimitKey = exports.orderKey = exports.swapImpactPoolAmountKey = exports.maxPositionImpactFactorForLiquidationsKey = exports.positionImpactPoolDistributionRateKey = exports.minPositionImpactPoolAmountKey = exports.positionImpactPoolAmountKey = exports.maxPnlFactorKey = exports.thresholdForDecreaseFundingKey = exports.thresholdForStableFundingKey = exports.maxFundingFactorPerSecondKey = exports.minFundingFactorPerSecondKey = exports.fundingDecreaseFactorPerSecondKey = exports.fundingIncreaseFactorPerSecondKey = exports.fundingExponentFactorKey = exports.fundingFactorKey = exports.totalBorrowingKey = exports.cumulativeBorrowingFactorKey = exports.borrowingExponentFactorKey = exports.borrowingFactorKey = exports.maxOpenInterestKey = exports.openInterestReserveFactorKey = exports.reserveFactorKey = exports.poolAmountKey = exports.openInterestInTokensKey = exports.openInterestKey = exports.withdrawalFeeFactorKey = exports.atomicSwapFeeFactorKey = exports.swapFeeFactorKey = exports.swapImpactExponentFactorKey = exports.swapImpactFactorKey = exports.positionFeeFactorKey = exports.maxPositionImpactFactorKey = exports.positionImpactExponentFactorKey = exports.positionImpactFactorKey = exports.isGlvDisabledKey = exports.glvMaxMarketTokenBalanceAmountKey = exports.glvMaxMarketTokenBalanceUsdKey = exports.glvShiftMinIntervalKey = exports.glvShiftLastExecutedAtKey = exports.subaccountExpiresAtKey = exports.USE_OPEN_INTEREST_IN_TOKENS_FOR_BALANCE = exports.GENERAL_CLAIM_FEATURE_DISABLED = exports.CLAIM_TERMS_KEY = exports.GMX_SIMULATION_ORIGIN = exports.REQUEST_EXPIRATION_TIME_KEY = exports.GELATO_RELAY_FEE_MULTIPLIER_FACTOR_KEY = exports.GASLESS_FEATURE_DISABLED_KEY = exports.PRICE_FEED_KEY = exports.MULTICHAIN_BALANCE = void 0;
|
|
6
|
+
exports.claimsDisabledKey = exports.claimTermsKey = exports.gaslessFeatureDisabledKey = exports.priceFeedKey = exports.multichainBalanceKey = exports.subaccountAutoTopUpAmountKey = exports.subaccountIntegrationIdKey = exports.maxLendableImpactUsdKey = exports.maxLendableImpactFactorForWithdrawalsKey = exports.maxLendableImpactFactorKey = exports.subaccountActionCountKey = exports.maxAllowedSubaccountActionCountKey = exports.subaccountListKey = exports.uiFeeFactorKey = exports.maxPoolAmountKey = exports.maxPoolUsdForDepositKey = exports.isMarketDisabledKey = exports.affiliateRewardKey = exports.virtualInventoryForPositionsKey = exports.virtualInventoryForSwapsKey = exports.virtualMarketIdKey = exports.virtualTokenIdKey = exports.claimableFundingAmountKey = exports.hashedPositionKey = exports.minCollateralFactorForOpenInterest = exports.minCollateralFactorForLiquidationKey = exports.minCollateralFactorKey = exports.accountOrderListKey = exports.swapOrderGasLimitKey = exports.decreaseOrderGasLimitKey = exports.increaseOrderGasLimitKey = exports.singleSwapGasLimitKey = exports.shiftGasLimitKey = exports.withdrawalGasLimitKey = void 0;
|
|
7
7
|
const hash_1 = require("../utils/hash");
|
|
8
8
|
exports.POSITION_IMPACT_FACTOR_KEY = (0, hash_1.hashString)("POSITION_IMPACT_FACTOR");
|
|
9
9
|
exports.MAX_POSITION_IMPACT_FACTOR_KEY = (0, hash_1.hashString)("MAX_POSITION_IMPACT_FACTOR");
|
|
@@ -170,6 +170,10 @@ function atomicSwapFeeFactorKey(market) {
|
|
|
170
170
|
return (0, hash_1.hashData)(["bytes32", "address"], [exports.ATOMIC_SWAP_FEE_FACTOR_KEY, market]);
|
|
171
171
|
}
|
|
172
172
|
exports.atomicSwapFeeFactorKey = atomicSwapFeeFactorKey;
|
|
173
|
+
function withdrawalFeeFactorKey(market, forBalanceWasImproved) {
|
|
174
|
+
return (0, hash_1.hashData)(["bytes32", "address", "bool"], [exports.WITHDRAWAL_FEE_FACTOR_KEY, market, forBalanceWasImproved]);
|
|
175
|
+
}
|
|
176
|
+
exports.withdrawalFeeFactorKey = withdrawalFeeFactorKey;
|
|
173
177
|
function openInterestKey(market, collateralToken, isLong) {
|
|
174
178
|
return (0, hash_1.hashData)(["bytes32", "address", "address", "bool"], [exports.OPEN_INTEREST_KEY, market, collateralToken, isLong]);
|
|
175
179
|
}
|
|
@@ -869,6 +869,27 @@ exports.MARKETS = {
|
|
|
869
869
|
longTokenAddress: "0x82aF49447D8a07e3bd95BD0d56f35241523fBab1",
|
|
870
870
|
shortTokenAddress: "0xaf88d065e77c8cC2239327C5EDb3A432268e5831",
|
|
871
871
|
},
|
|
872
|
+
// XAUT/USD [WBTC-USDC]
|
|
873
|
+
"0xeb28aD1a2e497F4Acc5D9b87e7B496623C93061E": {
|
|
874
|
+
marketTokenAddress: "0xeb28aD1a2e497F4Acc5D9b87e7B496623C93061E",
|
|
875
|
+
indexTokenAddress: "0x7624cccCc59361D583F28BEC40D37e7771d2ef5D",
|
|
876
|
+
longTokenAddress: "0x2f2a2543B76A4166549F7aaB2e75Bef0aefC5B0f",
|
|
877
|
+
shortTokenAddress: "0xaf88d065e77c8cC2239327C5EDb3A432268e5831",
|
|
878
|
+
},
|
|
879
|
+
// LIT/USD [WETH-USDC]
|
|
880
|
+
"0x044dFE01863CE85f9ECd5639eE5485c90AC320FC": {
|
|
881
|
+
marketTokenAddress: "0x044dFE01863CE85f9ECd5639eE5485c90AC320FC",
|
|
882
|
+
indexTokenAddress: "0xE6172EecBB07F197F52bb73d74daa0e19C31c4Db",
|
|
883
|
+
longTokenAddress: "0x82aF49447D8a07e3bd95BD0d56f35241523fBab1",
|
|
884
|
+
shortTokenAddress: "0xaf88d065e77c8cC2239327C5EDb3A432268e5831",
|
|
885
|
+
},
|
|
886
|
+
// IP/USD [WBTC-USDC]
|
|
887
|
+
"0x5ff52BE1968107D7886a8E9A64874A45c8F5D96a": {
|
|
888
|
+
marketTokenAddress: "0x5ff52BE1968107D7886a8E9A64874A45c8F5D96a",
|
|
889
|
+
indexTokenAddress: "0xe7304E9F4ca383BD6312a5179cdC7B40B96A6F5a",
|
|
890
|
+
longTokenAddress: "0x2f2a2543B76A4166549F7aaB2e75Bef0aefC5B0f",
|
|
891
|
+
shortTokenAddress: "0xaf88d065e77c8cC2239327C5EDb3A432268e5831",
|
|
892
|
+
},
|
|
872
893
|
},
|
|
873
894
|
[chains_1.AVALANCHE]: {
|
|
874
895
|
// BTC/USD [BTC-USDC]
|
|
@@ -1,27 +1,37 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.isSourceChainForAnySettlementChain = exports.isSourceChain = exports.isSettlementChain = void 0;
|
|
4
4
|
const chainIds_1 = require("./chainIds");
|
|
5
|
-
|
|
6
|
-
return Object.keys(value).map(Number);
|
|
7
|
-
}
|
|
8
|
-
exports.SETTLEMENT_CHAINS = ensureExhaustive({
|
|
9
|
-
[chainIds_1.ARBITRUM_SEPOLIA]: true,
|
|
10
|
-
[chainIds_1.ARBITRUM]: true,
|
|
11
|
-
[chainIds_1.AVALANCHE]: true,
|
|
12
|
-
});
|
|
13
|
-
exports.SOURCE_CHAINS = ensureExhaustive({
|
|
14
|
-
[chainIds_1.SOURCE_OPTIMISM_SEPOLIA]: true,
|
|
15
|
-
[chainIds_1.SOURCE_SEPOLIA]: true,
|
|
16
|
-
[chainIds_1.SOURCE_BASE_MAINNET]: true,
|
|
17
|
-
[chainIds_1.SOURCE_BSC_MAINNET]: true,
|
|
18
|
-
[chainIds_1.SOURCE_ETHEREUM_MAINNET]: true,
|
|
19
|
-
});
|
|
5
|
+
const chains_1 = require("./chains");
|
|
20
6
|
function isSettlementChain(chainId) {
|
|
21
|
-
return
|
|
7
|
+
return chains_1.SETTLEMENT_CHAIN_IDS.includes(chainId) || chains_1.SETTLEMENT_CHAIN_IDS_DEV.includes(chainId);
|
|
22
8
|
}
|
|
23
9
|
exports.isSettlementChain = isSettlementChain;
|
|
24
|
-
|
|
25
|
-
|
|
10
|
+
const SOURCE_CHAIN_IDS_MAP = {
|
|
11
|
+
[chainIds_1.ARBITRUM]: [chainIds_1.SOURCE_BASE_MAINNET, chainIds_1.SOURCE_ETHEREUM_MAINNET, chainIds_1.SOURCE_BSC_MAINNET],
|
|
12
|
+
[chainIds_1.AVALANCHE]: [chainIds_1.SOURCE_BASE_MAINNET, chainIds_1.SOURCE_BSC_MAINNET],
|
|
13
|
+
[chainIds_1.AVALANCHE_FUJI]: [chainIds_1.ARBITRUM_SEPOLIA],
|
|
14
|
+
[chainIds_1.ARBITRUM_SEPOLIA]: [chainIds_1.SOURCE_SEPOLIA, chainIds_1.SOURCE_OPTIMISM_SEPOLIA],
|
|
15
|
+
};
|
|
16
|
+
function isSourceChain(chainId, forSettlementChain) {
|
|
17
|
+
if (!chainId || !forSettlementChain) {
|
|
18
|
+
return false;
|
|
19
|
+
}
|
|
20
|
+
const sourceChainIds = SOURCE_CHAIN_IDS_MAP[forSettlementChain];
|
|
21
|
+
if (!sourceChainIds) {
|
|
22
|
+
return false;
|
|
23
|
+
}
|
|
24
|
+
return sourceChainIds.includes(chainId);
|
|
26
25
|
}
|
|
27
26
|
exports.isSourceChain = isSourceChain;
|
|
27
|
+
/**
|
|
28
|
+
* Check if a chain is a source chain for any settlement chain
|
|
29
|
+
* Useful when settlement chain context is not available
|
|
30
|
+
*/
|
|
31
|
+
function isSourceChainForAnySettlementChain(chainId) {
|
|
32
|
+
if (!chainId) {
|
|
33
|
+
return false;
|
|
34
|
+
}
|
|
35
|
+
return chains_1.SOURCE_CHAIN_IDS.includes(chainId);
|
|
36
|
+
}
|
|
37
|
+
exports.isSourceChainForAnySettlementChain = isSourceChainForAnySettlementChain;
|
|
@@ -320,6 +320,7 @@ exports.TOKENS = {
|
|
|
320
320
|
symbol: "WIF",
|
|
321
321
|
address: "0xA1b91fe9FD52141Ff8cac388Ce3F10BFDc1dE79d",
|
|
322
322
|
decimals: 6,
|
|
323
|
+
priceDecimals: 5,
|
|
323
324
|
categories: ["meme"],
|
|
324
325
|
imageUrl: "https://assets.coingecko.com/coins/images/33566/standard/dogwifhat.jpg?1702499428",
|
|
325
326
|
isPermitSupported: true,
|
|
@@ -1220,6 +1221,38 @@ exports.TOKENS = {
|
|
|
1220
1221
|
categories: ["layer1"],
|
|
1221
1222
|
imageUrl: "https://assets.coingecko.com/coins/images/8834/standard/CHZ_Token_updated.png?1696508986",
|
|
1222
1223
|
},
|
|
1224
|
+
{
|
|
1225
|
+
name: "Tether Gold",
|
|
1226
|
+
symbol: "XAUT",
|
|
1227
|
+
assetSymbol: "XAUT",
|
|
1228
|
+
baseSymbol: "XAUT",
|
|
1229
|
+
address: "0x7624cccCc59361D583F28BEC40D37e7771d2ef5D",
|
|
1230
|
+
isSynthetic: true,
|
|
1231
|
+
decimals: 18,
|
|
1232
|
+
priceDecimals: 2,
|
|
1233
|
+
categories: ["rwa"],
|
|
1234
|
+
imageUrl: "https://assets.coingecko.com/coins/images/10481/standard/Tether_Gold.png?1696510471",
|
|
1235
|
+
},
|
|
1236
|
+
{
|
|
1237
|
+
name: "Lighter",
|
|
1238
|
+
symbol: "LIT",
|
|
1239
|
+
address: "0xE6172EecBB07F197F52bb73d74daa0e19C31c4Db",
|
|
1240
|
+
isSynthetic: true,
|
|
1241
|
+
decimals: 18,
|
|
1242
|
+
priceDecimals: 4,
|
|
1243
|
+
categories: ["defi"],
|
|
1244
|
+
imageUrl: "https://assets.coingecko.com/coins/images/71121/standard/lighter.png?1765888098",
|
|
1245
|
+
},
|
|
1246
|
+
{
|
|
1247
|
+
name: "Story",
|
|
1248
|
+
symbol: "IP",
|
|
1249
|
+
address: "0xe7304E9F4ca383BD6312a5179cdC7B40B96A6F5a",
|
|
1250
|
+
isSynthetic: true,
|
|
1251
|
+
decimals: 18,
|
|
1252
|
+
priceDecimals: 4,
|
|
1253
|
+
categories: ["layer1"],
|
|
1254
|
+
imageUrl: "https://assets.coingecko.com/coins/images/54035/standard/Transparent_bg.png?1738075331",
|
|
1255
|
+
},
|
|
1223
1256
|
],
|
|
1224
1257
|
[chains_1.AVALANCHE]: [
|
|
1225
1258
|
{
|
|
@@ -2089,6 +2122,9 @@ function getNormalizedTokenSymbol(tokenSymbol) {
|
|
|
2089
2122
|
else if (["PBTC", "STBTC"].includes(tokenSymbol)) {
|
|
2090
2123
|
return "BTC";
|
|
2091
2124
|
}
|
|
2125
|
+
else if (tokenSymbol === "XAUT") {
|
|
2126
|
+
return "XAUT.v2";
|
|
2127
|
+
}
|
|
2092
2128
|
else if (tokenSymbol.includes(".")) {
|
|
2093
2129
|
return tokenSymbol.split(".")[0];
|
|
2094
2130
|
}
|