# Overview

## Ferra Aggregator V2 SDK

The Ferra Aggregator V2 SDK is a powerful TypeScript library for integrating decentralized exchange (DEX) aggregation functionality into your Sui blockchain applications. It aggregates quotes from multiple external DEX providers and executes swaps through Ferra's unified wrapper contracts.

### Key Features

* **Multi-Provider Aggregation**: Get the best quotes from Cetus, FlowX, and Bluefin aggregators
* **Unified Execution**: Execute swaps through Ferra's wrapper contracts for consistent interface
* **Flexible Configuration**: Enable/disable providers dynamically
* **Customizable Slippage**: Configure slippage tolerance in basis points
* **Type Safety**: Full TypeScript support with comprehensive type definitions
* **Transaction Composability**: Build complex multi-step transactions with customizable swap functions

### Architecture

```
┌─────────────────────────────────────────────────────────────────┐
│                    Ferra Aggregator V2 SDK                      │
├─────────────────────────────────────────────────────────────────┤
│                                                                 │
│  ┌──────────────┐    ┌──────────────┐    ┌──────────────┐       │
│  │    Cetus     │    │    FlowX     │    │   Bluefin    │       │
│  │  Aggregator  │    │  Aggregator  │    │  Aggregator  │       │
│  └──────┬───────┘    └──────┬───────┘    └──────┬───────┘       │
│         │                   │                   │               │
│         └───────────────────┼───────────────────┘               │
│                             │                                   │
│                             ▼                                   │
│                   ┌──────────────────┐                          │
│                   │   Quote Router   │                          │
│                   │                  │                          │
│                   └────────┬─────────┘                          │
│                            │                                    │
│                            ▼                                    │
│                   ┌──────────────────┐                          │
│                   │   TxBuilder      │                          │
│                   │  (Swap Builder)  │                          │
│                   └────────┬─────────┘                          │
│                            │                                    │
│                            ▼                                    │
│         ┌──────────────────────────────────────┐                │
│         │     Ferra Wrapper Contracts (Sui)    │                │
│         │  ┌────────┐ ┌────────┐ ┌──────────┐  │                │
│         │  │ Cetus  │ │ FlowX  │ │ Bluefin  │  │                │
│         │  │Wrapper │ │Wrapper │ │ Wrapper  │  │                │
│         │  └────────┘ └────────┘ └──────────┘  │                │
│         └──────────────────────────────────────┘                │
│                                                                 │
└─────────────────────────────────────────────────────────────────┘
```

### Supported Providers

| Provider    | Status   | Description                         |
| ----------- | -------- | ----------------------------------- |
| **Cetus**   | ✅ Active | Cetus Aggregator - primary provider |
| **FlowX**   | ✅ Active | FlowX DEX aggregator                |
| **Bluefin** | ✅ Active | Bluefin 7K aggregator               |


---

# 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.ferra.ag/integration/aggregator-v2/typescript-sdk/overview.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.
