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

# List Filters

Discover all available filters for querying properties and people. Returns filter metadata including types, available options, and allowed operators.

Use this endpoint to build dynamic filter UIs or to understand which filters are available before constructing search queries.

## Query Parameters

| Parameter     | Type    | Description                                            |
| ------------- | ------- | ------------------------------------------------------ |
| `source_type` | string  | Filter by source type: `properties` or `people`        |
| `search`      | string  | Search filters by name or description                  |
| `page`        | integer | Page number (default: `1`, min: `1`)                   |
| `per_page`    | integer | Results per page (default: `25`, min: `1`, max: `250`) |

<RequestExample>
  ```bash cURL theme={null}
  curl "https://api.v2.dealmachine.com/v1/filters?source_type=properties&per_page=50" \
    -H "Authorization: Bearer dm_sk_live_xxx"
  ```

  ```typescript Node.js theme={null}
  const response = await fetch(
    'https://api.v2.dealmachine.com/v1/filters?source_type=properties&per_page=50',
    {
      headers: {
        Authorization: `Bearer ${apiKey}`,
      },
    }
  );

  const { data, pagination } = await response.json();
  console.log(`Found ${pagination.total_results} filters`);
  ```

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

  response = requests.get(
      'https://api.v2.dealmachine.com/v1/filters',
      params={'source_type': 'properties', 'per_page': 50},
      headers={'Authorization': f'Bearer {api_key}'}
  )

  body = response.json()
  for f in body['data']:
      print(f"{f['filter_id']}: {f['name']} ({f['type']})")
  ```
</RequestExample>

<ResponseExample>
  ```json 200 Success theme={null}
  {
    "data": [
      {
        "filter_id": "estimated_value",
        "name": "Estimated Value",
        "description": "Current estimated market value of the property",
        "type": "NUMBER",
        "source_type": "properties",
        "group_id": "financial",
        "options": null,
        "allowed_operators": [
          "range",
          "greater_than",
          "greater_than_or_equal",
          "less_than",
          "less_than_or_equal",
          "equals",
          "not_equals"
        ]
      },
      {
        "filter_id": "property_type",
        "name": "Property Type",
        "description": "Classification of the property",
        "type": "MULTI_SELECT",
        "source_type": "properties",
        "group_id": "property_details",
        "options": [
          { "option_id": 1, "label": "Single Family" },
          { "option_id": 2, "label": "Multi-Family" },
          { "option_id": 3, "label": "Condo" }
        ],
        "allowed_operators": ["contains_any", "contains_none", "contains_all"]
      }
    ],
    "pagination": {
      "page": 1,
      "per_page": 50,
      "total_results": 215,
      "total_pages": 5,
      "has_next_page": true,
      "has_previous_page": false
    }
  }
  ```

  ```json 401 Unauthorized theme={null}
  {
    "error": {
      "code": "invalid_api_key",
      "message": "Invalid API key",
      "request_id": "req_abc123"
    }
  }
  ```
</ResponseExample>

## Response Fields

The response follows the standard [response envelope](/concepts/response-format) with a `data` array and `pagination` object.

Each filter object in `data` contains:

| Field                 | Type             | Description                                                      |
| --------------------- | ---------------- | ---------------------------------------------------------------- |
| `filter_id`           | string           | Unique identifier for the filter (e.g., `estimated_value`)       |
| `name`                | string           | Display name                                                     |
| `description`         | string \| null   | Human-readable description                                       |
| `type`                | string           | Data type: `NUMBER`, `STRING`, `DATE`, `MULTI_SELECT`, `BOOLEAN` |
| `source_type`         | string           | `properties` or `people`                                         |
| `group_id`            | string \| null   | Filter group identifier (e.g., `financial`, `property_details`)  |
| `options`             | array \| null    | Available values for `MULTI_SELECT` filters                      |
| `options[].option_id` | string \| number | Unique identifier for the option                                 |
| `options[].label`     | string           | Display label for the option                                     |
| `allowed_operators`   | array            | Valid operators for this filter type                             |

## Allowed Operators by Type

| Type                     | Operators                                                                                                   |
| ------------------------ | ----------------------------------------------------------------------------------------------------------- |
| `NUMBER`                 | `range`, `greater_than`, `greater_than_or_equal`, `less_than`, `less_than_or_equal`, `equals`, `not_equals` |
| `STRING`                 | `contains`, `any_of`, `starts_with`, `ends_with`, `equals`, `not_equals`, `not_contains`                    |
| `DATE`                   | `date_range`, `is_after`, `is_before`, `equals`, `relative_time`                                            |
| `DATE` (`last_exported`) | `date_range`, `is_after`, `is_before`, `equals`, `relative_time`, `is_known`                                |
| `MULTI_SELECT`           | `contains_any`, `contains_none`, `contains_all`                                                             |
| `BOOLEAN`                | *(automatic; no operator needed)*                                                                           |

<Note>
  This is a discovery endpoint. It returns metadata about available filters, not property data. Use
  each filter's `allowed_operators` value to construct queries against the [search
  endpoints](/concepts/searching). Filter-specific operators, such as `is_known` for Export
  Activity, are included in that array.
</Note>
