API Reference

Create Pool

This method allows the caller to create a pool on Bluefin Spot. Anyone can invoke the method to create a pool, but note that the creator can only specify the fee bases points, the protocol fee % is fixed to 20% and can not be changed by the pool creator. The following interfaces can be used to call the method, with the arguments described below:

Interfaces

public entry fun create_pool<CoinTypeA, CoinTypeB>( clock: &Clock, pool_name: vector<u8>, pool_icon_url: vector<u8>, coin_a_symbol: vector<u8>, coin_a_decimals: u8, coin_a_url: vector<u8>, coin_b_symbol: vector<u8>, coin_b_decimals: u8, coin_b_url: vector<u8>, tick_spacing: u32, fee_basis_points: u64, current_sqrt_price: u128, ctx: &mut TxContext){ abort 0 } /// Parameters: /// - clock : Sui clock object /// - pool_name : The name of the pool. The convention used on bluefin spot is `CoinA-CoinB` /// - pool_icon_url : The url to image to be shown on the position NFT of the pool (can be empty as well `""`) /// - coin_a_symbol : The symbol of coin A of the pool. The data is emitted and not stored on pool or the protocol /// - coin_a_decimals : The number of decimals the Coin A has. The data is emitted and not stored on pool or the protocol /// - coin_a_url : The url of the coin A token metadata or icon or anything else a user creating the /// pool might be interested in getting as part of the pool creation event. /// The data is emitted and not stored on pool or the protocol /// - coin_b_symbol : The symbol of coin B of the pool. The data is emitted and not stored on pool or the protocol /// - coin_b_decimals : The number of decimals the Coin B has. The data is emitted and not stored on pool or the protocol /// - coin_a_url : The url of the coin A token metadata or icon or anything else a user creating the /// pool might be interested in getting as part of the pool creation event. /// The data is emitted and not stored on pool or the protocol /// - tick_spacing : An unsigned number representing the tick spacing supported by the pool /// - fee_basis_points : The maount of fee the pool charges per swap. The fee is represented /// in 1e6 format. 1 bips is 1e3, 2.5 bps is 2.5*1e3 and so on. /// - current_sqrt_price : The starting sqrt price of the pool /// - ctx : Murable reference to caller's transaction context /// /// Events Emitted : PoolCreated