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

# FINRA API Platform

> FINRA datasets: OTC and ATS equity volume, short interest, Reg SHO, TRACE fixed-income and Treasury aggregates, and registration data, through one query API.

![](https://mintcdn.com/webrouter/gPu3tCeozwRcDBjt/logo/data-apis/finra.webp?fit=max\&auto=format\&n=gPu3tCeozwRcDBjt\&q=85\&s=bf08ede7c97a7e6c5f4b2cad9dd56e43)

[Web Catalog · Finance](https://docs.webrouter.net/data-apis.md?category=finance)

Needs&#x20;

`FINRA_CLIENT_ID`

,&#x20;

`FINRA_CLIENT_SECRET`

Endpoints

4

Auth

OAuth refresh token

[Vendor docs](https://developer.finra.org/docs)

## Setup

| Variable | | What it is |
| - | - | - |
| `FINRA_CLIENT_ID` | required | API client id from the API Console in FINRA Gateway (an individual account can create a Public credential). |
| `FINRA_CLIENT_SECRET` | required | The matching API client secret. |

Put them in your environment or `.env`; [Data APIs](https://docs.webrouter.net/vendors.md) covers the other ways.

## Notes

* Without Accept: application/json the platform answers CSV (text/plain); this entry sets it.
* Synchronous calls return at most 5,000 records (default 1,000); offset tops out at 500,000. Throttle: 1,200 requests per minute per IP.
* Use POST datasets.query to filter; GET datasets.get is for small samples. Sorting needs EQUAL compareFilters on the dataset's partition fields (see datasets.metadata).
* Individual accounts are for non-commercial access to public data; credentials carry a monthly data allowance (10 GB on firm credentials).

## Endpoints

POST

Query a dataset

Records of one dataset, filtered by field comparisons, date ranges and value lists.

[Open](#finra-datasets-query)

GET

Sample a dataset

The first records of a dataset, unfiltered.

[Open](#finra-datasets-get)

GET

Describe a dataset

Fields with types and descriptions, and the partition fields of a dataset.

[Open](#finra-datasets-metadata)

GET

List a dataset's partitions

Available partition values (e.g. week start dates) of a dataset.

[Open](#finra-datasets-partitions)

### Query a dataset

POST

`/data/group/{group}/name/{name}`

`finra.datasets.query`

Records of one dataset, filtered by field comparisons, date ranges and value lists.

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr><td>`group` required</td><td>string</td><td>path</td><td>Dataset group, e.g. otcMarket, fixedIncomeMarket. Example `otcMarket`</td></tr>
    <tr><td>`name` required</td><td>string</td><td>path</td><td>Dataset name, e.g. weeklySummary, treasuryDailyAggregates. Example `weeklySummary`</td></tr>

    <tr>
      <td>
        `fields`
      </td>

      <td>
        array
      </td>

      <td>
        body
      </td>

      <td>
        Field names to return; all when omitted.
      </td>
    </tr>

    <tr><td>`compareFilters`</td><td>array</td><td>body</td><td>List of \{fieldName, fieldValue, compareType}; compareType EQUAL, NOT\_EQUAL, GREATER, LESSER, GTE, LTE or BEGINS\_WITH. Example `[{"fieldName": "tierIdentifier", "fieldValue": "T1", "compareType": "EQUAL"}]`</td></tr>

    <tr>
      <td>
        `dateRangeFilters`
      </td>

      <td>
        array
      </td>

      <td>
        body
      </td>

      <td>
        List of \{fieldName, startDate, endDate}, dates yyyy-MM-dd, inclusive.
      </td>
    </tr>

    <tr>
      <td>
        `domainFilters`
      </td>

      <td>
        array
      </td>

      <td>
        body
      </td>

      <td>
        List of \{fieldName, values: \[...]}.
      </td>
    </tr>

    <tr>
      <td>
        `limit`
      </td>

      <td>
        integer
      </td>

      <td>
        body
      </td>

      <td>
        Records to return, default 1,000, max 5,000 synchronous.
      </td>
    </tr>

    <tr>
      <td>
        `offset`
      </td>

      <td>
        integer
      </td>

      <td>
        body
      </td>

      <td>
        Records to skip, max 500,000.
      </td>
    </tr>

    <tr>
      <td>
        `sortFields`
      </td>

      <td>
        array
      </td>

      <td>
        body
      </td>

      <td>
        Field names, prefixed + or - for direction.
      </td>
    </tr>
  </tbody>
</table>

[Vendor docs](https://developer.finra.org/docs) · Same job: [CMS Open Payments](https://docs.webrouter.net/data-apis/cms-open-payments.md#cms-open-payments-datastore-query), [CMS Data (data.cms.gov)](https://docs.webrouter.net/data-apis/data-cms.md#data-cms-dataset-rows), [data.gov.au](https://docs.webrouter.net/data-apis/data-gov-au.md#data-gov-au-rows-search), [Latvian Open Data Portal (data.gov.lv)](https://docs.webrouter.net/data-apis/data-gov-lv.md#data-gov-lv-rows-search), [data.gov.ua](https://docs.webrouter.net/data-apis/data-gov-ua.md#data-gov-ua-rows-search), [Dune](https://docs.webrouter.net/data-apis/dune.md#dune-query-latest-result)

```python Python theme={null}
router.call_data_api("finra.datasets.query", {'group': 'otcMarket', 'name': 'weeklySummary', 'compareFilters': [{'fieldName': 'tierIdentifier', 'fieldValue': 'T1', 'compareType': 'EQUAL'}]})
```

```text MCP theme={null}
call_data_api(endpoint="finra.datasets.query", params={"group": "otcMarket", "name": "weeklySummary", "compareFilters": [{"fieldName": "tierIdentifier", "fieldValue": "T1", "compareType": "EQUAL"}]})
```

> [!NOTE]
>
> * A read sent as POST.

### Sample a dataset

GET

`/data/group/{group}/name/{name}`

`finra.datasets.get`

The first records of a dataset, unfiltered.

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr><td>`group` required</td><td>string</td><td>path</td><td>Dataset group, e.g. otcMarket, fixedIncomeMarket. Example `otcMarket`</td></tr>
    <tr><td>`name` required</td><td>string</td><td>path</td><td>Dataset name, e.g. weeklySummary, treasuryDailyAggregates. Example `weeklySummary`</td></tr>

    <tr>
      <td>
        `fields`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Comma-separated field names.
      </td>
    </tr>

    <tr>
      <td>
        `limit`
      </td>

      <td>
        integer
      </td>

      <td>
        query
      </td>

      <td>
        Records to return, default 1,000.
      </td>
    </tr>

    <tr>
      <td>
        `sortFields`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Comma-separated fields, prefixed + or -.
      </td>
    </tr>
  </tbody>
</table>

[Vendor docs](https://developer.finra.org/docs) · Same job: [CMS Open Payments](https://docs.webrouter.net/data-apis/cms-open-payments.md#cms-open-payments-datastore-query), [CMS Data (data.cms.gov)](https://docs.webrouter.net/data-apis/data-cms.md#data-cms-dataset-rows), [data.gov.au](https://docs.webrouter.net/data-apis/data-gov-au.md#data-gov-au-rows-search), [Latvian Open Data Portal (data.gov.lv)](https://docs.webrouter.net/data-apis/data-gov-lv.md#data-gov-lv-rows-search), [data.gov.ua](https://docs.webrouter.net/data-apis/data-gov-ua.md#data-gov-ua-rows-search), [Dune](https://docs.webrouter.net/data-apis/dune.md#dune-query-latest-result)

```python Python theme={null}
router.call_data_api("finra.datasets.get", {'group': 'otcMarket', 'name': 'weeklySummary'})
```

```text MCP theme={null}
call_data_api(endpoint="finra.datasets.get", params={"group": "otcMarket", "name": "weeklySummary"})
```

### Describe a dataset

GET

`/metadata/group/{group}/name/{name}`

`finra.datasets.metadata`

Fields with types and descriptions, and the partition fields of a dataset.

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr><td>`group` required</td><td>string</td><td>path</td><td>Dataset group, e.g. otcMarket, fixedIncomeMarket. Example `otcMarket`</td></tr>
    <tr><td>`name` required</td><td>string</td><td>path</td><td>Dataset name, e.g. weeklySummary, treasuryDailyAggregates. Example `weeklySummary`</td></tr>
  </tbody>
</table>

[Vendor docs](https://developer.finra.org/docs) · Same job: [Affinity](https://docs.webrouter.net/data-apis/affinity.md#affinity-companies-fields), [ArcGIS Online](https://docs.webrouter.net/data-apis/arcgis.md#arcgis-items-get), [Attio](https://docs.webrouter.net/data-apis/attio.md#attio-attributes-list), [Bank of Canada](https://docs.webrouter.net/data-apis/bankofcanada.md#bankofcanada-series-get), [US Bureau of Economic Analysis](https://docs.webrouter.net/data-apis/bea.md#bea-parameters-list), [Bright Data](https://docs.webrouter.net/data-apis/brightdata.md#brightdata-datasets-metadata)

```python Python theme={null}
router.call_data_api("finra.datasets.metadata", {'group': 'otcMarket', 'name': 'weeklySummary'})
```

```text MCP theme={null}
call_data_api(endpoint="finra.datasets.metadata", params={"group": "otcMarket", "name": "weeklySummary"})
```

### List a dataset's partitions

GET

`/partitions/group/{group}/name/{name}`

`finra.datasets.partitions`

Available partition values (e.g. week start dates) of a dataset.

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr><td>`group` required</td><td>string</td><td>path</td><td>Dataset group, e.g. otcMarket, fixedIncomeMarket. Example `otcMarket`</td></tr>
    <tr><td>`name` required</td><td>string</td><td>path</td><td>Dataset name, e.g. weeklySummary, treasuryDailyAggregates. Example `weeklySummary`</td></tr>
  </tbody>
</table>

[Vendor docs](https://developer.finra.org/docs) · Same job: [Affinity](https://docs.webrouter.net/data-apis/affinity.md#affinity-companies-fields), [ArcGIS Online](https://docs.webrouter.net/data-apis/arcgis.md#arcgis-items-get), [Attio](https://docs.webrouter.net/data-apis/attio.md#attio-attributes-list), [Bank of Canada](https://docs.webrouter.net/data-apis/bankofcanada.md#bankofcanada-series-get), [US Bureau of Economic Analysis](https://docs.webrouter.net/data-apis/bea.md#bea-parameters-list), [Bright Data](https://docs.webrouter.net/data-apis/brightdata.md#brightdata-datasets-metadata)

```python Python theme={null}
router.call_data_api("finra.datasets.partitions", {'group': 'otcMarket', 'name': 'weeklySummary'})
```

```text MCP theme={null}
call_data_api(endpoint="finra.datasets.partitions", params={"group": "otcMarket", "name": "weeklySummary"})
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.