> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ostium.com/llms.txt
> Use this file to discover all available pages before exploring further.

# getPairs

> Fetch all Ostium pairs, leverage limits, live prices, and market-state fields.

## What it does

Returns the current pair list with market metadata and live price fields.

## Example

```ts theme={null}
const { pairs } = await client.getPairs();
```

Filter by pair:

```ts theme={null}
const { pairs } = await client.getPairs({ pairIds: [0, 1] });
```

Include a builder fee in the computed `openFee` values:

```ts theme={null}
const { pairs } = await client.getPairs({ builderFeeBps: 20 });
```

On `OstiumClient`, `builderFeeBps` defaults to the configured `builder.feeBps` when omitted.

## Use it for

* pair pickers
* market tables
* reading pair and overnight leverage limits before `openTrade()`
* pairId discovery before `openTrade()`

## Parameters

```ts theme={null}
interface GetPairsParams {
  pairIds?: Array<string | number>;
  builderFeeBps?: number;
}
```

## Response schema

```ts theme={null}
interface PairSchedule {
  id: number;
  alwaysOpen?: boolean;
  timezone?: string;
  openingHours?: string[];
}

interface Response {
  pairs: Array<{
    pairId: string;
    pairTo: string;
    pairFrom: string;
    minSz: string;
    maxBSz: string;
    maxSSz: string;
    minNtl: string;
    maxLeverage: number;
    overnightMaxLeverage: number;
    rolloverFeePerBlock: string;
    openInterest: string;
    buyOpenInterest: string;
    sellOpenInterest: string;
    maxOpenInterest: string;
    category: string;
    rolloverRate: { long: string; short: string };
    midPx: string;
    askPx: string;
    bidPx: string;
    isMarketOpen: boolean;
    isDayTradingClosed: boolean;
    secondsToToggleIsDayTradingClosed: number;
    schedule?: PairSchedule;
    openFee: number;
    closeFee: number;
  }>;
}
```

`openFee` is the pair taker fee plus the configured builder fee, in basis points. `closeFee` is currently always `0`.
