Skip to main content
@eco-incorp/sauce/actions reads JSON action programs ({ version, chainId?, actions }), validates them against the JSON Schema exported as @eco-incorp/sauce/actions/action-program.schema.json, and compiles them for a chain. A token field takes a registry symbol and a contract field a namespace reference, beside an address.
Generated from the type declarations of @eco-incorp/sauce.

TokenSymbol

Type · @eco-incorp/sauce/actions A registry token symbol - "USDC", "WETH" - in the spelling a Sauce program uses. It is the program global of that name, so it resolves on the chain the program is compiled for, and compiling for a chain that does not register it fails, naming the chain and the symbol.

Token

Type · @eco-incorp/sauce/actions A token: a registry symbol, or an address.

TokenOrNative

Type · @eco-incorp/sauce/actions A token, or "native": the venue’s marker for the chain’s native currency (the zero address).

ContractName

Type · @eco-incorp/sauce/actions A protocol contract by namespace - "UniswapV3.Factory", "BalancerV2.Vault" - in the spelling a Sauce program uses. Like a symbol, it resolves on the chain the program is compiled for.

Contract

Type · @eco-incorp/sauce/actions A protocol contract: a namespace reference, or an address.

TokenContract

Type · @eco-incorp/sauce/actions A contract that is also a token (WETH, wstETH, rETH): a symbol, a namespace reference or an address.

Recipient

Type · @eco-incorp/sauce/actions An address, or "pot" for the executing Pot.

RemoteRecipient

Type · @eco-incorp/sauce/actions A recipient on another chain: an address, or a 32-byte account for a non-EVM chain (Solana).

UniswapV2SwapAction

Type · @eco-incorp/sauce/actions One Uniswap V2 pair, or a fork’s (@sauce/router’s uniswapV2): priced from its reserves, paid by a push, swapped directly. The direction is the pair’s sort order. The pair is pool, or the one factory.getPair(tokenIn, tokenOut) names, read on chain.

UniswapV3SwapAction

Type · @eco-incorp/sauce/actions One Uniswap V3 pool, or a fork’s, through the Pot’s Router (@sauce/router’s uniswapV3). The pool is pool, or the one factory.getPool(tokenIn, tokenOut, fee) names - tickSpacing in place of fee for Aerodrome Slipstream - read on chain.

UniswapV4SwapAction

Interface · @eco-incorp/sauce/actions One Uniswap V4 pool, through the Pot’s Router (@sauce/router’s uniswapV4). A V4 pool has no address: it is its key, tokenIn and tokenOut in sort order with fee, tickSpacing and hooks. "native" is the native currency, which V4 keys as the zero address.

CurveSwapAction

Interface · @eco-incorp/sauce/actions A Curve pool’s 4-argument exchange (@sauce/router’s curve), approved for exactly the input; the output is the tokenOut balance delta.

BalancerV2SwapAction

Interface · @eco-incorp/sauce/actions One Balancer V2 pool, through its Vault (@sauce/router’s balancerV2), approved for exactly the input.

DodoV2SwapAction

Interface · @eco-incorp/sauce/actions A DODO V2 pool - DVM, DPP or DSP - paid by a push (@sauce/router’s dodoV2). tokenIn and tokenOut must be the pool’s base and quote tokens, in either order.

TraderJoeLBSwapAction

Type · @eco-incorp/sauce/actions A Trader Joe Liquidity Book pair, paid by a push (@sauce/router’s traderJoeLB). The pair is pool, or the one factory.getLBPairInformation(tokenIn, tokenOut, binStep) names, read on chain. tokenIn and tokenOut must be its X and Y tokens, in either order; leave tokenX and tokenY out to read them from the pair.

WoofiSwapAction

Interface · @eco-incorp/sauce/actions WOOFi’s WooPPV2 itself, paid by a push (@sauce/router’s woofi).

MaverickV2SwapAction

Interface · @eco-incorp/sauce/actions One Maverick V2 pool, through the Pot’s Router (@sauce/router’s maverickV2).

CurveRouterNGSwapAction

Interface · @eco-incorp/sauce/actions A Curve RouterNG route of up to five hops.

BalancerV2BatchStep

Interface · @eco-incorp/sauce/actions

BalancerV2BatchSwapAction

Interface · @eco-incorp/sauce/actions A Balancer V2 batch across pools; the output is the last step’s asset delta.

BalancerV3SwapAction

