> ## Documentation Index
> Fetch the complete documentation index at: https://cobalt-55-abhishek.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Dataref

> Get a dataref's records as a table.

Return a dataref's records reshaped as a tabular structure — `headers` plus `rows` — paginated by record ID.

## Authentication

<ParamField header="x-api-key" type="string" required>Your Refold API key.</ParamField>
<ParamField header="linked_account_id" type="string" required>The linked account that owns the dataref.</ParamField>

## Path Parameters

<ParamField path="refName" type="string" required>The dataref name. **Example:** `contacts`</ParamField>

## Query Parameters

<ParamField query="page" type="integer" default="1">Page number.</ParamField>
<ParamField query="limit" type="integer" default="100">Rows per page.</ParamField>

## Response

<Tabs>
  <Tab title="200 OK">
    <ResponseField name="headers" type="array">Column names. Always includes `record_id`.</ResponseField>
    <ResponseField name="rows" type="array">Row objects keyed by header.</ResponseField>
    <ResponseField name="totalDocs" type="integer">Total rows.</ResponseField>
    <ResponseField name="page" type="integer">Current page.</ResponseField>
    <ResponseField name="limit" type="integer">Rows per page.</ResponseField>
    <ResponseField name="hasNextPage" type="boolean">Whether another page follows.</ResponseField>
  </Tab>
</Tabs>

<ResponseExample>
  ```json 200 With records theme={null}
  {
    "headers": ["record_id", "email", "stage"],
    "rows": [
      { "record_id": "1", "email": "jane@example.com", "stage": "qualified" }
    ],
    "page": 1,
    "limit": 100,
    "totalDocs": 1,
    "totalPages": 1,
    "hasNextPage": false
  }
  ```

  ```json 200 Empty theme={null}
  {
    "headers": ["record_id"],
    "rows": [],
    "page": 1,
    "limit": 100,
    "totalDocs": 0,
    "totalPages": 0,
    "hasNextPage": false
  }
  ```
</ResponseExample>

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET "https://app.refold.ai/api/v2/public/dataref/{refName}" \
    -H "x-api-key: YOUR_API_KEY" \
    -H "linked_account_id: YOUR_LINKED_ACCOUNT_ID"
  ```
</RequestExample>
