@whetstone-research/doppler-sdk 0.0.1-alpha.9 → 0.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/LICENSE +21 -0
- package/README.md +726 -25
- package/dist/DopplerSDK.d.mts +45 -7
- package/dist/DopplerSDK.d.ts +45 -7
- package/dist/DopplerSDK.js +35 -12
- package/dist/DopplerSDK.mjs +34 -11
- package/dist/abis/bytecodes.d.mts +3 -2
- package/dist/abis/bytecodes.d.ts +3 -2
- package/dist/abis/bytecodes.js +9 -6
- package/dist/abis/bytecodes.mjs +1 -2
- package/dist/abis/index.d.mts +1507 -129
- package/dist/abis/index.d.ts +1507 -129
- package/dist/abis/index.js +43 -20
- package/dist/abis/index.mjs +2 -3
- package/dist/addresses.d.mts +16 -3
- package/dist/addresses.d.ts +16 -3
- package/dist/addresses.js +13 -5
- package/dist/addresses.mjs +2 -2
- package/dist/builders/DynamicAuctionBuilder.d.mts +119 -0
- package/dist/builders/DynamicAuctionBuilder.d.ts +119 -0
- package/dist/builders/DynamicAuctionBuilder.js +29 -0
- package/dist/builders/DynamicAuctionBuilder.js.map +1 -0
- package/dist/builders/DynamicAuctionBuilder.mjs +20 -0
- package/dist/builders/DynamicAuctionBuilder.mjs.map +1 -0
- package/dist/builders/MulticurveBuilder.d.mts +132 -0
- package/dist/builders/MulticurveBuilder.d.ts +132 -0
- package/dist/builders/MulticurveBuilder.js +29 -0
- package/dist/builders/MulticurveBuilder.js.map +1 -0
- package/dist/builders/MulticurveBuilder.mjs +20 -0
- package/dist/builders/MulticurveBuilder.mjs.map +1 -0
- package/dist/builders/StaticAuctionBuilder.d.mts +124 -0
- package/dist/builders/StaticAuctionBuilder.d.ts +124 -0
- package/dist/builders/StaticAuctionBuilder.js +29 -0
- package/dist/builders/StaticAuctionBuilder.js.map +1 -0
- package/dist/builders/StaticAuctionBuilder.mjs +20 -0
- package/dist/builders/StaticAuctionBuilder.mjs.map +1 -0
- package/dist/builders/index.d.mts +8 -0
- package/dist/builders/index.d.ts +8 -0
- package/dist/builders/index.js +56 -0
- package/dist/builders/index.js.map +1 -0
- package/dist/builders/index.mjs +23 -0
- package/dist/builders/index.mjs.map +1 -0
- package/dist/builders/shared.d.mts +116 -0
- package/dist/builders/shared.d.ts +116 -0
- package/dist/builders/shared.js +39 -0
- package/dist/builders/shared.js.map +1 -0
- package/dist/builders/shared.mjs +18 -0
- package/dist/builders/shared.mjs.map +1 -0
- package/dist/builders.d.mts +8 -131
- package/dist/builders.d.ts +8 -131
- package/dist/builders.js +44 -5
- package/dist/builders.mjs +22 -3
- package/dist/chunk-3PNCB4W5.js +4 -0
- package/dist/{chunk-KRN3ROUE.js.map → chunk-3PNCB4W5.js.map} +1 -1
- package/dist/chunk-3RK7LRAA.js +282 -0
- package/dist/chunk-3RK7LRAA.js.map +1 -0
- package/dist/chunk-4HM3ERBU.js +13 -0
- package/dist/chunk-4HM3ERBU.js.map +1 -0
- package/dist/{chunk-7W72MFJO.mjs → chunk-4TROGENW.mjs} +5 -4
- package/dist/chunk-4TROGENW.mjs.map +1 -0
- package/dist/chunk-5TL5V6UX.mjs +3 -0
- package/dist/{chunk-AZLFJNTG.mjs.map → chunk-5TL5V6UX.mjs.map} +1 -1
- package/dist/chunk-64AWG57M.mjs +192 -0
- package/dist/chunk-64AWG57M.mjs.map +1 -0
- package/dist/chunk-6KWCHTK3.js +166 -0
- package/dist/chunk-6KWCHTK3.js.map +1 -0
- package/dist/chunk-6OOWOPCX.js +1708 -0
- package/dist/chunk-6OOWOPCX.js.map +1 -0
- package/dist/chunk-7BBRPWQJ.js +257 -0
- package/dist/chunk-7BBRPWQJ.js.map +1 -0
- package/dist/{chunk-AQPINKEW.mjs → chunk-AKSEBAR7.mjs} +29 -19
- package/dist/chunk-AKSEBAR7.mjs.map +1 -0
- package/dist/chunk-AS64GWBX.js +204 -0
- package/dist/chunk-AS64GWBX.js.map +1 -0
- package/dist/chunk-AULFBXM5.mjs +331 -0
- package/dist/chunk-AULFBXM5.mjs.map +1 -0
- package/dist/chunk-AW3WR2D3.mjs +238 -0
- package/dist/chunk-AW3WR2D3.mjs.map +1 -0
- package/dist/chunk-BIQQ53O2.js +45 -0
- package/dist/chunk-BIQQ53O2.js.map +1 -0
- package/dist/chunk-C6MPV3CY.js +260 -0
- package/dist/chunk-C6MPV3CY.js.map +1 -0
- package/dist/{chunk-AYPP5JEQ.mjs → chunk-CLEQO6GU.mjs} +5 -5
- package/dist/chunk-CLEQO6GU.mjs.map +1 -0
- package/dist/chunk-CVHPLURA.js +147 -0
- package/dist/chunk-CVHPLURA.js.map +1 -0
- package/dist/chunk-D2RBCFNW.mjs +130 -0
- package/dist/chunk-D2RBCFNW.mjs.map +1 -0
- package/dist/chunk-ECD4FV3A.mjs +11 -0
- package/dist/chunk-ECD4FV3A.mjs.map +1 -0
- package/dist/chunk-EDJBZPMW.mjs +255 -0
- package/dist/chunk-EDJBZPMW.mjs.map +1 -0
- package/dist/chunk-FPAI4QYW.mjs +145 -0
- package/dist/chunk-FPAI4QYW.mjs.map +1 -0
- package/dist/chunk-HM25ZMO3.js +18 -0
- package/dist/chunk-HM25ZMO3.js.map +1 -0
- package/dist/chunk-IHC6UYKK.js +4 -0
- package/dist/{chunk-DRBRT57F.js.map → chunk-IHC6UYKK.js.map} +1 -1
- package/dist/{chunk-AXA7YT2G.mjs → chunk-J5BFFL3X.mjs} +87 -47
- package/dist/chunk-J5BFFL3X.mjs.map +1 -0
- package/dist/chunk-JIKAD4YL.js +4 -0
- package/dist/{chunk-KEXKKQVW.js.map → chunk-JIKAD4YL.js.map} +1 -1
- package/dist/{chunk-EFAPDN4J.js → chunk-JWEXGALU.js} +730 -33
- package/dist/chunk-JWEXGALU.js.map +1 -0
- package/dist/{chunk-4K5GBNQV.mjs → chunk-KDT76YQE.mjs} +52 -13
- package/dist/chunk-KDT76YQE.mjs.map +1 -0
- package/dist/chunk-LMQLMMEX.js +317 -0
- package/dist/chunk-LMQLMMEX.js.map +1 -0
- package/dist/{chunk-TOMVBPNZ.js → chunk-LS4TK6SX.js} +9 -4
- package/dist/chunk-LS4TK6SX.js.map +1 -0
- package/dist/chunk-M4WMHD3X.mjs +40 -0
- package/dist/chunk-M4WMHD3X.mjs.map +1 -0
- package/dist/chunk-MCOK3UFR.mjs +280 -0
- package/dist/chunk-MCOK3UFR.mjs.map +1 -0
- package/dist/chunk-MGQSQCFG.js +176 -0
- package/dist/chunk-MGQSQCFG.js.map +1 -0
- package/dist/chunk-MKE3BUL3.mjs +3 -0
- package/dist/{chunk-CYDWEPFL.mjs.map → chunk-MKE3BUL3.mjs.map} +1 -1
- package/dist/chunk-MNJ5OYPE.mjs +17 -0
- package/dist/chunk-MNJ5OYPE.mjs.map +1 -0
- package/dist/chunk-MNXD45J7.mjs +164 -0
- package/dist/chunk-MNXD45J7.mjs.map +1 -0
- package/dist/chunk-NGDPQC5E.js +333 -0
- package/dist/chunk-NGDPQC5E.js.map +1 -0
- package/dist/chunk-NNNCVFOH.mjs +16 -0
- package/dist/chunk-NNNCVFOH.mjs.map +1 -0
- package/dist/chunk-NZ4BJ2IC.mjs +315 -0
- package/dist/chunk-NZ4BJ2IC.mjs.map +1 -0
- package/dist/chunk-OKNM7ODQ.js +29 -0
- package/dist/chunk-OKNM7ODQ.js.map +1 -0
- package/dist/{chunk-DCFHANLR.mjs → chunk-OTG75GVH.mjs} +725 -34
- package/dist/chunk-OTG75GVH.mjs.map +1 -0
- package/dist/chunk-OZ6DGBRL.mjs +25 -0
- package/dist/chunk-OZ6DGBRL.mjs.map +1 -0
- package/dist/chunk-P25HBGP5.mjs +3 -0
- package/dist/chunk-P25HBGP5.mjs.map +1 -0
- package/dist/{chunk-XG7K4R56.js → chunk-P7KLEPVI.js} +52 -12
- package/dist/chunk-P7KLEPVI.js.map +1 -0
- package/dist/{chunk-OPKQMN46.mjs → chunk-PAPXGPJB.mjs} +9 -4
- package/dist/chunk-PAPXGPJB.mjs.map +1 -0
- package/dist/chunk-PCNXJAU5.js +19 -0
- package/dist/chunk-PCNXJAU5.js.map +1 -0
- package/dist/{chunk-PMIJTXU6.js → chunk-PD6HWEMG.js} +40 -30
- package/dist/chunk-PD6HWEMG.js.map +1 -0
- package/dist/{chunk-ER42VG7H.js → chunk-PH2KXREH.js} +20 -3
- package/dist/chunk-PH2KXREH.js.map +1 -0
- package/dist/chunk-Q5ERW5ZW.mjs +107 -0
- package/dist/chunk-Q5ERW5ZW.mjs.map +1 -0
- package/dist/chunk-Q7YNBSVH.js +28 -0
- package/dist/chunk-Q7YNBSVH.js.map +1 -0
- package/dist/{chunk-T644D54P.mjs → chunk-QKO2FZGN.mjs} +16 -4
- package/dist/chunk-QKO2FZGN.mjs.map +1 -0
- package/dist/{chunk-CIRZKWLL.js → chunk-RVFSRYI5.js} +5 -3
- package/dist/chunk-RVFSRYI5.js.map +1 -0
- package/dist/{chunk-KPBCG4X2.js → chunk-RW37KJ77.js} +11 -11
- package/dist/chunk-RW37KJ77.js.map +1 -0
- package/dist/chunk-SD7BHT2F.mjs +3 -0
- package/dist/chunk-SD7BHT2F.mjs.map +1 -0
- package/dist/chunk-SP5M57BG.mjs +258 -0
- package/dist/chunk-SP5M57BG.mjs.map +1 -0
- package/dist/chunk-TKSHYEYA.mjs +1706 -0
- package/dist/chunk-TKSHYEYA.mjs.map +1 -0
- package/dist/chunk-WTS75RUC.js +4 -0
- package/dist/chunk-WTS75RUC.js.map +1 -0
- package/dist/{chunk-EIRVZJTT.js → chunk-XRPIGMA2.js} +108 -68
- package/dist/chunk-XRPIGMA2.js.map +1 -0
- package/dist/chunk-XTKSM4QE.js +132 -0
- package/dist/chunk-XTKSM4QE.js.map +1 -0
- package/dist/chunk-XUE3CIJ5.mjs +174 -0
- package/dist/chunk-XUE3CIJ5.mjs.map +1 -0
- package/dist/chunk-YYUOLM6U.js +244 -0
- package/dist/chunk-YYUOLM6U.js.map +1 -0
- package/dist/chunk-ZH44DHVR.mjs +26 -0
- package/dist/chunk-ZH44DHVR.mjs.map +1 -0
- package/dist/chunk-ZPHOOG72.js +112 -0
- package/dist/chunk-ZPHOOG72.js.map +1 -0
- package/dist/constants.d.mts +7 -2
- package/dist/constants.d.ts +7 -2
- package/dist/constants.js +57 -38
- package/dist/constants.mjs +1 -2
- package/dist/deployments.generated.d.mts +2 -0
- package/dist/deployments.generated.d.ts +2 -0
- package/dist/deployments.generated.js +12 -0
- package/dist/deployments.generated.js.map +1 -0
- package/dist/deployments.generated.mjs +3 -0
- package/dist/deployments.generated.mjs.map +1 -0
- package/dist/entities/DopplerFactory.d.mts +139 -11
- package/dist/entities/DopplerFactory.d.ts +139 -11
- package/dist/entities/DopplerFactory.js +17 -7
- package/dist/entities/DopplerFactory.mjs +16 -6
- package/dist/entities/auction/DynamicAuction.d.mts +19 -4
- package/dist/entities/auction/DynamicAuction.d.ts +19 -4
- package/dist/entities/auction/DynamicAuction.js +6 -6
- package/dist/entities/auction/DynamicAuction.mjs +5 -5
- package/dist/entities/auction/MulticurvePool.d.mts +55 -0
- package/dist/entities/auction/MulticurvePool.d.ts +55 -0
- package/dist/entities/auction/MulticurvePool.js +18 -0
- package/dist/entities/auction/MulticurvePool.js.map +1 -0
- package/dist/entities/auction/MulticurvePool.mjs +9 -0
- package/dist/entities/auction/MulticurvePool.mjs.map +1 -0
- package/dist/entities/auction/StaticAuction.d.mts +6 -3
- package/dist/entities/auction/StaticAuction.d.ts +6 -3
- package/dist/entities/auction/StaticAuction.js +6 -6
- package/dist/entities/auction/StaticAuction.mjs +5 -5
- package/dist/entities/auction/index.d.mts +3 -0
- package/dist/entities/auction/index.d.ts +3 -0
- package/dist/entities/auction/index.js +16 -9
- package/dist/entities/auction/index.mjs +10 -7
- package/dist/entities/quoter/Quoter.d.mts +44 -2
- package/dist/entities/quoter/Quoter.d.ts +44 -2
- package/dist/entities/quoter/Quoter.js +6 -6
- package/dist/entities/quoter/Quoter.mjs +5 -5
- package/dist/entities/quoter/index.d.mts +3 -0
- package/dist/entities/quoter/index.d.ts +3 -0
- package/dist/entities/quoter/index.js +6 -6
- package/dist/entities/quoter/index.mjs +5 -5
- package/dist/entities/token/derc20/Derc20.d.mts +33 -7
- package/dist/entities/token/derc20/Derc20.d.ts +33 -7
- package/dist/entities/token/derc20/Derc20.js +4 -5
- package/dist/entities/token/derc20/Derc20.mjs +3 -4
- package/dist/entities/token/derc20/index.d.mts +3 -0
- package/dist/entities/token/derc20/index.d.ts +3 -0
- package/dist/entities/token/derc20/index.js +4 -5
- package/dist/entities/token/derc20/index.mjs +3 -4
- package/dist/entities/token/eth/Eth.d.mts +7 -3
- package/dist/entities/token/eth/Eth.d.ts +7 -3
- package/dist/entities/token/eth/Eth.js +2 -3
- package/dist/entities/token/eth/Eth.mjs +1 -2
- package/dist/entities/token/eth/index.d.mts +3 -0
- package/dist/entities/token/eth/index.d.ts +3 -0
- package/dist/entities/token/eth/index.js +2 -3
- package/dist/entities/token/eth/index.mjs +1 -2
- package/dist/entities/token/index.d.mts +3 -0
- package/dist/entities/token/index.d.ts +3 -0
- package/dist/entities/token/index.js +6 -7
- package/dist/entities/token/index.mjs +4 -5
- package/dist/index.d.mts +18 -6
- package/dist/index.d.ts +18 -6
- package/dist/index.js +305 -140
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +32 -19
- package/dist/index.mjs.map +1 -1
- package/dist/types.d.mts +260 -22
- package/dist/types.d.ts +260 -22
- package/dist/types.js +12 -3
- package/dist/types.mjs +3 -2
- package/dist/utils/airlock.d.mts +11 -0
- package/dist/utils/airlock.d.ts +11 -0
- package/dist/utils/airlock.js +26 -0
- package/dist/utils/airlock.js.map +1 -0
- package/dist/utils/airlock.mjs +5 -0
- package/dist/utils/airlock.mjs.map +1 -0
- package/dist/utils/balanceDelta.d.mts +10 -0
- package/dist/utils/balanceDelta.d.ts +10 -0
- package/dist/utils/balanceDelta.js +12 -0
- package/dist/utils/balanceDelta.js.map +1 -0
- package/dist/utils/balanceDelta.mjs +3 -0
- package/dist/utils/balanceDelta.mjs.map +1 -0
- package/dist/utils/computeOptimalGamma.d.mts +7 -0
- package/dist/utils/computeOptimalGamma.d.ts +7 -0
- package/dist/utils/computeOptimalGamma.js +12 -0
- package/dist/utils/computeOptimalGamma.js.map +1 -0
- package/dist/utils/computeOptimalGamma.mjs +3 -0
- package/dist/utils/computeOptimalGamma.mjs.map +1 -0
- package/dist/utils/index.d.mts +11 -0
- package/dist/utils/index.d.ts +11 -0
- package/dist/utils/index.js +114 -24
- package/dist/utils/index.mjs +14 -4
- package/dist/utils/isToken0Expected.d.mts +13 -0
- package/dist/utils/isToken0Expected.d.ts +13 -0
- package/dist/utils/isToken0Expected.js +12 -0
- package/dist/utils/isToken0Expected.js.map +1 -0
- package/dist/utils/isToken0Expected.mjs +3 -0
- package/dist/utils/isToken0Expected.mjs.map +1 -0
- package/dist/utils/marketCapHelpers.d.mts +309 -0
- package/dist/utils/marketCapHelpers.d.ts +309 -0
- package/dist/utils/marketCapHelpers.js +54 -0
- package/dist/utils/marketCapHelpers.js.map +1 -0
- package/dist/utils/marketCapHelpers.mjs +5 -0
- package/dist/utils/marketCapHelpers.mjs.map +1 -0
- package/dist/utils/poolKey.d.mts +17 -0
- package/dist/utils/poolKey.d.ts +17 -0
- package/dist/utils/poolKey.js +12 -0
- package/dist/utils/poolKey.js.map +1 -0
- package/dist/utils/poolKey.mjs +3 -0
- package/dist/utils/poolKey.mjs.map +1 -0
- package/dist/utils/priceHelpers.d.mts +3 -3
- package/dist/utils/priceHelpers.d.ts +3 -3
- package/dist/utils/priceHelpers.js +10 -11
- package/dist/utils/priceHelpers.mjs +2 -3
- package/dist/utils/tickMath.d.mts +8 -1
- package/dist/utils/tickMath.d.ts +8 -1
- package/dist/utils/tickMath.js +17 -14
- package/dist/utils/tickMath.mjs +1 -2
- package/dist/utils/tokenAddressMiner.d.mts +30 -0
- package/dist/utils/tokenAddressMiner.d.ts +30 -0
- package/dist/utils/tokenAddressMiner.js +14 -0
- package/dist/utils/tokenAddressMiner.js.map +1 -0
- package/dist/utils/tokenAddressMiner.mjs +5 -0
- package/dist/utils/tokenAddressMiner.mjs.map +1 -0
- package/package.json +14 -11
- package/dist/__tests__/mocks/addresses.d.mts +0 -46
- package/dist/__tests__/mocks/addresses.d.ts +0 -46
- package/dist/__tests__/mocks/addresses.js +0 -53
- package/dist/__tests__/mocks/addresses.js.map +0 -1
- package/dist/__tests__/mocks/addresses.mjs +0 -44
- package/dist/__tests__/mocks/addresses.mjs.map +0 -1
- package/dist/__tests__/mocks/clients.d.mts +0 -22
- package/dist/__tests__/mocks/clients.d.ts +0 -22
- package/dist/__tests__/mocks/clients.js +0 -17036
- package/dist/__tests__/mocks/clients.js.map +0 -1
- package/dist/__tests__/mocks/clients.mjs +0 -17032
- package/dist/__tests__/mocks/clients.mjs.map +0 -1
- package/dist/chunk-2N5JZSZ4.js +0 -14
- package/dist/chunk-2N5JZSZ4.js.map +0 -1
- package/dist/chunk-4K5GBNQV.mjs.map +0 -1
- package/dist/chunk-7F5IXZLH.js +0 -308
- package/dist/chunk-7F5IXZLH.js.map +0 -1
- package/dist/chunk-7W72MFJO.mjs.map +0 -1
- package/dist/chunk-AQPINKEW.mjs.map +0 -1
- package/dist/chunk-AXA7YT2G.mjs.map +0 -1
- package/dist/chunk-AYPP5JEQ.mjs.map +0 -1
- package/dist/chunk-AZLFJNTG.mjs +0 -3
- package/dist/chunk-CIRZKWLL.js.map +0 -1
- package/dist/chunk-CIVGL27M.mjs +0 -160
- package/dist/chunk-CIVGL27M.mjs.map +0 -1
- package/dist/chunk-CYDWEPFL.mjs +0 -3
- package/dist/chunk-DCFHANLR.mjs.map +0 -1
- package/dist/chunk-DRBRT57F.js +0 -4
- package/dist/chunk-EFAPDN4J.js.map +0 -1
- package/dist/chunk-EIRVZJTT.js.map +0 -1
- package/dist/chunk-ER42VG7H.js.map +0 -1
- package/dist/chunk-FPGJKJIR.js +0 -872
- package/dist/chunk-FPGJKJIR.js.map +0 -1
- package/dist/chunk-HRFHDSNE.js +0 -180
- package/dist/chunk-HRFHDSNE.js.map +0 -1
- package/dist/chunk-IHBIBFZK.mjs +0 -12
- package/dist/chunk-IHBIBFZK.mjs.map +0 -1
- package/dist/chunk-JIDZBQ7R.mjs +0 -870
- package/dist/chunk-JIDZBQ7R.mjs.map +0 -1
- package/dist/chunk-KEXKKQVW.js +0 -42
- package/dist/chunk-KFD6U3LQ.mjs +0 -305
- package/dist/chunk-KFD6U3LQ.mjs.map +0 -1
- package/dist/chunk-KPBCG4X2.js.map +0 -1
- package/dist/chunk-KRN3ROUE.js +0 -4
- package/dist/chunk-KT7U37XS.mjs +0 -207
- package/dist/chunk-KT7U37XS.mjs.map +0 -1
- package/dist/chunk-LOROXNH3.mjs +0 -37
- package/dist/chunk-LOROXNH3.mjs.map +0 -1
- package/dist/chunk-LZO67TYV.mjs +0 -176
- package/dist/chunk-LZO67TYV.mjs.map +0 -1
- package/dist/chunk-MZ2UBC4M.mjs +0 -80
- package/dist/chunk-MZ2UBC4M.mjs.map +0 -1
- package/dist/chunk-OPKQMN46.mjs.map +0 -1
- package/dist/chunk-PMIJTXU6.js.map +0 -1
- package/dist/chunk-T644D54P.mjs.map +0 -1
- package/dist/chunk-TOMVBPNZ.js.map +0 -1
- package/dist/chunk-UHT4QLL7.js +0 -162
- package/dist/chunk-UHT4QLL7.js.map +0 -1
- package/dist/chunk-XG7K4R56.js.map +0 -1
- package/dist/chunk-YNP2HGJZ.js +0 -82
- package/dist/chunk-YNP2HGJZ.js.map +0 -1
- package/dist/chunk-ZAIP54LX.js +0 -209
- package/dist/chunk-ZAIP54LX.js.map +0 -1
- package/dist/magic-string.es-CBLXTCZP.js +0 -1304
- package/dist/magic-string.es-CBLXTCZP.js.map +0 -1
- package/dist/magic-string.es-QHA47FSB.mjs +0 -1298
- package/dist/magic-string.es-QHA47FSB.mjs.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/builders/shared.ts"],"names":["DEFAULT_MULTICURVE_LOWER_TICKS","DEFAULT_MULTICURVE_UPPER_TICKS","DEFAULT_MULTICURVE_NUM_POSITIONS","DEFAULT_MULTICURVE_MAX_SUPPLY_SHARES","FEE_TIERS","TICK_SPACINGS","WAD","MIN_TICK","MAX_TICK"],"mappings":"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","file":"chunk-ZPHOOG72.js","sourcesContent":["import type { Address } from 'viem'\nimport {\n DEFAULT_MULTICURVE_LOWER_TICKS,\n DEFAULT_MULTICURVE_MAX_SUPPLY_SHARES,\n DEFAULT_MULTICURVE_NUM_POSITIONS,\n DEFAULT_MULTICURVE_UPPER_TICKS,\n FEE_TIERS,\n TICK_SPACINGS,\n WAD,\n} from '../constants'\nimport { MAX_TICK, MIN_TICK } from '../utils'\nimport type {\n PriceRange,\n TickRange,\n MulticurveMarketCapPreset,\n GovernanceOption,\n MigrationConfig,\n} from '../types'\nimport type { SupportedChainId } from '../addresses'\n\n// ============================================================================\n// Common Builder Interface\n// ============================================================================\n\n/**\n * Common interface shared by all auction builders.\n * \n * Defines the methods that all builders (Static, Dynamic, Multicurve) implement.\n * Useful for documentation and ensuring API consistency across builders.\n * \n * @template C - The chain ID type\n */\nexport interface BaseAuctionBuilder<C extends SupportedChainId> {\n /** The chain ID this builder is configured for */\n readonly chainId: C\n\n /**\n * Configure the token to be created.\n * Supports standard ERC20 or Doppler404 token types.\n */\n tokenConfig(\n params:\n | { type?: 'standard'; name: string; symbol: string; tokenURI: string; yearlyMintRate?: bigint }\n | { type: 'doppler404'; name: string; symbol: string; baseURI: string; unit?: bigint }\n ): this\n\n /**\n * Configure the token sale parameters.\n * @param params.initialSupply - Total token supply to mint\n * @param params.numTokensToSell - Number of tokens allocated for the bonding curve\n * @param params.numeraire - The quote token address (e.g., WETH)\n */\n saleConfig(params: {\n initialSupply: bigint\n numTokensToSell: bigint\n numeraire: Address\n }): this\n\n /**\n * Configure token vesting for team/investor allocations.\n * Pass undefined or omit to disable vesting.\n */\n withVesting(params?: {\n duration?: bigint\n cliffDuration?: number\n recipients?: Address[]\n amounts?: bigint[]\n }): this\n\n /**\n * Configure governance for the token.\n * @param params - Use { type: 'default' }, { type: 'noOp' }, or { type: 'custom', ... }\n */\n withGovernance(params: GovernanceOption<C>): this\n\n /**\n * Configure post-auction liquidity migration.\n * @param migration - Migration target (uniswapV2, uniswapV3, uniswapV4, or noOp)\n */\n withMigration(migration: MigrationConfig): this\n\n /**\n * Set the user address (token creator/owner).\n * Required for build().\n */\n withUserAddress(address: Address): this\n\n /**\n * Set the integrator address for fee attribution.\n * Defaults to zero address if not provided.\n */\n withIntegrator(address?: Address): this\n\n /**\n * Override the default gas limit for the create transaction.\n */\n withGasLimit(gas?: bigint): this\n\n // Module address overrides\n withTokenFactory(address: Address): this\n withAirlock(address: Address): this\n withGovernanceFactory(address: Address): this\n withV2Migrator(address: Address): this\n withV3Migrator(address: Address): this\n withV4Migrator(address: Address): this\n withNoOpMigrator(address: Address): this\n}\n\nexport function computeTicks(priceRange: PriceRange, tickSpacing: number): TickRange {\n const startTick =\n Math.floor(Math.log(priceRange.startPrice) / Math.log(1.0001) / tickSpacing) *\n tickSpacing\n const endTick =\n Math.ceil(Math.log(priceRange.endPrice) / Math.log(1.0001) / tickSpacing) *\n tickSpacing\n return { startTick, endTick }\n}\n\nexport const MARKET_CAP_PRESET_ORDER = ['low', 'medium', 'high'] as const satisfies readonly MulticurveMarketCapPreset[]\n\nexport type MarketCapPresetConfig = {\n tickLower: number\n tickUpper: number\n numPositions: number\n shares: bigint\n}\n\nexport const MARKET_CAP_PRESETS: Record<MulticurveMarketCapPreset, MarketCapPresetConfig> = {\n low: {\n tickLower: DEFAULT_MULTICURVE_LOWER_TICKS[0],\n tickUpper: DEFAULT_MULTICURVE_UPPER_TICKS[0],\n numPositions: DEFAULT_MULTICURVE_NUM_POSITIONS[0],\n shares: DEFAULT_MULTICURVE_MAX_SUPPLY_SHARES[0],\n },\n medium: {\n tickLower: DEFAULT_MULTICURVE_LOWER_TICKS[1],\n tickUpper: DEFAULT_MULTICURVE_UPPER_TICKS[1],\n numPositions: DEFAULT_MULTICURVE_NUM_POSITIONS[1],\n shares: DEFAULT_MULTICURVE_MAX_SUPPLY_SHARES[1],\n },\n high: {\n tickLower: DEFAULT_MULTICURVE_LOWER_TICKS[2],\n tickUpper: DEFAULT_MULTICURVE_UPPER_TICKS[2],\n numPositions: DEFAULT_MULTICURVE_NUM_POSITIONS[2],\n shares: DEFAULT_MULTICURVE_MAX_SUPPLY_SHARES[2],\n },\n}\n\nexport type MarketCapPresetOverrides = Partial<\n Record<\n MulticurveMarketCapPreset,\n {\n tickLower?: number\n tickUpper?: number\n numPositions?: number\n shares?: bigint\n }\n >\n>\n\n/**\n * Helper to build curves from market cap presets with optional filler curve\n */\nexport function buildCurvesFromPresets(params: {\n fee?: number\n tickSpacing?: number\n presets?: MulticurveMarketCapPreset[]\n overrides?: MarketCapPresetOverrides\n}): { fee: number; tickSpacing: number; curves: MarketCapPresetConfig[] } {\n const fee = params?.fee ?? FEE_TIERS.LOW\n const tickSpacing =\n params?.tickSpacing ??\n (TICK_SPACINGS as Record<number, number>)[fee]\n\n if (tickSpacing === undefined) {\n throw new Error('tickSpacing must be provided when using a custom fee tier')\n }\n\n const requestedPresets = params?.presets ?? [...MARKET_CAP_PRESET_ORDER]\n const uniquePresets: MulticurveMarketCapPreset[] = []\n for (const preset of requestedPresets) {\n if (!(preset in MARKET_CAP_PRESETS)) {\n throw new Error(`Unsupported market cap preset: ${preset}`)\n }\n if (!uniquePresets.includes(preset)) {\n uniquePresets.push(preset)\n }\n }\n\n if (uniquePresets.length === 0) {\n throw new Error('At least one market cap preset must be provided')\n }\n\n const presetCurves = uniquePresets.map((preset) => {\n const base = MARKET_CAP_PRESETS[preset]\n const override = params?.overrides?.[preset]\n return {\n tickLower: override?.tickLower ?? base.tickLower,\n tickUpper: override?.tickUpper ?? base.tickUpper,\n numPositions: override?.numPositions ?? base.numPositions,\n shares: override?.shares ?? base.shares,\n }\n })\n\n let totalShares = presetCurves.reduce((acc, curve) => {\n if (curve.shares <= 0n) {\n throw new Error('Preset shares must be greater than zero')\n }\n return acc + curve.shares\n }, 0n)\n\n if (totalShares > WAD) {\n throw new Error('Total preset shares cannot exceed 100% (1e18)')\n }\n\n const curves = [...presetCurves]\n\n // Add filler curve if shares don't sum to 100%\n if (totalShares < WAD) {\n const remainder = WAD - totalShares\n const lastCurve = curves[curves.length - 1]\n let fillerTickLower = lastCurve?.tickUpper ?? 0\n let fillerNumPositions = lastCurve?.numPositions ?? 1\n\n if (fillerNumPositions <= 0) {\n fillerNumPositions = 1\n }\n\n const minTickAllowed = Math.ceil(MIN_TICK / tickSpacing) * tickSpacing\n const rawMaxTick = Math.floor(MAX_TICK / tickSpacing) * tickSpacing\n const maxTickAllowed = rawMaxTick - tickSpacing\n\n fillerTickLower = Math.max(fillerTickLower, minTickAllowed)\n let fillerTickUpper = fillerTickLower + fillerNumPositions * tickSpacing\n\n if (fillerTickUpper > maxTickAllowed) {\n fillerTickUpper = maxTickAllowed\n fillerTickLower = Math.min(fillerTickLower, maxTickAllowed - tickSpacing)\n }\n\n if (fillerTickUpper <= fillerTickLower) {\n fillerTickLower = Math.max(minTickAllowed, maxTickAllowed - tickSpacing)\n fillerTickUpper = fillerTickLower + tickSpacing\n }\n\n curves.push({\n tickLower: fillerTickLower,\n tickUpper: fillerTickUpper,\n numPositions: fillerNumPositions,\n shares: remainder,\n })\n\n totalShares = WAD\n }\n\n if (totalShares !== WAD) {\n throw new Error('Failed to normalize preset shares to 100%')\n }\n\n return { fee, tickSpacing, curves }\n}\n"]}
|
package/dist/constants.d.mts
CHANGED
|
@@ -18,10 +18,11 @@ declare const TICK_SPACINGS: {
|
|
|
18
18
|
declare const SECONDS_PER_DAY = 86400;
|
|
19
19
|
declare const SECONDS_PER_YEAR: number;
|
|
20
20
|
declare const DEFAULT_EPOCH_LENGTH = 43200;
|
|
21
|
-
declare const DEFAULT_AUCTION_DURATION
|
|
21
|
+
declare const DEFAULT_AUCTION_DURATION: number;
|
|
22
22
|
declare const DEFAULT_LOCK_DURATION: number;
|
|
23
23
|
declare const DEFAULT_PD_SLUGS = 5;
|
|
24
24
|
declare const DAY_SECONDS = 86400;
|
|
25
|
+
declare const DEFAULT_CREATE_GAS_LIMIT = 13500000n;
|
|
25
26
|
declare const DEFAULT_V3_START_TICK = 175000;
|
|
26
27
|
declare const DEFAULT_V3_END_TICK = 225000;
|
|
27
28
|
declare const DEFAULT_V3_NUM_POSITIONS = 15;
|
|
@@ -39,6 +40,10 @@ declare const DEFAULT_V4_INITIAL_VOTING_DELAY = 7200;
|
|
|
39
40
|
declare const DEFAULT_V4_INITIAL_VOTING_PERIOD = 50400;
|
|
40
41
|
declare const DEFAULT_V4_INITIAL_PROPOSAL_THRESHOLD = 0n;
|
|
41
42
|
declare const DEFAULT_V4_YEARLY_MINT_RATE: bigint;
|
|
43
|
+
declare const DEFAULT_MULTICURVE_LOWER_TICKS: readonly [-202100, -183100, -167000];
|
|
44
|
+
declare const DEFAULT_MULTICURVE_UPPER_TICKS: readonly [-188200, -172100, -156000];
|
|
45
|
+
declare const DEFAULT_MULTICURVE_NUM_POSITIONS: readonly [11, 11, 11];
|
|
46
|
+
declare const DEFAULT_MULTICURVE_MAX_SUPPLY_SHARES: readonly [bigint, bigint, bigint];
|
|
42
47
|
declare const MIN_SQRT_RATIO = 4295128739n;
|
|
43
48
|
declare const MAX_SQRT_RATIO = 1461446703485210103287273052203988822378723970342n;
|
|
44
49
|
declare const BASIS_POINTS = 10000;
|
|
@@ -47,4 +52,4 @@ declare const DOPPLER_FLAGS: bigint;
|
|
|
47
52
|
declare const DYNAMIC_FEE_FLAG = 8388608;
|
|
48
53
|
declare const FEE_AMOUNT_MASK = 16777215;
|
|
49
54
|
|
|
50
|
-
export { BASIS_POINTS, DAY_SECONDS, DEAD_ADDRESS, DEFAULT_AUCTION_DURATION, DEFAULT_EPOCH_LENGTH, DEFAULT_LOCK_DURATION, DEFAULT_PD_SLUGS, DEFAULT_V3_END_TICK, DEFAULT_V3_FEE, DEFAULT_V3_INITIAL_PROPOSAL_THRESHOLD, DEFAULT_V3_INITIAL_SUPPLY, DEFAULT_V3_INITIAL_VOTING_DELAY, DEFAULT_V3_INITIAL_VOTING_PERIOD, DEFAULT_V3_MAX_SHARE_TO_BE_SOLD, DEFAULT_V3_NUM_POSITIONS, DEFAULT_V3_NUM_TOKENS_TO_SELL, DEFAULT_V3_PRE_MINT, DEFAULT_V3_START_TICK, DEFAULT_V3_VESTING_DURATION, DEFAULT_V3_YEARLY_MINT_RATE, DEFAULT_V4_INITIAL_PROPOSAL_THRESHOLD, DEFAULT_V4_INITIAL_VOTING_DELAY, DEFAULT_V4_INITIAL_VOTING_PERIOD, DEFAULT_V4_YEARLY_MINT_RATE, DOPPLER_FLAGS, DYNAMIC_FEE_FLAG, FEE_AMOUNT_MASK, FEE_TIERS, FLAG_MASK, MAX_SQRT_RATIO, MIN_SQRT_RATIO, SECONDS_PER_DAY, SECONDS_PER_YEAR, TICK_SPACINGS, WAD, ZERO_ADDRESS };
|
|
55
|
+
export { BASIS_POINTS, DAY_SECONDS, DEAD_ADDRESS, DEFAULT_AUCTION_DURATION, DEFAULT_CREATE_GAS_LIMIT, DEFAULT_EPOCH_LENGTH, DEFAULT_LOCK_DURATION, DEFAULT_MULTICURVE_LOWER_TICKS, DEFAULT_MULTICURVE_MAX_SUPPLY_SHARES, DEFAULT_MULTICURVE_NUM_POSITIONS, DEFAULT_MULTICURVE_UPPER_TICKS, DEFAULT_PD_SLUGS, DEFAULT_V3_END_TICK, DEFAULT_V3_FEE, DEFAULT_V3_INITIAL_PROPOSAL_THRESHOLD, DEFAULT_V3_INITIAL_SUPPLY, DEFAULT_V3_INITIAL_VOTING_DELAY, DEFAULT_V3_INITIAL_VOTING_PERIOD, DEFAULT_V3_MAX_SHARE_TO_BE_SOLD, DEFAULT_V3_NUM_POSITIONS, DEFAULT_V3_NUM_TOKENS_TO_SELL, DEFAULT_V3_PRE_MINT, DEFAULT_V3_START_TICK, DEFAULT_V3_VESTING_DURATION, DEFAULT_V3_YEARLY_MINT_RATE, DEFAULT_V4_INITIAL_PROPOSAL_THRESHOLD, DEFAULT_V4_INITIAL_VOTING_DELAY, DEFAULT_V4_INITIAL_VOTING_PERIOD, DEFAULT_V4_YEARLY_MINT_RATE, DOPPLER_FLAGS, DYNAMIC_FEE_FLAG, FEE_AMOUNT_MASK, FEE_TIERS, FLAG_MASK, MAX_SQRT_RATIO, MIN_SQRT_RATIO, SECONDS_PER_DAY, SECONDS_PER_YEAR, TICK_SPACINGS, WAD, ZERO_ADDRESS };
|
package/dist/constants.d.ts
CHANGED
|
@@ -18,10 +18,11 @@ declare const TICK_SPACINGS: {
|
|
|
18
18
|
declare const SECONDS_PER_DAY = 86400;
|
|
19
19
|
declare const SECONDS_PER_YEAR: number;
|
|
20
20
|
declare const DEFAULT_EPOCH_LENGTH = 43200;
|
|
21
|
-
declare const DEFAULT_AUCTION_DURATION
|
|
21
|
+
declare const DEFAULT_AUCTION_DURATION: number;
|
|
22
22
|
declare const DEFAULT_LOCK_DURATION: number;
|
|
23
23
|
declare const DEFAULT_PD_SLUGS = 5;
|
|
24
24
|
declare const DAY_SECONDS = 86400;
|
|
25
|
+
declare const DEFAULT_CREATE_GAS_LIMIT = 13500000n;
|
|
25
26
|
declare const DEFAULT_V3_START_TICK = 175000;
|
|
26
27
|
declare const DEFAULT_V3_END_TICK = 225000;
|
|
27
28
|
declare const DEFAULT_V3_NUM_POSITIONS = 15;
|
|
@@ -39,6 +40,10 @@ declare const DEFAULT_V4_INITIAL_VOTING_DELAY = 7200;
|
|
|
39
40
|
declare const DEFAULT_V4_INITIAL_VOTING_PERIOD = 50400;
|
|
40
41
|
declare const DEFAULT_V4_INITIAL_PROPOSAL_THRESHOLD = 0n;
|
|
41
42
|
declare const DEFAULT_V4_YEARLY_MINT_RATE: bigint;
|
|
43
|
+
declare const DEFAULT_MULTICURVE_LOWER_TICKS: readonly [-202100, -183100, -167000];
|
|
44
|
+
declare const DEFAULT_MULTICURVE_UPPER_TICKS: readonly [-188200, -172100, -156000];
|
|
45
|
+
declare const DEFAULT_MULTICURVE_NUM_POSITIONS: readonly [11, 11, 11];
|
|
46
|
+
declare const DEFAULT_MULTICURVE_MAX_SUPPLY_SHARES: readonly [bigint, bigint, bigint];
|
|
42
47
|
declare const MIN_SQRT_RATIO = 4295128739n;
|
|
43
48
|
declare const MAX_SQRT_RATIO = 1461446703485210103287273052203988822378723970342n;
|
|
44
49
|
declare const BASIS_POINTS = 10000;
|
|
@@ -47,4 +52,4 @@ declare const DOPPLER_FLAGS: bigint;
|
|
|
47
52
|
declare const DYNAMIC_FEE_FLAG = 8388608;
|
|
48
53
|
declare const FEE_AMOUNT_MASK = 16777215;
|
|
49
54
|
|
|
50
|
-
export { BASIS_POINTS, DAY_SECONDS, DEAD_ADDRESS, DEFAULT_AUCTION_DURATION, DEFAULT_EPOCH_LENGTH, DEFAULT_LOCK_DURATION, DEFAULT_PD_SLUGS, DEFAULT_V3_END_TICK, DEFAULT_V3_FEE, DEFAULT_V3_INITIAL_PROPOSAL_THRESHOLD, DEFAULT_V3_INITIAL_SUPPLY, DEFAULT_V3_INITIAL_VOTING_DELAY, DEFAULT_V3_INITIAL_VOTING_PERIOD, DEFAULT_V3_MAX_SHARE_TO_BE_SOLD, DEFAULT_V3_NUM_POSITIONS, DEFAULT_V3_NUM_TOKENS_TO_SELL, DEFAULT_V3_PRE_MINT, DEFAULT_V3_START_TICK, DEFAULT_V3_VESTING_DURATION, DEFAULT_V3_YEARLY_MINT_RATE, DEFAULT_V4_INITIAL_PROPOSAL_THRESHOLD, DEFAULT_V4_INITIAL_VOTING_DELAY, DEFAULT_V4_INITIAL_VOTING_PERIOD, DEFAULT_V4_YEARLY_MINT_RATE, DOPPLER_FLAGS, DYNAMIC_FEE_FLAG, FEE_AMOUNT_MASK, FEE_TIERS, FLAG_MASK, MAX_SQRT_RATIO, MIN_SQRT_RATIO, SECONDS_PER_DAY, SECONDS_PER_YEAR, TICK_SPACINGS, WAD, ZERO_ADDRESS };
|
|
55
|
+
export { BASIS_POINTS, DAY_SECONDS, DEAD_ADDRESS, DEFAULT_AUCTION_DURATION, DEFAULT_CREATE_GAS_LIMIT, DEFAULT_EPOCH_LENGTH, DEFAULT_LOCK_DURATION, DEFAULT_MULTICURVE_LOWER_TICKS, DEFAULT_MULTICURVE_MAX_SUPPLY_SHARES, DEFAULT_MULTICURVE_NUM_POSITIONS, DEFAULT_MULTICURVE_UPPER_TICKS, DEFAULT_PD_SLUGS, DEFAULT_V3_END_TICK, DEFAULT_V3_FEE, DEFAULT_V3_INITIAL_PROPOSAL_THRESHOLD, DEFAULT_V3_INITIAL_SUPPLY, DEFAULT_V3_INITIAL_VOTING_DELAY, DEFAULT_V3_INITIAL_VOTING_PERIOD, DEFAULT_V3_MAX_SHARE_TO_BE_SOLD, DEFAULT_V3_NUM_POSITIONS, DEFAULT_V3_NUM_TOKENS_TO_SELL, DEFAULT_V3_PRE_MINT, DEFAULT_V3_START_TICK, DEFAULT_V3_VESTING_DURATION, DEFAULT_V3_YEARLY_MINT_RATE, DEFAULT_V4_INITIAL_PROPOSAL_THRESHOLD, DEFAULT_V4_INITIAL_VOTING_DELAY, DEFAULT_V4_INITIAL_VOTING_PERIOD, DEFAULT_V4_YEARLY_MINT_RATE, DOPPLER_FLAGS, DYNAMIC_FEE_FLAG, FEE_AMOUNT_MASK, FEE_TIERS, FLAG_MASK, MAX_SQRT_RATIO, MIN_SQRT_RATIO, SECONDS_PER_DAY, SECONDS_PER_YEAR, TICK_SPACINGS, WAD, ZERO_ADDRESS };
|
package/dist/constants.js
CHANGED
|
@@ -1,153 +1,172 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('./chunk-KEXKKQVW.js');
|
|
3
|
+
var chunkPH2KXREH_js = require('./chunk-PH2KXREH.js');
|
|
5
4
|
|
|
6
5
|
|
|
7
6
|
|
|
8
7
|
Object.defineProperty(exports, "BASIS_POINTS", {
|
|
9
8
|
enumerable: true,
|
|
10
|
-
get: function () { return
|
|
9
|
+
get: function () { return chunkPH2KXREH_js.BASIS_POINTS; }
|
|
11
10
|
});
|
|
12
11
|
Object.defineProperty(exports, "DAY_SECONDS", {
|
|
13
12
|
enumerable: true,
|
|
14
|
-
get: function () { return
|
|
13
|
+
get: function () { return chunkPH2KXREH_js.DAY_SECONDS; }
|
|
15
14
|
});
|
|
16
15
|
Object.defineProperty(exports, "DEAD_ADDRESS", {
|
|
17
16
|
enumerable: true,
|
|
18
|
-
get: function () { return
|
|
17
|
+
get: function () { return chunkPH2KXREH_js.DEAD_ADDRESS; }
|
|
19
18
|
});
|
|
20
19
|
Object.defineProperty(exports, "DEFAULT_AUCTION_DURATION", {
|
|
21
20
|
enumerable: true,
|
|
22
|
-
get: function () { return
|
|
21
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_AUCTION_DURATION; }
|
|
22
|
+
});
|
|
23
|
+
Object.defineProperty(exports, "DEFAULT_CREATE_GAS_LIMIT", {
|
|
24
|
+
enumerable: true,
|
|
25
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_CREATE_GAS_LIMIT; }
|
|
23
26
|
});
|
|
24
27
|
Object.defineProperty(exports, "DEFAULT_EPOCH_LENGTH", {
|
|
25
28
|
enumerable: true,
|
|
26
|
-
get: function () { return
|
|
29
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_EPOCH_LENGTH; }
|
|
27
30
|
});
|
|
28
31
|
Object.defineProperty(exports, "DEFAULT_LOCK_DURATION", {
|
|
29
32
|
enumerable: true,
|
|
30
|
-
get: function () { return
|
|
33
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_LOCK_DURATION; }
|
|
34
|
+
});
|
|
35
|
+
Object.defineProperty(exports, "DEFAULT_MULTICURVE_LOWER_TICKS", {
|
|
36
|
+
enumerable: true,
|
|
37
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_MULTICURVE_LOWER_TICKS; }
|
|
38
|
+
});
|
|
39
|
+
Object.defineProperty(exports, "DEFAULT_MULTICURVE_MAX_SUPPLY_SHARES", {
|
|
40
|
+
enumerable: true,
|
|
41
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_MULTICURVE_MAX_SUPPLY_SHARES; }
|
|
42
|
+
});
|
|
43
|
+
Object.defineProperty(exports, "DEFAULT_MULTICURVE_NUM_POSITIONS", {
|
|
44
|
+
enumerable: true,
|
|
45
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_MULTICURVE_NUM_POSITIONS; }
|
|
46
|
+
});
|
|
47
|
+
Object.defineProperty(exports, "DEFAULT_MULTICURVE_UPPER_TICKS", {
|
|
48
|
+
enumerable: true,
|
|
49
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_MULTICURVE_UPPER_TICKS; }
|
|
31
50
|
});
|
|
32
51
|
Object.defineProperty(exports, "DEFAULT_PD_SLUGS", {
|
|
33
52
|
enumerable: true,
|
|
34
|
-
get: function () { return
|
|
53
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_PD_SLUGS; }
|
|
35
54
|
});
|
|
36
55
|
Object.defineProperty(exports, "DEFAULT_V3_END_TICK", {
|
|
37
56
|
enumerable: true,
|
|
38
|
-
get: function () { return
|
|
57
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V3_END_TICK; }
|
|
39
58
|
});
|
|
40
59
|
Object.defineProperty(exports, "DEFAULT_V3_FEE", {
|
|
41
60
|
enumerable: true,
|
|
42
|
-
get: function () { return
|
|
61
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V3_FEE; }
|
|
43
62
|
});
|
|
44
63
|
Object.defineProperty(exports, "DEFAULT_V3_INITIAL_PROPOSAL_THRESHOLD", {
|
|
45
64
|
enumerable: true,
|
|
46
|
-
get: function () { return
|
|
65
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V3_INITIAL_PROPOSAL_THRESHOLD; }
|
|
47
66
|
});
|
|
48
67
|
Object.defineProperty(exports, "DEFAULT_V3_INITIAL_SUPPLY", {
|
|
49
68
|
enumerable: true,
|
|
50
|
-
get: function () { return
|
|
69
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V3_INITIAL_SUPPLY; }
|
|
51
70
|
});
|
|
52
71
|
Object.defineProperty(exports, "DEFAULT_V3_INITIAL_VOTING_DELAY", {
|
|
53
72
|
enumerable: true,
|
|
54
|
-
get: function () { return
|
|
73
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V3_INITIAL_VOTING_DELAY; }
|
|
55
74
|
});
|
|
56
75
|
Object.defineProperty(exports, "DEFAULT_V3_INITIAL_VOTING_PERIOD", {
|
|
57
76
|
enumerable: true,
|
|
58
|
-
get: function () { return
|
|
77
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V3_INITIAL_VOTING_PERIOD; }
|
|
59
78
|
});
|
|
60
79
|
Object.defineProperty(exports, "DEFAULT_V3_MAX_SHARE_TO_BE_SOLD", {
|
|
61
80
|
enumerable: true,
|
|
62
|
-
get: function () { return
|
|
81
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V3_MAX_SHARE_TO_BE_SOLD; }
|
|
63
82
|
});
|
|
64
83
|
Object.defineProperty(exports, "DEFAULT_V3_NUM_POSITIONS", {
|
|
65
84
|
enumerable: true,
|
|
66
|
-
get: function () { return
|
|
85
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V3_NUM_POSITIONS; }
|
|
67
86
|
});
|
|
68
87
|
Object.defineProperty(exports, "DEFAULT_V3_NUM_TOKENS_TO_SELL", {
|
|
69
88
|
enumerable: true,
|
|
70
|
-
get: function () { return
|
|
89
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V3_NUM_TOKENS_TO_SELL; }
|
|
71
90
|
});
|
|
72
91
|
Object.defineProperty(exports, "DEFAULT_V3_PRE_MINT", {
|
|
73
92
|
enumerable: true,
|
|
74
|
-
get: function () { return
|
|
93
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V3_PRE_MINT; }
|
|
75
94
|
});
|
|
76
95
|
Object.defineProperty(exports, "DEFAULT_V3_START_TICK", {
|
|
77
96
|
enumerable: true,
|
|
78
|
-
get: function () { return
|
|
97
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V3_START_TICK; }
|
|
79
98
|
});
|
|
80
99
|
Object.defineProperty(exports, "DEFAULT_V3_VESTING_DURATION", {
|
|
81
100
|
enumerable: true,
|
|
82
|
-
get: function () { return
|
|
101
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V3_VESTING_DURATION; }
|
|
83
102
|
});
|
|
84
103
|
Object.defineProperty(exports, "DEFAULT_V3_YEARLY_MINT_RATE", {
|
|
85
104
|
enumerable: true,
|
|
86
|
-
get: function () { return
|
|
105
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V3_YEARLY_MINT_RATE; }
|
|
87
106
|
});
|
|
88
107
|
Object.defineProperty(exports, "DEFAULT_V4_INITIAL_PROPOSAL_THRESHOLD", {
|
|
89
108
|
enumerable: true,
|
|
90
|
-
get: function () { return
|
|
109
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V4_INITIAL_PROPOSAL_THRESHOLD; }
|
|
91
110
|
});
|
|
92
111
|
Object.defineProperty(exports, "DEFAULT_V4_INITIAL_VOTING_DELAY", {
|
|
93
112
|
enumerable: true,
|
|
94
|
-
get: function () { return
|
|
113
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V4_INITIAL_VOTING_DELAY; }
|
|
95
114
|
});
|
|
96
115
|
Object.defineProperty(exports, "DEFAULT_V4_INITIAL_VOTING_PERIOD", {
|
|
97
116
|
enumerable: true,
|
|
98
|
-
get: function () { return
|
|
117
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V4_INITIAL_VOTING_PERIOD; }
|
|
99
118
|
});
|
|
100
119
|
Object.defineProperty(exports, "DEFAULT_V4_YEARLY_MINT_RATE", {
|
|
101
120
|
enumerable: true,
|
|
102
|
-
get: function () { return
|
|
121
|
+
get: function () { return chunkPH2KXREH_js.DEFAULT_V4_YEARLY_MINT_RATE; }
|
|
103
122
|
});
|
|
104
123
|
Object.defineProperty(exports, "DOPPLER_FLAGS", {
|
|
105
124
|
enumerable: true,
|
|
106
|
-
get: function () { return
|
|
125
|
+
get: function () { return chunkPH2KXREH_js.DOPPLER_FLAGS; }
|
|
107
126
|
});
|
|
108
127
|
Object.defineProperty(exports, "DYNAMIC_FEE_FLAG", {
|
|
109
128
|
enumerable: true,
|
|
110
|
-
get: function () { return
|
|
129
|
+
get: function () { return chunkPH2KXREH_js.DYNAMIC_FEE_FLAG; }
|
|
111
130
|
});
|
|
112
131
|
Object.defineProperty(exports, "FEE_AMOUNT_MASK", {
|
|
113
132
|
enumerable: true,
|
|
114
|
-
get: function () { return
|
|
133
|
+
get: function () { return chunkPH2KXREH_js.FEE_AMOUNT_MASK; }
|
|
115
134
|
});
|
|
116
135
|
Object.defineProperty(exports, "FEE_TIERS", {
|
|
117
136
|
enumerable: true,
|
|
118
|
-
get: function () { return
|
|
137
|
+
get: function () { return chunkPH2KXREH_js.FEE_TIERS; }
|
|
119
138
|
});
|
|
120
139
|
Object.defineProperty(exports, "FLAG_MASK", {
|
|
121
140
|
enumerable: true,
|
|
122
|
-
get: function () { return
|
|
141
|
+
get: function () { return chunkPH2KXREH_js.FLAG_MASK; }
|
|
123
142
|
});
|
|
124
143
|
Object.defineProperty(exports, "MAX_SQRT_RATIO", {
|
|
125
144
|
enumerable: true,
|
|
126
|
-
get: function () { return
|
|
145
|
+
get: function () { return chunkPH2KXREH_js.MAX_SQRT_RATIO; }
|
|
127
146
|
});
|
|
128
147
|
Object.defineProperty(exports, "MIN_SQRT_RATIO", {
|
|
129
148
|
enumerable: true,
|
|
130
|
-
get: function () { return
|
|
149
|
+
get: function () { return chunkPH2KXREH_js.MIN_SQRT_RATIO; }
|
|
131
150
|
});
|
|
132
151
|
Object.defineProperty(exports, "SECONDS_PER_DAY", {
|
|
133
152
|
enumerable: true,
|
|
134
|
-
get: function () { return
|
|
153
|
+
get: function () { return chunkPH2KXREH_js.SECONDS_PER_DAY; }
|
|
135
154
|
});
|
|
136
155
|
Object.defineProperty(exports, "SECONDS_PER_YEAR", {
|
|
137
156
|
enumerable: true,
|
|
138
|
-
get: function () { return
|
|
157
|
+
get: function () { return chunkPH2KXREH_js.SECONDS_PER_YEAR; }
|
|
139
158
|
});
|
|
140
159
|
Object.defineProperty(exports, "TICK_SPACINGS", {
|
|
141
160
|
enumerable: true,
|
|
142
|
-
get: function () { return
|
|
161
|
+
get: function () { return chunkPH2KXREH_js.TICK_SPACINGS; }
|
|
143
162
|
});
|
|
144
163
|
Object.defineProperty(exports, "WAD", {
|
|
145
164
|
enumerable: true,
|
|
146
|
-
get: function () { return
|
|
165
|
+
get: function () { return chunkPH2KXREH_js.WAD; }
|
|
147
166
|
});
|
|
148
167
|
Object.defineProperty(exports, "ZERO_ADDRESS", {
|
|
149
168
|
enumerable: true,
|
|
150
|
-
get: function () { return
|
|
169
|
+
get: function () { return chunkPH2KXREH_js.ZERO_ADDRESS; }
|
|
151
170
|
});
|
|
152
171
|
//# sourceMappingURL=constants.js.map
|
|
153
172
|
//# sourceMappingURL=constants.js.map
|
package/dist/constants.mjs
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
export { BASIS_POINTS, DAY_SECONDS, DEAD_ADDRESS, DEFAULT_AUCTION_DURATION, DEFAULT_EPOCH_LENGTH, DEFAULT_LOCK_DURATION, DEFAULT_PD_SLUGS, DEFAULT_V3_END_TICK, DEFAULT_V3_FEE, DEFAULT_V3_INITIAL_PROPOSAL_THRESHOLD, DEFAULT_V3_INITIAL_SUPPLY, DEFAULT_V3_INITIAL_VOTING_DELAY, DEFAULT_V3_INITIAL_VOTING_PERIOD, DEFAULT_V3_MAX_SHARE_TO_BE_SOLD, DEFAULT_V3_NUM_POSITIONS, DEFAULT_V3_NUM_TOKENS_TO_SELL, DEFAULT_V3_PRE_MINT, DEFAULT_V3_START_TICK, DEFAULT_V3_VESTING_DURATION, DEFAULT_V3_YEARLY_MINT_RATE, DEFAULT_V4_INITIAL_PROPOSAL_THRESHOLD, DEFAULT_V4_INITIAL_VOTING_DELAY, DEFAULT_V4_INITIAL_VOTING_PERIOD, DEFAULT_V4_YEARLY_MINT_RATE, DOPPLER_FLAGS, DYNAMIC_FEE_FLAG, FEE_AMOUNT_MASK, FEE_TIERS, FLAG_MASK, MAX_SQRT_RATIO, MIN_SQRT_RATIO, SECONDS_PER_DAY, SECONDS_PER_YEAR, TICK_SPACINGS, WAD, ZERO_ADDRESS } from './chunk-
|
|
2
|
-
import './chunk-LOROXNH3.mjs';
|
|
1
|
+
export { BASIS_POINTS, DAY_SECONDS, DEAD_ADDRESS, DEFAULT_AUCTION_DURATION, DEFAULT_CREATE_GAS_LIMIT, DEFAULT_EPOCH_LENGTH, DEFAULT_LOCK_DURATION, DEFAULT_MULTICURVE_LOWER_TICKS, DEFAULT_MULTICURVE_MAX_SUPPLY_SHARES, DEFAULT_MULTICURVE_NUM_POSITIONS, DEFAULT_MULTICURVE_UPPER_TICKS, DEFAULT_PD_SLUGS, DEFAULT_V3_END_TICK, DEFAULT_V3_FEE, DEFAULT_V3_INITIAL_PROPOSAL_THRESHOLD, DEFAULT_V3_INITIAL_SUPPLY, DEFAULT_V3_INITIAL_VOTING_DELAY, DEFAULT_V3_INITIAL_VOTING_PERIOD, DEFAULT_V3_MAX_SHARE_TO_BE_SOLD, DEFAULT_V3_NUM_POSITIONS, DEFAULT_V3_NUM_TOKENS_TO_SELL, DEFAULT_V3_PRE_MINT, DEFAULT_V3_START_TICK, DEFAULT_V3_VESTING_DURATION, DEFAULT_V3_YEARLY_MINT_RATE, DEFAULT_V4_INITIAL_PROPOSAL_THRESHOLD, DEFAULT_V4_INITIAL_VOTING_DELAY, DEFAULT_V4_INITIAL_VOTING_PERIOD, DEFAULT_V4_YEARLY_MINT_RATE, DOPPLER_FLAGS, DYNAMIC_FEE_FLAG, FEE_AMOUNT_MASK, FEE_TIERS, FLAG_MASK, MAX_SQRT_RATIO, MIN_SQRT_RATIO, SECONDS_PER_DAY, SECONDS_PER_YEAR, TICK_SPACINGS, WAD, ZERO_ADDRESS } from './chunk-QKO2FZGN.mjs';
|
|
3
2
|
//# sourceMappingURL=constants.mjs.map
|
|
4
3
|
//# sourceMappingURL=constants.mjs.map
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkCVHPLURA_js = require('./chunk-CVHPLURA.js');
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
Object.defineProperty(exports, "GENERATED_DOPPLER_DEPLOYMENTS", {
|
|
8
|
+
enumerable: true,
|
|
9
|
+
get: function () { return chunkCVHPLURA_js.GENERATED_DOPPLER_DEPLOYMENTS; }
|
|
10
|
+
});
|
|
11
|
+
//# sourceMappingURL=deployments.generated.js.map
|
|
12
|
+
//# sourceMappingURL=deployments.generated.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"deployments.generated.js"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"deployments.generated.mjs"}
|
|
@@ -1,17 +1,47 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { CreateStaticAuctionParams, CreateDynamicAuctionParams } from '../types.mjs';
|
|
1
|
+
import { WalletClient, Hex, Address, Hash } from 'viem';
|
|
2
|
+
import { SupportedPublicClient, MigrationConfig, CreateStaticAuctionParams, CreateParams, CreateDynamicAuctionParams, CreateMulticurveParams, MulticurveBundleExactOutResult, MulticurveBundleExactInResult } from '../types.mjs';
|
|
3
|
+
import { SupportedChainId } from '../addresses.mjs';
|
|
4
|
+
import 'viem/chains';
|
|
3
5
|
|
|
4
|
-
|
|
6
|
+
type MigrationEncoder = (config: MigrationConfig) => Hex;
|
|
7
|
+
declare class DopplerFactory<C extends SupportedChainId = SupportedChainId> {
|
|
5
8
|
private publicClient;
|
|
6
9
|
private walletClient?;
|
|
7
10
|
private chainId;
|
|
8
|
-
|
|
11
|
+
private customMigrationEncoder?;
|
|
12
|
+
private multicurveBundlerSupport;
|
|
13
|
+
constructor(publicClient: SupportedPublicClient, walletClient: WalletClient | undefined, chainId: C);
|
|
14
|
+
/**
|
|
15
|
+
* Set a custom migration data encoder function
|
|
16
|
+
* @param encoder Custom function to encode migration data
|
|
17
|
+
* @returns The factory instance for method chaining
|
|
18
|
+
*/
|
|
19
|
+
withCustomMigrationEncoder(encoder: MigrationEncoder): this;
|
|
20
|
+
encodeCreateStaticAuctionParams(params: CreateStaticAuctionParams<C>): Promise<CreateParams>;
|
|
21
|
+
/**
|
|
22
|
+
* Simulate a static auction creation and return predicted addresses.
|
|
23
|
+
* Useful for pre-buy flows (bundle) to know the token/pool before sending.
|
|
24
|
+
*/
|
|
25
|
+
simulateCreateStaticAuction(params: CreateStaticAuctionParams<C>): Promise<{
|
|
26
|
+
createParams: CreateParams;
|
|
27
|
+
asset: Address;
|
|
28
|
+
pool: Address;
|
|
29
|
+
gasEstimate?: bigint;
|
|
30
|
+
/** Execute the create with the same params used in simulation (guarantees address match) */
|
|
31
|
+
execute: () => Promise<{
|
|
32
|
+
poolAddress: Address;
|
|
33
|
+
tokenAddress: Address;
|
|
34
|
+
transactionHash: string;
|
|
35
|
+
}>;
|
|
36
|
+
}>;
|
|
9
37
|
/**
|
|
10
38
|
* Create a new static auction (using Uniswap V3 for initial liquidity)
|
|
11
39
|
* @param params Configuration for the static auction
|
|
12
40
|
* @returns The address of the created pool and token
|
|
13
41
|
*/
|
|
14
|
-
createStaticAuction(params: CreateStaticAuctionParams
|
|
42
|
+
createStaticAuction(params: CreateStaticAuctionParams<C>, options?: {
|
|
43
|
+
_createParams?: CreateParams;
|
|
44
|
+
}): Promise<{
|
|
15
45
|
poolAddress: Address;
|
|
16
46
|
tokenAddress: Address;
|
|
17
47
|
transactionHash: string;
|
|
@@ -20,25 +50,82 @@ declare class DopplerFactory {
|
|
|
20
50
|
* Generate a random salt based on user address
|
|
21
51
|
*/
|
|
22
52
|
private generateRandomSalt;
|
|
53
|
+
/**
|
|
54
|
+
* Iteratively mine a salt that ensures the newly created token sorts after the numeraire.
|
|
55
|
+
* This mirrors the legacy SDK behaviour so tick configuration can assume the numeraire is token0.
|
|
56
|
+
*/
|
|
57
|
+
private mineTokenOrder;
|
|
58
|
+
encodeCreateDynamicAuctionParams(params: CreateDynamicAuctionParams<C>): Promise<{
|
|
59
|
+
createParams: CreateParams;
|
|
60
|
+
hookAddress: Address;
|
|
61
|
+
tokenAddress: Address;
|
|
62
|
+
}>;
|
|
23
63
|
/**
|
|
24
64
|
* Create a new dynamic auction (using Uniswap V4 hook for gradual Dutch auction)
|
|
25
65
|
* @param params Configuration for the dynamic auction
|
|
26
66
|
* @returns The address of the created hook and token
|
|
27
67
|
*/
|
|
28
|
-
createDynamicAuction(params: CreateDynamicAuctionParams
|
|
68
|
+
createDynamicAuction(params: CreateDynamicAuctionParams<C>, options?: {
|
|
69
|
+
_createParams?: CreateParams;
|
|
70
|
+
}): Promise<{
|
|
29
71
|
hookAddress: Address;
|
|
30
72
|
tokenAddress: Address;
|
|
31
73
|
poolId: string;
|
|
32
74
|
transactionHash: string;
|
|
33
75
|
}>;
|
|
76
|
+
/**
|
|
77
|
+
* Simulate a dynamic auction creation and return predicted addresses and poolId.
|
|
78
|
+
* Useful for clients that need the hook/token/poolId before submitting the tx.
|
|
79
|
+
*/
|
|
80
|
+
simulateCreateDynamicAuction(params: CreateDynamicAuctionParams<C>): Promise<{
|
|
81
|
+
createParams: CreateParams;
|
|
82
|
+
hookAddress: Address;
|
|
83
|
+
tokenAddress: Address;
|
|
84
|
+
poolId: string;
|
|
85
|
+
gasEstimate?: bigint;
|
|
86
|
+
/** Execute the create with the same params used in simulation (guarantees address match) */
|
|
87
|
+
execute: () => Promise<{
|
|
88
|
+
hookAddress: Address;
|
|
89
|
+
tokenAddress: Address;
|
|
90
|
+
poolId: string;
|
|
91
|
+
transactionHash: string;
|
|
92
|
+
}>;
|
|
93
|
+
}>;
|
|
94
|
+
private resolveCreateGasEstimate;
|
|
95
|
+
private isDoppler404Token;
|
|
34
96
|
/**
|
|
35
97
|
* Encode migration data based on the MigrationConfig
|
|
36
98
|
* This replaces the manual encoding methods from the old SDKs
|
|
37
99
|
*/
|
|
38
100
|
private encodeMigrationData;
|
|
39
101
|
/**
|
|
40
|
-
*
|
|
102
|
+
* Encode create params for Uniswap V4 Multicurve initializer/migrator flow
|
|
103
|
+
*/
|
|
104
|
+
encodeCreateMulticurveParams(params: CreateMulticurveParams<C>): CreateParams;
|
|
105
|
+
simulateCreateMulticurve(params: CreateMulticurveParams<C>): Promise<{
|
|
106
|
+
createParams: CreateParams;
|
|
107
|
+
asset: Address;
|
|
108
|
+
pool: Address;
|
|
109
|
+
gasEstimate?: bigint;
|
|
110
|
+
/** Execute the create with the same params used in simulation (guarantees address match) */
|
|
111
|
+
execute: () => Promise<{
|
|
112
|
+
poolAddress: Address;
|
|
113
|
+
tokenAddress: Address;
|
|
114
|
+
transactionHash: string;
|
|
115
|
+
}>;
|
|
116
|
+
}>;
|
|
117
|
+
createMulticurve(params: CreateMulticurveParams<C>, options?: {
|
|
118
|
+
_createParams?: CreateParams;
|
|
119
|
+
}): Promise<{
|
|
120
|
+
poolAddress: Address;
|
|
121
|
+
tokenAddress: Address;
|
|
122
|
+
transactionHash: string;
|
|
123
|
+
}>;
|
|
124
|
+
/**
|
|
125
|
+
* Normalize user-provided multicurve positions and ensure they satisfy SDK constraints
|
|
41
126
|
*/
|
|
127
|
+
private normalizeMulticurveCurves;
|
|
128
|
+
private roundMaxTickDown;
|
|
42
129
|
private validateStaticAuctionParams;
|
|
43
130
|
/**
|
|
44
131
|
* Validate dynamic auction parameters
|
|
@@ -52,15 +139,55 @@ declare class DopplerFactory {
|
|
|
52
139
|
* Get the appropriate initializer address based on auction type
|
|
53
140
|
*/
|
|
54
141
|
private getInitializerAddress;
|
|
142
|
+
/**
|
|
143
|
+
* Get the Bundler contract address for the current chain
|
|
144
|
+
* Used to perform atomic create + swap ("bundle") flows for static auctions
|
|
145
|
+
*/
|
|
146
|
+
private getBundlerAddress;
|
|
55
147
|
/**
|
|
56
148
|
* Get the appropriate migrator address based on migration config
|
|
149
|
+
* Allows override via ModuleAddressOverrides when provided in params.
|
|
57
150
|
*/
|
|
58
151
|
private getMigratorAddress;
|
|
59
152
|
/**
|
|
60
|
-
*
|
|
61
|
-
*
|
|
153
|
+
* Simulate a bundle with exact input on Uniswap V3 as part of create
|
|
154
|
+
* Returns the expected output amount for the provided exact input.
|
|
155
|
+
*/
|
|
156
|
+
simulateBundleExactInput(createParams: CreateParams, params: {
|
|
157
|
+
tokenIn: Address;
|
|
158
|
+
tokenOut: Address;
|
|
159
|
+
amountIn: bigint;
|
|
160
|
+
fee: number;
|
|
161
|
+
sqrtPriceLimitX96: bigint;
|
|
162
|
+
}): Promise<bigint>;
|
|
163
|
+
/**
|
|
164
|
+
* Simulate a bundle with exact output on Uniswap V3 as part of create
|
|
165
|
+
* Returns the required input amount for the provided exact output.
|
|
166
|
+
*/
|
|
167
|
+
simulateBundleExactOutput(createParams: CreateParams, params: {
|
|
168
|
+
tokenIn: Address;
|
|
169
|
+
tokenOut: Address;
|
|
170
|
+
amount: bigint;
|
|
171
|
+
fee: number;
|
|
172
|
+
sqrtPriceLimitX96: bigint;
|
|
173
|
+
}): Promise<bigint>;
|
|
174
|
+
simulateMulticurveBundleExactOut(createParams: CreateParams, params?: {
|
|
175
|
+
exactAmountOut?: bigint;
|
|
176
|
+
}): Promise<MulticurveBundleExactOutResult>;
|
|
177
|
+
simulateMulticurveBundleExactIn(createParams: CreateParams, params: {
|
|
178
|
+
exactAmountIn: bigint;
|
|
179
|
+
}): Promise<MulticurveBundleExactInResult>;
|
|
180
|
+
/**
|
|
181
|
+
* Execute an atomic create + swap bundle through the Bundler
|
|
182
|
+
* commands/inputs are Universal Router encoded values (e.g., from doppler-router)
|
|
62
183
|
*/
|
|
63
|
-
|
|
184
|
+
bundle(createParams: CreateParams, commands: Hex, inputs: Hex[], options?: {
|
|
185
|
+
gas?: bigint;
|
|
186
|
+
value?: bigint;
|
|
187
|
+
}): Promise<Hash>;
|
|
188
|
+
private ensureUint128;
|
|
189
|
+
private parseMulticurveBundleResult;
|
|
190
|
+
private normalizePoolKey;
|
|
64
191
|
/**
|
|
65
192
|
* Mines a salt and hook address with the appropriate flags
|
|
66
193
|
*
|
|
@@ -88,6 +215,7 @@ declare class DopplerFactory {
|
|
|
88
215
|
* Compute V4 pool ID from pool key components
|
|
89
216
|
*/
|
|
90
217
|
private computePoolId;
|
|
218
|
+
private ensureMulticurveBundlerSupport;
|
|
91
219
|
}
|
|
92
220
|
|
|
93
|
-
export { DopplerFactory };
|
|
221
|
+
export { DopplerFactory, type MigrationEncoder };
|