For the complete documentation index, see llms.txt. This page is also available as Markdown.

Typescript SDK

The typescript SDK to interact with Ferra CLMM protocol

Getting started

Install Ferra CLMM SDK: npm install @ferra-labs/damm

Optional: npm install @mysten/sui

The Ferra CLMM npm package is located here: https://npmjs.com/package/@ferra-labs/damm

Initialize the Ferra CLMM SDK with default values using the Sui mainnet RPC

// Initilize DAMM instance
import { dammMainnet, initFerraSDK }  from "@ferra-labs/clmm"

const useFerraSDK = (address: string) => {
  return useMemo(
    () =>
      initFerraSDK({
        ...dammMainnet,
        network: 'beta' // can be 'mainnet' or 'testnet', 'beta',
        fullNodeUrl: 'YOUR_PRC_FULL_NODE',
        wallet: 'YOUR_WALLET_ADDRES',
      }),
    [address]
  );
};

Last updated