Interface · @eco-incorp/sauce/actions One Balancer V3 pool. The router pulls through Permit2 (permit2Approve it first), except a WETH input under wethIsEth, which the Pot pays as native ETH.

AmbientSwapAction

Interface · @eco-incorp/sauce/actions An Ambient (CrocSwap) pool; the output is the received token’s balance delta.

DodoV1SwapAction

Interface · @eco-incorp/sauce/actions Legacy DODO V1 (Classical) pairs, through the DODO proxy; approvals go to DODOApprove.

CarbonTradeAction

Interface · @eco-incorp/sauce/actions

CarbonSwapAction

Interface · @eco-incorp/sauce/actions Carbon strategies, by source amount; the controller pays the Pot.

FraxswapSwapAction

Interface · @eco-incorp/sauce/actions A Fraxswap path; the output is the last token’s balance delta.

FluidDexT1SwapAction

Interface · @eco-incorp/sauce/actions A Fluid DEX T1 pool, selling its ERC-20 side.

RouterSwapAction

Type · @eco-incorp/sauce/actions A swap that @sauce/router implements: one pool, at one of its venues.

SwapAction

Type · @eco-incorp/sauce/actions

AcrossBridgeAction

Interface · @eco-incorp/sauce/actions Across: deposit for the destination chain’s token, less the relayer fee.

StargateBridgeAction

Interface · @eco-incorp/sauce/actions Stargate V2: send from a StargatePool, paying the LayerZero fee it quotes on-chain.

CCTPBridgeAction

Interface · @eco-incorp/sauce/actions Circle CCTP V2: burn USDC for minting on the destination.

HyperlaneBridgeAction

Interface · @eco-incorp/sauce/actions A Hyperlane warp route: transferRemote, paying the interchain gas it quotes on-chain.

BridgeAction

Type · @eco-incorp/sauce/actions

WrapETHAction

Interface · @eco-incorp/sauce/actions

UnwrapETHAction

Interface · @eco-incorp/sauce/actions

WrapStETHAction

Interface · @eco-incorp/sauce/actions stETH to wstETH; wstETH pulls the stETH, so approve it first.

UnwrapStETHAction

Interface · @eco-incorp/sauce/actions

LidoStakeAction

Interface · @eco-incorp/sauce/actions

LidoUnstakeAction

Interface · @eco-incorp/sauce/actions Requests a withdrawal of stETH; the queue pulls it, so approve it first.

RocketPoolStakeAction

Interface · @eco-incorp/sauce/actions

RocketPoolUnstakeAction

Interface · @eco-incorp/sauce/actions

EtherFiStakeAction

Interface · @eco-incorp/sauce/actions

WrapAction

Type · @eco-incorp/sauce/actions

StakeAction

Type · @eco-incorp/sauce/actions

AaveV3SupplyAction

Interface · @eco-incorp/sauce/actions

AaveV3WithdrawAction

Interface · @eco-incorp/sauce/actions Withdraws from Aave V3; the output is the amount withdrawn.

AaveV3BorrowAction

Interface · @eco-incorp/sauce/actions Borrows at the variable rate, the only rate Aave V3 offers.

AaveV3RepayAction

Interface · @eco-incorp/sauce/actions

CompoundV3SupplyAction

Interface · @eco-incorp/sauce/actions

CompoundV3WithdrawAction

Interface · @eco-incorp/sauce/actions

LendingAction

Type · @eco-incorp/sauce/actions

TransferAction

Interface · @eco-incorp/sauce/actions

ApproveAction

Interface · @eco-incorp/sauce/actions

Permit2ApproveAction

Interface · @eco-incorp/sauce/actions A Permit2 allowance, for spenders that pull through Permit2 (Balancer V3’s router, Uniswap’s Universal Router). The token must also be ERC-20-approved to Permit2 itself.

TokenAction

Type · @eco-incorp/sauce/actions

BalanceOfAction

Interface · @eco-incorp/sauce/actions The Pot’s balance of token when the program reaches this action.

NativeBalanceAction

Interface · @eco-incorp/sauce/actions The Pot’s native balance when the program reaches this action.

ArgumentAction

Interface · @eco-incorp/sauce/actions A runtime argument of the compiled program: main(<name>: Uint256). Standalone programs only.

SourceAction

Type · @eco-incorp/sauce/actions

Action

Type · @eco-incorp/sauce/actions

ActionType

Type · @eco-incorp/sauce/actions

ActionProgram

Interface · @eco-incorp/sauce/actions An action program: its actions in order, and optionally the one chain it is written for.