# Quickstart

The eckoDEX SDK is a stand-alone library designed to assist developers when interacting with the protocol in any environment that can execute JavaScript, such as websites or node scripts. With the SDK, you can manipulate data that has been queried from the Kadena Chainweb blockchain using libraries that assist with several needs, such as protection from rounding errors.

{% hint style="info" %}
**Good to know:** The Kadena Chainweb blockchain uses a unique runtime environment which uses the Pact programming language to describe and execute smart contracts. Pact provides several benefits over an EVM/Solidity environment, but it does require a few concepts in order to work with effectively. This SDK does wrap some common errors and edge cases, however please keep in mind that expertise with Kadena Chainweb and/or Pact may be required to support your use case. For more about Kadena, see <https://kadena.io/>. To learn about the Pact runtime, you can refer to the full documentation: <https://pact-language.readthedocs.io/en/stable/pact-reference.html>
{% endhint %}

## Install the library

You can install `kaddex-sdk` using any npm package manager.

{% tabs %}
{% tab title="Node" %}

```
# Install via NPM
npm install --save kaddex-sdk
```

{% endtab %}
{% endtabs %}

## Make your first request

To make your first request, send a signed Kadena chainweb transaction \`to the swap smart contract using the KaddexSdk library function, `swapExactIn`. You will need to have some tokens in your account.

Take a look at how you might call this method using our official library:

{% tabs %}
{% tab title="Node - TypeScript" %}

```typescript
import { KaddexSdk, retrieveVerifiedAccount, TOKENS } from 'kaddex-sdk';

const PUBLIC_KEY = '<YOUR PUBLIC KEY>'
const SECRET_KEY = '<YOUR SECRET KEY>'

// if your account name is different from your PUBLIC_KEY, use the correct value here
const account = await retrieveVerifiedAccount({ accountName: PUBLIC_KEY });

const kaddex = new KaddexSdk({ account, secretKey: SECRET_KEY });

try {
  (async () => {
    const swapResponse = await kaddex.swapExactIn({
      token0: {
        token: TOKENS.KDA,
        amount: 0.02
      },
      token1: {
        token: TOKENS.ABC,
        amount: 0.1
      },
      slippage: '0.05'
    });
    console.log(swapResponse);
  })();
} catch (err) {
  console.error(err);
}

```

{% endtab %}
{% endtabs %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.ecko.finance/eckodao/sdk/quickstart.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
