> For the complete documentation index, see [llms.txt](https://docs.carbondefi.xyz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.carbondefi.xyz/developer-guides/carbon-defi-sdk/sdk-functions.md).

# SDK Functions

The Carbon DeFi SDK's main point of interaction is exposed through the functions in **index.ts:**

| Name                                                                                                                    | Description                                                                                                |
| ----------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- |
| [`constructor`](/developer-guides/carbon-defi-sdk/sdk-functions/constructor.md)                                         | Initializes the SDK.                                                                                       |
| [`startDataSync`](/developer-guides/carbon-defi-sdk/sdk-functions/startdatasync.md)                                     | Fetches event data to create a representation of all Carbon DeFi strategies.                               |
| [`pairs`](/developer-guides/carbon-defi-sdk/sdk-functions/getcachedpairs.md)                                            | Gets a list of all active token pairs.                                                                     |
| [`hasLiquidityByPair`](/developer-guides/carbon-defi-sdk/sdk-functions/hasliquiditybypair.md)                           | Checks if a pair currently has liquidity in one or more strategies.                                        |
| [`getLiquidityByPair`](/developer-guides/carbon-defi-sdk/sdk-functions/getliquiditybypair.md)                           | Returns the total amount of liquidity in Carbon DeFi strategies for a given pair.                          |
| [`getUserStrategies`](/developer-guides/carbon-defi-sdk/sdk-functions/getuserstrategies.md)                             | Gets the list of strategies owned by an address.                                                           |
| [`getTradeData`](/developer-guides/carbon-defi-sdk/sdk-functions/gettradedata.md)                                       | Generates and returns a trade route for a trade, including an unsigned transaction to execute the trade.   |
| [`composeTradeByTargetTransaction`](/developer-guides/carbon-defi-sdk/sdk-functions/composetradebytargettransaction.md) | Creates an unsigned trade transaction for trading by target amount.                                        |
| [`composeTradeBySourceTransaction`](/developer-guides/carbon-defi-sdk/sdk-functions/composetradebysourcetransaction.md) | Creates an unsigned trade transaction for trading by source amount.                                        |
| [`createBuySellStrategy`](/developer-guides/carbon-defi-sdk/sdk-functions/createbuysellstrategy.md)                     | Creates a Carbon DeFi strategy, formatted for smart contract input, and generates an unsigned transaction. |
| [`updateStrategy`](/developer-guides/carbon-defi-sdk/sdk-functions/updatestrategy.md)                                   | Generates an unsigned transaction with updated order parameters.                                           |
| [`deleteStrategy`](/developer-guides/carbon-defi-sdk/sdk-functions/deletestrategy.md)                                   | Generates an unsigned transaction to delete a strategy.                                                    |
| [`getRateLiquidityDepthByPair`](/developer-guides/carbon-defi-sdk/sdk-functions/getrateliquiditydepthbypair.md)         | This returns the amount of liquidity available for a token pair at a specific trade-rate.                  |
| [`getMinRateByPair`](/developer-guides/carbon-defi-sdk/sdk-functions/getminratebypair.md)                               | Gets the current lowest trade price for a given token pair.                                                |
| [`getMaxRateByPair`](/developer-guides/carbon-defi-sdk/sdk-functions/getmaxratebypair.md)                               | Gets the current highest trade price for a given token pair.                                               |
