/* Autogenerated file. Do not edit manually. */ /* tslint:disable */ /* eslint-disable */ import { Address, ExecutableScript, ExecuteScriptParams, ExecuteScriptResult, Script, SignerProvider, HexString, } from "@alephium/web3"; import { getContractByCodeHash } from "./contracts"; import { default as AddLiquidityScriptJson } from "../scripts/AddLiquidity.ral.json"; import { default as BurnScriptJson } from "../scripts/Burn.ral.json"; import { default as CollectFeeScriptJson } from "../scripts/CollectFee.ral.json"; import { default as CreatePairScriptJson } from "../scripts/CreatePair.ral.json"; import { default as CreatePairAndAddLiquidityScriptJson } from "../scripts/CreatePairAndAddLiquidity.ral.json"; import { default as EnableFeeCollectorScriptJson } from "../scripts/EnableFeeCollector.ral.json"; import { default as GetTokenScriptJson } from "../test/GetToken.ral.json"; import { default as MintScriptJson } from "../scripts/Mint.ral.json"; import { default as RemoveLiquidityScriptJson } from "../scripts/RemoveLiquidity.ral.json"; import { default as SetFeeCollectorFactoryScriptJson } from "../scripts/SetFeeCollectorFactory.ral.json"; import { default as SwapScriptJson } from "../scripts/Swap.ral.json"; import { default as SwapMaxInScriptJson } from "../scripts/SwapMaxIn.ral.json"; import { default as SwapMinOutScriptJson } from "../scripts/SwapMinOut.ral.json"; export const AddLiquidity = new ExecutableScript<{ sender: Address; router: HexString; pair: HexString; amount0Desired: bigint; amount1Desired: bigint; amount0Min: bigint; amount1Min: bigint; deadline: bigint; }>(Script.fromJson(AddLiquidityScriptJson, "", []), getContractByCodeHash); export const Burn = new ExecutableScript<{ tokenPair: HexString; sender: Address; liquidity: bigint; }>(Script.fromJson(BurnScriptJson, "", []), getContractByCodeHash); export const CollectFee = new ExecutableScript<{ feeCollector: HexString }>( Script.fromJson(CollectFeeScriptJson, "", []), getContractByCodeHash ); export const CreatePair = new ExecutableScript<{ payer: Address; factory: HexString; alphAmount: bigint; tokenAId: HexString; tokenBId: HexString; }>(Script.fromJson(CreatePairScriptJson, "", []), getContractByCodeHash); export const CreatePairAndAddLiquidity = new ExecutableScript<{ payer: Address; factory: HexString; alphAmount: bigint; token0Id: HexString; token1Id: HexString; amount0: bigint; amount1: bigint; }>( Script.fromJson(CreatePairAndAddLiquidityScriptJson, "", []), getContractByCodeHash ); export const EnableFeeCollector = new ExecutableScript<{ tokenPairFactory: HexString; tokenPair: HexString; }>( Script.fromJson(EnableFeeCollectorScriptJson, "", []), getContractByCodeHash ); export const GetToken = new ExecutableScript<{ token: HexString; sender: Address; amount: bigint; }>(Script.fromJson(GetTokenScriptJson, "", []), getContractByCodeHash); export const Mint = new ExecutableScript<{ tokenPair: HexString; sender: Address; amount0: bigint; amount1: bigint; }>(Script.fromJson(MintScriptJson, "", []), getContractByCodeHash); export const RemoveLiquidity = new ExecutableScript<{ sender: Address; router: HexString; pairId: HexString; liquidity: bigint; amount0Min: bigint; amount1Min: bigint; deadline: bigint; }>(Script.fromJson(RemoveLiquidityScriptJson, "", []), getContractByCodeHash); export const SetFeeCollectorFactory = new ExecutableScript<{ tokenPairFactory: HexString; feeCollectorFactory: HexString; }>( Script.fromJson(SetFeeCollectorFactoryScriptJson, "", []), getContractByCodeHash ); export const Swap = new ExecutableScript<{ dexAccount: HexString; tokenPair: HexString; sender: Address; to: Address; amount0In: bigint; amount1In: bigint; amount0Out: bigint; amount1Out: bigint; }>(Script.fromJson(SwapScriptJson, "", []), getContractByCodeHash); export const SwapMaxIn = new ExecutableScript<{ dexAccount: HexString; sender: Address; router: HexString; pair: HexString; tokenInId: HexString; amountInMax: bigint; amountOut: bigint; deadline: bigint; }>(Script.fromJson(SwapMaxInScriptJson, "", []), getContractByCodeHash); export const SwapMinOut = new ExecutableScript<{ dexAccount: HexString; sender: Address; router: HexString; pair: HexString; tokenInId: HexString; amountIn: bigint; amountOutMin: bigint; deadline: bigint; }>(Script.fromJson(SwapMinOutScriptJson, "", []), getContractByCodeHash);