four-flap-meme-sdk 2.2.20 → 3.0.1
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/dist/abis/flap/portal-events.d.ts +1 -1
- package/dist/abis/flap/portal-events.js +1 -1
- package/dist/abis/flap/portal.d.ts +1 -1
- package/dist/abis/flap/portal.js +1 -1
- package/dist/abis/flap/vault.d.ts +1 -1
- package/dist/abis/flap/vault.js +1 -1
- package/dist/abis/index.d.ts +0 -2
- package/dist/abis/index.js +0 -2
- package/dist/{bundle-core → bundle}/config-helpers.d.ts +1 -1
- package/dist/{bundle-core → bundle}/config-helpers.js +1 -1
- package/dist/{bundle-core → bundle}/four-meme/approve-tokenmanager.js +3 -3
- package/dist/{bundle-core → bundle}/four-meme/core-helpers.d.ts +1 -1
- package/dist/{bundle-core → bundle}/four-meme/core-helpers.js +2 -2
- package/dist/{bundle-core → bundle}/four-meme/core.js +3 -3
- package/dist/{bundle-core → bundle}/four-meme/pancake-proxy.js +2 -2
- package/dist/{bundle-core → bundle}/four-meme/private.js +2 -2
- package/dist/{bundle-core → bundle}/four-meme/sign-context-helpers.d.ts +1 -1
- package/dist/{bundle-core → bundle}/four-meme/sign-context-helpers.js +1 -1
- package/dist/{bundle-core → bundle}/four-meme/swap-buy-first.js +3 -3
- package/dist/{bundle-core → bundle}/four-meme/swap-internal.js +1 -1
- package/dist/{bundle-core → bundle}/four-meme/swap-sign-helpers.js +2 -2
- package/dist/{bundle-core → bundle}/four-meme/types/index.d.ts +1 -1
- package/dist/{bundle-core → bundle}/four-meme/utils-disperse.js +1 -1
- package/dist/{bundle-core → bundle}/four-meme/utils-pairwise.js +1 -1
- package/dist/{bundle-core → bundle}/four-meme/utils-sweep.js +1 -1
- package/dist/{bundle-core → bundle}/internal.d.ts +1 -1
- package/dist/{bundle-core → bundle}/internal.js +2 -2
- package/dist/{bundle-core → bundle}/sign-context-helpers.js +1 -1
- package/dist/{bundle-core → bundle}/submit.js +4 -4
- package/dist/chains/bsc/constants.js +1 -1
- package/dist/chains/bsc/four/approve-tokenmanager.d.ts +1 -1
- package/dist/chains/bsc/four/approve-tokenmanager.js +1 -1
- package/dist/chains/bsc/four/config.d.ts +3 -3
- package/dist/chains/bsc/four/config.js +2 -2
- package/dist/chains/bsc/four/core.d.ts +1 -1
- package/dist/chains/bsc/four/core.js +1 -1
- package/dist/chains/bsc/four/internal.d.ts +2 -2
- package/dist/chains/bsc/four/internal.js +2 -2
- package/dist/chains/bsc/four/pancake-proxy.d.ts +1 -1
- package/dist/chains/bsc/four/pancake-proxy.js +1 -1
- package/dist/chains/bsc/four/private.d.ts +1 -1
- package/dist/chains/bsc/four/private.js +1 -1
- package/dist/chains/bsc/four/submit.d.ts +2 -2
- package/dist/chains/bsc/four/submit.js +2 -2
- package/dist/chains/bsc/four/swap-buy-first.d.ts +2 -2
- package/dist/chains/bsc/four/swap-buy-first.js +2 -2
- package/dist/chains/bsc/four/swap-internal.d.ts +1 -1
- package/dist/chains/bsc/four/swap-internal.js +1 -1
- package/dist/chains/bsc/four/swap.d.ts +2 -2
- package/dist/chains/bsc/four/swap.js +2 -2
- package/dist/chains/bsc/four/types.d.ts +1 -1
- package/dist/chains/bsc/four/utils-disperse.d.ts +1 -1
- package/dist/chains/bsc/four/utils-disperse.js +1 -1
- package/dist/chains/bsc/four/utils-pairwise.d.ts +1 -1
- package/dist/chains/bsc/four/utils-pairwise.js +1 -1
- package/dist/chains/bsc/four/utils-sweep.d.ts +1 -1
- package/dist/chains/bsc/four/utils-sweep.js +1 -1
- package/dist/chains/bsc/index.d.ts +1 -1
- package/dist/chains/bsc/index.js +2 -0
- package/dist/chains/bsc/pancake/bundle-buy-first-helpers.d.ts +1 -1
- package/dist/chains/bsc/pancake/bundle-buy-first-helpers.js +3 -3
- package/dist/chains/bsc/pancake/bundle-buy-first.js +4 -4
- package/dist/chains/bsc/pancake/bundle-swap-helpers.d.ts +1 -1
- package/dist/chains/bsc/pancake/bundle-swap-helpers.js +5 -5
- package/dist/chains/bsc/pancake/bundle-swap.js +2 -2
- package/dist/chains/bsc/platforms/iro/constants.js +1 -1
- package/dist/chains/bsc/platforms/iro/token.js +1 -1
- package/dist/chains/eni/batch-router/transfer.js +2 -2
- package/dist/chains/eni/constants.js +1 -1
- package/dist/chains/eni/index.d.ts +2 -0
- package/dist/chains/eni/index.js +4 -0
- package/dist/chains/eni/platforms/daoaas/create.js +1 -1
- package/dist/chains/eni/platforms/daoaas/portal-direct.js +1 -1
- package/dist/chains/eni/platforms/dswap/liquidity.js +1 -1
- package/dist/chains/eni/platforms/fair-launch/constants.js +1 -1
- package/dist/chains/eni/platforms/fair-launch/launcher.js +1 -1
- package/dist/chains/eni/platforms/fair-launch/pool.js +1 -1
- package/dist/chains/eni/platforms/iro/constants.d.ts +1 -1
- package/dist/chains/eni/platforms/iro/constants.js +2 -2
- package/dist/chains/eni/platforms/iro/token.js +1 -1
- package/dist/chains/eni/submit.js +2 -2
- package/dist/chains/monad/constants.js +1 -1
- package/dist/chains/xlayer/constants.js +1 -1
- package/dist/chains/xlayer/eip7702/bundle-create.js +1 -1
- package/dist/chains/xlayer/eip7702/bundle-sell.js +1 -1
- package/dist/chains/xlayer/eip7702/bundle-swap.js +1 -1
- package/dist/chains/xlayer/eip7702/constants.d.ts +1 -1
- package/dist/chains/xlayer/eip7702/constants.js +2 -2
- package/dist/chains/xlayer/eip7702/multi-hop-transfer.js +1 -1
- package/dist/chains/xlayer/eip7702/utils.js +1 -1
- package/dist/chains/xlayer/eip7702/volume.js +1 -1
- package/dist/chains/xlayer/eoa/constants.js +1 -1
- package/dist/chains/xlayer/eoa/dex-helpers.d.ts +1 -1
- package/dist/chains/xlayer/eoa/dex-helpers.js +2 -2
- package/dist/chains/xlayer/eoa/eoa-bundle-swap-helpers.d.ts +1 -1
- package/dist/chains/xlayer/eoa/eoa-bundle-swap-helpers.js +3 -3
- package/dist/chains/xlayer/eoa/eoa-bundle-swap.js +2 -2
- package/dist/chains/xlayer/eoa/eoa-wash-volume.d.ts +1 -1
- package/dist/chains/xlayer/eoa/eoa-wash-volume.js +2 -2
- package/dist/chains/xlayer/eoa/router-manager.js +1 -1
- package/dist/{shared → core}/clients/blockrazor.js +1 -1
- package/dist/{shared → core}/clients/four.js +1 -1
- package/dist/{shared → core}/clients/merkle.js +1 -1
- package/dist/{shared → core}/constants/index.d.ts +2 -2
- package/dist/{shared → core}/constants/index.js +1 -1
- package/dist/{shared/foundation → core}/dex/v3-path.js +1 -1
- package/dist/{utils → core}/erc20.d.ts +2 -2
- package/dist/{utils → core}/erc20.js +3 -3
- package/dist/{shared/foundation → core}/gas/profit-hop.js +1 -1
- package/dist/core/index.d.ts +5 -0
- package/dist/core/index.js +5 -0
- package/dist/{shared/foundation → core}/nonce/nonce-manager.js +1 -1
- package/dist/{shared/foundation → core}/types/airdrop-sweep.d.ts +1 -1
- package/dist/{shared/foundation → core}/types/holders-maker.d.ts +1 -1
- package/dist/{shared/foundation → core}/types/lp-inspect.d.ts +1 -1
- package/dist/{shared/foundation → core}/types/private-sale.d.ts +1 -1
- package/dist/{utils/types/erc20.d.ts → core/types-erc20.d.ts} +1 -1
- package/dist/{dex → domains/dex}/direct-router-helpers.d.ts +1 -1
- package/dist/{dex → domains/dex}/direct-router-helpers.js +4 -4
- package/dist/{dex → domains/dex}/direct-router.js +6 -6
- package/dist/{dex → domains/dex}/types.d.ts +1 -1
- package/dist/{shared → domains}/flap/constants.d.ts +1 -1
- package/dist/{shared → domains}/flap/constants.js +1 -1
- package/dist/{shared → domains}/flap/errors.js +1 -1
- package/dist/{flap → domains/flap}/index.d.ts +5 -9
- package/dist/domains/flap/index.js +5 -0
- package/dist/{shared → domains}/flap/meta.js +2 -2
- package/dist/{shared → domains}/flap/permit.js +2 -2
- package/dist/{shared → domains}/flap/portal-bundle-merkle/config.d.ts +2 -2
- package/dist/{shared → domains}/flap/portal-bundle-merkle/config.js +4 -4
- package/dist/{shared → domains}/flap/portal-bundle-merkle/core-helpers.js +3 -3
- package/dist/{shared → domains}/flap/portal-bundle-merkle/core.js +4 -4
- package/dist/{shared → domains}/flap/portal-bundle-merkle/create-to-dex.js +3 -3
- package/dist/{shared → domains}/flap/portal-bundle-merkle/curve-to-dex.js +4 -4
- package/dist/{shared → domains}/flap/portal-bundle-merkle/pancake-proxy.js +4 -4
- package/dist/{shared → domains}/flap/portal-bundle-merkle/private.js +3 -3
- package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-batch.js +2 -2
- package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-buy-first-helpers.js +3 -3
- package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-buy-first.js +7 -7
- package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-cross.js +1 -1
- package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-helpers.js +3 -3
- package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-planning.js +5 -5
- package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-quick-batch.js +4 -4
- package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-single.js +2 -2
- package/dist/{shared → domains}/flap/portal-bundle-merkle/utils.js +3 -3
- package/dist/{shared → domains}/flap/portal-bundle.d.ts +2 -2
- package/dist/{shared → domains}/flap/portal-bundle.js +3 -3
- package/dist/{shared → domains}/flap/portal-create-token.js +1 -1
- package/dist/{shared → domains}/flap/vault.js +1 -1
- package/dist/{flows → domains/flows}/create.js +2 -2
- package/dist/{contracts → domains/four/contracts}/helper3.js +2 -2
- package/dist/{contracts → domains/four/contracts}/tm-bundle-helpers.d.ts +4 -4
- package/dist/{contracts → domains/four/contracts}/tm-bundle-helpers.js +3 -3
- package/dist/{contracts → domains/four/contracts}/tm-bundle.d.ts +2 -2
- package/dist/{contracts → domains/four/contracts}/tm-bundle.js +7 -7
- package/dist/{contracts → domains/four/contracts}/tm.d.ts +1 -1
- package/dist/{contracts → domains/four/contracts}/tm.js +4 -4
- package/dist/{contracts → domains/four/contracts}/tm1.js +2 -2
- package/dist/{contracts → domains/four/contracts}/tm2.js +2 -2
- package/dist/domains/four/index.d.ts +7 -0
- package/dist/domains/four/index.js +7 -0
- package/dist/{shared → domains}/four/tax-token.js +1 -1
- package/dist/{utils → domains/holders}/holders-maker-helpers.d.ts +7 -7
- package/dist/{utils → domains/holders}/holders-maker-helpers.js +7 -7
- package/dist/{utils → domains/holders}/holders-maker.d.ts +2 -2
- package/dist/{utils → domains/holders}/holders-maker.js +4 -4
- package/dist/domains/holders/index.d.ts +1 -0
- package/dist/domains/holders/index.js +1 -0
- package/dist/{utils/holders-maker → domains/holders/internal}/addresses.js +1 -1
- package/dist/{utils/holders-maker → domains/holders/internal}/buy-tx.d.ts +1 -1
- package/dist/{utils/holders-maker → domains/holders/internal}/buy-tx.js +4 -4
- package/dist/{utils/holders-maker → domains/holders/internal}/constants.js +1 -1
- package/dist/{utils/holders-maker → domains/holders/internal}/disperse.d.ts +4 -4
- package/dist/{utils/holders-maker → domains/holders/internal}/disperse.js +2 -2
- package/dist/{utils/holders-maker → domains/holders/internal}/routing.d.ts +1 -1
- package/dist/{utils/holders-maker → domains/holders/internal}/routing.js +1 -1
- package/dist/{utils/holders-maker → domains/holders/internal}/transfer-tx.js +2 -2
- package/dist/{utils/types/holders-maker.d.ts → domains/holders/types.d.ts} +1 -1
- package/dist/domains/lp-inspect/index.d.ts +1 -0
- package/dist/domains/lp-inspect/index.js +1 -0
- package/dist/{utils → domains/lp-inspect}/lp-inspect-helpers.d.ts +1 -1
- package/dist/{utils → domains/lp-inspect}/lp-inspect-helpers.js +1 -1
- package/dist/{utils → domains/lp-inspect}/lp-inspect.d.ts +2 -2
- package/dist/{utils → domains/lp-inspect}/lp-inspect.js +6 -6
- package/dist/{utils/types/lp-inspect.d.ts → domains/lp-inspect/types.d.ts} +1 -1
- package/dist/{merkle → domains/merkle}/index.d.ts +7 -7
- package/dist/domains/merkle/index.js +11 -0
- package/dist/domains/private-sale/index.d.ts +1 -0
- package/dist/domains/private-sale/index.js +1 -0
- package/dist/{utils → domains/private-sale}/private-sale.d.ts +2 -2
- package/dist/{utils → domains/private-sale}/private-sale.js +2 -2
- package/dist/domains/private-sale/types.d.ts +1 -0
- package/dist/domains/quote/index.d.ts +1 -0
- package/dist/domains/quote/index.js +1 -0
- package/dist/{utils → domains/quote}/quote-helpers.d.ts +3 -3
- package/dist/{utils → domains/quote}/quote-helpers.js +2 -2
- package/dist/{utils/types/quote-helpers.d.ts → domains/quote/types.d.ts} +1 -1
- package/dist/domains/vanity/index.d.ts +5 -0
- package/dist/domains/vanity/index.js +5 -0
- package/dist/exports/root-bundle-and-tooling.d.ts +11 -11
- package/dist/exports/root-bundle-and-tooling.js +11 -11
- package/dist/exports/root-foundations.d.ts +21 -21
- package/dist/exports/root-foundations.js +21 -21
- package/dist/exports/root-swap-dex-and-xlayer.d.ts +10 -10
- package/dist/exports/root-swap-dex-and-xlayer.js +8 -8
- package/dist/index.d.ts +7 -10
- package/dist/index.js +7 -10
- package/dist/utils/airdrop-sweep.js +3 -3
- package/dist/utils/bundle-helpers.d.ts +7 -7
- package/dist/utils/bundle-helpers.js +7 -7
- package/dist/utils/constants.d.ts +2 -2
- package/dist/utils/constants.js +2 -2
- package/dist/utils/contract-factory.js +1 -1
- package/dist/utils/errors.d.ts +2 -2
- package/dist/utils/errors.js +3 -3
- package/dist/utils/hop-chains.d.ts +1 -1
- package/dist/utils/hop-chains.js +2 -2
- package/dist/utils/index.d.ts +5 -0
- package/dist/utils/index.js +5 -0
- package/dist/utils/mpcExclusive.js +1 -1
- package/dist/utils/stealth-transfer.js +2 -2
- package/dist/utils/swap-helpers.d.ts +1 -1
- package/dist/utils/swap-helpers.js +1 -1
- package/dist/utils/types/airdrop-sweep.d.ts +1 -1
- package/dist/utils/types/index.d.ts +6 -6
- package/dist/utils/types/stealth-transfer.d.ts +1 -1
- package/dist/utils/wallet.d.ts +2 -2
- package/dist/utils/wallet.js +3 -3
- package/package.json +56 -56
- package/dist/__tests__/subpath-exports.test.js +0 -64
- package/dist/bundle-core/__tests__/config-helpers.test.js +0 -28
- package/dist/bundle-core/__tests__/facade-parity.test.js +0 -33
- package/dist/bundle-core/__tests__/sign-context-helpers.test.js +0 -60
- package/dist/bundle-core/__tests__/sign-fixture.test.d.ts +0 -1
- package/dist/bundle-core/__tests__/sign-fixture.test.js +0 -220
- package/dist/bundle-core/__tests__/sign-fixtures.d.ts +0 -10
- package/dist/bundle-core/__tests__/sign-fixtures.js +0 -16
- package/dist/contracts/tm-bundle-merkle/approve-tokenmanager.d.ts +0 -1
- package/dist/contracts/tm-bundle-merkle/approve-tokenmanager.js +0 -1
- package/dist/contracts/tm-bundle-merkle/config.d.ts +0 -8
- package/dist/contracts/tm-bundle-merkle/config.js +0 -2
- package/dist/contracts/tm-bundle-merkle/core.d.ts +0 -1
- package/dist/contracts/tm-bundle-merkle/core.js +0 -1
- package/dist/contracts/tm-bundle-merkle/index.d.ts +0 -15
- package/dist/contracts/tm-bundle-merkle/index.js +0 -29
- package/dist/contracts/tm-bundle-merkle/internal.d.ts +0 -4
- package/dist/contracts/tm-bundle-merkle/internal.js +0 -4
- package/dist/contracts/tm-bundle-merkle/pancake-proxy.d.ts +0 -1
- package/dist/contracts/tm-bundle-merkle/pancake-proxy.js +0 -1
- package/dist/contracts/tm-bundle-merkle/private.d.ts +0 -1
- package/dist/contracts/tm-bundle-merkle/private.js +0 -1
- package/dist/contracts/tm-bundle-merkle/submit.d.ts +0 -3
- package/dist/contracts/tm-bundle-merkle/submit.js +0 -3
- package/dist/contracts/tm-bundle-merkle/swap-buy-first.d.ts +0 -4
- package/dist/contracts/tm-bundle-merkle/swap-buy-first.js +0 -4
- package/dist/contracts/tm-bundle-merkle/swap-internal.d.ts +0 -1
- package/dist/contracts/tm-bundle-merkle/swap-internal.js +0 -1
- package/dist/contracts/tm-bundle-merkle/swap.d.ts +0 -4
- package/dist/contracts/tm-bundle-merkle/swap.js +0 -4
- package/dist/contracts/tm-bundle-merkle/types.d.ts +0 -1
- package/dist/contracts/tm-bundle-merkle/utils-disperse.d.ts +0 -1
- package/dist/contracts/tm-bundle-merkle/utils-disperse.js +0 -1
- package/dist/contracts/tm-bundle-merkle/utils-pairwise.d.ts +0 -1
- package/dist/contracts/tm-bundle-merkle/utils-pairwise.js +0 -1
- package/dist/contracts/tm-bundle-merkle/utils-sweep.d.ts +0 -1
- package/dist/contracts/tm-bundle-merkle/utils-sweep.js +0 -1
- package/dist/contracts/tm-bundle-merkle/utils.d.ts +0 -8
- package/dist/contracts/tm-bundle-merkle/utils.js +0 -8
- package/dist/flap/index.js +0 -9
- package/dist/merkle/index.js +0 -11
- package/dist/shared/abis/TaxToken.json +0 -105
- package/dist/shared/abis/TokenManager.json +0 -836
- package/dist/shared/abis/TokenManager2.json +0 -60
- package/dist/shared/abis/TokenManagerHelper3.json +0 -993
- package/dist/shared/flap/graduated-dex.d.ts +0 -1
- package/dist/shared/flap/graduated-dex.js +0 -1
- package/dist/shared/flap/launch-v6.d.ts +0 -127
- package/dist/shared/flap/launch-v6.js +0 -123
- package/dist/shared/four/index.d.ts +0 -7
- package/dist/shared/four/index.js +0 -22
- package/dist/shared/index.d.ts +0 -16
- package/dist/shared/index.js +0 -14
- package/dist/utils/pcs-infinity-cl.d.ts +0 -65
- package/dist/utils/pcs-infinity-cl.js +0 -390
- package/dist/utils/types/erc20.js +0 -1
- package/dist/utils/types/holders-maker.js +0 -1
- package/dist/utils/types/lp-inspect.js +0 -1
- package/dist/utils/types/private-sale.d.ts +0 -1
- package/dist/utils/types/private-sale.js +0 -1
- package/dist/utils/types/quote-helpers.js +0 -1
- package/dist/vanity/index.d.ts +0 -5
- package/dist/vanity/index.js +0 -5
- /package/dist/{bundle-core → bundle}/errors.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/errors.js +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/approve-tokenmanager.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/core.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/pancake-proxy.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/private.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/swap-buy-first.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/swap-hop-helpers.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/swap-hop-helpers.js +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/swap-internal.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/swap-sign-helpers.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/swap.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/swap.js +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/types/buy-first.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/types/buy-first.js +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/types/core-flow.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/types/core-flow.js +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/types/index.js +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/types/swap-internal.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/types/swap-internal.js +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/types.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/types.js +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/utils-disperse.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/utils-pairwise.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/four-meme/utils-sweep.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/index.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/index.js +0 -0
- /package/dist/{bundle-core → bundle}/sign-context-helpers.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/submit.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/types/index.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/types/index.js +0 -0
- /package/dist/{bundle-core → bundle}/types.d.ts +0 -0
- /package/dist/{bundle-core → bundle}/types.js +0 -0
- /package/dist/{shared/foundation → core}/amount/split-by-weight.d.ts +0 -0
- /package/dist/{shared/foundation → core}/amount/split-by-weight.js +0 -0
- /package/dist/{shared → core}/clients/blockrazor.d.ts +0 -0
- /package/dist/{shared → core}/clients/club48.d.ts +0 -0
- /package/dist/{shared → core}/clients/club48.js +0 -0
- /package/dist/{shared → core}/clients/emitservice.d.ts +0 -0
- /package/dist/{shared → core}/clients/emitservice.js +0 -0
- /package/dist/{shared → core}/clients/four.d.ts +0 -0
- /package/dist/{shared → core}/clients/index.d.ts +0 -0
- /package/dist/{shared → core}/clients/index.js +0 -0
- /package/dist/{shared → core}/clients/merkle.d.ts +0 -0
- /package/dist/{shared → core}/constants/addresses.d.ts +0 -0
- /package/dist/{shared → core}/constants/addresses.js +0 -0
- /package/dist/{shared → core}/constants/chains.d.ts +0 -0
- /package/dist/{shared → core}/constants/chains.js +0 -0
- /package/dist/{shared → core}/constants/gas.d.ts +0 -0
- /package/dist/{shared → core}/constants/gas.js +0 -0
- /package/dist/{shared → core}/constants/profit.d.ts +0 -0
- /package/dist/{shared → core}/constants/profit.js +0 -0
- /package/dist/{shared → core}/constants/quote.d.ts +0 -0
- /package/dist/{shared → core}/constants/quote.js +0 -0
- /package/dist/{shared/foundation → core}/dex/v3-path.d.ts +0 -0
- /package/dist/{shared/foundation → core}/erc20/decimals.d.ts +0 -0
- /package/dist/{shared/foundation → core}/erc20/decimals.js +0 -0
- /package/dist/{shared/foundation/index.d.ts → core/foundation.d.ts} +0 -0
- /package/dist/{shared/foundation/index.js → core/foundation.js} +0 -0
- /package/dist/{shared/foundation → core}/gas/bundle-gas.d.ts +0 -0
- /package/dist/{shared/foundation → core}/gas/bundle-gas.js +0 -0
- /package/dist/{shared/foundation → core}/gas/profit-hop.d.ts +0 -0
- /package/dist/{types → core/legacy-types}/errors.d.ts +0 -0
- /package/dist/{types → core/legacy-types}/errors.js +0 -0
- /package/dist/{shared/foundation → core}/nonce/nonce-manager.d.ts +0 -0
- /package/dist/{shared/foundation → core}/normalize-unknown.d.ts +0 -0
- /package/dist/{shared/foundation → core}/normalize-unknown.js +0 -0
- /package/dist/{shared/foundation → core}/sdk-logger.d.ts +0 -0
- /package/dist/{shared/foundation → core}/sdk-logger.js +0 -0
- /package/dist/{shared/abis → core/shared-abis}/common.d.ts +0 -0
- /package/dist/{shared/abis → core/shared-abis}/common.js +0 -0
- /package/dist/{shared/abis → core/shared-abis}/index.d.ts +0 -0
- /package/dist/{shared/abis → core/shared-abis}/index.js +0 -0
- /package/dist/{shared/foundation → core}/tx/build-request.d.ts +0 -0
- /package/dist/{shared/foundation → core}/tx/build-request.js +0 -0
- /package/dist/{shared/foundation → core}/tx/sign-batch.d.ts +0 -0
- /package/dist/{shared/foundation → core}/tx/sign-batch.js +0 -0
- /package/dist/{shared/foundation → core}/tx/wallet-sign-patch.d.ts +0 -0
- /package/dist/{shared/foundation → core}/tx/wallet-sign-patch.js +0 -0
- /package/dist/{shared/foundation → core}/types/airdrop-sweep.js +0 -0
- /package/dist/{shared/foundation → core}/types/erc20.d.ts +0 -0
- /package/dist/{shared/foundation → core}/types/erc20.js +0 -0
- /package/dist/{shared/foundation → core}/types/holders-maker.js +0 -0
- /package/dist/{shared/foundation → core}/types/index.d.ts +0 -0
- /package/dist/{shared/foundation → core}/types/index.js +0 -0
- /package/dist/{shared/foundation → core}/types/lp-inspect.js +0 -0
- /package/dist/{shared/foundation → core}/types/multicall.d.ts +0 -0
- /package/dist/{shared/foundation → core}/types/multicall.js +0 -0
- /package/dist/{shared/foundation → core}/types/private-sale.js +0 -0
- /package/dist/{shared/foundation → core}/types/quote-helpers.d.ts +0 -0
- /package/dist/{shared/foundation → core}/types/quote-helpers.js +0 -0
- /package/dist/{__tests__/subpath-exports.test.d.ts → core/types-erc20.js} +0 -0
- /package/dist/{shared/foundation → core}/wallet/generate.d.ts +0 -0
- /package/dist/{shared/foundation → core}/wallet/generate.js +0 -0
- /package/dist/{dex → domains/dex}/direct-router.d.ts +0 -0
- /package/dist/{dex → domains/dex}/index.d.ts +0 -0
- /package/dist/{dex → domains/dex}/index.js +0 -0
- /package/dist/{contracts/tm-bundle-merkle → domains/dex}/types.js +0 -0
- /package/dist/{shared → domains}/flap/abi.d.ts +0 -0
- /package/dist/{shared → domains}/flap/abi.js +0 -0
- /package/dist/{shared → domains}/flap/curve.d.ts +0 -0
- /package/dist/{shared → domains}/flap/curve.js +0 -0
- /package/dist/{shared → domains}/flap/errors.d.ts +0 -0
- /package/dist/{shared → domains}/flap/ipfs.d.ts +0 -0
- /package/dist/{shared → domains}/flap/ipfs.js +0 -0
- /package/dist/{shared → domains}/flap/meta.d.ts +0 -0
- /package/dist/{shared/flap/index.d.ts → domains/flap/module.d.ts} +0 -0
- /package/dist/{shared/flap/index.js → domains/flap/module.js} +0 -0
- /package/dist/{shared → domains}/flap/permit.d.ts +0 -0
- /package/dist/{shared → domains}/flap/pinata.d.ts +0 -0
- /package/dist/{shared → domains}/flap/pinata.js +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/core-helpers.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/core.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/create-to-dex.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/curve-to-dex.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/index.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/index.js +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/pancake-proxy.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/private.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-batch.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-buy-first-helpers.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-buy-first.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-cross.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-helpers.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-planning.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-quick-batch.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-single.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-types.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/swap-types.js +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/swap.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/swap.js +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/types.d.ts +0 -0
- /package/dist/{dex → domains/flap/portal-bundle-merkle}/types.js +0 -0
- /package/dist/{shared → domains}/flap/portal-bundle-merkle/utils.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal-create-token.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal.d.ts +0 -0
- /package/dist/{shared → domains}/flap/portal.js +0 -0
- /package/dist/{shared → domains}/flap/vanity.d.ts +0 -0
- /package/dist/{shared → domains}/flap/vanity.js +0 -0
- /package/dist/{shared → domains}/flap/vault.d.ts +0 -0
- /package/dist/{flows → domains/flows}/create.d.ts +0 -0
- /package/dist/{flows → domains/flows}/index.d.ts +0 -0
- /package/dist/{flows → domains/flows}/index.js +0 -0
- /package/dist/{contracts → domains/four/contracts}/helper3.d.ts +0 -0
- /package/dist/{contracts → domains/four/contracts}/tm1.d.ts +0 -0
- /package/dist/{contracts → domains/four/contracts}/tm2.d.ts +0 -0
- /package/dist/{shared → domains}/four/tax-token.d.ts +0 -0
- /package/dist/{utils/holders-maker → domains/holders/internal}/addresses.d.ts +0 -0
- /package/dist/{utils/holders-maker → domains/holders/internal}/constants.d.ts +0 -0
- /package/dist/{utils/holders-maker → domains/holders/internal}/transfer-tx.d.ts +0 -0
- /package/dist/{shared/flap/portal-bundle-merkle → domains/holders}/types.js +0 -0
- /package/dist/{bundle-core/__tests__/config-helpers.test.d.ts → domains/lp-inspect/types.js} +0 -0
- /package/dist/{bundle-core/__tests__/facade-parity.test.d.ts → domains/private-sale/types.js} +0 -0
- /package/dist/{bundle-core/__tests__/sign-context-helpers.test.d.ts → domains/quote/types.js} +0 -0
|
@@ -15,7 +15,7 @@ export * as Abis from '../abis/index.js';
|
|
|
15
15
|
// ============================================================================
|
|
16
16
|
// SDK 基础(unknown 收口 / 可选 Logger;审计 P1)
|
|
17
17
|
// ============================================================================
|
|
18
|
-
export { getErrorMessageFromUnknown, normalizeUnknownError, noopSdkLogger, consoleSdkLogger, buildTransactionRequest, } from '../
|
|
18
|
+
export { getErrorMessageFromUnknown, normalizeUnknownError, noopSdkLogger, consoleSdkLogger, buildTransactionRequest, } from '../core/index.js';
|
|
19
19
|
// export * as Sol from '../sol/index.js';
|
|
20
20
|
export { ERC20_ABI, ERC20_BALANCE_ABI, ERC20_ALLOWANCE_ABI, MULTICALL3_ABI, V2_ROUTER_ABI, V2_ROUTER_QUOTE_ABI, V3_ROUTER02_ABI, V3_ROUTER_LEGACY_ABI, V3_QUOTER_ABI, V2_FACTORY_ABI, V2_PAIR_ABI, V3_FACTORY_ABI, V3_POOL_ABI, FLAP_PORTAL_ABI, TM2_ABI, HELPER3_ABI, } from '../abis/common.js';
|
|
21
21
|
// ============================================================================
|
|
@@ -31,7 +31,7 @@ ADDRESSES, getMulticall3Address, getFlapPortalAddress, isZeroAddress, isNativeTo
|
|
|
31
31
|
// 利润配置
|
|
32
32
|
getProfitRecipient, getAllProfitRecipients, getProfitRateBps, calculateProfitAmount, calculateProfitHopGasCost, getTransferFeePerAddress, TRANSFER_FEE_PER_ADDRESS,
|
|
33
33
|
// DEX 报价配置
|
|
34
|
-
QUOTE_CONFIG, QUOTE_V3_FEE_TIERS, } from '../
|
|
34
|
+
QUOTE_CONFIG, QUOTE_V3_FEE_TIERS, } from '../core/constants/index.js';
|
|
35
35
|
export { buildProfitHopTransactions, PROFIT_HOP_COUNT } from '../utils/bundle-helpers.js';
|
|
36
36
|
export { isExclusiveOnChain, isExclusiveOffChain } from '../utils/mpcExclusive.js';
|
|
37
37
|
export {
|
|
@@ -46,25 +46,25 @@ ensureFlapSellApproval, checkFlapSellApproval, ensureFlapSellApprovalBatch, chec
|
|
|
46
46
|
// ✅ 智能路由授权方法(自动选择 spender,适用于 Flap、Four、V2、V3)
|
|
47
47
|
checkAllowance, approveToken, checkAllowanceBatch, approveTokenBatch,
|
|
48
48
|
// ✅ 底层授权方法(手动指定 spender,适用于任意合约)
|
|
49
|
-
checkAllowanceRaw, approveTokenRaw, checkAllowanceBatchRaw, approveTokenBatchRaw, } from '../
|
|
49
|
+
checkAllowanceRaw, approveTokenRaw, checkAllowanceBatchRaw, approveTokenBatchRaw, } from '../core/erc20.js';
|
|
50
50
|
export { parseFourError } from '../utils/errors.js';
|
|
51
51
|
export { getTokenManagerV1, getTokenManagerV2, getTokenManagerHelper3, getTokenManagerV1Writer, getTokenManagerV2Writer, getTokenManagerHelper3Writer, getTokenManagerAddress, } from '../utils/contract-factory.js';
|
|
52
|
-
export { FourClient, buildLoginMessage, } from '../
|
|
53
|
-
export { createTokenOnChain, tryBuy, trySell, buyTokenWithFunds, sellToken, tradeBuy, tradeSell, } from '../contracts/tm.js';
|
|
54
|
-
export { TM1 } from '../contracts/tm1.js';
|
|
55
|
-
export { TM2 } from '../contracts/tm2.js';
|
|
56
|
-
export { Helper3, Helper3Writer } from '../contracts/helper3.js';
|
|
57
|
-
export { CDPV2 } from '../
|
|
58
|
-
export { FlapPortal, FlapPortalWriter, validateTaxDistribution, TokenStatus, TokenVersion, DexThreshType, MigratorType, V3LPFeeProfile, lpFeeProfileToV3Fee, DEXId, } from '../
|
|
59
|
-
export { uploadTokenMeta } from '../
|
|
60
|
-
export { buildPermitPiggybackAuto } from '../
|
|
61
|
-
export { predictVanityTokenAddressByChain, findSaltEndingByChain } from '../
|
|
62
|
-
export { FLAP_DEFAULT_FEE_RATES, FLAP_IPFS_API_URL, FLAP_VANITY_SUFFIX, FLAP_DEX_THRESHOLDS, FLAP_TOTAL_SUPPLY, ZERO_ADDRESS, CHAIN_TAX_SUPPORT, getVanitySuffix, isChainSupportTax, } from '../
|
|
63
|
-
export { parseFlapError, getFlapErrorMessage, getFlapErrorMessageEn, } from '../
|
|
64
|
-
export { getFlapMetaByAddress, getFlapMetasByAddresses } from '../
|
|
65
|
-
export { createTokenFlow } from '../flows/create.js';
|
|
66
|
-
export { Club48Client, sendBatchPrivateTransactions, sendBackrunBundle, } from '../
|
|
67
|
-
export { MerkleClient, createMerkleClient, } from '../
|
|
68
|
-
export { BlockRazorClient, createBlockRazorClient, BLOCKRAZOR_BUILDER_EOA, } from '../
|
|
69
|
-
export { EmitServiceClient, submitToEmitServiceBlockRazor, } from '../
|
|
52
|
+
export { FourClient, buildLoginMessage, } from '../core/clients/four.js';
|
|
53
|
+
export { createTokenOnChain, tryBuy, trySell, buyTokenWithFunds, sellToken, tradeBuy, tradeSell, } from '../domains/four/contracts/tm.js';
|
|
54
|
+
export { TM1 } from '../domains/four/contracts/tm1.js';
|
|
55
|
+
export { TM2 } from '../domains/four/contracts/tm2.js';
|
|
56
|
+
export { Helper3, Helper3Writer } from '../domains/four/contracts/helper3.js';
|
|
57
|
+
export { CDPV2 } from '../domains/flap/curve.js';
|
|
58
|
+
export { FlapPortal, FlapPortalWriter, validateTaxDistribution, TokenStatus, TokenVersion, DexThreshType, MigratorType, V3LPFeeProfile, lpFeeProfileToV3Fee, DEXId, } from '../domains/flap/portal.js';
|
|
59
|
+
export { uploadTokenMeta } from '../domains/flap/ipfs.js';
|
|
60
|
+
export { buildPermitPiggybackAuto } from '../domains/flap/permit.js';
|
|
61
|
+
export { predictVanityTokenAddressByChain, findSaltEndingByChain } from '../domains/flap/vanity.js';
|
|
62
|
+
export { FLAP_DEFAULT_FEE_RATES, FLAP_IPFS_API_URL, FLAP_VANITY_SUFFIX, FLAP_DEX_THRESHOLDS, FLAP_TOTAL_SUPPLY, ZERO_ADDRESS, CHAIN_TAX_SUPPORT, getVanitySuffix, isChainSupportTax, } from '../domains/flap/constants.js';
|
|
63
|
+
export { parseFlapError, getFlapErrorMessage, getFlapErrorMessageEn, } from '../domains/flap/errors.js';
|
|
64
|
+
export { getFlapMetaByAddress, getFlapMetasByAddresses } from '../domains/flap/meta.js';
|
|
65
|
+
export { createTokenFlow } from '../domains/flows/create.js';
|
|
66
|
+
export { Club48Client, sendBatchPrivateTransactions, sendBackrunBundle, } from '../core/clients/club48.js';
|
|
67
|
+
export { MerkleClient, createMerkleClient, } from '../core/clients/merkle.js';
|
|
68
|
+
export { BlockRazorClient, createBlockRazorClient, BLOCKRAZOR_BUILDER_EOA, } from '../core/clients/blockrazor.js';
|
|
69
|
+
export { EmitServiceClient, submitToEmitServiceBlockRazor, } from '../core/clients/emitservice.js';
|
|
70
70
|
export { NonceManager, getOptimizedGasPrice, estimateGasWithSafety, estimateGasBatch, buildTransaction, signTransactionsBatch, signTransactionsBatchMultiWallet, validateSignedTransactions, getDeadline, encodeV3Path, decodeV3Path, getGasLimit, getGasPriceConfig, getTxType, getChainId, } from '../utils/bundle-helpers.js';
|
|
@@ -5,25 +5,25 @@
|
|
|
5
5
|
* v2:包根不再导出 `PROFIT_CONFIG` / 报价 `V3_FEE_TIERS`;迁移说明见 README.zh-CN.md。
|
|
6
6
|
*/
|
|
7
7
|
export { fourBundleSwapMerkle, fourBatchSwapMerkle, fourQuickBatchSwapMerkle, type FourSwapSignConfig, type FourSwapConfig, type FourBundleSwapSignParams, type FourBundleSwapParams, type FourSwapResult, type FourBatchSwapSignParams, type FourBatchSwapResult, type FourQuickBatchSwapSignParams, type FourQuickBatchSwapResult, } from '../chains/bsc/four/swap.js';
|
|
8
|
-
export { flapBundleSwapMerkle, flapBatchSwapMerkle, flapQuickBatchSwapMerkle, flapCrossSwapMerkle, } from '../
|
|
9
|
-
export type { FlapSwapSignConfig, FlapSwapConfig, FlapBundleSwapSignParams, FlapBundleSwapParams, FlapSwapResult, } from '../
|
|
10
|
-
export type { FlapBatchSwapSignParams, FlapBatchSwapResult, FlapQuickBatchSwapSignParams, FlapQuickBatchSwapResult, FlapCrossSwapParams, FlapCrossSwapResult, } from '../
|
|
8
|
+
export { flapBundleSwapMerkle, flapBatchSwapMerkle, flapQuickBatchSwapMerkle, flapCrossSwapMerkle, } from '../domains/flap/portal-bundle-merkle/swap.js';
|
|
9
|
+
export type { FlapSwapSignConfig, FlapSwapConfig, FlapBundleSwapSignParams, FlapBundleSwapParams, FlapSwapResult, } from '../domains/flap/portal-bundle-merkle/swap-helpers.js';
|
|
10
|
+
export type { FlapBatchSwapSignParams, FlapBatchSwapResult, FlapQuickBatchSwapSignParams, FlapQuickBatchSwapResult, FlapCrossSwapParams, FlapCrossSwapResult, } from '../domains/flap/portal-bundle-merkle/swap.js';
|
|
11
11
|
export { pancakeBundleSwapMerkle, pancakeBatchSwapMerkle, pancakeQuickBatchSwapMerkle, pancakeCrossSwapMerkle, type PancakeBatchSwapSignParams, type PancakeBatchSwapResult, type PancakeQuickBatchSwapParams, type PancakeQuickBatchSwapResult, type PancakeCrossSwapParams, type PancakeCrossSwapResult, } from '../chains/bsc/pancake/bundle-swap.js';
|
|
12
12
|
export type { PancakeSwapSignConfig, PancakeSwapConfig, PancakeBundleSwapSignParams, PancakeBundleSwapParams, PancakeSwapResult, SwapRouteType, RouteParams, V2RouteParams, V3SingleRouteParams, V3MultiRouteParams, } from '../chains/bsc/pancake/bundle-swap-helpers.js';
|
|
13
13
|
export { fourBundleBuyFirstMerkle, type FourBuyFirstConfig, type FourBundleBuyFirstParams, type FourBuyFirstSignConfig, type FourBundleBuyFirstSignParams, type FourBuyFirstResult, } from '../chains/bsc/four/swap-buy-first.js';
|
|
14
|
-
export { flapBundleBuyFirstMerkle } from '../
|
|
15
|
-
export type { FlapBuyFirstSignConfig, FlapBuyFirstConfig, FlapBundleBuyFirstSignParams, FlapBundleBuyFirstParams, FlapBuyFirstResult, } from '../
|
|
14
|
+
export { flapBundleBuyFirstMerkle } from '../domains/flap/portal-bundle-merkle/swap-buy-first.js';
|
|
15
|
+
export type { FlapBuyFirstSignConfig, FlapBuyFirstConfig, FlapBundleBuyFirstSignParams, FlapBundleBuyFirstParams, FlapBuyFirstResult, } from '../domains/flap/portal-bundle-merkle/swap-buy-first-helpers.js';
|
|
16
16
|
export { pancakeBundleBuyFirstMerkle } from '../chains/bsc/pancake/bundle-buy-first.js';
|
|
17
17
|
export type { PancakeBuyFirstSignConfig, PancakeBuyFirstConfig, PancakeBundleBuyFirstSignParams, PancakeBundleBuyFirstParams, PancakeBuyFirstResult, } from '../chains/bsc/pancake/bundle-buy-first-helpers.js';
|
|
18
|
-
export { flapBundleCurveToDex, type CurveToDexChain, type DexPoolType, type CurveToDexSignConfig, type CurveBuyerConfig, type DexBuyerConfig, type FlapCurveToDexParams, type FlapCurveToDexResult, } from '../
|
|
19
|
-
export { flapBundleCreateToDex, type CreateToDexChain, type CreateToDexSignConfig, type CreateTokenInfo, type FlapCreateToDexParams, type FlapCreateToDexResult, } from '../
|
|
20
|
-
export { NONE_EXTENSION_ID, VAULT_TYPE_LABELS, VAULT_TYPE_CATEGORIES, VAULT_FACTORY_ADDRESSES, VAULT_PORTAL_ADDRESSES, VAULT_PORTAL_ABI, VAULT_EXTRA_CONFIG, FLAP_GUARDIAN_ADDRESSES, VAULT_FACTORY_ABI, VAULT_FACTORY_V2_ABI, VAULT_BASE_ABI, VAULT_BASE_V2_ABI, type VaultType, type TaxVaultConfig, type VaultInfo, type FieldDescriptor, type VaultDataSchema, type ApproveAction, type VaultMethodSchema, type VaultUISchema, encodeVaultData, buildVaultParams, buildVaultExtensionParams, getVaultFactoryAddress, getVaultPortalAddress, queryVaultDataSchema, queryVaultUISchema, queryVaultDescription, validateVaultFactory, getVaultInfo, isValidContract, } from '../
|
|
18
|
+
export { flapBundleCurveToDex, type CurveToDexChain, type DexPoolType, type CurveToDexSignConfig, type CurveBuyerConfig, type DexBuyerConfig, type FlapCurveToDexParams, type FlapCurveToDexResult, } from '../domains/flap/portal-bundle-merkle/curve-to-dex.js';
|
|
19
|
+
export { flapBundleCreateToDex, type CreateToDexChain, type CreateToDexSignConfig, type CreateTokenInfo, type FlapCreateToDexParams, type FlapCreateToDexResult, } from '../domains/flap/portal-bundle-merkle/create-to-dex.js';
|
|
20
|
+
export { NONE_EXTENSION_ID, VAULT_TYPE_LABELS, VAULT_TYPE_CATEGORIES, VAULT_FACTORY_ADDRESSES, VAULT_PORTAL_ADDRESSES, VAULT_PORTAL_ABI, VAULT_EXTRA_CONFIG, FLAP_GUARDIAN_ADDRESSES, VAULT_FACTORY_ABI, VAULT_FACTORY_V2_ABI, VAULT_BASE_ABI, VAULT_BASE_V2_ABI, type VaultType, type TaxVaultConfig, type VaultInfo, type FieldDescriptor, type VaultDataSchema, type ApproveAction, type VaultMethodSchema, type VaultUISchema, encodeVaultData, buildVaultParams, buildVaultExtensionParams, getVaultFactoryAddress, getVaultPortalAddress, queryVaultDataSchema, queryVaultUISchema, queryVaultDescription, validateVaultFactory, getVaultInfo, isValidContract, } from '../domains/flap/vault.js';
|
|
21
21
|
export { quoteV2, quoteV3, quote, getTokenToNativeQuote, getNativeToTokenQuote,
|
|
22
22
|
/** 链名字符串版 WETH/WBNB 地址(与 shared/constants.getWrappedNativeAddress(chainId) 签名不同) */
|
|
23
|
-
getWrappedNativeAddress, getStableCoins, } from '../
|
|
23
|
+
getWrappedNativeAddress, getStableCoins, } from '../domains/quote/quote-helpers.js';
|
|
24
24
|
export { submitDirectToRpc, submitDirectToRpcSequential, submitDirectToRpcSequentialNoWait, submitDirectToRpcParallel, submitDirectToRpcSmart, submitDirectToRpcSmart as xlayerBundleSubmit, type DirectSubmitConfig, type DirectSubmitResult, type DirectTxResult, } from '../chains/bsc/four/submit.js';
|
|
25
25
|
export { submitBundleToEni, submitEniParallelThenProfit, type EniBundleSubmitConfig, type EniBundleSubmitResult, } from '../chains/eni/submit.js';
|
|
26
|
-
export { directV2BatchBuy, directV2BatchSell, directV3BatchBuy, directV3BatchSell, getRouterAddress, DIRECT_ROUTERS, type DirectV2BuyParams, type DirectV2SellParams, type DirectV3BuyParams, type DirectV3SellParams, type DirectRouterResult, type DirectRouterSignConfig, type DexKey, type RouterVersion, } from '../dex/index.js';
|
|
26
|
+
export { directV2BatchBuy, directV2BatchSell, directV3BatchBuy, directV3BatchSell, getRouterAddress, DIRECT_ROUTERS, type DirectV2BuyParams, type DirectV2SellParams, type DirectV3BuyParams, type DirectV3SellParams, type DirectRouterResult, type DirectRouterSignConfig, type DexKey, type RouterVersion, } from '../domains/dex/index.js';
|
|
27
27
|
export * as XLayer from '../chains/xlayer/eoa/index.js';
|
|
28
28
|
export { createPortalQuery as xlayerCreatePortalQuery, PortalQuery as XLayerPortalQuery, encodeBuyCall as xlayerEncodeBuyCall, encodeSellCall as xlayerEncodeSellCall, encodeApproveCall as xlayerEncodeApproveCall, parseOkb as xlayerParseOkb, formatOkb as xlayerFormatOkb, XLAYER_CHAIN_ID, FLAP_PORTAL as XLAYER_FLAP_PORTAL, ENTRYPOINT_V06 as XLAYER_ENTRYPOINT, SIMPLE_ACCOUNT_FACTORY as XLAYER_FACTORY, PARTICLE_BUNDLER_URL as XLAYER_BUNDLER_URL, WOKB as XLAYER_WOKB, POTATOSWAP_V2_ROUTER as XLAYER_POTATOSWAP_ROUTER, signEoaWashBuyTransactions as xlayerSignEoaWashBuyTransactions, signEoaWashSellTransactions as xlayerSignEoaWashSellTransactions, signEoaWashVolumeTransactions as xlayerSignEoaWashVolumeTransactions, type EoaWashPoolType as XLayerEoaWashPoolType, type EoaWashVolumeParams as XLayerEoaWashVolumeParams, type EoaWashVolumeResult as XLayerEoaWashVolumeResult, xlayerQuickBatchSwapMerkle, xlayerCrossSwapMerkle, xlayerPureCrossSwapMerkle, type XLayerEoaSwapConfig, type XLayerQuickBatchSwapParams, type XLayerQuickBatchSwapResult, type XLayerCrossSwapParams, type XLayerCrossSwapResult, type XLayerPureCrossSwapParams, type XLayerPureCrossSwapResult, type BundleSwapParams as XLayerBundleSwapParams, type BundleSwapSignParams as XLayerBundleSwapSignParams, type BundleBatchSwapParams as XLayerBundleBatchSwapParams, type BundleBatchSwapSignParams as XLayerBundleBatchSwapSignParams, type BuyFirstParams as XLayerBuyFirstParams, type BuyFirstResult as XLayerBuyFirstResult, } from '../chains/xlayer/eoa/index.js';
|
|
29
29
|
export * as XLayerEIP7702 from '../chains/xlayer/eip7702/index.js';
|
|
@@ -10,23 +10,23 @@
|
|
|
10
10
|
// Four内盘换手
|
|
11
11
|
export { fourBundleSwapMerkle, fourBatchSwapMerkle, fourQuickBatchSwapMerkle, } from '../chains/bsc/four/swap.js';
|
|
12
12
|
// Flap内盘换手
|
|
13
|
-
export { flapBundleSwapMerkle, flapBatchSwapMerkle, flapQuickBatchSwapMerkle, flapCrossSwapMerkle, } from '../
|
|
13
|
+
export { flapBundleSwapMerkle, flapBatchSwapMerkle, flapQuickBatchSwapMerkle, flapCrossSwapMerkle, } from '../domains/flap/portal-bundle-merkle/swap.js';
|
|
14
14
|
// PancakeSwap V2/V3通用换手
|
|
15
15
|
export { pancakeBundleSwapMerkle, pancakeBatchSwapMerkle, pancakeQuickBatchSwapMerkle, pancakeCrossSwapMerkle, } from '../chains/bsc/pancake/bundle-swap.js';
|
|
16
16
|
// 先买后卖(Buy-First)入口
|
|
17
17
|
export { fourBundleBuyFirstMerkle, } from '../chains/bsc/four/swap-buy-first.js';
|
|
18
|
-
export { flapBundleBuyFirstMerkle } from '../
|
|
18
|
+
export { flapBundleBuyFirstMerkle } from '../domains/flap/portal-bundle-merkle/swap-buy-first.js';
|
|
19
19
|
export { pancakeBundleBuyFirstMerkle } from '../chains/bsc/pancake/bundle-buy-first.js';
|
|
20
20
|
// ✅ 内盘买到外盘(Bonding Curve → DEX)- 已存在代币
|
|
21
|
-
export { flapBundleCurveToDex, } from '../
|
|
21
|
+
export { flapBundleCurveToDex, } from '../domains/flap/portal-bundle-merkle/curve-to-dex.js';
|
|
22
22
|
// ✅ 发币 + 一键买到外盘(Create → Curve → DEX)- 新代币
|
|
23
|
-
export { flapBundleCreateToDex, } from '../
|
|
23
|
+
export { flapBundleCreateToDex, } from '../domains/flap/portal-bundle-merkle/create-to-dex.js';
|
|
24
24
|
// ✅ Tax Vault 金库模块(基于 VaultPortal + VaultFactory 规范)
|
|
25
|
-
export { NONE_EXTENSION_ID, VAULT_TYPE_LABELS, VAULT_TYPE_CATEGORIES, VAULT_FACTORY_ADDRESSES, VAULT_PORTAL_ADDRESSES, VAULT_PORTAL_ABI, VAULT_EXTRA_CONFIG, FLAP_GUARDIAN_ADDRESSES, VAULT_FACTORY_ABI, VAULT_FACTORY_V2_ABI, VAULT_BASE_ABI, VAULT_BASE_V2_ABI, encodeVaultData, buildVaultParams, buildVaultExtensionParams, getVaultFactoryAddress, getVaultPortalAddress, queryVaultDataSchema, queryVaultUISchema, queryVaultDescription, validateVaultFactory, getVaultInfo, isValidContract, } from '../
|
|
26
|
-
// ✅ V2/V3 报价工具(QUOTE_CONFIG / QUOTE_V3_FEE_TIERS 见 root-foundations /
|
|
25
|
+
export { NONE_EXTENSION_ID, VAULT_TYPE_LABELS, VAULT_TYPE_CATEGORIES, VAULT_FACTORY_ADDRESSES, VAULT_PORTAL_ADDRESSES, VAULT_PORTAL_ABI, VAULT_EXTRA_CONFIG, FLAP_GUARDIAN_ADDRESSES, VAULT_FACTORY_ABI, VAULT_FACTORY_V2_ABI, VAULT_BASE_ABI, VAULT_BASE_V2_ABI, encodeVaultData, buildVaultParams, buildVaultExtensionParams, getVaultFactoryAddress, getVaultPortalAddress, queryVaultDataSchema, queryVaultUISchema, queryVaultDescription, validateVaultFactory, getVaultInfo, isValidContract, } from '../domains/flap/vault.js';
|
|
26
|
+
// ✅ V2/V3 报价工具(QUOTE_CONFIG / QUOTE_V3_FEE_TIERS 见 root-foundations / core/constants/quote)
|
|
27
27
|
export { quoteV2, quoteV3, quote, getTokenToNativeQuote, getNativeToTokenQuote,
|
|
28
28
|
/** 链名字符串版 WETH/WBNB 地址(与 shared/constants.getWrappedNativeAddress(chainId) 签名不同) */
|
|
29
|
-
getWrappedNativeAddress, getStableCoins, } from '../
|
|
29
|
+
getWrappedNativeAddress, getStableCoins, } from '../domains/quote/quote-helpers.js';
|
|
30
30
|
// ✅ Monad 等不支持 Bundle 的链:逐笔 RPC 广播方法(服务器端使用)
|
|
31
31
|
export { submitDirectToRpc, submitDirectToRpcSequential, submitDirectToRpcSequentialNoWait, submitDirectToRpcParallel, submitDirectToRpcSmart, submitDirectToRpcSmart as xlayerBundleSubmit, } from '../chains/bsc/four/submit.js';
|
|
32
32
|
// ✅ ENI Bundle 提交
|
|
@@ -42,7 +42,7 @@ directV3BatchBuy, directV3BatchSell,
|
|
|
42
42
|
// 辅助函数
|
|
43
43
|
getRouterAddress,
|
|
44
44
|
// 常量
|
|
45
|
-
DIRECT_ROUTERS, } from '../dex/index.js';
|
|
45
|
+
DIRECT_ROUTERS, } from '../domains/dex/index.js';
|
|
46
46
|
// ============================================================
|
|
47
47
|
// ✅ XLayer SDK(EOA 模式 + EIP-7702)
|
|
48
48
|
// ============================================================
|
package/dist/index.d.ts
CHANGED
|
@@ -1,20 +1,17 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* SDK 公共 API
|
|
2
|
+
* SDK 公共 API 聚合入口(3.0 · 不推荐作默认消费入口)
|
|
3
3
|
*
|
|
4
|
-
* -
|
|
5
|
-
* -
|
|
6
|
-
* -
|
|
7
|
-
*
|
|
8
|
-
* @see README.zh-CN.md · README.md
|
|
9
|
-
* @see 子路径:`four-flap-meme-sdk/foundation` · `four-flap-meme-sdk/bundle-core` · `four-flap-meme-sdk/flows` · `four-flap-meme-sdk/constants`
|
|
4
|
+
* - **实现**:`core/` · `domains/*` · `chains/` · `bundle/` · 瘦 `utils/`
|
|
5
|
+
* - **扁平再导出**:`exports/root-*.ts`
|
|
6
|
+
* - **具名 facade**:见 `package.json#exports` / docs/PUBLIC_API.md §2
|
|
10
7
|
*/
|
|
11
8
|
export * from './exports/root-foundations.js';
|
|
12
9
|
export * from './exports/root-bundle-and-tooling.js';
|
|
13
10
|
export * from './exports/root-swap-dex-and-xlayer.js';
|
|
14
11
|
export * from './exports/root-eni-and-bsc-iro.js';
|
|
15
12
|
/** 横向基础:错误收口、Logger、共享类型、Nonce/Gas/Tx 工具 */
|
|
16
|
-
export * as foundation from './
|
|
13
|
+
export * as foundation from './core/foundation.js';
|
|
17
14
|
/** Bundle 共享核心:internal、submit、config-helpers、four-meme 实现 */
|
|
18
|
-
export * as bundleCore from './bundle
|
|
15
|
+
export * as bundleCore from './bundle/index.js';
|
|
19
16
|
/** 高层业务流程 */
|
|
20
|
-
export * as flows from './flows/index.js';
|
|
17
|
+
export * as flows from './domains/flows/index.js';
|
package/dist/index.js
CHANGED
|
@@ -1,20 +1,17 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* SDK 公共 API
|
|
2
|
+
* SDK 公共 API 聚合入口(3.0 · 不推荐作默认消费入口)
|
|
3
3
|
*
|
|
4
|
-
* -
|
|
5
|
-
* -
|
|
6
|
-
* -
|
|
7
|
-
*
|
|
8
|
-
* @see README.zh-CN.md · README.md
|
|
9
|
-
* @see 子路径:`four-flap-meme-sdk/foundation` · `four-flap-meme-sdk/bundle-core` · `four-flap-meme-sdk/flows` · `four-flap-meme-sdk/constants`
|
|
4
|
+
* - **实现**:`core/` · `domains/*` · `chains/` · `bundle/` · 瘦 `utils/`
|
|
5
|
+
* - **扁平再导出**:`exports/root-*.ts`
|
|
6
|
+
* - **具名 facade**:见 `package.json#exports` / docs/PUBLIC_API.md §2
|
|
10
7
|
*/
|
|
11
8
|
export * from './exports/root-foundations.js';
|
|
12
9
|
export * from './exports/root-bundle-and-tooling.js';
|
|
13
10
|
export * from './exports/root-swap-dex-and-xlayer.js';
|
|
14
11
|
export * from './exports/root-eni-and-bsc-iro.js';
|
|
15
12
|
/** 横向基础:错误收口、Logger、共享类型、Nonce/Gas/Tx 工具 */
|
|
16
|
-
export * as foundation from './
|
|
13
|
+
export * as foundation from './core/foundation.js';
|
|
17
14
|
/** Bundle 共享核心:internal、submit、config-helpers、four-meme 实现 */
|
|
18
|
-
export * as bundleCore from './bundle
|
|
15
|
+
export * as bundleCore from './bundle/index.js';
|
|
19
16
|
/** 高层业务流程 */
|
|
20
|
-
export * as flows from './flows/index.js';
|
|
17
|
+
export * as flows from './domains/flows/index.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ethers, JsonRpcProvider } from 'ethers';
|
|
2
|
-
import { GAS_LIMITS, isEniChain } from '../
|
|
3
|
-
import { buildGasFields } from '../
|
|
4
|
-
import { getErc20Decimals } from '../
|
|
2
|
+
import { GAS_LIMITS, isEniChain } from '../core/constants/index.js';
|
|
3
|
+
import { buildGasFields } from '../core/gas/bundle-gas.js';
|
|
4
|
+
import { getErc20Decimals } from '../core/erc20/decimals.js';
|
|
5
5
|
function getTxTypeForChain(chainId) {
|
|
6
6
|
return isEniChain(chainId) ? 2 : 0;
|
|
7
7
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Bundle 交易辅助工具 — 实现已迁至
|
|
2
|
+
* Bundle 交易辅助工具 — 实现已迁至 core/
|
|
3
3
|
* 本文件保留 re-export,兼容现有 import 路径。
|
|
4
4
|
*/
|
|
5
|
-
export { NonceManager } from '../
|
|
6
|
-
export { type GasPriceConfig, type GasEstimateConfig, type BuildTransactionOptions, type CommonBundleConfig, getOptimizedGasPrice, estimateGasWithSafety, estimateGasBatch, buildTransaction, getGasLimit, getGasPriceConfig, getTxType, buildGasFields, } from '../
|
|
7
|
-
export { type ProfitHopConfig, type ProfitHopResult, PROFIT_HOP_COUNT, buildProfitHopTransactions, } from '../
|
|
8
|
-
export { getChainId, signTransactionsBatch, signTransactionsBatchMultiWallet, validateSignedTransactions, } from '../
|
|
9
|
-
export { getDeadline, encodeV3Path, decodeV3Path } from '../
|
|
10
|
-
import '../
|
|
5
|
+
export { NonceManager } from '../core/nonce/nonce-manager.js';
|
|
6
|
+
export { type GasPriceConfig, type GasEstimateConfig, type BuildTransactionOptions, type CommonBundleConfig, getOptimizedGasPrice, estimateGasWithSafety, estimateGasBatch, buildTransaction, getGasLimit, getGasPriceConfig, getTxType, buildGasFields, } from '../core/gas/bundle-gas.js';
|
|
7
|
+
export { type ProfitHopConfig, type ProfitHopResult, PROFIT_HOP_COUNT, buildProfitHopTransactions, } from '../core/gas/profit-hop.js';
|
|
8
|
+
export { getChainId, signTransactionsBatch, signTransactionsBatchMultiWallet, validateSignedTransactions, } from '../core/tx/sign-batch.js';
|
|
9
|
+
export { getDeadline, encodeV3Path, decodeV3Path } from '../core/dex/v3-path.js';
|
|
10
|
+
import '../core/tx/wallet-sign-patch.js';
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Bundle 交易辅助工具 — 实现已迁至
|
|
2
|
+
* Bundle 交易辅助工具 — 实现已迁至 core/
|
|
3
3
|
* 本文件保留 re-export,兼容现有 import 路径。
|
|
4
4
|
*/
|
|
5
|
-
export { NonceManager } from '../
|
|
6
|
-
export { getOptimizedGasPrice, estimateGasWithSafety, estimateGasBatch, buildTransaction, getGasLimit, getGasPriceConfig, getTxType, buildGasFields, } from '../
|
|
7
|
-
export { PROFIT_HOP_COUNT, buildProfitHopTransactions, } from '../
|
|
8
|
-
export { getChainId, signTransactionsBatch, signTransactionsBatchMultiWallet, validateSignedTransactions, } from '../
|
|
9
|
-
export { getDeadline, encodeV3Path, decodeV3Path } from '../
|
|
5
|
+
export { NonceManager } from '../core/nonce/nonce-manager.js';
|
|
6
|
+
export { getOptimizedGasPrice, estimateGasWithSafety, estimateGasBatch, buildTransaction, getGasLimit, getGasPriceConfig, getTxType, buildGasFields, } from '../core/gas/bundle-gas.js';
|
|
7
|
+
export { PROFIT_HOP_COUNT, buildProfitHopTransactions, } from '../core/gas/profit-hop.js';
|
|
8
|
+
export { getChainId, signTransactionsBatch, signTransactionsBatchMultiWallet, validateSignedTransactions, } from '../core/tx/sign-batch.js';
|
|
9
|
+
export { getDeadline, encodeV3Path, decodeV3Path } from '../core/dex/v3-path.js';
|
|
10
10
|
// 加载 Wallet EIP-1559 patch(NonceManager 模块也会加载,此处确保从 bundle-helpers 导入时生效)
|
|
11
|
-
import '../
|
|
11
|
+
import '../core/tx/wallet-sign-patch.js';
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
* 公共常量 - 向后兼容 re-export 层
|
|
3
3
|
*
|
|
4
4
|
* 新代码请直接使用 `shared/constants`:
|
|
5
|
-
* `import { CHAINS, ADDRESSES, getProfitRateBps } from '../
|
|
5
|
+
* `import { CHAINS, ADDRESSES, getProfitRateBps } from '../core/constants/index.js'`
|
|
6
6
|
*
|
|
7
7
|
* v2:不再导出 `CHAIN` / `DEFAULT_DEADLINE_MINUTES` / `PROFIT_CONFIG` / 报价 `V3_FEE_TIERS`。
|
|
8
8
|
*/
|
|
9
|
-
export { CHAINS, CHAIN_ID_MAP, getChainById, getChainName, getDefaultRpcUrl, isKnownChain, isBscChain, isXLayerChain, isMonadChain, isEniChain, getConfirmationTimeout, GAS_LIMITS, GAS_CONFIG, calculateGasLimit, getTransferGasLimit, ZERO_ADDRESS, BLOCKRAZOR_BUILDER_EOA, ADDRESSES, getAddress, getWrappedNativeAddress, getMulticall3Address, getFlapPortalAddress, isZeroAddress, isNativeToken, getProfitRecipient, getAllProfitRecipients, getProfitRateBps, calculateProfitAmount, calculateProfitHopGasCost, TRANSFER_FEE_PER_ADDRESS, getTransferFeePerAddress, calculateTransferFee, QUOTE_CONFIG, QUOTE_V3_FEE_TIERS, } from '../
|
|
9
|
+
export { CHAINS, CHAIN_ID_MAP, getChainById, getChainName, getDefaultRpcUrl, isKnownChain, isBscChain, isXLayerChain, isMonadChain, isEniChain, getConfirmationTimeout, GAS_LIMITS, GAS_CONFIG, calculateGasLimit, getTransferGasLimit, ZERO_ADDRESS, BLOCKRAZOR_BUILDER_EOA, ADDRESSES, getAddress, getWrappedNativeAddress, getMulticall3Address, getFlapPortalAddress, isZeroAddress, isNativeToken, getProfitRecipient, getAllProfitRecipients, getProfitRateBps, calculateProfitAmount, calculateProfitHopGasCost, TRANSFER_FEE_PER_ADDRESS, getTransferFeePerAddress, calculateTransferFee, QUOTE_CONFIG, QUOTE_V3_FEE_TIERS, } from '../core/constants/index.js';
|
package/dist/utils/constants.js
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
* 公共常量 - 向后兼容 re-export 层
|
|
3
3
|
*
|
|
4
4
|
* 新代码请直接使用 `shared/constants`:
|
|
5
|
-
* `import { CHAINS, ADDRESSES, getProfitRateBps } from '../
|
|
5
|
+
* `import { CHAINS, ADDRESSES, getProfitRateBps } from '../core/constants/index.js'`
|
|
6
6
|
*
|
|
7
7
|
* v2:不再导出 `CHAIN` / `DEFAULT_DEADLINE_MINUTES` / `PROFIT_CONFIG` / 报价 `V3_FEE_TIERS`。
|
|
8
8
|
*/
|
|
9
|
-
export { CHAINS, CHAIN_ID_MAP, getChainById, getChainName, getDefaultRpcUrl, isKnownChain, isBscChain, isXLayerChain, isMonadChain, isEniChain, getConfirmationTimeout, GAS_LIMITS, GAS_CONFIG, calculateGasLimit, getTransferGasLimit, ZERO_ADDRESS, BLOCKRAZOR_BUILDER_EOA, ADDRESSES, getAddress, getWrappedNativeAddress, getMulticall3Address, getFlapPortalAddress, isZeroAddress, isNativeToken, getProfitRecipient, getAllProfitRecipients, getProfitRateBps, calculateProfitAmount, calculateProfitHopGasCost, TRANSFER_FEE_PER_ADDRESS, getTransferFeePerAddress, calculateTransferFee, QUOTE_CONFIG, QUOTE_V3_FEE_TIERS, } from '../
|
|
9
|
+
export { CHAINS, CHAIN_ID_MAP, getChainById, getChainName, getDefaultRpcUrl, isKnownChain, isBscChain, isXLayerChain, isMonadChain, isEniChain, getConfirmationTimeout, GAS_LIMITS, GAS_CONFIG, calculateGasLimit, getTransferGasLimit, ZERO_ADDRESS, BLOCKRAZOR_BUILDER_EOA, ADDRESSES, getAddress, getWrappedNativeAddress, getMulticall3Address, getFlapPortalAddress, isZeroAddress, isNativeToken, getProfitRecipient, getAllProfitRecipients, getProfitRateBps, calculateProfitAmount, calculateProfitHopGasCost, TRANSFER_FEE_PER_ADDRESS, getTransferFeePerAddress, calculateTransferFee, QUOTE_CONFIG, QUOTE_V3_FEE_TIERS, } from '../core/constants/index.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Contract, Wallet } from 'ethers';
|
|
2
2
|
import { TokenManager, TokenManager2, TokenManagerHelper3 } from '../abis/index.js';
|
|
3
|
-
import { ADDRESSES } from '../
|
|
3
|
+
import { ADDRESSES } from '../core/constants/index.js';
|
|
4
4
|
import { createProvider } from './provider-factory.js';
|
|
5
5
|
const TOKEN_MANAGER_ABI = TokenManager;
|
|
6
6
|
const TOKEN_MANAGER2_ABI = TokenManager2;
|
package/dist/utils/errors.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { SdkErrorCode } from '../types/errors.js';
|
|
1
|
+
import { SdkErrorCode } from '../core/legacy-types/errors.js';
|
|
2
2
|
import type { FourErrorCode } from './types/errors.js';
|
|
3
|
-
export { SdkErrorCode } from '../types/errors.js';
|
|
3
|
+
export { SdkErrorCode } from '../core/legacy-types/errors.js';
|
|
4
4
|
export type { FourErrorCode } from './types/errors.js';
|
|
5
5
|
export declare function parseFourError(err: unknown): {
|
|
6
6
|
code?: FourErrorCode;
|
package/dist/utils/errors.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { getErrorMessageFromUnknown } from '../
|
|
2
|
-
import { SdkErrorCode } from '../types/errors.js';
|
|
3
|
-
export { SdkErrorCode } from '../types/errors.js';
|
|
1
|
+
import { getErrorMessageFromUnknown } from '../core/normalize-unknown.js';
|
|
2
|
+
import { SdkErrorCode } from '../core/legacy-types/errors.js';
|
|
3
|
+
export { SdkErrorCode } from '../core/legacy-types/errors.js';
|
|
4
4
|
const MESSAGES = {
|
|
5
5
|
GW: 'Amount precision is not aligned to GWEI',
|
|
6
6
|
ZA: "The 'to' address should not be address(0)",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* 多跳(Hop Chain)转账链生成工具
|
|
3
3
|
*
|
|
4
|
-
* 提取自 chains/bsc/four/swap.ts、chains/bsc/pancake/bundle-swap.ts、
|
|
4
|
+
* 提取自 chains/bsc/four/swap.ts、chains/bsc/pancake/bundle-swap.ts、domains/flap/portal-bundle-merkle/swap.ts
|
|
5
5
|
* 消除三个文件之间的复制代码
|
|
6
6
|
*/
|
|
7
7
|
import { ethers, Wallet, JsonRpcProvider } from 'ethers';
|
package/dist/utils/hop-chains.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* 多跳(Hop Chain)转账链生成工具
|
|
3
3
|
*
|
|
4
|
-
* 提取自 chains/bsc/four/swap.ts、chains/bsc/pancake/bundle-swap.ts、
|
|
4
|
+
* 提取自 chains/bsc/four/swap.ts、chains/bsc/pancake/bundle-swap.ts、domains/flap/portal-bundle-merkle/swap.ts
|
|
5
5
|
* 消除三个文件之间的复制代码
|
|
6
6
|
*/
|
|
7
7
|
import { ethers, Wallet } from 'ethers';
|
|
8
|
-
import { GAS_LIMITS } from '../
|
|
8
|
+
import { GAS_LIMITS } from '../core/constants/index.js';
|
|
9
9
|
import { ERC20_ABI } from '../abis/common.js';
|
|
10
10
|
import { generateWallets } from './wallet.js';
|
|
11
11
|
export const NATIVE_TRANSFER_GAS_LIMIT = GAS_LIMITS.NATIVE_TRANSFER;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Contract, JsonRpcProvider } from 'ethers';
|
|
2
2
|
import TokenManager2Abi from '../abis/contracts/TokenManager2.json' with { type: 'json' };
|
|
3
|
-
import { ADDRESSES } from '../
|
|
3
|
+
import { ADDRESSES } from '../core/constants/index.js';
|
|
4
4
|
const TOKEN_MANAGER2_ABI = TokenManager2Abi;
|
|
5
5
|
// 链上识别:template & 0x10000 > 0
|
|
6
6
|
export async function isExclusiveOnChain(params) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ethers, JsonRpcProvider } from 'ethers';
|
|
2
|
-
import { Club48Client } from '../
|
|
3
|
-
import { GAS_LIMITS } from '../
|
|
2
|
+
import { Club48Client } from '../core/clients/club48.js';
|
|
3
|
+
import { GAS_LIMITS } from '../core/constants/index.js';
|
|
4
4
|
/**
|
|
5
5
|
* 隐秘转账(原生币,多跳)
|
|
6
6
|
* - 生成 hopCount 个中转地址
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* 换手交易通用工具函数
|
|
3
3
|
*/
|
|
4
4
|
import { ethers, Contract } from 'ethers';
|
|
5
|
-
import { batchCheckAllowances } from '
|
|
5
|
+
import { batchCheckAllowances } from '../core/erc20.js';
|
|
6
6
|
import { ERC20_ABI } from '../abis/common.js';
|
|
7
7
|
import { NonceManager, getOptimizedGasPrice } from './bundle-helpers.js';
|
|
8
8
|
const APPROVAL_THRESHOLD = ethers.MaxUint256 / 2n;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export type { BundleSubmitResult, SignedTransactionsResult, AirdropDisperseParams, AirdropDisperseSignParams, AirdropSweepParams, AirdropSweepSignParams, DisperseParams, DisperseSignParams, SweepParams, SweepSignParams, } from '../../
|
|
1
|
+
export type { BundleSubmitResult, SignedTransactionsResult, AirdropDisperseParams, AirdropDisperseSignParams, AirdropSweepParams, AirdropSweepSignParams, DisperseParams, DisperseSignParams, SweepParams, SweepSignParams, } from '../../core/types/airdrop-sweep.js';
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
/** utils 层类型 facade
|
|
2
|
-
export type * from '
|
|
3
|
-
export type * from '
|
|
1
|
+
/** utils 层类型 facade(业务类型源在 core/types;utils 不得依赖 domains) */
|
|
2
|
+
export type * from '../../core/types/holders-maker.js';
|
|
3
|
+
export type * from '../../core/types/lp-inspect.js';
|
|
4
4
|
export type * from './airdrop-sweep.js';
|
|
5
|
-
export type * from '
|
|
6
|
-
export type * from '
|
|
7
|
-
export type * from '
|
|
5
|
+
export type * from '../../core/types/private-sale.js';
|
|
6
|
+
export type * from '../../core/types/quote-helpers.js';
|
|
7
|
+
export type * from '../../core/types/erc20.js';
|
|
8
8
|
export type * from './wallet.js';
|
|
9
9
|
export type * from './stealth-transfer.js';
|
|
10
10
|
export type * from './errors.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { SoulPointSignatureMode, VNormalizationMode } from '../../
|
|
1
|
+
import type { SoulPointSignatureMode, VNormalizationMode } from '../../core/clients/club48.js';
|
|
2
2
|
export type StealthTransferResult = {
|
|
3
3
|
bundleUuid: string;
|
|
4
4
|
txs: string[];
|
package/dist/utils/wallet.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { type GeneratedWallet } from '../
|
|
1
|
+
import { type GeneratedWallet } from '../core/wallet/generate.js';
|
|
2
2
|
import type { MultiTokenBalancesResult, MulticallResult, PrivateKeyValidation } from './types/wallet.js';
|
|
3
3
|
export type { PrivateKeyValidation, MulticallResult, MultiTokenBalancesResult, } from './types/wallet.js';
|
|
4
|
-
export type { GeneratedWallet } from '../
|
|
4
|
+
export type { GeneratedWallet } from '../core/wallet/generate.js';
|
|
5
5
|
/**
|
|
6
6
|
* 批量生成钱包(并行优化)
|
|
7
7
|
*/
|
package/dist/utils/wallet.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Wallet, Interface, JsonRpcProvider, formatEther, formatUnits, isHexString } from 'ethers';
|
|
2
|
-
import { CHAIN_ID_MAP, ADDRESSES } from '../
|
|
2
|
+
import { CHAIN_ID_MAP, ADDRESSES } from '../core/constants/index.js';
|
|
3
3
|
import { ERC20_ABI, MULTICALL3_ABI } from '../abis/common.js';
|
|
4
|
-
import { getErrorMessageFromUnknown } from '../
|
|
5
|
-
import { generateWallets as generateWalletsFromFoundation, } from '../
|
|
4
|
+
import { getErrorMessageFromUnknown } from '../core/index.js';
|
|
5
|
+
import { generateWallets as generateWalletsFromFoundation, } from '../core/wallet/generate.js';
|
|
6
6
|
// ============================================================================
|
|
7
7
|
// 常量
|
|
8
8
|
// ============================================================================
|