This page contains extensive information about all exit codes with which execution of DEX contracts may end up with.

Additionally to standard exit codes, our contracts feature some new ones:

Error CodeNameDescription
6Unknown opcode (Standard)Contract received internal message with unknown opcode or contract received jetton transfer notification with custom payload, which contains unknown opcode
40Not Enough Gas (Standard)There is not enogh gas to perform (or continue) contract execution
250UnexpectedSome unexpected error occurred. Please, contact swap.coffee administration if you face this issue
251Invalid RequestInternal error that signifies about inter-contract communication going wrong
252Wrong SenderIndicates that internal message have been sent by inappropriate contract. Usually met when somebody tries to “hack” DEX contracts
253Not a FactoryIndicates that internal message was expected to be sent by the factory, but it’s sender differs. Usually met when somebody tries to “hack” DEX contracts
254Not an AdminIndicates that internal message was expected to be sent by the administrative wallet, but it’s sender differs. Usually met when somebody tries to “hack” DEX contracts
255Wrong ChainThrown when address other than from basechain (id = 0) was received as an argument in some query
256Wrong AssetsThrown on a swap if pool doesn’t correlate with given assets or if it is unable to determine which asset is input and which is output
257Same AssetsThrown when user tries to swap/deposit liquidity/create pool for a pair of very same assets
258Wrong SignatureThrown at a proof validation stage if proof’s signature is not valid. Usually met when somebody tries to “hack” DEX contracts
259Invalid BalanceIndicates that message wasn’t provided with enough currency
260Invalid Jetton MasterThrown on Jetton Vault if activation failed due to Jetton Master unexpected response
261Unknown AMMThrown when user tries to swap/deposit liquidity/create pool of unknown AMM
262AMM FailedInternal error that signifies about AMM strategy logic going wrong. Please, contact swap.coffee administration if you face this issue
263Invalid AMM SettingsInternal error that signifies about wrong pool setup. Please, contact swap.coffee administration if you face this issue
264Invalid LiquidityThrown if user tried to deposit less liquidity than minimum allowed or in case of zero-amount of one of the assets on liquidity deposition stage
265Invalid FeesThrown when DEX administrator tried to set invalid fees for the pool
266Invalid ConditionIndicates that liquidity deposition condition is of inappropriate format or contains invalid data
267Invalid Asset TypeIndicates that internal message’s body was built wrong and asset in it couldn’t be deserialized
268Deadline ExceededIndicates that deadline (the one that’s being specified in request body) for swap or liquidity deposition exceeded by the time contract received and tried to handle that message
269Slippage ToleratedIndicates that request couldn’t be executed, because slippage limitation (the one that’s being specified in request body) had been triggered
270Pool Already ExistsThrown on pool creation request handling if pool already exists
271Reserves Ratio FailedIndicates that liquidity deposition reserves ratio condition (the one that’s being specified in the deposit request body) check failed
272Already ActiveInternal error that is being thrown whenever contracts or DEX administrator try to activate vault or pool, but it’s already active
273Not ActiveThrown whenever user tries to swap/create pool/deposit liquidity throughout inactive vault or pool