Swap2ExecutionPlan
Defined in: protocol-swap2-core/src/swap2/base.ts:297
What swap2() is about to sign, handed to Swap2EngineConfig.reviewExecution.
Properties
Section titled “Properties”approvals
Section titled “approvals”approvals:
object[]
Defined in: protocol-swap2-core/src/swap2/base.ts:311
ERC-20 approvals sent first, in order (USDT on Ethereum resets to 0 first).
amount
Section titled “amount”amount:
bigint
chainId?
Section titled “chainId?”
optionalchainId?:number
spender
Section titled “spender”spender:
string
token:
string
destAmount
Section titled “destAmount”destAmount:
bigint
Defined in: protocol-swap2-core/src/swap2/base.ts:305
destChain
Section titled “destChain”destChain:
string
Defined in: protocol-swap2-core/src/swap2/base.ts:300
destToken
Section titled “destToken”destToken:
string
Defined in: protocol-swap2-core/src/swap2/base.ts:301
etaSeconds
Section titled “etaSeconds”etaSeconds:
number
Defined in: protocol-swap2-core/src/swap2/base.ts:308
feeUsd
Section titled “feeUsd”feeUsd:
number
Defined in: protocol-swap2-core/src/swap2/base.ts:307
fromChain
Section titled “fromChain”fromChain:
string
Defined in: protocol-swap2-core/src/swap2/base.ts:299
minDestAmount
Section titled “minDestAmount”minDestAmount:
bigint
Defined in: protocol-swap2-core/src/swap2/base.ts:306
provider
Section titled “provider”provider:
string
Defined in: protocol-swap2-core/src/swap2/base.ts:298
recipient
Section titled “recipient”recipient:
string
Defined in: protocol-swap2-core/src/swap2/base.ts:302
refundAddress
Section titled “refundAddress”refundAddress:
string
Defined in: protocol-swap2-core/src/swap2/base.ts:303
requoted?
Section titled “requoted?”
optionalrequoted?:true
Defined in: protocol-swap2-core/src/swap2/base.ts:317
true on a second review: the first quote expired while its approval was being mined, and
the fresh one differs from what was reviewed (another payload, a worse output). The allowance
is already in place, so approvals is empty; cancelling revokes it.
source
Section titled “source”source: {
cellBody?:boolean;cellBodyDecoded?:TonBodySummary;chainId?:number;data?:string;gasLimit?:bigint;kind:"call";memo?:string;memoEncoding?:"utf8"|"hex";to:string;value:bigint; } | {amount:bigint;kind:"token-transfer";memo?:string;memoEncoding?:"utf8"|"hex";recipient:string;token:string; } | {kind:"serialized";serializedTx:string; } | {kind:"typed-order";typedData:string; }
Defined in: protocol-swap2-core/src/swap2/base.ts:319
The source leg exactly as the account will receive it.
sourceAmount
Section titled “sourceAmount”sourceAmount:
bigint
Defined in: protocol-swap2-core/src/swap2/base.ts:304
validUntilMs
Section titled “validUntilMs”validUntilMs:
number
Defined in: protocol-swap2-core/src/swap2/base.ts:309