robosystems-client 0.1.9__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 robosystems-client might be problematic. Click here for more details.
- robosystems_client/__init__.py +14 -0
- robosystems_client/api/__init__.py +1 -0
- robosystems_client/api/agent/__init__.py +1 -0
- robosystems_client/api/agent/query_financial_agent.py +423 -0
- robosystems_client/api/auth/__init__.py +1 -0
- robosystems_client/api/auth/check_password_strength.py +172 -0
- robosystems_client/api/auth/complete_sso_auth.py +177 -0
- robosystems_client/api/auth/generate_sso_token.py +174 -0
- robosystems_client/api/auth/get_captcha_config.py +87 -0
- robosystems_client/api/auth/get_current_auth_user.py +220 -0
- robosystems_client/api/auth/get_password_policy.py +134 -0
- robosystems_client/api/auth/login_user.py +181 -0
- robosystems_client/api/auth/logout_user.py +169 -0
- robosystems_client/api/auth/refresh_session.py +174 -0
- robosystems_client/api/auth/register_user.py +189 -0
- robosystems_client/api/auth/sso_login.py +177 -0
- robosystems_client/api/auth/sso_token_exchange.py +181 -0
- robosystems_client/api/backup/__init__.py +1 -0
- robosystems_client/api/backup/create_backup.py +401 -0
- robosystems_client/api/backup/export_backup.py +225 -0
- robosystems_client/api/backup/get_backup_download_url.py +258 -0
- robosystems_client/api/backup/get_backup_stats.py +182 -0
- robosystems_client/api/backup/kuzu_backup_health.py +202 -0
- robosystems_client/api/backup/list_backups.py +217 -0
- robosystems_client/api/backup/restore_backup.py +401 -0
- robosystems_client/api/billing/__init__.py +1 -0
- robosystems_client/api/billing/get_available_subscription_plans_v1_graph_id_billing_available_plans_get.py +198 -0
- robosystems_client/api/billing/get_credit_billing_info_v1_graph_id_billing_credits_get.py +210 -0
- robosystems_client/api/billing/get_current_graph_bill.py +285 -0
- robosystems_client/api/billing/get_graph_billing_history.py +329 -0
- robosystems_client/api/billing/get_graph_monthly_bill.py +315 -0
- robosystems_client/api/billing/get_graph_pricing_info_v1_graph_id_billing_pricing_get.py +198 -0
- robosystems_client/api/billing/get_graph_subscription_v1_graph_id_billing_subscription_get.py +198 -0
- robosystems_client/api/billing/get_graph_usage_details.py +350 -0
- robosystems_client/api/billing/upgrade_graph_subscription_v1_graph_id_billing_subscription_upgrade_post.py +216 -0
- robosystems_client/api/connections/__init__.py +1 -0
- robosystems_client/api/connections/create_connection.py +327 -0
- robosystems_client/api/connections/create_link_token.py +281 -0
- robosystems_client/api/connections/delete_connection.py +278 -0
- robosystems_client/api/connections/exchange_link_token.py +301 -0
- robosystems_client/api/connections/get_connection.py +262 -0
- robosystems_client/api/connections/get_connection_options.py +285 -0
- robosystems_client/api/connections/init_o_auth.py +230 -0
- robosystems_client/api/connections/list_connections.py +314 -0
- robosystems_client/api/connections/oauth_callback.py +318 -0
- robosystems_client/api/connections/sync_connection.py +362 -0
- robosystems_client/api/create/__init__.py +1 -0
- robosystems_client/api/create/create_graph.py +375 -0
- robosystems_client/api/create/get_available_extensions.py +134 -0
- robosystems_client/api/credits_/__init__.py +1 -0
- robosystems_client/api/credits_/check_credit_balance.py +299 -0
- robosystems_client/api/credits_/check_storage_limits.py +249 -0
- robosystems_client/api/credits_/get_credit_summary.py +245 -0
- robosystems_client/api/credits_/get_storage_usage.py +279 -0
- robosystems_client/api/credits_/list_credit_transactions.py +392 -0
- robosystems_client/api/graph_analytics/__init__.py +1 -0
- robosystems_client/api/graph_analytics/get_graph_metrics.py +285 -0
- robosystems_client/api/graph_analytics/get_graph_usage_stats.py +329 -0
- robosystems_client/api/graph_status/__init__.py +1 -0
- robosystems_client/api/graph_status/get_database_health.py +273 -0
- robosystems_client/api/graph_status/get_database_info.py +277 -0
- robosystems_client/api/mcp/__init__.py +1 -0
- robosystems_client/api/mcp/call_mcp_tool.py +432 -0
- robosystems_client/api/mcp/list_mcp_tools.py +265 -0
- robosystems_client/api/operations/__init__.py +1 -0
- robosystems_client/api/operations/cancel_operation.py +246 -0
- robosystems_client/api/operations/get_operation_status.py +273 -0
- robosystems_client/api/operations/stream_operation_events.py +415 -0
- robosystems_client/api/query/__init__.py +1 -0
- robosystems_client/api/query/execute_cypher_query.py +482 -0
- robosystems_client/api/schema/__init__.py +1 -0
- robosystems_client/api/schema/export_graph_schema.py +239 -0
- robosystems_client/api/schema/get_graph_schema_info.py +277 -0
- robosystems_client/api/schema/list_schema_extensions.py +216 -0
- robosystems_client/api/schema/validate_schema.py +326 -0
- robosystems_client/api/service_offerings/__init__.py +1 -0
- robosystems_client/api/service_offerings/get_service_offerings.py +197 -0
- robosystems_client/api/status/__init__.py +1 -0
- robosystems_client/api/status/get_mcp_health.py +136 -0
- robosystems_client/api/status/get_service_status.py +134 -0
- robosystems_client/api/user/__init__.py +1 -0
- robosystems_client/api/user/create_user_api_key.py +205 -0
- robosystems_client/api/user/get_all_credit_summaries.py +256 -0
- robosystems_client/api/user/get_current_user.py +187 -0
- robosystems_client/api/user/get_user_graphs.py +187 -0
- robosystems_client/api/user/list_user_api_keys.py +187 -0
- robosystems_client/api/user/revoke_user_api_key.py +209 -0
- robosystems_client/api/user/select_user_graph.py +213 -0
- robosystems_client/api/user/update_user.py +205 -0
- robosystems_client/api/user/update_user_api_key.py +218 -0
- robosystems_client/api/user/update_user_password.py +218 -0
- robosystems_client/api/user_analytics/__init__.py +1 -0
- robosystems_client/api/user_analytics/get_detailed_user_analytics.py +222 -0
- robosystems_client/api/user_analytics/get_user_usage_overview.py +187 -0
- robosystems_client/api/user_limits/__init__.py +1 -0
- robosystems_client/api/user_limits/get_user_limits.py +190 -0
- robosystems_client/api/user_limits/get_user_usage.py +187 -0
- robosystems_client/api/user_subscriptions/__init__.py +1 -0
- robosystems_client/api/user_subscriptions/cancel_shared_repository_subscription.py +209 -0
- robosystems_client/api/user_subscriptions/get_repository_credits.py +206 -0
- robosystems_client/api/user_subscriptions/get_shared_repository_credits.py +193 -0
- robosystems_client/api/user_subscriptions/get_user_shared_subscriptions.py +213 -0
- robosystems_client/api/user_subscriptions/subscribe_to_shared_repository.py +214 -0
- robosystems_client/api/user_subscriptions/upgrade_shared_repository_subscription.py +228 -0
- robosystems_client/client.py +278 -0
- robosystems_client/errors.py +16 -0
- robosystems_client/extensions/README.md +611 -0
- robosystems_client/extensions/__init__.py +108 -0
- robosystems_client/extensions/auth_integration.py +210 -0
- robosystems_client/extensions/extensions.py +170 -0
- robosystems_client/extensions/operation_client.py +368 -0
- robosystems_client/extensions/query_client.py +375 -0
- robosystems_client/extensions/sse_client.py +520 -0
- robosystems_client/extensions/tests/__init__.py +1 -0
- robosystems_client/extensions/tests/test_integration.py +490 -0
- robosystems_client/extensions/tests/test_unit.py +560 -0
- robosystems_client/extensions/utils.py +526 -0
- robosystems_client/models/__init__.py +379 -0
- robosystems_client/models/account_info.py +79 -0
- robosystems_client/models/add_on_credit_info.py +119 -0
- robosystems_client/models/agent_message.py +68 -0
- robosystems_client/models/agent_request.py +132 -0
- robosystems_client/models/agent_request_context_type_0.py +44 -0
- robosystems_client/models/agent_response.py +132 -0
- robosystems_client/models/agent_response_metadata_type_0.py +44 -0
- robosystems_client/models/api_key_info.py +134 -0
- robosystems_client/models/api_keys_response.py +74 -0
- robosystems_client/models/auth_response.py +82 -0
- robosystems_client/models/auth_response_user.py +44 -0
- robosystems_client/models/available_extension.py +78 -0
- robosystems_client/models/available_extensions_response.py +73 -0
- robosystems_client/models/backup_create_request.py +117 -0
- robosystems_client/models/backup_export_request.py +72 -0
- robosystems_client/models/backup_list_response.py +90 -0
- robosystems_client/models/backup_response.py +200 -0
- robosystems_client/models/backup_restore_request.py +81 -0
- robosystems_client/models/backup_stats_response.py +156 -0
- robosystems_client/models/backup_stats_response_backup_formats.py +44 -0
- robosystems_client/models/cancel_operation_response_canceloperation.py +44 -0
- robosystems_client/models/cancellation_response.py +76 -0
- robosystems_client/models/check_credit_balance_response_checkcreditbalance.py +44 -0
- robosystems_client/models/connection_options_response.py +82 -0
- robosystems_client/models/connection_provider_info.py +203 -0
- robosystems_client/models/connection_provider_info_auth_type.py +11 -0
- robosystems_client/models/connection_provider_info_provider.py +10 -0
- robosystems_client/models/connection_response.py +149 -0
- robosystems_client/models/connection_response_metadata.py +44 -0
- robosystems_client/models/connection_response_provider.py +10 -0
- robosystems_client/models/create_api_key_request.py +82 -0
- robosystems_client/models/create_api_key_response.py +74 -0
- robosystems_client/models/create_connection_request.py +179 -0
- robosystems_client/models/create_connection_request_provider.py +10 -0
- robosystems_client/models/create_graph_request.py +183 -0
- robosystems_client/models/credit_check_request.py +82 -0
- robosystems_client/models/credit_summary.py +128 -0
- robosystems_client/models/credit_summary_response.py +140 -0
- robosystems_client/models/credits_summary_response.py +122 -0
- robosystems_client/models/credits_summary_response_credits_by_addon_item.py +44 -0
- robosystems_client/models/custom_schema_definition.py +194 -0
- robosystems_client/models/custom_schema_definition_metadata.py +49 -0
- robosystems_client/models/custom_schema_definition_nodes_item.py +44 -0
- robosystems_client/models/custom_schema_definition_relationships_item.py +44 -0
- robosystems_client/models/cypher_query_request.py +128 -0
- robosystems_client/models/cypher_query_request_parameters_type_0.py +44 -0
- robosystems_client/models/database_health_response.py +181 -0
- robosystems_client/models/database_info_response.py +191 -0
- robosystems_client/models/detailed_transactions_response.py +124 -0
- robosystems_client/models/detailed_transactions_response_date_range.py +44 -0
- robosystems_client/models/detailed_transactions_response_summary.py +59 -0
- robosystems_client/models/enhanced_credit_transaction_response.py +192 -0
- robosystems_client/models/enhanced_credit_transaction_response_metadata.py +44 -0
- robosystems_client/models/error_response.py +145 -0
- robosystems_client/models/exchange_token_request.py +116 -0
- robosystems_client/models/exchange_token_request_metadata_type_0.py +44 -0
- robosystems_client/models/get_all_credit_summaries_response_getallcreditsummaries.py +44 -0
- robosystems_client/models/get_backup_download_url_response_getbackupdownloadurl.py +44 -0
- robosystems_client/models/get_current_auth_user_response_getcurrentauthuser.py +44 -0
- robosystems_client/models/get_current_graph_bill_response_getcurrentgraphbill.py +44 -0
- robosystems_client/models/get_graph_billing_history_response_getgraphbillinghistory.py +44 -0
- robosystems_client/models/get_graph_monthly_bill_response_getgraphmonthlybill.py +44 -0
- robosystems_client/models/get_graph_schema_info_response_getgraphschemainfo.py +44 -0
- robosystems_client/models/get_graph_usage_details_response_getgraphusagedetails.py +44 -0
- robosystems_client/models/get_mcp_health_response_getmcphealth.py +44 -0
- robosystems_client/models/get_operation_status_response_getoperationstatus.py +44 -0
- robosystems_client/models/get_storage_usage_response_getstorageusage.py +44 -0
- robosystems_client/models/graph_info.py +92 -0
- robosystems_client/models/graph_metadata.py +105 -0
- robosystems_client/models/graph_metrics_response.py +188 -0
- robosystems_client/models/graph_metrics_response_estimated_size.py +44 -0
- robosystems_client/models/graph_metrics_response_health_status.py +44 -0
- robosystems_client/models/graph_metrics_response_node_counts.py +44 -0
- robosystems_client/models/graph_metrics_response_relationship_counts.py +44 -0
- robosystems_client/models/graph_usage_response.py +116 -0
- robosystems_client/models/graph_usage_response_query_statistics.py +44 -0
- robosystems_client/models/graph_usage_response_recent_activity.py +44 -0
- robosystems_client/models/graph_usage_response_storage_usage.py +44 -0
- robosystems_client/models/health_status.py +110 -0
- robosystems_client/models/health_status_details_type_0.py +44 -0
- robosystems_client/models/http_validation_error.py +75 -0
- robosystems_client/models/initial_entity_data.py +212 -0
- robosystems_client/models/kuzu_backup_health_response_kuzubackuphealth.py +44 -0
- robosystems_client/models/link_token_request.py +174 -0
- robosystems_client/models/link_token_request_options_type_0.py +44 -0
- robosystems_client/models/link_token_request_provider_type_0.py +10 -0
- robosystems_client/models/list_connections_provider_type_0.py +10 -0
- robosystems_client/models/list_schema_extensions_response_listschemaextensions.py +44 -0
- robosystems_client/models/login_request.py +68 -0
- robosystems_client/models/logout_user_response_logoutuser.py +44 -0
- robosystems_client/models/mcp_tool_call.py +84 -0
- robosystems_client/models/mcp_tool_call_arguments.py +44 -0
- robosystems_client/models/mcp_tools_response.py +74 -0
- robosystems_client/models/mcp_tools_response_tools_item.py +44 -0
- robosystems_client/models/o_auth_callback_request.py +130 -0
- robosystems_client/models/o_auth_init_request.py +128 -0
- robosystems_client/models/o_auth_init_request_additional_params_type_0.py +44 -0
- robosystems_client/models/o_auth_init_response.py +78 -0
- robosystems_client/models/password_check_request.py +82 -0
- robosystems_client/models/password_check_response.py +112 -0
- robosystems_client/models/password_check_response_character_types.py +44 -0
- robosystems_client/models/password_policy_response.py +66 -0
- robosystems_client/models/password_policy_response_policy.py +44 -0
- robosystems_client/models/plaid_connection_config.py +209 -0
- robosystems_client/models/plaid_connection_config_accounts_type_0_item.py +44 -0
- robosystems_client/models/plaid_connection_config_institution_type_0.py +44 -0
- robosystems_client/models/quick_books_connection_config.py +92 -0
- robosystems_client/models/register_request.py +98 -0
- robosystems_client/models/repository_credits_response.py +101 -0
- robosystems_client/models/repository_plan.py +10 -0
- robosystems_client/models/repository_type.py +10 -0
- robosystems_client/models/response_mode.py +11 -0
- robosystems_client/models/schema_export_response.py +163 -0
- robosystems_client/models/schema_export_response_data_stats_type_0.py +44 -0
- robosystems_client/models/schema_export_response_schema_definition_type_0.py +44 -0
- robosystems_client/models/schema_validation_request.py +142 -0
- robosystems_client/models/schema_validation_request_schema_definition_type_0.py +44 -0
- robosystems_client/models/schema_validation_response.py +227 -0
- robosystems_client/models/schema_validation_response_compatibility_type_0.py +44 -0
- robosystems_client/models/schema_validation_response_stats_type_0.py +44 -0
- robosystems_client/models/sec_connection_config.py +82 -0
- robosystems_client/models/sso_complete_request.py +60 -0
- robosystems_client/models/sso_exchange_request.py +90 -0
- robosystems_client/models/sso_exchange_response.py +78 -0
- robosystems_client/models/sso_login_request.py +60 -0
- robosystems_client/models/sso_token_response.py +78 -0
- robosystems_client/models/storage_limit_response.py +149 -0
- robosystems_client/models/subscription_info.py +180 -0
- robosystems_client/models/subscription_info_metadata.py +44 -0
- robosystems_client/models/subscription_request.py +89 -0
- robosystems_client/models/subscription_response.py +82 -0
- robosystems_client/models/success_response.py +112 -0
- robosystems_client/models/success_response_data_type_0.py +44 -0
- robosystems_client/models/sync_connection_request.py +106 -0
- robosystems_client/models/sync_connection_request_sync_options_type_0.py +44 -0
- robosystems_client/models/sync_connection_response_syncconnection.py +44 -0
- robosystems_client/models/tier_upgrade_request.py +62 -0
- robosystems_client/models/transaction_summary_response.py +126 -0
- robosystems_client/models/update_api_key_request.py +92 -0
- robosystems_client/models/update_password_request.py +76 -0
- robosystems_client/models/update_user_request.py +92 -0
- robosystems_client/models/upgrade_subscription_request.py +82 -0
- robosystems_client/models/user_analytics_response.py +132 -0
- robosystems_client/models/user_analytics_response_api_usage.py +44 -0
- robosystems_client/models/user_analytics_response_graph_usage.py +44 -0
- robosystems_client/models/user_analytics_response_limits.py +44 -0
- robosystems_client/models/user_analytics_response_recent_activity_item.py +44 -0
- robosystems_client/models/user_analytics_response_user_info.py +44 -0
- robosystems_client/models/user_graph_summary.py +134 -0
- robosystems_client/models/user_graphs_response.py +96 -0
- robosystems_client/models/user_limits_response.py +95 -0
- robosystems_client/models/user_response.py +132 -0
- robosystems_client/models/user_subscriptions_response.py +90 -0
- robosystems_client/models/user_usage_response.py +90 -0
- robosystems_client/models/user_usage_response_graphs.py +44 -0
- robosystems_client/models/user_usage_summary_response.py +130 -0
- robosystems_client/models/user_usage_summary_response_usage_vs_limits.py +44 -0
- robosystems_client/models/validation_error.py +88 -0
- robosystems_client/py.typed +1 -0
- robosystems_client/sdk-config.yaml +5 -0
- robosystems_client/types.py +54 -0
- robosystems_client-0.1.9.dist-info/METADATA +302 -0
- robosystems_client-0.1.9.dist-info/RECORD +282 -0
- robosystems_client-0.1.9.dist-info/WHEEL +4 -0
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import TYPE_CHECKING, Any, TypeVar, Union, cast
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
|
|
7
|
+
from ..types import UNSET, Unset
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
from ..models.schema_export_response_data_stats_type_0 import (
|
|
11
|
+
SchemaExportResponseDataStatsType0,
|
|
12
|
+
)
|
|
13
|
+
from ..models.schema_export_response_schema_definition_type_0 import (
|
|
14
|
+
SchemaExportResponseSchemaDefinitionType0,
|
|
15
|
+
)
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
T = TypeVar("T", bound="SchemaExportResponse")
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
@_attrs_define
|
|
22
|
+
class SchemaExportResponse:
|
|
23
|
+
"""Response model for schema export.
|
|
24
|
+
|
|
25
|
+
Attributes:
|
|
26
|
+
graph_id (str): Graph ID Example: entity_12345.
|
|
27
|
+
schema_definition (Union['SchemaExportResponseSchemaDefinitionType0', str]): Exported schema definition Example:
|
|
28
|
+
{'name': 'entity_12345_schema', 'nodes': [{'name': 'Entity', 'properties': []}], 'relationships': [], 'version':
|
|
29
|
+
'1.0.0'}.
|
|
30
|
+
format_ (str): Export format used Example: json.
|
|
31
|
+
exported_at (str): Export timestamp Example: 2024-01-15T10:30:00Z.
|
|
32
|
+
data_stats (Union['SchemaExportResponseDataStatsType0', None, Unset]): Data statistics if requested Example:
|
|
33
|
+
{'node_counts': {'Entity': 1, 'Report': 25}, 'total_nodes': 26}.
|
|
34
|
+
"""
|
|
35
|
+
|
|
36
|
+
graph_id: str
|
|
37
|
+
schema_definition: Union["SchemaExportResponseSchemaDefinitionType0", str]
|
|
38
|
+
format_: str
|
|
39
|
+
exported_at: str
|
|
40
|
+
data_stats: Union["SchemaExportResponseDataStatsType0", None, Unset] = UNSET
|
|
41
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
42
|
+
|
|
43
|
+
def to_dict(self) -> dict[str, Any]:
|
|
44
|
+
from ..models.schema_export_response_data_stats_type_0 import (
|
|
45
|
+
SchemaExportResponseDataStatsType0,
|
|
46
|
+
)
|
|
47
|
+
from ..models.schema_export_response_schema_definition_type_0 import (
|
|
48
|
+
SchemaExportResponseSchemaDefinitionType0,
|
|
49
|
+
)
|
|
50
|
+
|
|
51
|
+
graph_id = self.graph_id
|
|
52
|
+
|
|
53
|
+
schema_definition: Union[dict[str, Any], str]
|
|
54
|
+
if isinstance(self.schema_definition, SchemaExportResponseSchemaDefinitionType0):
|
|
55
|
+
schema_definition = self.schema_definition.to_dict()
|
|
56
|
+
else:
|
|
57
|
+
schema_definition = self.schema_definition
|
|
58
|
+
|
|
59
|
+
format_ = self.format_
|
|
60
|
+
|
|
61
|
+
exported_at = self.exported_at
|
|
62
|
+
|
|
63
|
+
data_stats: Union[None, Unset, dict[str, Any]]
|
|
64
|
+
if isinstance(self.data_stats, Unset):
|
|
65
|
+
data_stats = UNSET
|
|
66
|
+
elif isinstance(self.data_stats, SchemaExportResponseDataStatsType0):
|
|
67
|
+
data_stats = self.data_stats.to_dict()
|
|
68
|
+
else:
|
|
69
|
+
data_stats = self.data_stats
|
|
70
|
+
|
|
71
|
+
field_dict: dict[str, Any] = {}
|
|
72
|
+
field_dict.update(self.additional_properties)
|
|
73
|
+
field_dict.update(
|
|
74
|
+
{
|
|
75
|
+
"graph_id": graph_id,
|
|
76
|
+
"schema_definition": schema_definition,
|
|
77
|
+
"format": format_,
|
|
78
|
+
"exported_at": exported_at,
|
|
79
|
+
}
|
|
80
|
+
)
|
|
81
|
+
if data_stats is not UNSET:
|
|
82
|
+
field_dict["data_stats"] = data_stats
|
|
83
|
+
|
|
84
|
+
return field_dict
|
|
85
|
+
|
|
86
|
+
@classmethod
|
|
87
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
88
|
+
from ..models.schema_export_response_data_stats_type_0 import (
|
|
89
|
+
SchemaExportResponseDataStatsType0,
|
|
90
|
+
)
|
|
91
|
+
from ..models.schema_export_response_schema_definition_type_0 import (
|
|
92
|
+
SchemaExportResponseSchemaDefinitionType0,
|
|
93
|
+
)
|
|
94
|
+
|
|
95
|
+
d = dict(src_dict)
|
|
96
|
+
graph_id = d.pop("graph_id")
|
|
97
|
+
|
|
98
|
+
def _parse_schema_definition(
|
|
99
|
+
data: object,
|
|
100
|
+
) -> Union["SchemaExportResponseSchemaDefinitionType0", str]:
|
|
101
|
+
try:
|
|
102
|
+
if not isinstance(data, dict):
|
|
103
|
+
raise TypeError()
|
|
104
|
+
schema_definition_type_0 = SchemaExportResponseSchemaDefinitionType0.from_dict(
|
|
105
|
+
data
|
|
106
|
+
)
|
|
107
|
+
|
|
108
|
+
return schema_definition_type_0
|
|
109
|
+
except: # noqa: E722
|
|
110
|
+
pass
|
|
111
|
+
return cast(Union["SchemaExportResponseSchemaDefinitionType0", str], data)
|
|
112
|
+
|
|
113
|
+
schema_definition = _parse_schema_definition(d.pop("schema_definition"))
|
|
114
|
+
|
|
115
|
+
format_ = d.pop("format")
|
|
116
|
+
|
|
117
|
+
exported_at = d.pop("exported_at")
|
|
118
|
+
|
|
119
|
+
def _parse_data_stats(
|
|
120
|
+
data: object,
|
|
121
|
+
) -> Union["SchemaExportResponseDataStatsType0", None, Unset]:
|
|
122
|
+
if data is None:
|
|
123
|
+
return data
|
|
124
|
+
if isinstance(data, Unset):
|
|
125
|
+
return data
|
|
126
|
+
try:
|
|
127
|
+
if not isinstance(data, dict):
|
|
128
|
+
raise TypeError()
|
|
129
|
+
data_stats_type_0 = SchemaExportResponseDataStatsType0.from_dict(data)
|
|
130
|
+
|
|
131
|
+
return data_stats_type_0
|
|
132
|
+
except: # noqa: E722
|
|
133
|
+
pass
|
|
134
|
+
return cast(Union["SchemaExportResponseDataStatsType0", None, Unset], data)
|
|
135
|
+
|
|
136
|
+
data_stats = _parse_data_stats(d.pop("data_stats", UNSET))
|
|
137
|
+
|
|
138
|
+
schema_export_response = cls(
|
|
139
|
+
graph_id=graph_id,
|
|
140
|
+
schema_definition=schema_definition,
|
|
141
|
+
format_=format_,
|
|
142
|
+
exported_at=exported_at,
|
|
143
|
+
data_stats=data_stats,
|
|
144
|
+
)
|
|
145
|
+
|
|
146
|
+
schema_export_response.additional_properties = d
|
|
147
|
+
return schema_export_response
|
|
148
|
+
|
|
149
|
+
@property
|
|
150
|
+
def additional_keys(self) -> list[str]:
|
|
151
|
+
return list(self.additional_properties.keys())
|
|
152
|
+
|
|
153
|
+
def __getitem__(self, key: str) -> Any:
|
|
154
|
+
return self.additional_properties[key]
|
|
155
|
+
|
|
156
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
157
|
+
self.additional_properties[key] = value
|
|
158
|
+
|
|
159
|
+
def __delitem__(self, key: str) -> None:
|
|
160
|
+
del self.additional_properties[key]
|
|
161
|
+
|
|
162
|
+
def __contains__(self, key: str) -> bool:
|
|
163
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import Any, TypeVar
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
|
|
7
|
+
T = TypeVar("T", bound="SchemaExportResponseDataStatsType0")
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
@_attrs_define
|
|
11
|
+
class SchemaExportResponseDataStatsType0:
|
|
12
|
+
""" """
|
|
13
|
+
|
|
14
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
15
|
+
|
|
16
|
+
def to_dict(self) -> dict[str, Any]:
|
|
17
|
+
field_dict: dict[str, Any] = {}
|
|
18
|
+
field_dict.update(self.additional_properties)
|
|
19
|
+
|
|
20
|
+
return field_dict
|
|
21
|
+
|
|
22
|
+
@classmethod
|
|
23
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
24
|
+
d = dict(src_dict)
|
|
25
|
+
schema_export_response_data_stats_type_0 = cls()
|
|
26
|
+
|
|
27
|
+
schema_export_response_data_stats_type_0.additional_properties = d
|
|
28
|
+
return schema_export_response_data_stats_type_0
|
|
29
|
+
|
|
30
|
+
@property
|
|
31
|
+
def additional_keys(self) -> list[str]:
|
|
32
|
+
return list(self.additional_properties.keys())
|
|
33
|
+
|
|
34
|
+
def __getitem__(self, key: str) -> Any:
|
|
35
|
+
return self.additional_properties[key]
|
|
36
|
+
|
|
37
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
38
|
+
self.additional_properties[key] = value
|
|
39
|
+
|
|
40
|
+
def __delitem__(self, key: str) -> None:
|
|
41
|
+
del self.additional_properties[key]
|
|
42
|
+
|
|
43
|
+
def __contains__(self, key: str) -> bool:
|
|
44
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import Any, TypeVar
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
|
|
7
|
+
T = TypeVar("T", bound="SchemaExportResponseSchemaDefinitionType0")
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
@_attrs_define
|
|
11
|
+
class SchemaExportResponseSchemaDefinitionType0:
|
|
12
|
+
""" """
|
|
13
|
+
|
|
14
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
15
|
+
|
|
16
|
+
def to_dict(self) -> dict[str, Any]:
|
|
17
|
+
field_dict: dict[str, Any] = {}
|
|
18
|
+
field_dict.update(self.additional_properties)
|
|
19
|
+
|
|
20
|
+
return field_dict
|
|
21
|
+
|
|
22
|
+
@classmethod
|
|
23
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
24
|
+
d = dict(src_dict)
|
|
25
|
+
schema_export_response_schema_definition_type_0 = cls()
|
|
26
|
+
|
|
27
|
+
schema_export_response_schema_definition_type_0.additional_properties = d
|
|
28
|
+
return schema_export_response_schema_definition_type_0
|
|
29
|
+
|
|
30
|
+
@property
|
|
31
|
+
def additional_keys(self) -> list[str]:
|
|
32
|
+
return list(self.additional_properties.keys())
|
|
33
|
+
|
|
34
|
+
def __getitem__(self, key: str) -> Any:
|
|
35
|
+
return self.additional_properties[key]
|
|
36
|
+
|
|
37
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
38
|
+
self.additional_properties[key] = value
|
|
39
|
+
|
|
40
|
+
def __delitem__(self, key: str) -> None:
|
|
41
|
+
del self.additional_properties[key]
|
|
42
|
+
|
|
43
|
+
def __contains__(self, key: str) -> bool:
|
|
44
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import TYPE_CHECKING, Any, TypeVar, Union, cast
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
|
|
7
|
+
from ..types import UNSET, Unset
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
from ..models.schema_validation_request_schema_definition_type_0 import (
|
|
11
|
+
SchemaValidationRequestSchemaDefinitionType0,
|
|
12
|
+
)
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
T = TypeVar("T", bound="SchemaValidationRequest")
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
@_attrs_define
|
|
19
|
+
class SchemaValidationRequest:
|
|
20
|
+
"""Request model for schema validation.
|
|
21
|
+
|
|
22
|
+
Attributes:
|
|
23
|
+
schema_definition (Union['SchemaValidationRequestSchemaDefinitionType0', str]): Schema definition as JSON dict
|
|
24
|
+
or JSON/YAML string Example: {'extends': 'base', 'name': 'inventory_management', 'nodes': [{'name': 'Product',
|
|
25
|
+
'properties': [{'name': 'sku', 'type': 'STRING', 'is_primary_key': True}, {'name': 'name', 'type': 'STRING',
|
|
26
|
+
'is_required': True}]}], 'version': '1.0.0'}.
|
|
27
|
+
format_ (Union[Unset, str]): Schema format: json, yaml, or dict Default: 'json'. Example: json.
|
|
28
|
+
check_compatibility (Union[None, Unset, list[str]]): List of existing schema extensions to check compatibility
|
|
29
|
+
with Example: ['roboledger'].
|
|
30
|
+
"""
|
|
31
|
+
|
|
32
|
+
schema_definition: Union["SchemaValidationRequestSchemaDefinitionType0", str]
|
|
33
|
+
format_: Union[Unset, str] = "json"
|
|
34
|
+
check_compatibility: Union[None, Unset, list[str]] = UNSET
|
|
35
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
36
|
+
|
|
37
|
+
def to_dict(self) -> dict[str, Any]:
|
|
38
|
+
from ..models.schema_validation_request_schema_definition_type_0 import (
|
|
39
|
+
SchemaValidationRequestSchemaDefinitionType0,
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
schema_definition: Union[dict[str, Any], str]
|
|
43
|
+
if isinstance(self.schema_definition, SchemaValidationRequestSchemaDefinitionType0):
|
|
44
|
+
schema_definition = self.schema_definition.to_dict()
|
|
45
|
+
else:
|
|
46
|
+
schema_definition = self.schema_definition
|
|
47
|
+
|
|
48
|
+
format_ = self.format_
|
|
49
|
+
|
|
50
|
+
check_compatibility: Union[None, Unset, list[str]]
|
|
51
|
+
if isinstance(self.check_compatibility, Unset):
|
|
52
|
+
check_compatibility = UNSET
|
|
53
|
+
elif isinstance(self.check_compatibility, list):
|
|
54
|
+
check_compatibility = self.check_compatibility
|
|
55
|
+
|
|
56
|
+
else:
|
|
57
|
+
check_compatibility = self.check_compatibility
|
|
58
|
+
|
|
59
|
+
field_dict: dict[str, Any] = {}
|
|
60
|
+
field_dict.update(self.additional_properties)
|
|
61
|
+
field_dict.update(
|
|
62
|
+
{
|
|
63
|
+
"schema_definition": schema_definition,
|
|
64
|
+
}
|
|
65
|
+
)
|
|
66
|
+
if format_ is not UNSET:
|
|
67
|
+
field_dict["format"] = format_
|
|
68
|
+
if check_compatibility is not UNSET:
|
|
69
|
+
field_dict["check_compatibility"] = check_compatibility
|
|
70
|
+
|
|
71
|
+
return field_dict
|
|
72
|
+
|
|
73
|
+
@classmethod
|
|
74
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
75
|
+
from ..models.schema_validation_request_schema_definition_type_0 import (
|
|
76
|
+
SchemaValidationRequestSchemaDefinitionType0,
|
|
77
|
+
)
|
|
78
|
+
|
|
79
|
+
d = dict(src_dict)
|
|
80
|
+
|
|
81
|
+
def _parse_schema_definition(
|
|
82
|
+
data: object,
|
|
83
|
+
) -> Union["SchemaValidationRequestSchemaDefinitionType0", str]:
|
|
84
|
+
try:
|
|
85
|
+
if not isinstance(data, dict):
|
|
86
|
+
raise TypeError()
|
|
87
|
+
schema_definition_type_0 = (
|
|
88
|
+
SchemaValidationRequestSchemaDefinitionType0.from_dict(data)
|
|
89
|
+
)
|
|
90
|
+
|
|
91
|
+
return schema_definition_type_0
|
|
92
|
+
except: # noqa: E722
|
|
93
|
+
pass
|
|
94
|
+
return cast(Union["SchemaValidationRequestSchemaDefinitionType0", str], data)
|
|
95
|
+
|
|
96
|
+
schema_definition = _parse_schema_definition(d.pop("schema_definition"))
|
|
97
|
+
|
|
98
|
+
format_ = d.pop("format", UNSET)
|
|
99
|
+
|
|
100
|
+
def _parse_check_compatibility(data: object) -> Union[None, Unset, list[str]]:
|
|
101
|
+
if data is None:
|
|
102
|
+
return data
|
|
103
|
+
if isinstance(data, Unset):
|
|
104
|
+
return data
|
|
105
|
+
try:
|
|
106
|
+
if not isinstance(data, list):
|
|
107
|
+
raise TypeError()
|
|
108
|
+
check_compatibility_type_0 = cast(list[str], data)
|
|
109
|
+
|
|
110
|
+
return check_compatibility_type_0
|
|
111
|
+
except: # noqa: E722
|
|
112
|
+
pass
|
|
113
|
+
return cast(Union[None, Unset, list[str]], data)
|
|
114
|
+
|
|
115
|
+
check_compatibility = _parse_check_compatibility(
|
|
116
|
+
d.pop("check_compatibility", UNSET)
|
|
117
|
+
)
|
|
118
|
+
|
|
119
|
+
schema_validation_request = cls(
|
|
120
|
+
schema_definition=schema_definition,
|
|
121
|
+
format_=format_,
|
|
122
|
+
check_compatibility=check_compatibility,
|
|
123
|
+
)
|
|
124
|
+
|
|
125
|
+
schema_validation_request.additional_properties = d
|
|
126
|
+
return schema_validation_request
|
|
127
|
+
|
|
128
|
+
@property
|
|
129
|
+
def additional_keys(self) -> list[str]:
|
|
130
|
+
return list(self.additional_properties.keys())
|
|
131
|
+
|
|
132
|
+
def __getitem__(self, key: str) -> Any:
|
|
133
|
+
return self.additional_properties[key]
|
|
134
|
+
|
|
135
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
136
|
+
self.additional_properties[key] = value
|
|
137
|
+
|
|
138
|
+
def __delitem__(self, key: str) -> None:
|
|
139
|
+
del self.additional_properties[key]
|
|
140
|
+
|
|
141
|
+
def __contains__(self, key: str) -> bool:
|
|
142
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import Any, TypeVar
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
|
|
7
|
+
T = TypeVar("T", bound="SchemaValidationRequestSchemaDefinitionType0")
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
@_attrs_define
|
|
11
|
+
class SchemaValidationRequestSchemaDefinitionType0:
|
|
12
|
+
""" """
|
|
13
|
+
|
|
14
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
15
|
+
|
|
16
|
+
def to_dict(self) -> dict[str, Any]:
|
|
17
|
+
field_dict: dict[str, Any] = {}
|
|
18
|
+
field_dict.update(self.additional_properties)
|
|
19
|
+
|
|
20
|
+
return field_dict
|
|
21
|
+
|
|
22
|
+
@classmethod
|
|
23
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
24
|
+
d = dict(src_dict)
|
|
25
|
+
schema_validation_request_schema_definition_type_0 = cls()
|
|
26
|
+
|
|
27
|
+
schema_validation_request_schema_definition_type_0.additional_properties = d
|
|
28
|
+
return schema_validation_request_schema_definition_type_0
|
|
29
|
+
|
|
30
|
+
@property
|
|
31
|
+
def additional_keys(self) -> list[str]:
|
|
32
|
+
return list(self.additional_properties.keys())
|
|
33
|
+
|
|
34
|
+
def __getitem__(self, key: str) -> Any:
|
|
35
|
+
return self.additional_properties[key]
|
|
36
|
+
|
|
37
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
38
|
+
self.additional_properties[key] = value
|
|
39
|
+
|
|
40
|
+
def __delitem__(self, key: str) -> None:
|
|
41
|
+
del self.additional_properties[key]
|
|
42
|
+
|
|
43
|
+
def __contains__(self, key: str) -> bool:
|
|
44
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,227 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import TYPE_CHECKING, Any, TypeVar, Union, cast
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
|
|
7
|
+
from ..types import UNSET, Unset
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
from ..models.schema_validation_response_compatibility_type_0 import (
|
|
11
|
+
SchemaValidationResponseCompatibilityType0,
|
|
12
|
+
)
|
|
13
|
+
from ..models.schema_validation_response_stats_type_0 import (
|
|
14
|
+
SchemaValidationResponseStatsType0,
|
|
15
|
+
)
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
T = TypeVar("T", bound="SchemaValidationResponse")
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
@_attrs_define
|
|
22
|
+
class SchemaValidationResponse:
|
|
23
|
+
"""Response model for schema validation.
|
|
24
|
+
|
|
25
|
+
Attributes:
|
|
26
|
+
valid (bool): Whether the schema is valid Example: True.
|
|
27
|
+
message (str): Validation message Example: Schema is valid with 1 warning(s).
|
|
28
|
+
errors (Union[None, Unset, list[str]]): List of validation errors
|
|
29
|
+
warnings (Union[None, Unset, list[str]]): List of warnings Example: ['Schema has no relationships defined'].
|
|
30
|
+
stats (Union['SchemaValidationResponseStatsType0', None, Unset]): Schema statistics (nodes, relationships,
|
|
31
|
+
properties) Example: {'nodes': 2, 'primary_keys': 2, 'relationships': 1, 'total_properties': 6}.
|
|
32
|
+
compatibility (Union['SchemaValidationResponseCompatibilityType0', None, Unset]): Compatibility check results if
|
|
33
|
+
requested Example: {'checked_extensions': ['roboledger'], 'compatible': True, 'conflicts': []}.
|
|
34
|
+
"""
|
|
35
|
+
|
|
36
|
+
valid: bool
|
|
37
|
+
message: str
|
|
38
|
+
errors: Union[None, Unset, list[str]] = UNSET
|
|
39
|
+
warnings: Union[None, Unset, list[str]] = UNSET
|
|
40
|
+
stats: Union["SchemaValidationResponseStatsType0", None, Unset] = UNSET
|
|
41
|
+
compatibility: Union["SchemaValidationResponseCompatibilityType0", None, Unset] = (
|
|
42
|
+
UNSET
|
|
43
|
+
)
|
|
44
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
45
|
+
|
|
46
|
+
def to_dict(self) -> dict[str, Any]:
|
|
47
|
+
from ..models.schema_validation_response_compatibility_type_0 import (
|
|
48
|
+
SchemaValidationResponseCompatibilityType0,
|
|
49
|
+
)
|
|
50
|
+
from ..models.schema_validation_response_stats_type_0 import (
|
|
51
|
+
SchemaValidationResponseStatsType0,
|
|
52
|
+
)
|
|
53
|
+
|
|
54
|
+
valid = self.valid
|
|
55
|
+
|
|
56
|
+
message = self.message
|
|
57
|
+
|
|
58
|
+
errors: Union[None, Unset, list[str]]
|
|
59
|
+
if isinstance(self.errors, Unset):
|
|
60
|
+
errors = UNSET
|
|
61
|
+
elif isinstance(self.errors, list):
|
|
62
|
+
errors = self.errors
|
|
63
|
+
|
|
64
|
+
else:
|
|
65
|
+
errors = self.errors
|
|
66
|
+
|
|
67
|
+
warnings: Union[None, Unset, list[str]]
|
|
68
|
+
if isinstance(self.warnings, Unset):
|
|
69
|
+
warnings = UNSET
|
|
70
|
+
elif isinstance(self.warnings, list):
|
|
71
|
+
warnings = self.warnings
|
|
72
|
+
|
|
73
|
+
else:
|
|
74
|
+
warnings = self.warnings
|
|
75
|
+
|
|
76
|
+
stats: Union[None, Unset, dict[str, Any]]
|
|
77
|
+
if isinstance(self.stats, Unset):
|
|
78
|
+
stats = UNSET
|
|
79
|
+
elif isinstance(self.stats, SchemaValidationResponseStatsType0):
|
|
80
|
+
stats = self.stats.to_dict()
|
|
81
|
+
else:
|
|
82
|
+
stats = self.stats
|
|
83
|
+
|
|
84
|
+
compatibility: Union[None, Unset, dict[str, Any]]
|
|
85
|
+
if isinstance(self.compatibility, Unset):
|
|
86
|
+
compatibility = UNSET
|
|
87
|
+
elif isinstance(self.compatibility, SchemaValidationResponseCompatibilityType0):
|
|
88
|
+
compatibility = self.compatibility.to_dict()
|
|
89
|
+
else:
|
|
90
|
+
compatibility = self.compatibility
|
|
91
|
+
|
|
92
|
+
field_dict: dict[str, Any] = {}
|
|
93
|
+
field_dict.update(self.additional_properties)
|
|
94
|
+
field_dict.update(
|
|
95
|
+
{
|
|
96
|
+
"valid": valid,
|
|
97
|
+
"message": message,
|
|
98
|
+
}
|
|
99
|
+
)
|
|
100
|
+
if errors is not UNSET:
|
|
101
|
+
field_dict["errors"] = errors
|
|
102
|
+
if warnings is not UNSET:
|
|
103
|
+
field_dict["warnings"] = warnings
|
|
104
|
+
if stats is not UNSET:
|
|
105
|
+
field_dict["stats"] = stats
|
|
106
|
+
if compatibility is not UNSET:
|
|
107
|
+
field_dict["compatibility"] = compatibility
|
|
108
|
+
|
|
109
|
+
return field_dict
|
|
110
|
+
|
|
111
|
+
@classmethod
|
|
112
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
113
|
+
from ..models.schema_validation_response_compatibility_type_0 import (
|
|
114
|
+
SchemaValidationResponseCompatibilityType0,
|
|
115
|
+
)
|
|
116
|
+
from ..models.schema_validation_response_stats_type_0 import (
|
|
117
|
+
SchemaValidationResponseStatsType0,
|
|
118
|
+
)
|
|
119
|
+
|
|
120
|
+
d = dict(src_dict)
|
|
121
|
+
valid = d.pop("valid")
|
|
122
|
+
|
|
123
|
+
message = d.pop("message")
|
|
124
|
+
|
|
125
|
+
def _parse_errors(data: object) -> Union[None, Unset, list[str]]:
|
|
126
|
+
if data is None:
|
|
127
|
+
return data
|
|
128
|
+
if isinstance(data, Unset):
|
|
129
|
+
return data
|
|
130
|
+
try:
|
|
131
|
+
if not isinstance(data, list):
|
|
132
|
+
raise TypeError()
|
|
133
|
+
errors_type_0 = cast(list[str], data)
|
|
134
|
+
|
|
135
|
+
return errors_type_0
|
|
136
|
+
except: # noqa: E722
|
|
137
|
+
pass
|
|
138
|
+
return cast(Union[None, Unset, list[str]], data)
|
|
139
|
+
|
|
140
|
+
errors = _parse_errors(d.pop("errors", UNSET))
|
|
141
|
+
|
|
142
|
+
def _parse_warnings(data: object) -> Union[None, Unset, list[str]]:
|
|
143
|
+
if data is None:
|
|
144
|
+
return data
|
|
145
|
+
if isinstance(data, Unset):
|
|
146
|
+
return data
|
|
147
|
+
try:
|
|
148
|
+
if not isinstance(data, list):
|
|
149
|
+
raise TypeError()
|
|
150
|
+
warnings_type_0 = cast(list[str], data)
|
|
151
|
+
|
|
152
|
+
return warnings_type_0
|
|
153
|
+
except: # noqa: E722
|
|
154
|
+
pass
|
|
155
|
+
return cast(Union[None, Unset, list[str]], data)
|
|
156
|
+
|
|
157
|
+
warnings = _parse_warnings(d.pop("warnings", UNSET))
|
|
158
|
+
|
|
159
|
+
def _parse_stats(
|
|
160
|
+
data: object,
|
|
161
|
+
) -> Union["SchemaValidationResponseStatsType0", None, Unset]:
|
|
162
|
+
if data is None:
|
|
163
|
+
return data
|
|
164
|
+
if isinstance(data, Unset):
|
|
165
|
+
return data
|
|
166
|
+
try:
|
|
167
|
+
if not isinstance(data, dict):
|
|
168
|
+
raise TypeError()
|
|
169
|
+
stats_type_0 = SchemaValidationResponseStatsType0.from_dict(data)
|
|
170
|
+
|
|
171
|
+
return stats_type_0
|
|
172
|
+
except: # noqa: E722
|
|
173
|
+
pass
|
|
174
|
+
return cast(Union["SchemaValidationResponseStatsType0", None, Unset], data)
|
|
175
|
+
|
|
176
|
+
stats = _parse_stats(d.pop("stats", UNSET))
|
|
177
|
+
|
|
178
|
+
def _parse_compatibility(
|
|
179
|
+
data: object,
|
|
180
|
+
) -> Union["SchemaValidationResponseCompatibilityType0", None, Unset]:
|
|
181
|
+
if data is None:
|
|
182
|
+
return data
|
|
183
|
+
if isinstance(data, Unset):
|
|
184
|
+
return data
|
|
185
|
+
try:
|
|
186
|
+
if not isinstance(data, dict):
|
|
187
|
+
raise TypeError()
|
|
188
|
+
compatibility_type_0 = SchemaValidationResponseCompatibilityType0.from_dict(
|
|
189
|
+
data
|
|
190
|
+
)
|
|
191
|
+
|
|
192
|
+
return compatibility_type_0
|
|
193
|
+
except: # noqa: E722
|
|
194
|
+
pass
|
|
195
|
+
return cast(
|
|
196
|
+
Union["SchemaValidationResponseCompatibilityType0", None, Unset], data
|
|
197
|
+
)
|
|
198
|
+
|
|
199
|
+
compatibility = _parse_compatibility(d.pop("compatibility", UNSET))
|
|
200
|
+
|
|
201
|
+
schema_validation_response = cls(
|
|
202
|
+
valid=valid,
|
|
203
|
+
message=message,
|
|
204
|
+
errors=errors,
|
|
205
|
+
warnings=warnings,
|
|
206
|
+
stats=stats,
|
|
207
|
+
compatibility=compatibility,
|
|
208
|
+
)
|
|
209
|
+
|
|
210
|
+
schema_validation_response.additional_properties = d
|
|
211
|
+
return schema_validation_response
|
|
212
|
+
|
|
213
|
+
@property
|
|
214
|
+
def additional_keys(self) -> list[str]:
|
|
215
|
+
return list(self.additional_properties.keys())
|
|
216
|
+
|
|
217
|
+
def __getitem__(self, key: str) -> Any:
|
|
218
|
+
return self.additional_properties[key]
|
|
219
|
+
|
|
220
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
221
|
+
self.additional_properties[key] = value
|
|
222
|
+
|
|
223
|
+
def __delitem__(self, key: str) -> None:
|
|
224
|
+
del self.additional_properties[key]
|
|
225
|
+
|
|
226
|
+
def __contains__(self, key: str) -> bool:
|
|
227
|
+
return key in self.additional_properties
|