flash_swap_callback
Last updated
Last updated
An entrypoint that executes after execution of user's lambda but only in case when user is trying to loan TEZ tokens. It checks the returns of TEZ tokens and fills it to the appropriative Bucket contract.
When user need to return TEZ tokens, he need to transfer correct amount of TEZ tokens to the DexCore contract at the end of his lambda execution.
Field | Type | Description |
---|---|---|
Only DexCore contract can call this entrypoint.
108
- pair (pool) with the specified token_id
not listed.
113
- a Bucket contract not found (not TOK/TEZ LP pair).
129
- wrong amount of flash swap returns.
138
- only entered (transaction must be not the first transaction in the chain of calls).
403
- sender
of the transaction is not DexCore contract.
412
- non payable entrypoint (can't accept TEZ tokens during call of an entrypoint).
pair_id
token_id_t (nat)
Identifier of the liquidity pool (pair)
prev_tez_balance
nat
TEZ balance of DexCore contract before execution of user's lambda
amount_in
nat
The number of incoming tokens (amount that user must repay)