mindbridge-api-python-client 1.8.3__tar.gz → 26.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/PKG-INFO +5 -4
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/pyproject.toml +17 -4
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/__init__.py +12 -0
- mindbridge_api_python_client-26.1.0/src/mindbridgeapi/account_group_item.py +19 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/account_grouping_item.py +4 -16
- mindbridge_api_python_client-26.1.0/src/mindbridgeapi/account_mapping_item.py +23 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/accounting_period.py +1 -10
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/activity_report_parameters.py +6 -21
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/analysis_item.py +3 -22
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/analysis_period.py +1 -10
- mindbridge_api_python_client-26.1.0/src/mindbridgeapi/analysis_result_item.py +15 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/analysis_source_item.py +24 -45
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/analysis_source_type_item.py +3 -13
- mindbridge_api_python_client-26.1.0/src/mindbridgeapi/analysis_type_configuration_item.py +23 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/analysis_type_item.py +3 -13
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/api_token_item.py +5 -24
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/api_tokens.py +1 -1
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/async_result_item.py +3 -13
- mindbridge_api_python_client-26.1.0/src/mindbridgeapi/base_item.py +66 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/base_set.py +2 -2
- mindbridge_api_python_client-26.1.0/src/mindbridgeapi/chunked_file_item.py +23 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/chunked_file_part_item.py +0 -10
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/column_mapping.py +1 -9
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/common_validators.py +0 -28
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/engagement_account_group_item.py +0 -22
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/engagement_account_grouping_item.py +3 -13
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/engagement_item.py +3 -22
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/file_manager_item.py +6 -23
- mindbridge_api_python_client-26.1.0/src/mindbridgeapi/file_result_item.py +15 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/filter_group_condition_item.py +7 -11
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/generated_pydantic_model/model.py +284 -671
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/library_item.py +3 -22
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/organization_item.py +11 -29
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/organizations.py +53 -14
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/population_item.py +17 -34
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/populations.py +2 -3
- mindbridge_api_python_client-26.1.0/src/mindbridgeapi/reporting_period_configuration_item.py +95 -0
- mindbridge_api_python_client-26.1.0/src/mindbridgeapi/reporting_period_configuration_month_item.py +51 -0
- mindbridge_api_python_client-26.1.0/src/mindbridgeapi/reporting_period_configuration_week_item.py +50 -0
- mindbridge_api_python_client-26.1.0/src/mindbridgeapi/reporting_period_configurations.py +139 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/risk_ranges.py +1 -1
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/risk_ranges_item.py +6 -27
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/row_usage_report_parameters.py +1 -15
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/server.py +10 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/task_history_item.py +1 -9
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/task_item.py +3 -20
- mindbridge_api_python_client-26.1.0/src/mindbridgeapi/transaction_id_preview_item.py +15 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/transaction_id_selection.py +1 -10
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/user_item.py +0 -19
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/version.py +1 -1
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/virtual_column.py +1 -10
- mindbridge_api_python_client-26.1.0/src/mindbridgeapi/webhook_event_log_item.py +38 -0
- mindbridge_api_python_client-26.1.0/src/mindbridgeapi/webhook_event_logs.py +74 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/webhook_item.py +0 -19
- mindbridge_api_python_client-1.8.3/src/mindbridgeapi/account_group_item.py +0 -31
- mindbridge_api_python_client-1.8.3/src/mindbridgeapi/account_mapping_item.py +0 -37
- mindbridge_api_python_client-1.8.3/src/mindbridgeapi/analysis_result_item.py +0 -25
- mindbridge_api_python_client-1.8.3/src/mindbridgeapi/analysis_type_configuration_item.py +0 -39
- mindbridge_api_python_client-1.8.3/src/mindbridgeapi/chunked_file_item.py +0 -37
- mindbridge_api_python_client-1.8.3/src/mindbridgeapi/file_result_item.py +0 -25
- mindbridge_api_python_client-1.8.3/src/mindbridgeapi/transaction_id_preview_item.py +0 -25
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/.gitignore +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/LICENSE.txt +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/README.md +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/account_groupings.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/account_groups.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/account_mappings.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/admin_reports.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/analyses.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/analysis_results.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/analysis_source_types.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/analysis_sources.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/analysis_type_configurations.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/analysis_types.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/async_results.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/chunked_files.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/data_tables.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/engagement_account_groupings.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/engagement_account_groups.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/engagements.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/exceptions.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/file_info_item.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/file_infos.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/file_manager.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/file_results.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/generated_pydantic_model/__init__.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/json_tables.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/libraries.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/py.typed +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/task_histories.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/tasks.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/transaction_id_previews.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/users.py +0 -0
- {mindbridge_api_python_client-1.8.3 → mindbridge_api_python_client-26.1.0}/src/mindbridgeapi/webhooks.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: mindbridge-api-python-client
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 26.1.0
|
|
4
4
|
Summary: Interact with the MindBridge API
|
|
5
5
|
Project-URL: Homepage, https://www.mindbridge.ai
|
|
6
6
|
Author-email: MBAI Support <mbaisupport@mindbridge.ai>
|
|
@@ -18,9 +18,10 @@ Classifier: Programming Language :: Python :: 3.13
|
|
|
18
18
|
Classifier: Programming Language :: Python :: 3.14
|
|
19
19
|
Classifier: Typing :: Typed
|
|
20
20
|
Requires-Python: >=3.10
|
|
21
|
-
Requires-Dist: annotated-types
|
|
22
|
-
Requires-Dist: pydantic<=2.12.5,>=2.
|
|
23
|
-
Requires-Dist:
|
|
21
|
+
Requires-Dist: annotated-types<=0.7,>=0.4
|
|
22
|
+
Requires-Dist: pydantic<=2.12.5,>=2.11
|
|
23
|
+
Requires-Dist: typing-extensions<=4.15,>=4; python_full_version < '3.11'
|
|
24
|
+
Requires-Dist: urllib3<=2.6.2,>=2.6
|
|
24
25
|
Description-Content-Type: text/markdown
|
|
25
26
|
|
|
26
27
|
<h1 align="center">MindBridge API Python Client</h1>
|
|
@@ -29,9 +29,10 @@ classifiers = [
|
|
|
29
29
|
]
|
|
30
30
|
dynamic = [ "version" ]
|
|
31
31
|
dependencies = [
|
|
32
|
-
"annotated-types>=0.
|
|
33
|
-
"pydantic>=2.
|
|
34
|
-
"
|
|
32
|
+
"annotated-types>=0.4,<=0.7",
|
|
33
|
+
"pydantic>=2.11,<=2.12.5",
|
|
34
|
+
"typing-extensions>=4,<=4.15 ; python_full_version < '3.11'",
|
|
35
|
+
"urllib3>=2.6,<=2.6.2",
|
|
35
36
|
]
|
|
36
37
|
urls.Homepage = "https://www.mindbridge.ai"
|
|
37
38
|
|
|
@@ -78,6 +79,18 @@ build.targets.sdist.only-include = [ "src/mindbridgeapi" ]
|
|
|
78
79
|
python-downloads = "never"
|
|
79
80
|
python-preference = "only-system"
|
|
80
81
|
|
|
82
|
+
[[tool.uv.index]]
|
|
83
|
+
name = "pypi"
|
|
84
|
+
url = "https://pypi.org/simple"
|
|
85
|
+
publish-url = "https://upload.pypi.org/legacy/"
|
|
86
|
+
explicit = true
|
|
87
|
+
|
|
88
|
+
[[tool.uv.index]]
|
|
89
|
+
name = "testpypi"
|
|
90
|
+
url = "https://test.pypi.org/simple/"
|
|
91
|
+
publish-url = "https://test.pypi.org/legacy/"
|
|
92
|
+
explicit = true
|
|
93
|
+
|
|
81
94
|
[tool.ruff]
|
|
82
95
|
extend-exclude = [ ".cci_pycache" ]
|
|
83
96
|
format.line-ending = "lf"
|
|
@@ -197,7 +210,7 @@ capitalise-enum-members = true
|
|
|
197
210
|
force-optional = true
|
|
198
211
|
snake-case-field = true
|
|
199
212
|
# Model customization:
|
|
200
|
-
|
|
213
|
+
base-class = "mindbridgeapi.base_item.BaseItem"
|
|
201
214
|
disable-timestamp = true
|
|
202
215
|
output-datetime-class = "AwareDatetime"
|
|
203
216
|
target-python-version = "3.10"
|
|
@@ -71,6 +71,15 @@ from mindbridgeapi.generated_pydantic_model.model import (
|
|
|
71
71
|
from mindbridgeapi.library_item import LibraryItem
|
|
72
72
|
from mindbridgeapi.organization_item import OrganizationItem
|
|
73
73
|
from mindbridgeapi.population_item import PopulationItem
|
|
74
|
+
from mindbridgeapi.reporting_period_configuration_item import (
|
|
75
|
+
ReportingPeriodConfigurationItem,
|
|
76
|
+
)
|
|
77
|
+
from mindbridgeapi.reporting_period_configuration_month_item import (
|
|
78
|
+
ReportingPeriodConfigurationMonthItem,
|
|
79
|
+
)
|
|
80
|
+
from mindbridgeapi.reporting_period_configuration_week_item import (
|
|
81
|
+
ReportingPeriodConfigurationWeekItem,
|
|
82
|
+
)
|
|
74
83
|
from mindbridgeapi.risk_ranges_item import RiskRangesItem
|
|
75
84
|
from mindbridgeapi.row_usage_report_parameters import RowUsageReportParameters
|
|
76
85
|
from mindbridgeapi.server import Server
|
|
@@ -144,6 +153,9 @@ __all__ = [
|
|
|
144
153
|
"LibraryItem",
|
|
145
154
|
"OrganizationItem",
|
|
146
155
|
"PopulationItem",
|
|
156
|
+
"ReportingPeriodConfigurationItem",
|
|
157
|
+
"ReportingPeriodConfigurationMonthItem",
|
|
158
|
+
"ReportingPeriodConfigurationWeekItem",
|
|
147
159
|
"RiskRangeBounds",
|
|
148
160
|
"RiskRangesItem",
|
|
149
161
|
"RiskScoreDisplay",
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
#
|
|
2
|
+
# Copyright MindBridge Analytics Inc. all rights reserved.
|
|
3
|
+
#
|
|
4
|
+
# This material is confidential and may not be copied, distributed,
|
|
5
|
+
# reversed engineered, decompiled or otherwise disseminated without
|
|
6
|
+
# the prior written consent of MindBridge Analytics Inc.
|
|
7
|
+
#
|
|
8
|
+
|
|
9
|
+
from typing import Any
|
|
10
|
+
from mindbridgeapi.generated_pydantic_model.model import (
|
|
11
|
+
ApiAccountGroupRead,
|
|
12
|
+
ApiAccountGroupUpdate,
|
|
13
|
+
)
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
class AccountGroupItem(ApiAccountGroupRead):
|
|
17
|
+
@property
|
|
18
|
+
def update_json(self) -> dict[str, Any]:
|
|
19
|
+
return self._get_post_json(out_class=ApiAccountGroupUpdate)
|
|
@@ -8,12 +8,9 @@
|
|
|
8
8
|
|
|
9
9
|
from collections.abc import Generator
|
|
10
10
|
from typing import Annotated, Any
|
|
11
|
-
from pydantic import
|
|
11
|
+
from pydantic import Field, field_validator
|
|
12
12
|
from mindbridgeapi.account_group_item import AccountGroupItem
|
|
13
|
-
from mindbridgeapi.common_validators import
|
|
14
|
-
_convert_userinfo_to_useritem,
|
|
15
|
-
_warning_if_extra_fields,
|
|
16
|
-
)
|
|
13
|
+
from mindbridgeapi.common_validators import _convert_userinfo_to_useritem
|
|
17
14
|
from mindbridgeapi.generated_pydantic_model.model import (
|
|
18
15
|
ApiAccountGroupingRead,
|
|
19
16
|
ApiAccountGroupingUpdate,
|
|
@@ -41,17 +38,8 @@ class AccountGroupingItem(ApiAccountGroupingRead):
|
|
|
41
38
|
Generator[AccountGroupItem, None, None], Field(exclude=True)
|
|
42
39
|
] = _empty_account_groups()
|
|
43
40
|
|
|
44
|
-
|
|
45
|
-
extra="allow",
|
|
46
|
-
validate_assignment=True,
|
|
47
|
-
validate_default=True,
|
|
48
|
-
validate_return=True,
|
|
49
|
-
)
|
|
50
|
-
_a = model_validator(mode="after")(_warning_if_extra_fields)
|
|
51
|
-
_b = field_validator("*")(_convert_userinfo_to_useritem)
|
|
41
|
+
_ = field_validator("*")(_convert_userinfo_to_useritem)
|
|
52
42
|
|
|
53
43
|
@property
|
|
54
44
|
def update_json(self) -> dict[str, Any]:
|
|
55
|
-
|
|
56
|
-
ag_update = ApiAccountGroupingUpdate.model_validate(in_class_dict)
|
|
57
|
-
return ag_update.model_dump(mode="json", by_alias=True, exclude_none=True)
|
|
45
|
+
return self._get_post_json(out_class=ApiAccountGroupingUpdate)
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
#
|
|
2
|
+
# Copyright MindBridge Analytics Inc. all rights reserved.
|
|
3
|
+
#
|
|
4
|
+
# This material is confidential and may not be copied, distributed,
|
|
5
|
+
# reversed engineered, decompiled or otherwise disseminated without
|
|
6
|
+
# the prior written consent of MindBridge Analytics Inc.
|
|
7
|
+
#
|
|
8
|
+
|
|
9
|
+
from typing import Any
|
|
10
|
+
from pydantic import field_validator
|
|
11
|
+
from mindbridgeapi.common_validators import _convert_userinfo_to_useritem
|
|
12
|
+
from mindbridgeapi.generated_pydantic_model.model import (
|
|
13
|
+
ApiAccountMappingRead,
|
|
14
|
+
ApiAccountMappingUpdate,
|
|
15
|
+
)
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
class AccountMappingItem(ApiAccountMappingRead):
|
|
19
|
+
_ = field_validator("*")(_convert_userinfo_to_useritem)
|
|
20
|
+
|
|
21
|
+
@property
|
|
22
|
+
def update_json(self) -> dict[str, Any]:
|
|
23
|
+
return self._get_post_json(out_class=ApiAccountMappingUpdate)
|
|
@@ -7,8 +7,7 @@
|
|
|
7
7
|
#
|
|
8
8
|
|
|
9
9
|
from typing import Annotated
|
|
10
|
-
from pydantic import
|
|
11
|
-
from mindbridgeapi.common_validators import _warning_if_extra_fields
|
|
10
|
+
from pydantic import Field
|
|
12
11
|
from mindbridgeapi.generated_pydantic_model.model import (
|
|
13
12
|
ApiAccountingPeriodRead,
|
|
14
13
|
Frequency,
|
|
@@ -42,11 +41,3 @@ class AccountingPeriod(ApiAccountingPeriodRead):
|
|
|
42
41
|
].description
|
|
43
42
|
),
|
|
44
43
|
] = Frequency.ANNUAL
|
|
45
|
-
|
|
46
|
-
model_config = ConfigDict(
|
|
47
|
-
extra="allow",
|
|
48
|
-
validate_assignment=True,
|
|
49
|
-
validate_default=True,
|
|
50
|
-
validate_return=True,
|
|
51
|
-
)
|
|
52
|
-
_ = model_validator(mode="after")(_warning_if_extra_fields)
|
|
@@ -7,8 +7,6 @@
|
|
|
7
7
|
#
|
|
8
8
|
|
|
9
9
|
from typing import Any
|
|
10
|
-
from pydantic import ConfigDict, model_validator
|
|
11
|
-
from mindbridgeapi.common_validators import _warning_if_extra_fields
|
|
12
10
|
from mindbridgeapi.generated_pydantic_model.model import (
|
|
13
11
|
Category as _ActivityReportCategory,
|
|
14
12
|
RunActivityReportRequestCreate,
|
|
@@ -35,26 +33,13 @@ class ActivityReportParameters(RunActivityReportRequestCreate):
|
|
|
35
33
|
Attributes:
|
|
36
34
|
start (datetime): The first date in the reporting timeframe.
|
|
37
35
|
end (datetime): The last date in the reporting timeframe.
|
|
38
|
-
user_ids (
|
|
39
|
-
|
|
40
|
-
categories (
|
|
41
|
-
|
|
42
|
-
only_completed_analyses (
|
|
43
|
-
events.
|
|
36
|
+
user_ids (list[str]): The users to include in the report. If empty, all users
|
|
37
|
+
will be included.
|
|
38
|
+
categories (list[ActivityReportCategory]): The categories to include in the
|
|
39
|
+
report. If empty, all categories will be included.
|
|
40
|
+
only_completed_analyses (bool): Restrict entries to analysis complete events.
|
|
44
41
|
"""
|
|
45
42
|
|
|
46
|
-
model_config = ConfigDict(
|
|
47
|
-
extra="allow",
|
|
48
|
-
validate_assignment=True,
|
|
49
|
-
validate_default=True,
|
|
50
|
-
validate_return=True,
|
|
51
|
-
)
|
|
52
|
-
_ = model_validator(mode="after")(_warning_if_extra_fields)
|
|
53
|
-
|
|
54
43
|
@property
|
|
55
44
|
def create_json(self) -> dict[str, Any]:
|
|
56
|
-
|
|
57
|
-
out_class_object = RunActivityReportRequestCreate.model_validate(in_class_dict)
|
|
58
|
-
return out_class_object.model_dump(
|
|
59
|
-
mode="json", by_alias=True, exclude_none=True
|
|
60
|
-
)
|
|
45
|
+
return self._get_post_json(out_class=RunActivityReportRequestCreate)
|
|
@@ -9,15 +9,12 @@
|
|
|
9
9
|
from collections.abc import Generator
|
|
10
10
|
from datetime import date, timedelta
|
|
11
11
|
from typing import Annotated, Any
|
|
12
|
-
from pydantic import
|
|
12
|
+
from pydantic import Field, field_validator, model_validator
|
|
13
13
|
from mindbridgeapi.analysis_period import AnalysisPeriod
|
|
14
14
|
from mindbridgeapi.analysis_result_item import AnalysisResultItem
|
|
15
15
|
from mindbridgeapi.analysis_source_item import AnalysisSourceItem
|
|
16
16
|
from mindbridgeapi.analysis_type_item import AnalysisTypeItem
|
|
17
|
-
from mindbridgeapi.common_validators import
|
|
18
|
-
_convert_userinfo_to_useritem,
|
|
19
|
-
_warning_if_extra_fields,
|
|
20
|
-
)
|
|
17
|
+
from mindbridgeapi.common_validators import _convert_userinfo_to_useritem
|
|
21
18
|
from mindbridgeapi.generated_pydantic_model.model import (
|
|
22
19
|
ApiAnalysisCreate,
|
|
23
20
|
ApiAnalysisRead,
|
|
@@ -115,14 +112,7 @@ class AnalysisItem(ApiAnalysisRead):
|
|
|
115
112
|
_empty_tasks()
|
|
116
113
|
)
|
|
117
114
|
|
|
118
|
-
|
|
119
|
-
extra="allow",
|
|
120
|
-
validate_assignment=True,
|
|
121
|
-
validate_default=True,
|
|
122
|
-
validate_return=True,
|
|
123
|
-
)
|
|
124
|
-
_a = model_validator(mode="after")(_warning_if_extra_fields)
|
|
125
|
-
_b = field_validator("*")(_convert_userinfo_to_useritem)
|
|
115
|
+
_ = field_validator("*")(_convert_userinfo_to_useritem)
|
|
126
116
|
|
|
127
117
|
@field_validator("analysis_periods", mode="after")
|
|
128
118
|
@classmethod
|
|
@@ -146,15 +136,6 @@ class AnalysisItem(ApiAnalysisRead):
|
|
|
146
136
|
|
|
147
137
|
return self
|
|
148
138
|
|
|
149
|
-
def _get_post_json(
|
|
150
|
-
self, out_class: type[ApiAnalysisCreate | ApiAnalysisUpdate]
|
|
151
|
-
) -> dict[str, Any]:
|
|
152
|
-
in_class_dict = self.model_dump()
|
|
153
|
-
out_class_object = out_class.model_validate(in_class_dict)
|
|
154
|
-
return out_class_object.model_dump(
|
|
155
|
-
mode="json", by_alias=True, exclude_none=True
|
|
156
|
-
)
|
|
157
|
-
|
|
158
139
|
@property
|
|
159
140
|
def create_json(self) -> dict[str, Any]:
|
|
160
141
|
return self._get_post_json(out_class=ApiAnalysisCreate)
|
|
@@ -8,8 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
from datetime import date, datetime, timezone
|
|
10
10
|
from typing import Annotated
|
|
11
|
-
from pydantic import
|
|
12
|
-
from mindbridgeapi.common_validators import _warning_if_extra_fields
|
|
11
|
+
from pydantic import Field
|
|
13
12
|
from mindbridgeapi.generated_pydantic_model.model import ApiAnalysisPeriodRead
|
|
14
13
|
|
|
15
14
|
|
|
@@ -29,14 +28,6 @@ class AnalysisPeriod(ApiAnalysisPeriodRead):
|
|
|
29
28
|
),
|
|
30
29
|
] = date(datetime.now(tz=timezone.utc).astimezone().year - 1, 12, 31)
|
|
31
30
|
|
|
32
|
-
model_config = ConfigDict(
|
|
33
|
-
extra="allow",
|
|
34
|
-
validate_assignment=True,
|
|
35
|
-
validate_default=True,
|
|
36
|
-
validate_return=True,
|
|
37
|
-
)
|
|
38
|
-
_ = model_validator(mode="after")(_warning_if_extra_fields)
|
|
39
|
-
|
|
40
31
|
def __lt__(self, other: object) -> bool:
|
|
41
32
|
"""Sort as current then prior period 1, 2, 3, 4 (newest to oldest).
|
|
42
33
|
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
#
|
|
2
|
+
# Copyright MindBridge Analytics Inc. all rights reserved.
|
|
3
|
+
#
|
|
4
|
+
# This material is confidential and may not be copied, distributed,
|
|
5
|
+
# reversed engineered, decompiled or otherwise disseminated without
|
|
6
|
+
# the prior written consent of MindBridge Analytics Inc.
|
|
7
|
+
#
|
|
8
|
+
|
|
9
|
+
from pydantic import field_validator
|
|
10
|
+
from mindbridgeapi.common_validators import _convert_userinfo_to_useritem
|
|
11
|
+
from mindbridgeapi.generated_pydantic_model.model import ApiAnalysisResultRead
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
class AnalysisResultItem(ApiAnalysisResultRead):
|
|
15
|
+
_ = field_validator("*")(_convert_userinfo_to_useritem)
|
|
@@ -7,52 +7,49 @@
|
|
|
7
7
|
#
|
|
8
8
|
|
|
9
9
|
from typing import Annotated, Any, Literal
|
|
10
|
-
from pydantic import
|
|
10
|
+
from pydantic import Field, field_validator
|
|
11
11
|
from mindbridgeapi.analysis_source_type_item import AnalysisSourceTypeItem
|
|
12
|
-
from mindbridgeapi.common_validators import
|
|
13
|
-
_convert_userinfo_to_useritem,
|
|
14
|
-
_warning_if_extra_fields,
|
|
15
|
-
)
|
|
12
|
+
from mindbridgeapi.common_validators import _convert_userinfo_to_useritem
|
|
16
13
|
from mindbridgeapi.generated_pydantic_model.model import (
|
|
17
14
|
ApiAnalysisSourceCreate,
|
|
18
15
|
ApiAnalysisSourceRead,
|
|
19
16
|
ApiAnalysisSourceUpdate,
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
17
|
+
ApiDuplicateVirtualColumnRead,
|
|
18
|
+
ApiJoinVirtualColumnRead,
|
|
19
|
+
ApiSplitByDelimiterVirtualColumnRead,
|
|
20
|
+
ApiSplitByPositionVirtualColumnRead,
|
|
24
21
|
)
|
|
25
22
|
from mindbridgeapi.virtual_column import VirtualColumn, VirtualColumnType
|
|
26
23
|
|
|
27
24
|
|
|
28
|
-
class DuplicateVirtualColumn(
|
|
25
|
+
class DuplicateVirtualColumn(ApiDuplicateVirtualColumnRead):
|
|
29
26
|
name: Annotated[
|
|
30
27
|
str | None,
|
|
31
28
|
Field(
|
|
32
|
-
description=
|
|
29
|
+
description=ApiDuplicateVirtualColumnRead.model_fields["name"].description
|
|
33
30
|
),
|
|
34
31
|
] = None # type: ignore[assignment]
|
|
35
32
|
type: Annotated[
|
|
36
33
|
Literal[VirtualColumnType.DUPLICATE],
|
|
37
34
|
Field(
|
|
38
|
-
description=
|
|
35
|
+
description=ApiDuplicateVirtualColumnRead.model_fields["type"].description
|
|
39
36
|
),
|
|
40
37
|
]
|
|
41
38
|
version: Annotated[
|
|
42
39
|
int | None,
|
|
43
40
|
Field(
|
|
44
|
-
description=
|
|
41
|
+
description=ApiDuplicateVirtualColumnRead.model_fields[
|
|
45
42
|
"version"
|
|
46
43
|
].description
|
|
47
44
|
),
|
|
48
45
|
] = None # type: ignore[assignment]
|
|
49
46
|
|
|
50
47
|
|
|
51
|
-
class SplitByPositionVirtualColumn(
|
|
48
|
+
class SplitByPositionVirtualColumn(ApiSplitByPositionVirtualColumnRead):
|
|
52
49
|
name: Annotated[
|
|
53
50
|
str | None,
|
|
54
51
|
Field(
|
|
55
|
-
description=
|
|
52
|
+
description=ApiSplitByPositionVirtualColumnRead.model_fields[
|
|
56
53
|
"name"
|
|
57
54
|
].description
|
|
58
55
|
),
|
|
@@ -60,7 +57,7 @@ class SplitByPositionVirtualColumn(ApiSplitByPositionVirtualColumnUpdate):
|
|
|
60
57
|
type: Annotated[
|
|
61
58
|
Literal[VirtualColumnType.SPLIT_BY_POSITION],
|
|
62
59
|
Field(
|
|
63
|
-
description=
|
|
60
|
+
description=ApiSplitByPositionVirtualColumnRead.model_fields[
|
|
64
61
|
"type"
|
|
65
62
|
].description
|
|
66
63
|
),
|
|
@@ -68,18 +65,18 @@ class SplitByPositionVirtualColumn(ApiSplitByPositionVirtualColumnUpdate):
|
|
|
68
65
|
version: Annotated[
|
|
69
66
|
int | None,
|
|
70
67
|
Field(
|
|
71
|
-
description=
|
|
68
|
+
description=ApiSplitByPositionVirtualColumnRead.model_fields[
|
|
72
69
|
"version"
|
|
73
70
|
].description
|
|
74
71
|
),
|
|
75
72
|
] = None # type: ignore[assignment]
|
|
76
73
|
|
|
77
74
|
|
|
78
|
-
class SplitByDelimiterVirtualColumn(
|
|
75
|
+
class SplitByDelimiterVirtualColumn(ApiSplitByDelimiterVirtualColumnRead):
|
|
79
76
|
name: Annotated[
|
|
80
77
|
str | None,
|
|
81
78
|
Field(
|
|
82
|
-
description=
|
|
79
|
+
description=ApiSplitByDelimiterVirtualColumnRead.model_fields[
|
|
83
80
|
"name"
|
|
84
81
|
].description
|
|
85
82
|
),
|
|
@@ -87,7 +84,7 @@ class SplitByDelimiterVirtualColumn(ApiSplitByDelimiterVirtualColumnUpdate):
|
|
|
87
84
|
type: Annotated[
|
|
88
85
|
Literal[VirtualColumnType.SPLIT_BY_DELIMITER],
|
|
89
86
|
Field(
|
|
90
|
-
description=
|
|
87
|
+
description=ApiSplitByDelimiterVirtualColumnRead.model_fields[
|
|
91
88
|
"type"
|
|
92
89
|
].description
|
|
93
90
|
),
|
|
@@ -95,27 +92,25 @@ class SplitByDelimiterVirtualColumn(ApiSplitByDelimiterVirtualColumnUpdate):
|
|
|
95
92
|
version: Annotated[
|
|
96
93
|
int | None,
|
|
97
94
|
Field(
|
|
98
|
-
description=
|
|
95
|
+
description=ApiSplitByDelimiterVirtualColumnRead.model_fields[
|
|
99
96
|
"version"
|
|
100
97
|
].description
|
|
101
98
|
),
|
|
102
99
|
] = None # type: ignore[assignment]
|
|
103
100
|
|
|
104
101
|
|
|
105
|
-
class JoinVirtualColumn(
|
|
102
|
+
class JoinVirtualColumn(ApiJoinVirtualColumnRead):
|
|
106
103
|
name: Annotated[
|
|
107
104
|
str | None,
|
|
108
|
-
Field(description=
|
|
105
|
+
Field(description=ApiJoinVirtualColumnRead.model_fields["name"].description),
|
|
109
106
|
] = None # type: ignore[assignment]
|
|
110
107
|
type: Annotated[
|
|
111
108
|
Literal[VirtualColumnType.JOIN],
|
|
112
|
-
Field(description=
|
|
113
|
-
]
|
|
109
|
+
Field(description=ApiJoinVirtualColumnRead.model_fields["type"].description),
|
|
110
|
+
] = VirtualColumnType.JOIN
|
|
114
111
|
version: Annotated[
|
|
115
112
|
int | None,
|
|
116
|
-
Field(
|
|
117
|
-
description=ApiJoinVirtualColumnUpdate.model_fields["version"].description
|
|
118
|
-
),
|
|
113
|
+
Field(description=ApiJoinVirtualColumnRead.model_fields["version"].description),
|
|
119
114
|
] = None # type: ignore[assignment]
|
|
120
115
|
|
|
121
116
|
|
|
@@ -221,14 +216,7 @@ class AnalysisSourceItem(ApiAnalysisSourceRead):
|
|
|
221
216
|
),
|
|
222
217
|
] = True
|
|
223
218
|
|
|
224
|
-
|
|
225
|
-
extra="allow",
|
|
226
|
-
validate_assignment=True,
|
|
227
|
-
validate_default=True,
|
|
228
|
-
validate_return=True,
|
|
229
|
-
)
|
|
230
|
-
_a = model_validator(mode="after")(_warning_if_extra_fields)
|
|
231
|
-
_b = field_validator("*")(_convert_userinfo_to_useritem)
|
|
219
|
+
_ = field_validator("*")(_convert_userinfo_to_useritem)
|
|
232
220
|
|
|
233
221
|
@field_validator("proposed_virtual_columns", mode="before")
|
|
234
222
|
@classmethod
|
|
@@ -250,15 +238,6 @@ class AnalysisSourceItem(ApiAnalysisSourceRead):
|
|
|
250
238
|
|
|
251
239
|
return new_list
|
|
252
240
|
|
|
253
|
-
def _get_post_json(
|
|
254
|
-
self, out_class: type[_ApiAnalysisSourceCreate | _ApiAnalysisSourceUpdate]
|
|
255
|
-
) -> dict[str, Any]:
|
|
256
|
-
in_class_dict = self.model_dump()
|
|
257
|
-
out_class_object = out_class.model_validate(in_class_dict)
|
|
258
|
-
return out_class_object.model_dump(
|
|
259
|
-
mode="json", by_alias=True, exclude_none=True
|
|
260
|
-
)
|
|
261
|
-
|
|
262
241
|
@property
|
|
263
242
|
def create_json(self) -> dict[str, Any]:
|
|
264
243
|
return self._get_post_json(out_class=_ApiAnalysisSourceCreate)
|
|
@@ -7,11 +7,8 @@
|
|
|
7
7
|
#
|
|
8
8
|
|
|
9
9
|
from typing import ClassVar
|
|
10
|
-
from pydantic import
|
|
11
|
-
from mindbridgeapi.common_validators import
|
|
12
|
-
_convert_userinfo_to_useritem,
|
|
13
|
-
_warning_if_extra_fields,
|
|
14
|
-
)
|
|
10
|
+
from pydantic import field_validator
|
|
11
|
+
from mindbridgeapi.common_validators import _convert_userinfo_to_useritem
|
|
15
12
|
from mindbridgeapi.generated_pydantic_model.model import ApiAnalysisSourceTypeRead
|
|
16
13
|
|
|
17
14
|
|
|
@@ -45,11 +42,4 @@ class AnalysisSourceTypeItem(ApiAnalysisSourceTypeRead):
|
|
|
45
42
|
FUND_ELIMINATION_ENTRIES: ClassVar[str] = "4b8361d00000000000000020"
|
|
46
43
|
FUND_RECLASSIFICATION_ENTRIES: ClassVar[str] = "4b8361d00000000000000021"
|
|
47
44
|
|
|
48
|
-
|
|
49
|
-
extra="allow",
|
|
50
|
-
validate_assignment=True,
|
|
51
|
-
validate_default=True,
|
|
52
|
-
validate_return=True,
|
|
53
|
-
)
|
|
54
|
-
_a = model_validator(mode="after")(_warning_if_extra_fields)
|
|
55
|
-
_b = field_validator("*")(_convert_userinfo_to_useritem)
|
|
45
|
+
_ = field_validator("*")(_convert_userinfo_to_useritem)
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
#
|
|
2
|
+
# Copyright MindBridge Analytics Inc. all rights reserved.
|
|
3
|
+
#
|
|
4
|
+
# This material is confidential and may not be copied, distributed,
|
|
5
|
+
# reversed engineered, decompiled or otherwise disseminated without
|
|
6
|
+
# the prior written consent of MindBridge Analytics Inc.
|
|
7
|
+
#
|
|
8
|
+
|
|
9
|
+
from typing import Any
|
|
10
|
+
from pydantic import field_validator
|
|
11
|
+
from mindbridgeapi.common_validators import _convert_userinfo_to_useritem
|
|
12
|
+
from mindbridgeapi.generated_pydantic_model.model import (
|
|
13
|
+
ApiAnalysisTypeConfigurationRead,
|
|
14
|
+
ApiAnalysisTypeConfigurationUpdate,
|
|
15
|
+
)
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
class AnalysisTypeConfigurationItem(ApiAnalysisTypeConfigurationRead):
|
|
19
|
+
_ = field_validator("*")(_convert_userinfo_to_useritem)
|
|
20
|
+
|
|
21
|
+
@property
|
|
22
|
+
def update_json(self) -> dict[str, Any]:
|
|
23
|
+
return self._get_post_json(out_class=ApiAnalysisTypeConfigurationUpdate)
|
|
@@ -8,12 +8,9 @@
|
|
|
8
8
|
|
|
9
9
|
from collections.abc import Generator
|
|
10
10
|
from typing import Annotated, ClassVar
|
|
11
|
-
from pydantic import
|
|
11
|
+
from pydantic import Field, field_validator
|
|
12
12
|
from mindbridgeapi.analysis_source_type_item import AnalysisSourceTypeItem
|
|
13
|
-
from mindbridgeapi.common_validators import
|
|
14
|
-
_convert_userinfo_to_useritem,
|
|
15
|
-
_warning_if_extra_fields,
|
|
16
|
-
)
|
|
13
|
+
from mindbridgeapi.common_validators import _convert_userinfo_to_useritem
|
|
17
14
|
from mindbridgeapi.generated_pydantic_model.model import ApiAnalysisTypeRead
|
|
18
15
|
|
|
19
16
|
|
|
@@ -39,11 +36,4 @@ class AnalysisTypeItem(ApiAnalysisTypeRead):
|
|
|
39
36
|
Generator[AnalysisSourceTypeItem, None, None], Field(exclude=True)
|
|
40
37
|
] = _empty_analysis_source_types()
|
|
41
38
|
|
|
42
|
-
|
|
43
|
-
extra="allow",
|
|
44
|
-
validate_assignment=True,
|
|
45
|
-
validate_default=True,
|
|
46
|
-
validate_return=True,
|
|
47
|
-
)
|
|
48
|
-
_a = model_validator(mode="after")(_warning_if_extra_fields)
|
|
49
|
-
_b = field_validator("*")(_convert_userinfo_to_useritem)
|
|
39
|
+
_ = field_validator("*")(_convert_userinfo_to_useritem)
|
|
@@ -7,11 +7,8 @@
|
|
|
7
7
|
#
|
|
8
8
|
|
|
9
9
|
from typing import Annotated, Any
|
|
10
|
-
from pydantic import
|
|
11
|
-
from mindbridgeapi.common_validators import
|
|
12
|
-
_convert_userinfo_to_useritem,
|
|
13
|
-
_warning_if_extra_fields,
|
|
14
|
-
)
|
|
10
|
+
from pydantic import Field, field_validator
|
|
11
|
+
from mindbridgeapi.common_validators import _convert_userinfo_to_useritem
|
|
15
12
|
from mindbridgeapi.generated_pydantic_model.model import (
|
|
16
13
|
ApiApiTokenCreate,
|
|
17
14
|
ApiApiTokenRead,
|
|
@@ -47,8 +44,8 @@ class ApiTokenItem(ApiApiTokenRead):
|
|
|
47
44
|
info.
|
|
48
45
|
permissions (list[ApiTokenPermission]): The set of permissions that inform which
|
|
49
46
|
endpoints this token is authorized to access.
|
|
50
|
-
allowed_addresses (
|
|
51
|
-
|
|
47
|
+
allowed_addresses (list[str]): Indicates the set of addresses that are allowed
|
|
48
|
+
to use this token. If empty, any address may use it.
|
|
52
49
|
partial_token (str): A partial representation of the API token.
|
|
53
50
|
user_id (str): Identifies the API Token User associated with this token.
|
|
54
51
|
token (str): The token string associated with the API token.
|
|
@@ -63,23 +60,7 @@ class ApiTokenItem(ApiApiTokenRead):
|
|
|
63
60
|
Field(description=CreateApiTokenResponseRead.model_fields["token"].description),
|
|
64
61
|
] = None
|
|
65
62
|
|
|
66
|
-
|
|
67
|
-
extra="allow",
|
|
68
|
-
validate_assignment=True,
|
|
69
|
-
validate_default=True,
|
|
70
|
-
validate_return=True,
|
|
71
|
-
)
|
|
72
|
-
_a = model_validator(mode="after")(_warning_if_extra_fields)
|
|
73
|
-
_b = field_validator("*")(_convert_userinfo_to_useritem)
|
|
74
|
-
|
|
75
|
-
def _get_post_json(
|
|
76
|
-
self, out_class: type[ApiApiTokenCreate | ApiApiTokenUpdate]
|
|
77
|
-
) -> dict[str, Any]:
|
|
78
|
-
in_class_dict = self.model_dump()
|
|
79
|
-
out_class_object = out_class.model_validate(in_class_dict)
|
|
80
|
-
return out_class_object.model_dump(
|
|
81
|
-
mode="json", by_alias=True, exclude_none=True
|
|
82
|
-
)
|
|
63
|
+
_ = field_validator("*")(_convert_userinfo_to_useritem)
|
|
83
64
|
|
|
84
65
|
@property
|
|
85
66
|
def create_json(self) -> dict[str, Any]:
|
|
@@ -94,7 +94,7 @@ class ApiTokens(BaseSet):
|
|
|
94
94
|
"""Retrieves API tokens from the server based on the provided query parameters.
|
|
95
95
|
|
|
96
96
|
Args:
|
|
97
|
-
json (
|
|
97
|
+
json (dict[str, Any]): Query parameters for filtering API tokens.
|
|
98
98
|
|
|
99
99
|
Yields:
|
|
100
100
|
(ApiTokenItem): A generator of API token items.
|
|
@@ -7,11 +7,8 @@
|
|
|
7
7
|
#
|
|
8
8
|
|
|
9
9
|
import logging
|
|
10
|
-
from pydantic import
|
|
11
|
-
from mindbridgeapi.common_validators import
|
|
12
|
-
_convert_userinfo_to_useritem,
|
|
13
|
-
_warning_if_extra_fields,
|
|
14
|
-
)
|
|
10
|
+
from pydantic import field_validator
|
|
11
|
+
from mindbridgeapi.common_validators import _convert_userinfo_to_useritem
|
|
15
12
|
from mindbridgeapi.exceptions import ItemError, ItemNotFoundError, ValidationError
|
|
16
13
|
from mindbridgeapi.generated_pydantic_model.model import (
|
|
17
14
|
ApiAsyncResult,
|
|
@@ -26,14 +23,7 @@ AsyncResultType = _AsyncResultType # Match the type of AsyncResultItem.type
|
|
|
26
23
|
|
|
27
24
|
|
|
28
25
|
class AsyncResultItem(ApiAsyncResult):
|
|
29
|
-
|
|
30
|
-
extra="allow",
|
|
31
|
-
validate_assignment=True,
|
|
32
|
-
validate_default=True,
|
|
33
|
-
validate_return=True,
|
|
34
|
-
)
|
|
35
|
-
_a = model_validator(mode="after")(_warning_if_extra_fields)
|
|
36
|
-
_b = field_validator("*")(_convert_userinfo_to_useritem)
|
|
26
|
+
_ = field_validator("*")(_convert_userinfo_to_useritem)
|
|
37
27
|
|
|
38
28
|
def _check_if_completed(self) -> bool:
|
|
39
29
|
"""Checks if the AsyncResultItem is completed.
|