|
2 | 2 |
|
3 | 3 | from __future__ import annotations |
4 | 4 |
|
5 | | -from typing import Union, Iterable |
6 | | -from typing_extensions import Literal, Required, Annotated, TypeAlias, TypedDict |
| 5 | +from typing import Union |
| 6 | +from typing_extensions import Literal, Annotated, TypeAlias, TypedDict |
7 | 7 |
|
8 | 8 | from .._types import SequenceNotStr |
9 | 9 | from .._utils import PropertyInfo |
| 10 | +from .shared_params.or_ import Or |
| 11 | +from .shared_params.and_ import And |
10 | 12 |
|
11 | | -__all__ = ["DocumentListParams", "Filters", "FiltersOr", "FiltersAnd"] |
| 13 | +__all__ = ["DocumentListParams", "Filters"] |
12 | 14 |
|
13 | 15 |
|
14 | 16 | class DocumentListParams(TypedDict, total=False): |
@@ -41,16 +43,4 @@ class DocumentListParams(TypedDict, total=False): |
41 | 43 | """Field to sort by""" |
42 | 44 |
|
43 | 45 |
|
44 | | -class FiltersOr(TypedDict, total=False): |
45 | | - """OR""" |
46 | | - |
47 | | - or_: Required[Annotated[Iterable[object], PropertyInfo(alias="OR")]] |
48 | | - |
49 | | - |
50 | | -class FiltersAnd(TypedDict, total=False): |
51 | | - """AND""" |
52 | | - |
53 | | - and_: Required[Annotated[Iterable[object], PropertyInfo(alias="AND")]] |
54 | | - |
55 | | - |
56 | | -Filters: TypeAlias = Union[FiltersOr, FiltersAnd] |
| 46 | +Filters: TypeAlias = Union[Or, And] |
0 commit comments