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

# List domains

> Query and list research domains with filtering, sorting, and pagination.

Retrieves a list of top-level research domains with pagination metadata.

### Query Parameters

<ParamField query="page" default="1" type="integer">
  Page number for pagination. Default is `1`.
</ParamField>

<ParamField query="per_page" default="25" type="integer">
  Results per page. Allowed values: `10`, `25`, `50`, `100`.
</ParamField>

<ParamField query="sort" type="string">
  Sorting parameter (e.g. `outputs_count:desc`, `cited_by_count:desc`).
</ParamField>

### Response Fields

<ResponseField name="meta" type="object" required>
  Pagination metadata.

  <Expandable title="meta attributes">
    <ResponseField name="count" type="integer">Total matching records count.</ResponseField>
    <ResponseField name="page" type="integer">Current page number.</ResponseField>
    <ResponseField name="per_page" type="integer">Items per page.</ResponseField>
  </Expandable>
</ResponseField>

<ResponseField name="results" type="array" required>
  Array of domain records.

  <Expandable title="results item attributes">
    <ResponseField name="id" type="integer">Domain numeric ID.</ResponseField>
    <ResponseField name="name" type="string">Domain display name.</ResponseField>
    <ResponseField name="description" type="string">Domain description.</ResponseField>

    <ResponseField name="ids" type="object">
      External identifiers.

      <Expandable title="ids attributes">
        <ResponseField name="wikidata" type="string">Wikidata URL.</ResponseField>
        <ResponseField name="wikipedia" type="string">Wikipedia URL.</ResponseField>
      </Expandable>
    </ResponseField>

    <ResponseField name="display_name_alternatives" type="array">Alternative display names or abbreviations.</ResponseField>

    <ResponseField name="fields" type="array">
      Child research fields.

      <Expandable title="fields attributes">
        <ResponseField name="id" type="integer">Field numeric ID.</ResponseField>
        <ResponseField name="name" type="string">Field display name.</ResponseField>
      </Expandable>
    </ResponseField>

    <ResponseField name="siblings" type="array">
      Sibling domains.

      <Expandable title="siblings attributes">
        <ResponseField name="id" type="integer">Sibling domain numeric ID.</ResponseField>
        <ResponseField name="name" type="string">Sibling domain display name.</ResponseField>
      </Expandable>
    </ResponseField>

    <ResponseField name="outputs_count" type="integer">Outputs count.</ResponseField>
    <ResponseField name="cited_by_count" type="integer">Citations count.</ResponseField>
    <ResponseField name="updated_date" type="string">Last updated timestamp.</ResponseField>
    <ResponseField name="created_date" type="string">Creation timestamp.</ResponseField>
  </Expandable>
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET "https://api.hexagraph.in/domains?sort=outputs_count:desc"
  ```

  ```javascript JavaScript theme={null}
  fetch("https://api.hexagraph.in/domains?sort=outputs_count:desc")
    .then(response => response.json())
    .then(data => console.log(data));
  ```

  ```python Python theme={null}
  import requests

  response = requests.get("https://api.hexagraph.in/domains", params={"sort": "outputs_count:desc"})
  print(response.json())
  ```
</RequestExample>

<ResponseExample>
  ```json 200 OK theme={null}
  {
    "meta": {
      "count": 4,
      "page": 1,
      "per_page": 25
    },
    "results": [
      {
        "id": 3,
        "name": "Physical Sciences",
        "description": "branch of natural science that studies non-living systems",
        "ids": {
          "wikidata": "https://www.wikidata.org/wiki/Q14632398",
          "wikipedia": "https://en.wikipedia.org/wiki/Outline_of_physical_science"
        },
        "display_name_alternatives": ["Natural Sciences"],
        "fields": [
          {
            "id": 15,
            "name": "Chemical Engineering"
          }
        ],
        "siblings": [
          {
            "id": 1,
            "name": "Life Sciences"
          }
        ],
        "outputs_count": 163713213,
        "cited_by_count": 1132994559,
        "updated_date": "2026-08-05T03:01:47",
        "created_date": "2024-01-23T15:21:58"
      }
    ]
  }
  ```

  ```json 400 Bad Request theme={null}
  {
    "statusCode": 400,
    "message": "Bad Request - Invalid query parameters",
    "error": "Bad Request"
  }
  ```

  ```json 429 Rate Limit Exceeded theme={null}
  {
    "statusCode": 429,
    "message": "Rate limit exceeded. Maximum 30 requests per minute.",
    "error": "Too Many Requests"
  }
  ```
</ResponseExample>
