Name | Lookup | Parameters | |
|---|---|---|---|
| initialize_pool | 3b00 | 4 | |
| add_token | 3b01 | 4 | |
| add_liquidity | 3b02 | 2 | |
| remove_liquidity | 3b03 | 2 | |
| sacrifice_position | 3b04 | 1 | |
| sell | 3b05 | 4 | |
| buy | 3b06 | 4 | |
| set_asset_tradable_state | 3b07 | 2 | |
| refund_refused_asset | 3b08 | 3 | |
| set_asset_weight_cap | 3b09 | 2 | |
| set_tvl_cap | 3b0a | 1 |
Name | Lookup | Attributes | |
|---|---|---|---|
| TokenAdded | 3b00 | ["AssetId","Balance","Price"] | |
| LiquidityAdded | 3b01 | ["AccountId","AssetId","Balance","PositionItemId"] | |
| LiquidityRemoved | 3b02 | ["AccountId","PositionItemId","AssetId","Balance","FixedU128"] | |
| SellExecuted | 3b03 | ["AccountId","AssetId","AssetId","Balance","Balance","Balance","Balance"] | |
| BuyExecuted | 3b04 | ["AccountId","AssetId","AssetId","Balance","Balance","Balance","Balance"] | |
| PositionCreated | 3b05 | ["PositionItemId","AccountId","AssetId","Balance","Balance","Price"] | |
| PositionDestroyed | 3b06 | ["PositionItemId","AccountId"] | |
| PositionUpdated | 3b07 | ["PositionItemId","AccountId","AssetId","Balance","Balance","Price"] | |
| TradableStateUpdated | 3b08 | ["AssetId","Tradability"] | |
| AssetRefunded | 3b09 | ["AssetId","Balance","AccountId"] | |
| AssetWeightCapUpdated | 3b0a | ["AssetId","Permill"] | |
| TVLCapUpdated | 3b0b | ["Balance"] |
Name | Type | |
|---|---|---|
| Assets | {"origin":"Map","n_map_type":{"hashers":["Blake2_128Concat"],"key_vec":["U32"],"value":"pallet_omnipool:types:AssetState","keys_id":4,"value_id":434}} | |
| HubAssetImbalance | {"origin":"PlainType","plain_type":"pallet_omnipool:types:SimpleImbalance","PlainTypeValue":435} | |
| HubAssetTradability | {"origin":"PlainType","plain_type":"U8","PlainTypeValue":80} | |
| Positions | {"origin":"Map","n_map_type":{"hashers":["Blake2_128Concat"],"key_vec":["U128"],"value":"pallet_omnipool:types:Position","keys_id":6,"value_id":436}} | |
| NextPositionId | {"origin":"PlainType","plain_type":"U128","PlainTypeValue":6} | |
| TvlCap | {"origin":"PlainType","plain_type":"U128","PlainTypeValue":6} |
Name | Type | Value | |
|---|---|---|---|
| HdxAssetId | U32 | 00000000 | |
| HubAssetId | U32 | 01000000 | |
| StableCoinAssetId | U32 | 02000000 | |
| MinWithdrawalFee | U32 | 64000000 | |
| MinimumTradingLimit | U128 | e8030000000000000000000000000000 | |
| MinimumPoolLiquidity | U128 | 40420f00000000000000000000000000 | |
| MaxInRatio | U128 | 03000000000000000000000000000000 | |
| MaxOutRatio | U128 | 03000000000000000000000000000000 | |
| NFTCollectionId | U128 | 39050000000000000000000000000000 |
Name | Docs |
|---|---|
| InsufficientBalance | Balance too low |
| AssetAlreadyAdded | Asset is already in omnipool |
| AssetNotFound | Asset is not in omnipool |
| NoStableAssetInPool | No stable asset in the pool |
| NoNativeAssetInPool | No native asset in the pool yet. |
| MissingBalance | Adding token as protocol ( root ), token balance has not been updated prior to add token. |
| InvalidInitialAssetPrice | Invalid initial asset price. Price must be non-zero. |
| BuyLimitNotReached | Minimum limit has not been reached during trade. |
| SellLimitExceeded | Maximum limit has been exceeded during trade. |
| PositionNotFound | Position has not been found. |
| InsufficientShares | Insufficient shares in position |
| NotAllowed | Asset is not allowed to be bought or sold |
| Forbidden | Signed account is not owner of position instance. |
| AssetWeightCapExceeded | Asset weight cap has been exceeded. |
| TVLCapExceeded | TVL cap has been exceeded |
| AssetNotRegistered | Asset is not registered in asset registry |
| InsufficientLiquidity | Provided liquidity is below minimum allowed limit |
| InsufficientTradingAmount | Traded amount is below minimum allowed limit |
| SameAssetTradeNotAllowed | Sell or buy with same asset ids is not allowed. |
| HubAssetUpdateError | LRNA update after trade results in positive value. |
| PositiveImbalance | Imbalance results in positive value. |
| InvalidSharesAmount | Amount of shares provided cannot be 0. |
| InvalidHubAssetTradableState | HJb Asset's trabable is only allowed to be SELL or BUY. |
| AssetRefundNotAllowed | Asset is not allowed to be refunded. |
| MaxOutRatioExceeded | Max fraction of asset reserve to buy has been exceeded. |
| MaxInRatioExceeded | Max fraction of asset reserve to sell has been exceeded. |
| PriceDifferenceTooHigh | Max allowed price difference has been exceeded. |
| InvalidOraclePrice | Invalid oracle price - division by zero. |
| InvalidWithdrawalFee | Failed to calculate withdrawal fee. |
| FeeOverdraft | More than allowed amount of fee has been transferred. |