SDK Q3

Dywe SDK: Functionality

The Dywe SDK provides a set of functions for interacting with the trading platform, including position management, liquidity and spot market operations.

1. Position Management

  • Position Opening: Allows the user to open a new trading position by specifying the trading pair, trade direction (long/short), volume and leverage.

  • Close Position: Allows the user to close an active position at the current market price or at predetermined conditions.

  • Add Margin: Provides the ability to increase margin for an open position, which reduces the risk of liquidation.

  • Set Stop Loss: Allows you to set the price level at which a position will be automatically closed to limit losses.

  • Take Profit Setting: Allows you to set the price level at which the position will automatically close to lock in profits.

2. Liquidity Management

  • Adding liquidity to the pool: Allows users to deposit assets into a liquidity pool, receiving DLP tokens in exchange for the deposit.

  • Removing liquidity from the pool: Allows assets to be removed from the liquidity pool by burning DLP tokens, with the resulting value determined by the current state of the pool.

  • Adding liquidity to a spot market pool: Allows assets to be deposited into a separate liquidity pool used to enable spot trading.

3. Spot Market Transactions

  • Buying Spot Tokens: Allows digital assets to be purchased on the spot market at market or limit price.

  • Selling spot tokens: Allows you to sell assets with instant execution or according to pre-defined parameters.

The SDK provides programmatic access to all functions, providing flexibility and automation of trading operations.

Last updated