label-studio-sdk 1.0.8__py3-none-any.whl → 1.0.10__py3-none-any.whl
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.
Potentially problematic release.
This version of label-studio-sdk might be problematic. Click here for more details.
- label_studio_sdk/__init__.py +20 -7
- label_studio_sdk/_extensions/label_studio_tools/core/utils/io.py +16 -4
- label_studio_sdk/_extensions/pager_ext.py +8 -0
- label_studio_sdk/actions/client.py +91 -40
- label_studio_sdk/actions/types/actions_create_request_filters.py +14 -24
- label_studio_sdk/actions/types/actions_create_request_filters_items_item.py +16 -26
- label_studio_sdk/actions/types/actions_create_request_filters_items_item_value.py +3 -1
- label_studio_sdk/actions/types/actions_create_request_selected_items.py +1 -2
- label_studio_sdk/actions/types/actions_create_request_selected_items_excluded.py +15 -25
- label_studio_sdk/actions/types/actions_create_request_selected_items_included.py +15 -25
- label_studio_sdk/annotations/__init__.py +2 -2
- label_studio_sdk/annotations/client.py +278 -104
- label_studio_sdk/annotations/types/__init__.py +2 -1
- label_studio_sdk/annotations/types/annotations_create_bulk_request_selected_items.py +34 -0
- label_studio_sdk/annotations/types/annotations_create_bulk_response_item.py +11 -21
- label_studio_sdk/base_client.py +46 -27
- label_studio_sdk/client.py +1 -0
- label_studio_sdk/comments/client.py +190 -44
- label_studio_sdk/converter/converter.py +56 -13
- label_studio_sdk/converter/imports/yolo.py +1 -1
- label_studio_sdk/converter/utils.py +3 -2
- label_studio_sdk/core/__init__.py +21 -4
- label_studio_sdk/core/client_wrapper.py +9 -10
- label_studio_sdk/core/file.py +37 -8
- label_studio_sdk/core/http_client.py +52 -28
- label_studio_sdk/core/jsonable_encoder.py +33 -31
- label_studio_sdk/core/pagination.py +5 -4
- label_studio_sdk/core/pydantic_utilities.py +272 -4
- label_studio_sdk/core/query_encoder.py +38 -13
- label_studio_sdk/core/request_options.py +3 -0
- label_studio_sdk/core/serialization.py +272 -0
- label_studio_sdk/errors/bad_request_error.py +2 -3
- label_studio_sdk/export_storage/azure/client.py +228 -58
- label_studio_sdk/export_storage/azure/types/azure_create_response.py +19 -29
- label_studio_sdk/export_storage/azure/types/azure_update_response.py +19 -29
- label_studio_sdk/export_storage/client.py +48 -18
- label_studio_sdk/export_storage/gcs/client.py +228 -58
- label_studio_sdk/export_storage/gcs/types/gcs_create_response.py +19 -29
- label_studio_sdk/export_storage/gcs/types/gcs_update_response.py +19 -29
- label_studio_sdk/export_storage/local/client.py +222 -56
- label_studio_sdk/export_storage/local/types/local_create_response.py +17 -27
- label_studio_sdk/export_storage/local/types/local_update_response.py +17 -27
- label_studio_sdk/export_storage/redis/client.py +228 -58
- label_studio_sdk/export_storage/redis/types/redis_create_response.py +20 -30
- label_studio_sdk/export_storage/redis/types/redis_update_response.py +20 -30
- label_studio_sdk/export_storage/s3/client.py +228 -58
- label_studio_sdk/export_storage/s3/types/s3create_response.py +27 -35
- label_studio_sdk/export_storage/s3/types/s3update_response.py +27 -35
- label_studio_sdk/export_storage/s3s/client.py +187 -43
- label_studio_sdk/export_storage/types/export_storage_list_types_response_item.py +11 -21
- label_studio_sdk/files/client.py +172 -56
- label_studio_sdk/import_storage/azure/client.py +223 -53
- label_studio_sdk/import_storage/azure/types/azure_create_response.py +22 -32
- label_studio_sdk/import_storage/azure/types/azure_update_response.py +22 -32
- label_studio_sdk/import_storage/client.py +48 -18
- label_studio_sdk/import_storage/gcs/client.py +223 -53
- label_studio_sdk/import_storage/gcs/types/gcs_create_response.py +22 -32
- label_studio_sdk/import_storage/gcs/types/gcs_update_response.py +22 -32
- label_studio_sdk/import_storage/local/client.py +223 -53
- label_studio_sdk/import_storage/local/types/local_create_response.py +17 -27
- label_studio_sdk/import_storage/local/types/local_update_response.py +17 -27
- label_studio_sdk/import_storage/redis/client.py +223 -53
- label_studio_sdk/import_storage/redis/types/redis_create_response.py +20 -30
- label_studio_sdk/import_storage/redis/types/redis_update_response.py +20 -30
- label_studio_sdk/import_storage/s3/client.py +223 -53
- label_studio_sdk/import_storage/s3/types/s3create_response.py +31 -39
- label_studio_sdk/import_storage/s3/types/s3update_response.py +31 -39
- label_studio_sdk/import_storage/s3s/client.py +222 -52
- label_studio_sdk/import_storage/types/import_storage_list_types_response_item.py +11 -21
- label_studio_sdk/label_interface/control_tags.py +1 -1
- label_studio_sdk/ml/client.py +280 -78
- label_studio_sdk/ml/types/ml_create_response.py +21 -31
- label_studio_sdk/ml/types/ml_update_response.py +21 -31
- label_studio_sdk/model_providers/client.py +173 -56
- label_studio_sdk/predictions/client.py +247 -101
- label_studio_sdk/projects/__init__.py +3 -0
- label_studio_sdk/projects/client.py +309 -115
- label_studio_sdk/projects/client_ext.py +16 -0
- label_studio_sdk/projects/exports/__init__.py +3 -0
- label_studio_sdk/projects/exports/client.py +447 -296
- label_studio_sdk/projects/exports/client_ext.py +134 -0
- label_studio_sdk/projects/exports/types/__init__.py +6 -0
- label_studio_sdk/projects/exports/types/exports_convert_response.py +24 -0
- label_studio_sdk/projects/exports/types/exports_list_formats_response_item.py +44 -0
- label_studio_sdk/projects/types/projects_create_response.py +29 -34
- label_studio_sdk/projects/types/projects_import_tasks_response.py +19 -29
- label_studio_sdk/projects/types/projects_list_response.py +11 -21
- label_studio_sdk/projects/types/projects_update_response.py +24 -34
- label_studio_sdk/prompts/client.py +309 -92
- label_studio_sdk/prompts/indicators/client.py +67 -23
- label_studio_sdk/prompts/runs/client.py +95 -40
- label_studio_sdk/prompts/types/prompts_batch_failed_predictions_request_failed_predictions_item.py +14 -24
- label_studio_sdk/prompts/types/prompts_batch_failed_predictions_response.py +11 -21
- label_studio_sdk/prompts/types/prompts_batch_predictions_request_results_item.py +26 -29
- label_studio_sdk/prompts/types/prompts_batch_predictions_response.py +11 -21
- label_studio_sdk/prompts/versions/client.py +277 -88
- label_studio_sdk/tasks/client.py +263 -90
- label_studio_sdk/tasks/types/tasks_list_response.py +15 -25
- label_studio_sdk/types/__init__.py +10 -6
- label_studio_sdk/types/annotation.py +29 -38
- label_studio_sdk/types/annotation_filter_options.py +14 -24
- label_studio_sdk/types/annotations_dm_field.py +30 -39
- label_studio_sdk/types/azure_blob_export_storage.py +28 -37
- label_studio_sdk/types/azure_blob_import_storage.py +28 -37
- label_studio_sdk/types/base_task.py +30 -39
- label_studio_sdk/types/base_task_updated_by.py +3 -1
- label_studio_sdk/types/base_user.py +14 -21
- label_studio_sdk/types/comment.py +12 -21
- label_studio_sdk/types/comment_created_by.py +1 -1
- label_studio_sdk/types/converted_format.py +12 -22
- label_studio_sdk/types/data_manager_task_serializer.py +31 -40
- label_studio_sdk/types/data_manager_task_serializer_annotators_item.py +1 -1
- label_studio_sdk/types/data_manager_task_serializer_drafts_item.py +13 -22
- label_studio_sdk/types/data_manager_task_serializer_predictions_item.py +15 -24
- label_studio_sdk/types/export.py +17 -26
- label_studio_sdk/types/export_format.py +25 -0
- label_studio_sdk/types/export_snapshot.py +45 -0
- label_studio_sdk/types/export_snapshot_status.py +5 -0
- label_studio_sdk/types/file_upload.py +11 -21
- label_studio_sdk/types/filter.py +16 -26
- label_studio_sdk/types/filter_group.py +12 -22
- label_studio_sdk/types/gcs_export_storage.py +28 -37
- label_studio_sdk/types/gcs_import_storage.py +28 -37
- label_studio_sdk/types/inference_run.py +14 -23
- label_studio_sdk/types/inference_run_cost_estimate.py +17 -27
- label_studio_sdk/types/inference_run_created_by.py +1 -1
- label_studio_sdk/types/inference_run_organization.py +1 -1
- label_studio_sdk/types/key_indicator_value.py +12 -22
- label_studio_sdk/types/key_indicators.py +0 -1
- label_studio_sdk/types/key_indicators_item.py +15 -25
- label_studio_sdk/types/key_indicators_item_additional_kpis_item.py +13 -23
- label_studio_sdk/types/key_indicators_item_extra_kpis_item.py +13 -23
- label_studio_sdk/types/local_files_export_storage.py +25 -34
- label_studio_sdk/types/local_files_import_storage.py +24 -33
- label_studio_sdk/types/ml_backend.py +23 -32
- label_studio_sdk/types/model_provider_connection.py +22 -31
- label_studio_sdk/types/model_provider_connection_created_by.py +1 -1
- label_studio_sdk/types/model_provider_connection_organization.py +1 -1
- label_studio_sdk/types/model_provider_connection_provider.py +3 -1
- label_studio_sdk/types/prediction.py +21 -30
- label_studio_sdk/types/project.py +48 -55
- label_studio_sdk/types/project_import.py +21 -30
- label_studio_sdk/types/project_label_config.py +12 -22
- label_studio_sdk/types/prompt.py +24 -32
- label_studio_sdk/types/prompt_associated_projects_item.py +6 -0
- label_studio_sdk/types/prompt_associated_projects_item_id.py +20 -0
- label_studio_sdk/types/prompt_created_by.py +1 -1
- label_studio_sdk/types/prompt_organization.py +1 -1
- label_studio_sdk/types/prompt_version.py +13 -22
- label_studio_sdk/types/prompt_version_created_by.py +1 -1
- label_studio_sdk/types/prompt_version_organization.py +1 -1
- label_studio_sdk/types/prompt_version_provider.py +3 -1
- label_studio_sdk/types/redis_export_storage.py +29 -38
- label_studio_sdk/types/redis_import_storage.py +28 -37
- label_studio_sdk/types/refined_prompt_response.py +19 -29
- label_studio_sdk/types/s3export_storage.py +36 -43
- label_studio_sdk/types/s3import_storage.py +37 -44
- label_studio_sdk/types/s3s_export_storage.py +26 -33
- label_studio_sdk/types/s3s_import_storage.py +35 -42
- label_studio_sdk/types/serialization_option.py +12 -22
- label_studio_sdk/types/serialization_options.py +18 -28
- label_studio_sdk/types/task.py +44 -47
- label_studio_sdk/types/task_annotators_item.py +1 -1
- label_studio_sdk/types/task_comment_authors_item.py +1 -1
- label_studio_sdk/types/task_filter_options.py +15 -25
- label_studio_sdk/types/user_simple.py +11 -21
- label_studio_sdk/types/view.py +16 -26
- label_studio_sdk/types/webhook.py +19 -28
- label_studio_sdk/types/webhook_serializer_for_update.py +19 -28
- label_studio_sdk/types/workspace.py +22 -31
- label_studio_sdk/users/client.py +257 -63
- label_studio_sdk/users/types/users_get_token_response.py +12 -22
- label_studio_sdk/users/types/users_reset_token_response.py +12 -22
- label_studio_sdk/version.py +0 -1
- label_studio_sdk/versions/__init__.py +5 -0
- label_studio_sdk/versions/client.py +112 -0
- label_studio_sdk/versions/types/__init__.py +6 -0
- label_studio_sdk/versions/types/versions_get_response.py +73 -0
- label_studio_sdk/versions/types/versions_get_response_edition.py +5 -0
- label_studio_sdk/views/client.py +219 -52
- label_studio_sdk/views/types/views_create_request_data.py +13 -23
- label_studio_sdk/views/types/views_create_request_data_filters.py +14 -24
- label_studio_sdk/views/types/views_create_request_data_filters_items_item.py +16 -26
- label_studio_sdk/views/types/views_create_request_data_filters_items_item_value.py +3 -1
- label_studio_sdk/views/types/views_update_request_data.py +13 -23
- label_studio_sdk/views/types/views_update_request_data_filters.py +14 -24
- label_studio_sdk/views/types/views_update_request_data_filters_items_item.py +16 -26
- label_studio_sdk/views/types/views_update_request_data_filters_items_item_value.py +3 -1
- label_studio_sdk/webhooks/client.py +191 -61
- label_studio_sdk/workspaces/client.py +164 -41
- label_studio_sdk/workspaces/members/client.py +109 -31
- label_studio_sdk/workspaces/members/types/members_create_response.py +12 -22
- label_studio_sdk/workspaces/members/types/members_list_response_item.py +12 -22
- {label_studio_sdk-1.0.8.dist-info → label_studio_sdk-1.0.10.dist-info}/METADATA +7 -5
- {label_studio_sdk-1.0.8.dist-info → label_studio_sdk-1.0.10.dist-info}/RECORD +197 -184
- {label_studio_sdk-1.0.8.dist-info → label_studio_sdk-1.0.10.dist-info}/WHEEL +1 -1
- label_studio_sdk/types/export_convert.py +0 -32
- label_studio_sdk/types/export_create.py +0 -54
- label_studio_sdk/types/export_create_status.py +0 -5
- {label_studio_sdk-1.0.8.dist-info → label_studio_sdk-1.0.10.dist-info}/LICENSE +0 -0
|
@@ -1,64 +1,54 @@
|
|
|
1
1
|
# This file was auto-generated by Fern from our API Definition.
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
from ..core.pydantic_utilities import UniversalBaseModel
|
|
4
4
|
import typing
|
|
5
|
-
|
|
6
|
-
from ..core.datetime_utils import serialize_datetime
|
|
7
|
-
from ..core.pydantic_utilities import deep_union_pydantic_dicts, pydantic_v1
|
|
8
|
-
from .prompt_version import PromptVersion
|
|
5
|
+
import pydantic
|
|
9
6
|
from .refined_prompt_response_refinement_status import RefinedPromptResponseRefinementStatus
|
|
7
|
+
from .prompt_version import PromptVersion
|
|
8
|
+
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
|
10
9
|
|
|
11
10
|
|
|
12
|
-
class RefinedPromptResponse(
|
|
13
|
-
title: typing.Optional[str] =
|
|
11
|
+
class RefinedPromptResponse(UniversalBaseModel):
|
|
12
|
+
title: typing.Optional[str] = pydantic.Field(default=None)
|
|
14
13
|
"""
|
|
15
14
|
Title of the refined prompt
|
|
16
15
|
"""
|
|
17
16
|
|
|
18
|
-
reasoning: typing.Optional[str] =
|
|
17
|
+
reasoning: typing.Optional[str] = pydantic.Field(default=None)
|
|
19
18
|
"""
|
|
20
19
|
Reasoning behind the refinement
|
|
21
20
|
"""
|
|
22
21
|
|
|
23
|
-
prompt: str =
|
|
22
|
+
prompt: str = pydantic.Field()
|
|
24
23
|
"""
|
|
25
24
|
The refined prompt text
|
|
26
25
|
"""
|
|
27
26
|
|
|
28
|
-
refinement_job_id: typing.Optional[str] =
|
|
27
|
+
refinement_job_id: typing.Optional[str] = pydantic.Field(default=None)
|
|
29
28
|
"""
|
|
30
29
|
Unique identifier for the refinement job
|
|
31
30
|
"""
|
|
32
31
|
|
|
33
|
-
refinement_status: typing.Optional[RefinedPromptResponseRefinementStatus] =
|
|
32
|
+
refinement_status: typing.Optional[RefinedPromptResponseRefinementStatus] = pydantic.Field(default=None)
|
|
34
33
|
"""
|
|
35
34
|
Status of the refinement job
|
|
36
35
|
"""
|
|
37
36
|
|
|
38
|
-
total_cost: typing.Optional[str] =
|
|
37
|
+
total_cost: typing.Optional[str] = pydantic.Field(default=None)
|
|
39
38
|
"""
|
|
40
39
|
Total cost of the refinement job (in USD)
|
|
41
40
|
"""
|
|
42
41
|
|
|
43
|
-
previous_version: typing.Optional[PromptVersion] =
|
|
42
|
+
previous_version: typing.Optional[PromptVersion] = pydantic.Field(default=None)
|
|
44
43
|
"""
|
|
45
44
|
Previous version of the prompt
|
|
46
45
|
"""
|
|
47
46
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
def dict(self, **kwargs: typing.Any) -> typing.Dict[str, typing.Any]:
|
|
53
|
-
kwargs_with_defaults_exclude_unset: typing.Any = {"by_alias": True, "exclude_unset": True, **kwargs}
|
|
54
|
-
kwargs_with_defaults_exclude_none: typing.Any = {"by_alias": True, "exclude_none": True, **kwargs}
|
|
55
|
-
|
|
56
|
-
return deep_union_pydantic_dicts(
|
|
57
|
-
super().dict(**kwargs_with_defaults_exclude_unset), super().dict(**kwargs_with_defaults_exclude_none)
|
|
58
|
-
)
|
|
47
|
+
if IS_PYDANTIC_V2:
|
|
48
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
49
|
+
else:
|
|
59
50
|
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
json_encoders = {dt.datetime: serialize_datetime}
|
|
51
|
+
class Config:
|
|
52
|
+
frozen = True
|
|
53
|
+
smart_union = True
|
|
54
|
+
extra = pydantic.Extra.allow
|
|
@@ -1,134 +1,127 @@
|
|
|
1
1
|
# This file was auto-generated by Fern from our API Definition.
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
from ..core.pydantic_utilities import UniversalBaseModel
|
|
4
4
|
import typing
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
from ..core.pydantic_utilities import deep_union_pydantic_dicts, pydantic_v1
|
|
5
|
+
import datetime as dt
|
|
6
|
+
import pydantic
|
|
8
7
|
from .s3export_storage_status import S3ExportStorageStatus
|
|
8
|
+
import typing_extensions
|
|
9
|
+
from ..core.serialization import FieldMetadata
|
|
10
|
+
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
|
9
11
|
|
|
10
12
|
|
|
11
|
-
class S3ExportStorage(
|
|
13
|
+
class S3ExportStorage(UniversalBaseModel):
|
|
12
14
|
id: typing.Optional[int] = None
|
|
13
15
|
type: typing.Optional[str] = None
|
|
14
16
|
synchronizable: typing.Optional[bool] = None
|
|
15
|
-
last_sync: typing.Optional[dt.datetime] =
|
|
17
|
+
last_sync: typing.Optional[dt.datetime] = pydantic.Field(default=None)
|
|
16
18
|
"""
|
|
17
19
|
Last sync finished time
|
|
18
20
|
"""
|
|
19
21
|
|
|
20
|
-
last_sync_count: typing.Optional[int] =
|
|
22
|
+
last_sync_count: typing.Optional[int] = pydantic.Field(default=None)
|
|
21
23
|
"""
|
|
22
24
|
Count of tasks synced last time
|
|
23
25
|
"""
|
|
24
26
|
|
|
25
|
-
last_sync_job: typing.Optional[str] =
|
|
27
|
+
last_sync_job: typing.Optional[str] = pydantic.Field(default=None)
|
|
26
28
|
"""
|
|
27
29
|
Last sync job ID
|
|
28
30
|
"""
|
|
29
31
|
|
|
30
32
|
status: typing.Optional[S3ExportStorageStatus] = None
|
|
31
|
-
traceback: typing.Optional[str] =
|
|
33
|
+
traceback: typing.Optional[str] = pydantic.Field(default=None)
|
|
32
34
|
"""
|
|
33
35
|
Traceback report for the last failed sync
|
|
34
36
|
"""
|
|
35
37
|
|
|
36
|
-
meta: typing.Optional[typing.Dict[str, typing.Any]] =
|
|
38
|
+
meta: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = pydantic.Field(default=None)
|
|
37
39
|
"""
|
|
38
40
|
Meta and debug information about storage processes
|
|
39
41
|
"""
|
|
40
42
|
|
|
41
|
-
title: typing.Optional[str] =
|
|
43
|
+
title: typing.Optional[str] = pydantic.Field(default=None)
|
|
42
44
|
"""
|
|
43
45
|
Cloud storage title
|
|
44
46
|
"""
|
|
45
47
|
|
|
46
|
-
description: typing.Optional[str] =
|
|
48
|
+
description: typing.Optional[str] = pydantic.Field(default=None)
|
|
47
49
|
"""
|
|
48
50
|
Cloud storage description
|
|
49
51
|
"""
|
|
50
52
|
|
|
51
|
-
created_at: typing.Optional[dt.datetime] =
|
|
53
|
+
created_at: typing.Optional[dt.datetime] = pydantic.Field(default=None)
|
|
52
54
|
"""
|
|
53
55
|
Creation time
|
|
54
56
|
"""
|
|
55
57
|
|
|
56
|
-
can_delete_objects: typing.Optional[bool] =
|
|
58
|
+
can_delete_objects: typing.Optional[bool] = pydantic.Field(default=None)
|
|
57
59
|
"""
|
|
58
60
|
Deletion from storage enabled
|
|
59
61
|
"""
|
|
60
62
|
|
|
61
|
-
bucket: typing.Optional[str] =
|
|
63
|
+
bucket: typing.Optional[str] = pydantic.Field(default=None)
|
|
62
64
|
"""
|
|
63
65
|
S3 bucket name
|
|
64
66
|
"""
|
|
65
67
|
|
|
66
|
-
prefix: typing.Optional[str] =
|
|
68
|
+
prefix: typing.Optional[str] = pydantic.Field(default=None)
|
|
67
69
|
"""
|
|
68
70
|
S3 bucket prefix
|
|
69
71
|
"""
|
|
70
72
|
|
|
71
|
-
regex_filter: typing.Optional[str] =
|
|
73
|
+
regex_filter: typing.Optional[str] = pydantic.Field(default=None)
|
|
72
74
|
"""
|
|
73
75
|
Cloud storage regex for filtering objects
|
|
74
76
|
"""
|
|
75
77
|
|
|
76
|
-
use_blob_urls: typing.Optional[bool] =
|
|
78
|
+
use_blob_urls: typing.Optional[bool] = pydantic.Field(default=None)
|
|
77
79
|
"""
|
|
78
80
|
Interpret objects as BLOBs and generate URLs
|
|
79
81
|
"""
|
|
80
82
|
|
|
81
|
-
aws_access_key_id: typing.Optional[str] =
|
|
83
|
+
aws_access_key_id: typing.Optional[str] = pydantic.Field(default=None)
|
|
82
84
|
"""
|
|
83
85
|
AWS_ACCESS_KEY_ID
|
|
84
86
|
"""
|
|
85
87
|
|
|
86
|
-
aws_secret_access_key: typing.Optional[str] =
|
|
88
|
+
aws_secret_access_key: typing.Optional[str] = pydantic.Field(default=None)
|
|
87
89
|
"""
|
|
88
90
|
AWS_SECRET_ACCESS_KEY
|
|
89
91
|
"""
|
|
90
92
|
|
|
91
|
-
aws_session_token: typing.Optional[str] =
|
|
93
|
+
aws_session_token: typing.Optional[str] = pydantic.Field(default=None)
|
|
92
94
|
"""
|
|
93
95
|
AWS_SESSION_TOKEN
|
|
94
96
|
"""
|
|
95
97
|
|
|
96
|
-
aws_sse_kms_key_id: typing.Optional[str] =
|
|
98
|
+
aws_sse_kms_key_id: typing.Optional[str] = pydantic.Field(default=None)
|
|
97
99
|
"""
|
|
98
100
|
AWS SSE KMS Key ID
|
|
99
101
|
"""
|
|
100
102
|
|
|
101
|
-
region_name: typing.Optional[str] =
|
|
103
|
+
region_name: typing.Optional[str] = pydantic.Field(default=None)
|
|
102
104
|
"""
|
|
103
105
|
AWS Region
|
|
104
106
|
"""
|
|
105
107
|
|
|
106
|
-
s3endpoint: typing.Optional[str]
|
|
108
|
+
s3endpoint: typing_extensions.Annotated[typing.Optional[str], FieldMetadata(alias="s3_endpoint")] = pydantic.Field(
|
|
109
|
+
default=None
|
|
110
|
+
)
|
|
107
111
|
"""
|
|
108
112
|
S3 Endpoint
|
|
109
113
|
"""
|
|
110
114
|
|
|
111
|
-
project: int =
|
|
115
|
+
project: int = pydantic.Field()
|
|
112
116
|
"""
|
|
113
117
|
A unique integer value identifying this project.
|
|
114
118
|
"""
|
|
115
119
|
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
def dict(self, **kwargs: typing.Any) -> typing.Dict[str, typing.Any]:
|
|
121
|
-
kwargs_with_defaults_exclude_unset: typing.Any = {"by_alias": True, "exclude_unset": True, **kwargs}
|
|
122
|
-
kwargs_with_defaults_exclude_none: typing.Any = {"by_alias": True, "exclude_none": True, **kwargs}
|
|
123
|
-
|
|
124
|
-
return deep_union_pydantic_dicts(
|
|
125
|
-
super().dict(**kwargs_with_defaults_exclude_unset), super().dict(**kwargs_with_defaults_exclude_none)
|
|
126
|
-
)
|
|
120
|
+
if IS_PYDANTIC_V2:
|
|
121
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
122
|
+
else:
|
|
127
123
|
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
populate_by_name = True
|
|
133
|
-
extra = pydantic_v1.Extra.allow
|
|
134
|
-
json_encoders = {dt.datetime: serialize_datetime}
|
|
124
|
+
class Config:
|
|
125
|
+
frozen = True
|
|
126
|
+
smart_union = True
|
|
127
|
+
extra = pydantic.Extra.allow
|
|
@@ -1,140 +1,133 @@
|
|
|
1
1
|
# This file was auto-generated by Fern from our API Definition.
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
from ..core.pydantic_utilities import UniversalBaseModel
|
|
4
4
|
import typing
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
from ..core.pydantic_utilities import deep_union_pydantic_dicts, pydantic_v1
|
|
5
|
+
import datetime as dt
|
|
6
|
+
import pydantic
|
|
8
7
|
from .s3import_storage_status import S3ImportStorageStatus
|
|
8
|
+
import typing_extensions
|
|
9
|
+
from ..core.serialization import FieldMetadata
|
|
10
|
+
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
|
9
11
|
|
|
10
12
|
|
|
11
|
-
class S3ImportStorage(
|
|
13
|
+
class S3ImportStorage(UniversalBaseModel):
|
|
12
14
|
id: typing.Optional[int] = None
|
|
13
15
|
type: typing.Optional[str] = None
|
|
14
16
|
synchronizable: typing.Optional[bool] = None
|
|
15
17
|
presign: typing.Optional[bool] = None
|
|
16
|
-
last_sync: typing.Optional[dt.datetime] =
|
|
18
|
+
last_sync: typing.Optional[dt.datetime] = pydantic.Field(default=None)
|
|
17
19
|
"""
|
|
18
20
|
Last sync finished time
|
|
19
21
|
"""
|
|
20
22
|
|
|
21
|
-
last_sync_count: typing.Optional[int] =
|
|
23
|
+
last_sync_count: typing.Optional[int] = pydantic.Field(default=None)
|
|
22
24
|
"""
|
|
23
25
|
Count of tasks synced last time
|
|
24
26
|
"""
|
|
25
27
|
|
|
26
|
-
last_sync_job: typing.Optional[str] =
|
|
28
|
+
last_sync_job: typing.Optional[str] = pydantic.Field(default=None)
|
|
27
29
|
"""
|
|
28
30
|
Last sync job ID
|
|
29
31
|
"""
|
|
30
32
|
|
|
31
33
|
status: typing.Optional[S3ImportStorageStatus] = None
|
|
32
|
-
traceback: typing.Optional[str] =
|
|
34
|
+
traceback: typing.Optional[str] = pydantic.Field(default=None)
|
|
33
35
|
"""
|
|
34
36
|
Traceback report for the last failed sync
|
|
35
37
|
"""
|
|
36
38
|
|
|
37
|
-
meta: typing.Optional[typing.Dict[str, typing.Any]] =
|
|
39
|
+
meta: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = pydantic.Field(default=None)
|
|
38
40
|
"""
|
|
39
41
|
Meta and debug information about storage processes
|
|
40
42
|
"""
|
|
41
43
|
|
|
42
|
-
title: typing.Optional[str] =
|
|
44
|
+
title: typing.Optional[str] = pydantic.Field(default=None)
|
|
43
45
|
"""
|
|
44
46
|
Cloud storage title
|
|
45
47
|
"""
|
|
46
48
|
|
|
47
|
-
description: typing.Optional[str] =
|
|
49
|
+
description: typing.Optional[str] = pydantic.Field(default=None)
|
|
48
50
|
"""
|
|
49
51
|
Cloud storage description
|
|
50
52
|
"""
|
|
51
53
|
|
|
52
|
-
created_at: typing.Optional[dt.datetime] =
|
|
54
|
+
created_at: typing.Optional[dt.datetime] = pydantic.Field(default=None)
|
|
53
55
|
"""
|
|
54
56
|
Creation time
|
|
55
57
|
"""
|
|
56
58
|
|
|
57
|
-
bucket: typing.Optional[str] =
|
|
59
|
+
bucket: typing.Optional[str] = pydantic.Field(default=None)
|
|
58
60
|
"""
|
|
59
61
|
S3 bucket name
|
|
60
62
|
"""
|
|
61
63
|
|
|
62
|
-
prefix: typing.Optional[str] =
|
|
64
|
+
prefix: typing.Optional[str] = pydantic.Field(default=None)
|
|
63
65
|
"""
|
|
64
66
|
S3 bucket prefix
|
|
65
67
|
"""
|
|
66
68
|
|
|
67
|
-
regex_filter: typing.Optional[str] =
|
|
69
|
+
regex_filter: typing.Optional[str] = pydantic.Field(default=None)
|
|
68
70
|
"""
|
|
69
71
|
Cloud storage regex for filtering objects
|
|
70
72
|
"""
|
|
71
73
|
|
|
72
|
-
use_blob_urls: typing.Optional[bool] =
|
|
74
|
+
use_blob_urls: typing.Optional[bool] = pydantic.Field(default=None)
|
|
73
75
|
"""
|
|
74
76
|
Interpret objects as BLOBs and generate URLs
|
|
75
77
|
"""
|
|
76
78
|
|
|
77
|
-
aws_access_key_id: typing.Optional[str] =
|
|
79
|
+
aws_access_key_id: typing.Optional[str] = pydantic.Field(default=None)
|
|
78
80
|
"""
|
|
79
81
|
AWS_ACCESS_KEY_ID
|
|
80
82
|
"""
|
|
81
83
|
|
|
82
|
-
aws_secret_access_key: typing.Optional[str] =
|
|
84
|
+
aws_secret_access_key: typing.Optional[str] = pydantic.Field(default=None)
|
|
83
85
|
"""
|
|
84
86
|
AWS_SECRET_ACCESS_KEY
|
|
85
87
|
"""
|
|
86
88
|
|
|
87
|
-
aws_session_token: typing.Optional[str] =
|
|
89
|
+
aws_session_token: typing.Optional[str] = pydantic.Field(default=None)
|
|
88
90
|
"""
|
|
89
91
|
AWS_SESSION_TOKEN
|
|
90
92
|
"""
|
|
91
93
|
|
|
92
|
-
aws_sse_kms_key_id: typing.Optional[str] =
|
|
94
|
+
aws_sse_kms_key_id: typing.Optional[str] = pydantic.Field(default=None)
|
|
93
95
|
"""
|
|
94
96
|
AWS SSE KMS Key ID
|
|
95
97
|
"""
|
|
96
98
|
|
|
97
|
-
region_name: typing.Optional[str] =
|
|
99
|
+
region_name: typing.Optional[str] = pydantic.Field(default=None)
|
|
98
100
|
"""
|
|
99
101
|
AWS Region
|
|
100
102
|
"""
|
|
101
103
|
|
|
102
|
-
s3endpoint: typing.Optional[str]
|
|
104
|
+
s3endpoint: typing_extensions.Annotated[typing.Optional[str], FieldMetadata(alias="s3_endpoint")] = pydantic.Field(
|
|
105
|
+
default=None
|
|
106
|
+
)
|
|
103
107
|
"""
|
|
104
108
|
S3 Endpoint
|
|
105
109
|
"""
|
|
106
110
|
|
|
107
|
-
presign_ttl: typing.Optional[int] =
|
|
111
|
+
presign_ttl: typing.Optional[int] = pydantic.Field(default=None)
|
|
108
112
|
"""
|
|
109
113
|
Presigned URLs TTL (in minutes)
|
|
110
114
|
"""
|
|
111
115
|
|
|
112
|
-
recursive_scan: typing.Optional[bool] =
|
|
116
|
+
recursive_scan: typing.Optional[bool] = pydantic.Field(default=None)
|
|
113
117
|
"""
|
|
114
118
|
Perform recursive scan over the bucket content
|
|
115
119
|
"""
|
|
116
120
|
|
|
117
|
-
project: int =
|
|
121
|
+
project: int = pydantic.Field()
|
|
118
122
|
"""
|
|
119
123
|
A unique integer value identifying this project.
|
|
120
124
|
"""
|
|
121
125
|
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
def dict(self, **kwargs: typing.Any) -> typing.Dict[str, typing.Any]:
|
|
127
|
-
kwargs_with_defaults_exclude_unset: typing.Any = {"by_alias": True, "exclude_unset": True, **kwargs}
|
|
128
|
-
kwargs_with_defaults_exclude_none: typing.Any = {"by_alias": True, "exclude_none": True, **kwargs}
|
|
129
|
-
|
|
130
|
-
return deep_union_pydantic_dicts(
|
|
131
|
-
super().dict(**kwargs_with_defaults_exclude_unset), super().dict(**kwargs_with_defaults_exclude_none)
|
|
132
|
-
)
|
|
126
|
+
if IS_PYDANTIC_V2:
|
|
127
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
128
|
+
else:
|
|
133
129
|
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
populate_by_name = True
|
|
139
|
-
extra = pydantic_v1.Extra.allow
|
|
140
|
-
json_encoders = {dt.datetime: serialize_datetime}
|
|
130
|
+
class Config:
|
|
131
|
+
frozen = True
|
|
132
|
+
smart_union = True
|
|
133
|
+
extra = pydantic.Extra.allow
|
|
@@ -1,80 +1,73 @@
|
|
|
1
1
|
# This file was auto-generated by Fern from our API Definition.
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
from ..core.pydantic_utilities import UniversalBaseModel
|
|
4
4
|
import typing
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
import pydantic
|
|
6
|
+
import datetime as dt
|
|
7
|
+
import typing_extensions
|
|
8
|
+
from ..core.serialization import FieldMetadata
|
|
9
|
+
from ..core.pydantic_utilities import IS_PYDANTIC_V2
|
|
8
10
|
|
|
9
11
|
|
|
10
|
-
class S3SExportStorage(
|
|
12
|
+
class S3SExportStorage(UniversalBaseModel):
|
|
11
13
|
id: typing.Optional[int] = None
|
|
12
|
-
title: typing.Optional[str] =
|
|
14
|
+
title: typing.Optional[str] = pydantic.Field(default=None)
|
|
13
15
|
"""
|
|
14
16
|
Cloud storage title
|
|
15
17
|
"""
|
|
16
18
|
|
|
17
|
-
description: typing.Optional[str] =
|
|
19
|
+
description: typing.Optional[str] = pydantic.Field(default=None)
|
|
18
20
|
"""
|
|
19
21
|
Cloud storage description
|
|
20
22
|
"""
|
|
21
23
|
|
|
22
|
-
created_at: typing.Optional[dt.datetime] =
|
|
24
|
+
created_at: typing.Optional[dt.datetime] = pydantic.Field(default=None)
|
|
23
25
|
"""
|
|
24
26
|
Creation time
|
|
25
27
|
"""
|
|
26
28
|
|
|
27
|
-
bucket: typing.Optional[str] =
|
|
29
|
+
bucket: typing.Optional[str] = pydantic.Field(default=None)
|
|
28
30
|
"""
|
|
29
31
|
S3 bucket name
|
|
30
32
|
"""
|
|
31
33
|
|
|
32
|
-
prefix: typing.Optional[str] =
|
|
34
|
+
prefix: typing.Optional[str] = pydantic.Field(default=None)
|
|
33
35
|
"""
|
|
34
36
|
S3 bucket prefix
|
|
35
37
|
"""
|
|
36
38
|
|
|
37
|
-
external_id: typing.Optional[str] =
|
|
39
|
+
external_id: typing.Optional[str] = pydantic.Field(default=None)
|
|
38
40
|
"""
|
|
39
41
|
AWS External ID
|
|
40
42
|
"""
|
|
41
43
|
|
|
42
|
-
role_arn: typing.Optional[str] =
|
|
44
|
+
role_arn: typing.Optional[str] = pydantic.Field(default=None)
|
|
43
45
|
"""
|
|
44
46
|
AWS Role ARN
|
|
45
47
|
"""
|
|
46
48
|
|
|
47
|
-
region_name: typing.Optional[str] =
|
|
49
|
+
region_name: typing.Optional[str] = pydantic.Field(default=None)
|
|
48
50
|
"""
|
|
49
51
|
AWS Region
|
|
50
52
|
"""
|
|
51
53
|
|
|
52
|
-
s3endpoint: typing.Optional[str]
|
|
54
|
+
s3endpoint: typing_extensions.Annotated[typing.Optional[str], FieldMetadata(alias="s3_endpoint")] = pydantic.Field(
|
|
55
|
+
default=None
|
|
56
|
+
)
|
|
53
57
|
"""
|
|
54
58
|
S3 Endpoint
|
|
55
59
|
"""
|
|
56
60
|
|
|
57
|
-
project: int =
|
|
61
|
+
project: int = pydantic.Field()
|
|
58
62
|
"""
|
|
59
63
|
A unique integer value identifying this project.
|
|
60
64
|
"""
|
|
61
65
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
def dict(self, **kwargs: typing.Any) -> typing.Dict[str, typing.Any]:
|
|
67
|
-
kwargs_with_defaults_exclude_unset: typing.Any = {"by_alias": True, "exclude_unset": True, **kwargs}
|
|
68
|
-
kwargs_with_defaults_exclude_none: typing.Any = {"by_alias": True, "exclude_none": True, **kwargs}
|
|
69
|
-
|
|
70
|
-
return deep_union_pydantic_dicts(
|
|
71
|
-
super().dict(**kwargs_with_defaults_exclude_unset), super().dict(**kwargs_with_defaults_exclude_none)
|
|
72
|
-
)
|
|
66
|
+
if IS_PYDANTIC_V2:
|
|
67
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
68
|
+
else:
|
|
73
69
|
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
populate_by_name = True
|
|
79
|
-
extra = pydantic_v1.Extra.allow
|
|
80
|
-
json_encoders = {dt.datetime: serialize_datetime}
|
|
70
|
+
class Config:
|
|
71
|
+
frozen = True
|
|
72
|
+
smart_union = True
|
|
73
|
+
extra = pydantic.Extra.allow
|