> For the complete documentation index, see [llms.txt](https://docs.nexus.xyz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.nexus.xyz/api-reference/funding/fetch-funding-samples-v1.md).

# GET /api/v1/markets/{market\_id}/funding-samples

Funding premium-index samples

Funding premium-index samples.

`operationId`: `fetchFundingSamplesV1`

> **Declared server:** `https://api.testnet.nexus.xyz`. Examples follow the OpenAPI operation, path-item, then document server precedence and append the full operation path. A declared URL is not proof of live routing; verify the target deployment before use. See [Networks](/api-reference/guides/networks.md).

> **Not reachable through CCXT.** Premium-index samples between funding settlements, not funding rates. CCXT's only funding-rate structure is `FundingRateHistory` (a settled `fundingRate` at a timestamp), and `GET /markets/{market_id}/funding` already serves it as fetchFundingRateHistory. `FundingPremiumSample` carries a timestamp and `premium_index`, and states that the settled rate is a property of the settlement window rather than of an intra-window sample, so a fetchFundingRateHistory badge here would publish a `fundingRate` nothing can fill. fetchPremiumIndexOHLCV is the only other candidate in ccxt 4.5.76 and does not describe it either: it returns OHLCV candles, and these are scalar point observations. Reachable natively as the implicit publicGetMarketsMarketIdFundingSamples.

**Authentication:** none — this operation is public.

Dense per-tick premium-index samples (60s cadence, up to 480 points = 8h). Public — no authentication required.

## Parameters

| Name        | In    | Type      | Required | Default | Description                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| ----------- | ----- | --------- | -------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `market_id` | path  | `string`  | Yes      | —       | Market identifier (e.g. BTC-USDX-PERP, ETH-USDX-PERP). Uppercase ASCII alphanumeric segments joined by single hyphens, at most 64 characters. A value outside that set is rejected with `400` (`INVALID_MARKET_ID`) before any store is read — it cannot name a market, so an empty result would assert that nothing traded rather than that the question was malformed. A well-formed identifier that names no listed market is a `404`, not a `400`. |
| `limit`     | query | `integer` | No       | `480`   | Maximum samples to return (capped at 480).                                                                                                                                                                                                                                                                                                                                                                                                             |

## Responses

| Status | Body                                                                                     | Meaning                              |
| ------ | ---------------------------------------------------------------------------------------- | ------------------------------------ |
| `200`  | array of [`FundingPremiumSample`](/api-reference/guides/schemas.md#fundingpremiumsample) | Premium-index samples, oldest first. |
| `400`  | — *(no schema declared)*                                                                 | —                                    |

## Example

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

```bash
curl -X GET 'https://api.testnet.nexus.xyz/api/v1/markets/BTC-USDX-PERP/funding-samples'
```

{% endtab %}

{% tab title="Python" %}

```python
import requests


response = requests.get("https://api.testnet.nexus.xyz/api/v1/markets/BTC-USDX-PERP/funding-samples")
response.raise_for_status()
print(response.json())
```

{% endtab %}

{% tab title="TypeScript" %}

```typescript
const response = await fetch("https://api.testnet.nexus.xyz/api/v1/markets/BTC-USDX-PERP/funding-samples", {
  method: "GET",
});
if (!response.ok) throw new Error(`${response.status} ${await response.text()}`);
console.log(await response.json());
```

{% endtab %}
{% endtabs %}

***

<sub>Generated from</sub> <sub></sub><sub>`eng/apps/exchange/api/openapi.json`</sub> <sub></sub><sub>(spec</sub> <sub></sub><sub>`0.9.70`</sub><sub>). Do not edit by hand — regenerate with</sub> <sub></sub><sub>`python3 product/docs/tools/api-reference/generate.py`</sub><sub>. Hand-authored context lives in the Guides pages.</sub>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://docs.nexus.xyz/api-reference/funding/fetch-funding-samples-v1.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
