api-sdk-py 1.11.66__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.
- api_sdk_py/__init__.py +312 -0
- api_sdk_py/api/__init__.py +18 -0
- api_sdk_py/api/canvases_api.py +1605 -0
- api_sdk_py/api/compositions_api.py +11616 -0
- api_sdk_py/api/credits_api.py +628 -0
- api_sdk_py/api/entitlements_api.py +676 -0
- api_sdk_py/api/invoices_api.py +357 -0
- api_sdk_py/api/managed_users_api.py +5087 -0
- api_sdk_py/api/operations_api.py +305 -0
- api_sdk_py/api/partner_api.py +41365 -0
- api_sdk_py/api/partners_api.py +11156 -0
- api_sdk_py/api/public_embed_api.py +1938 -0
- api_sdk_py/api/tokens_api.py +283 -0
- api_sdk_py/api/uploads_api.py +1507 -0
- api_sdk_py/api/users_api.py +3649 -0
- api_sdk_py/api/widgets_api.py +1300 -0
- api_sdk_py/api_client.py +797 -0
- api_sdk_py/api_response.py +21 -0
- api_sdk_py/configuration.py +526 -0
- api_sdk_py/exceptions.py +199 -0
- api_sdk_py/models/__init__.py +282 -0
- api_sdk_py/models/account_credit_balance.py +96 -0
- api_sdk_py/models/account_credit_balance_response.py +99 -0
- api_sdk_py/models/account_credit_transaction.py +120 -0
- api_sdk_py/models/adapter_connection.py +112 -0
- api_sdk_py/models/adapter_connection_removal.py +87 -0
- api_sdk_py/models/add_ai_answers_knowledge_document201_response.py +99 -0
- api_sdk_py/models/add_ai_answers_knowledge_document_request.py +90 -0
- api_sdk_py/models/add_domain_request.py +87 -0
- api_sdk_py/models/ai_answers_knowledge.py +101 -0
- api_sdk_py/models/ai_answers_knowledge_document.py +113 -0
- api_sdk_py/models/ai_answers_knowledge_removal.py +87 -0
- api_sdk_py/models/ai_answers_knowledge_totals.py +93 -0
- api_sdk_py/models/api_key_scope.py +44 -0
- api_sdk_py/models/canvas.py +112 -0
- api_sdk_py/models/canvas_response.py +99 -0
- api_sdk_py/models/check_composition_access_response.py +99 -0
- api_sdk_py/models/check_composition_access_response_data.py +89 -0
- api_sdk_py/models/composition.py +133 -0
- api_sdk_py/models/composition_data_source.py +90 -0
- api_sdk_py/models/composition_data_source_response.py +99 -0
- api_sdk_py/models/composition_entries_description.py +99 -0
- api_sdk_py/models/composition_entries_description_response.py +99 -0
- api_sdk_py/models/composition_entries_reading.py +126 -0
- api_sdk_py/models/composition_entries_reading_response.py +99 -0
- api_sdk_py/models/composition_entry_aggregate_tally.py +122 -0
- api_sdk_py/models/composition_entry_aggregates_block.py +99 -0
- api_sdk_py/models/composition_entry_column.py +89 -0
- api_sdk_py/models/composition_entry_delete_success.py +93 -0
- api_sdk_py/models/composition_entry_delete_success_data.py +87 -0
- api_sdk_py/models/composition_entry_item.py +111 -0
- api_sdk_py/models/composition_entry_items_meta.py +106 -0
- api_sdk_py/models/composition_entry_items_page_success.py +103 -0
- api_sdk_py/models/composition_entry_table.py +105 -0
- api_sdk_py/models/composition_entry_tally.py +95 -0
- api_sdk_py/models/composition_response.py +99 -0
- api_sdk_py/models/composition_version.py +96 -0
- api_sdk_py/models/content_check_finding.py +93 -0
- api_sdk_py/models/content_item_write_result.py +101 -0
- api_sdk_py/models/content_item_write_result_validation_result.py +91 -0
- api_sdk_py/models/copy_partner_preset_request.py +88 -0
- api_sdk_py/models/create_canvas_request.py +118 -0
- api_sdk_py/models/create_composition_content_item201_response.py +99 -0
- api_sdk_py/models/create_composition_content_item_request.py +101 -0
- api_sdk_py/models/create_composition_database_record201_response.py +95 -0
- api_sdk_py/models/create_composition_from_preset_request.py +100 -0
- api_sdk_py/models/create_composition_from_widget201_response.py +99 -0
- api_sdk_py/models/create_composition_from_widget_request.py +102 -0
- api_sdk_py/models/create_user_api_key_request.py +106 -0
- api_sdk_py/models/create_widget201_response.py +99 -0
- api_sdk_py/models/create_widget201_response_data.py +207 -0
- api_sdk_py/models/created_user_api_key.py +117 -0
- api_sdk_py/models/created_user_api_key_response.py +99 -0
- api_sdk_py/models/delete_composition_content_item_response.py +99 -0
- api_sdk_py/models/delete_composition_content_item_response_data.py +89 -0
- api_sdk_py/models/delete_composition_data_source_response.py +99 -0
- api_sdk_py/models/delete_composition_data_source_response_data.py +87 -0
- api_sdk_py/models/delete_managed_user200_response.py +99 -0
- api_sdk_py/models/delete_personal_workspace_domain_response.py +99 -0
- api_sdk_py/models/delete_personal_workspace_domain_response_data.py +87 -0
- api_sdk_py/models/delete_user_api_key_response.py +99 -0
- api_sdk_py/models/delete_user_api_key_response_data.py +87 -0
- api_sdk_py/models/design_defaults.py +92 -0
- api_sdk_py/models/duplicate_composition202_response.py +99 -0
- api_sdk_py/models/duplicate_composition202_response_data.py +87 -0
- api_sdk_py/models/duplicate_composition_request.py +89 -0
- api_sdk_py/models/editor_session.py +122 -0
- api_sdk_py/models/editor_session_response.py +99 -0
- api_sdk_py/models/entitlement.py +118 -0
- api_sdk_py/models/error_detail.py +104 -0
- api_sdk_py/models/error_response.py +108 -0
- api_sdk_py/models/export_composition_entry_items200_response.py +103 -0
- api_sdk_py/models/export_composition_entry_items200_response_meta.py +89 -0
- api_sdk_py/models/get_ai_answers_knowledge200_response.py +99 -0
- api_sdk_py/models/get_all_canvases_response.py +99 -0
- api_sdk_py/models/get_all_canvases_response_data.py +101 -0
- api_sdk_py/models/get_all_compositions200_response.py +103 -0
- api_sdk_py/models/get_all_managed_users200_response.py +103 -0
- api_sdk_py/models/get_composition_content_response.py +95 -0
- api_sdk_py/models/get_composition_content_schema_response.py +99 -0
- api_sdk_py/models/get_composition_content_schema_response_data.py +97 -0
- api_sdk_py/models/get_composition_data_source_response.py +104 -0
- api_sdk_py/models/get_composition_database_records200_response.py +95 -0
- api_sdk_py/models/get_composition_design_response.py +95 -0
- api_sdk_py/models/get_composition_design_schema_response.py +99 -0
- api_sdk_py/models/get_composition_design_schema_response_data.py +97 -0
- api_sdk_py/models/get_composition_embed_schema_response.py +99 -0
- api_sdk_py/models/get_composition_embed_schema_response_data.py +107 -0
- api_sdk_py/models/get_composition_embed_settings_response.py +95 -0
- api_sdk_py/models/get_composition_preview_response.py +99 -0
- api_sdk_py/models/get_composition_preview_response_data.py +93 -0
- api_sdk_py/models/get_composition_versions200_response.py +103 -0
- api_sdk_py/models/get_compositions_batch_request.py +88 -0
- api_sdk_py/models/get_compositions_batch_response.py +99 -0
- api_sdk_py/models/get_compositions_batch_response_data.py +105 -0
- api_sdk_py/models/get_invoices_by_partner_id200_response.py +103 -0
- api_sdk_py/models/get_managed_user_entitlements_response.py +99 -0
- api_sdk_py/models/get_managed_user_entitlements_response_data.py +97 -0
- api_sdk_py/models/get_managed_user_limits200_response.py +99 -0
- api_sdk_py/models/get_managed_user_storage_usage200_response.py +99 -0
- api_sdk_py/models/get_managed_user_storage_usage200_response_data.py +95 -0
- api_sdk_py/models/get_managed_user_storage_usage200_response_data_by_purpose.py +106 -0
- api_sdk_py/models/get_managed_users_by_manager_id_response.py +99 -0
- api_sdk_py/models/get_managed_users_by_manager_id_response_data.py +101 -0
- api_sdk_py/models/get_partner_billing_overview200_response.py +99 -0
- api_sdk_py/models/get_partner_credit_transactions200_response.py +103 -0
- api_sdk_py/models/get_partner_design_defaults200_response.py +99 -0
- api_sdk_py/models/get_partner_entitlements_response.py +99 -0
- api_sdk_py/models/get_partner_entitlements_response_data.py +97 -0
- api_sdk_py/models/get_personal_workspace_domains200_response.py +103 -0
- api_sdk_py/models/get_public_composition_embed200_response.py +133 -0
- api_sdk_py/models/get_public_composition_embed200_response_data_source.py +89 -0
- api_sdk_py/models/get_public_composition_embed200_response_direct.py +96 -0
- api_sdk_py/models/get_user_adapter_connections200_response.py +103 -0
- api_sdk_py/models/get_user_api_key_usage_logs_response.py +99 -0
- api_sdk_py/models/get_user_api_key_usage_logs_response_data.py +95 -0
- api_sdk_py/models/get_user_api_keys200_response.py +103 -0
- api_sdk_py/models/get_widgets200_response.py +103 -0
- api_sdk_py/models/get_widgets_batch_request.py +87 -0
- api_sdk_py/models/get_widgets_batch_response.py +99 -0
- api_sdk_py/models/get_widgets_batch_response_data.py +105 -0
- api_sdk_py/models/get_widgets_batch_response_data_errors_inner.py +89 -0
- api_sdk_py/models/list_partner_presets200_response.py +103 -0
- api_sdk_py/models/managed_user.py +105 -0
- api_sdk_py/models/managed_user_entries_meta.py +100 -0
- api_sdk_py/models/managed_user_entries_page_success.py +103 -0
- api_sdk_py/models/managed_user_entry_item.py +115 -0
- api_sdk_py/models/managed_user_limits.py +104 -0
- api_sdk_py/models/managed_user_operation_usage.py +95 -0
- api_sdk_py/models/managed_user_removal.py +89 -0
- api_sdk_py/models/managed_user_response.py +99 -0
- api_sdk_py/models/managed_user_usage.py +110 -0
- api_sdk_py/models/managed_user_usage_response.py +99 -0
- api_sdk_py/models/managed_user_usage_totals.py +93 -0
- api_sdk_py/models/my_partner.py +136 -0
- api_sdk_py/models/my_partners.py +112 -0
- api_sdk_py/models/my_partners_response.py +99 -0
- api_sdk_py/models/new_composition.py +108 -0
- api_sdk_py/models/new_editor_session.py +107 -0
- api_sdk_py/models/new_managed_user.py +91 -0
- api_sdk_py/models/new_widget.py +118 -0
- api_sdk_py/models/operations_id_get_response.py +99 -0
- api_sdk_py/models/operations_id_get_response_data.py +113 -0
- api_sdk_py/models/partner_analytics_by_managed_user.py +109 -0
- api_sdk_py/models/partner_analytics_by_managed_user_response.py +99 -0
- api_sdk_py/models/partner_analytics_of_day.py +94 -0
- api_sdk_py/models/partner_analytics_of_managed_user.py +126 -0
- api_sdk_py/models/partner_analytics_of_widget.py +102 -0
- api_sdk_py/models/partner_analytics_summary.py +110 -0
- api_sdk_py/models/partner_analytics_summary_response.py +99 -0
- api_sdk_py/models/partner_analytics_timeline.py +110 -0
- api_sdk_py/models/partner_analytics_timeline_response.py +99 -0
- api_sdk_py/models/partner_analytics_top_widgets.py +110 -0
- api_sdk_py/models/partner_analytics_top_widgets_response.py +99 -0
- api_sdk_py/models/partner_billing_overview.py +114 -0
- api_sdk_py/models/partner_billing_overview_billing_integration.py +100 -0
- api_sdk_py/models/partner_billing_overview_operational_credits.py +101 -0
- api_sdk_py/models/partner_billing_overview_partner.py +100 -0
- api_sdk_py/models/partner_contract.py +158 -0
- api_sdk_py/models/partner_contract_response.py +99 -0
- api_sdk_py/models/partner_customization.py +140 -0
- api_sdk_py/models/partner_data_database.py +112 -0
- api_sdk_py/models/partner_data_database_removal.py +87 -0
- api_sdk_py/models/partner_data_database_removal_response.py +99 -0
- api_sdk_py/models/partner_data_database_response.py +99 -0
- api_sdk_py/models/partner_entry_context_secret.py +93 -0
- api_sdk_py/models/partner_entry_context_secret_response.py +99 -0
- api_sdk_py/models/partner_entry_context_signing.py +108 -0
- api_sdk_py/models/partner_entry_context_signing_response.py +99 -0
- api_sdk_py/models/partner_extra_credits_invoice.py +130 -0
- api_sdk_py/models/partner_extra_credits_invoice_response.py +99 -0
- api_sdk_py/models/partner_invoice.py +234 -0
- api_sdk_py/models/partner_notification.py +108 -0
- api_sdk_py/models/partner_notification_default_recipients.py +89 -0
- api_sdk_py/models/partner_notification_delivery.py +170 -0
- api_sdk_py/models/partner_notification_delivery_log.py +95 -0
- api_sdk_py/models/partner_notification_delivery_log_response.py +99 -0
- api_sdk_py/models/partner_notification_delivery_response.py +99 -0
- api_sdk_py/models/partner_notification_event.py +112 -0
- api_sdk_py/models/partner_notification_event_type.py +51 -0
- api_sdk_py/models/partner_notification_page.py +103 -0
- api_sdk_py/models/partner_notification_page_response.py +99 -0
- api_sdk_py/models/partner_notification_settings.py +139 -0
- api_sdk_py/models/partner_notification_settings_change.py +98 -0
- api_sdk_py/models/partner_notification_settings_change_response.py +99 -0
- api_sdk_py/models/partner_notification_settings_response.py +99 -0
- api_sdk_py/models/partner_notification_test_event_request.py +88 -0
- api_sdk_py/models/partner_notification_test_event_result.py +98 -0
- api_sdk_py/models/partner_notification_test_event_result_response.py +99 -0
- api_sdk_py/models/partner_preset.py +119 -0
- api_sdk_py/models/partner_preset_copy.py +97 -0
- api_sdk_py/models/partner_preset_copy_response.py +99 -0
- api_sdk_py/models/partner_preset_removal.py +87 -0
- api_sdk_py/models/partner_preset_removal_response.py +99 -0
- api_sdk_py/models/partner_preset_response.py +99 -0
- api_sdk_py/models/partner_report_page.py +91 -0
- api_sdk_py/models/partner_report_period.py +90 -0
- api_sdk_py/models/partner_storage_destination.py +120 -0
- api_sdk_py/models/partner_storage_destination_response.py +99 -0
- api_sdk_py/models/partner_storage_removal.py +87 -0
- api_sdk_py/models/partner_storage_removal_response.py +99 -0
- api_sdk_py/models/partner_storage_usage.py +109 -0
- api_sdk_py/models/partner_storage_usage_of_managed_user.py +129 -0
- api_sdk_py/models/partner_storage_usage_response.py +99 -0
- api_sdk_py/models/partner_storage_usage_totals.py +93 -0
- api_sdk_py/models/personal_workspace_domain.py +96 -0
- api_sdk_py/models/personal_workspace_domain_result.py +93 -0
- api_sdk_py/models/personal_workspace_domain_result_response.py +99 -0
- api_sdk_py/models/post_public_composition_embed_status200_response.py +99 -0
- api_sdk_py/models/post_public_composition_embed_status200_response_data.py +97 -0
- api_sdk_py/models/post_public_composition_embed_status_request.py +88 -0
- api_sdk_py/models/public_adapter_call_error.py +93 -0
- api_sdk_py/models/public_adapter_call_request.py +113 -0
- api_sdk_py/models/public_adapter_call_result.py +93 -0
- api_sdk_py/models/public_adapter_call_result_data.py +87 -0
- api_sdk_py/models/public_adapter_file_result.py +93 -0
- api_sdk_py/models/public_adapter_file_result_data.py +91 -0
- api_sdk_py/models/public_adapter_file_result_data_file.py +108 -0
- api_sdk_py/models/public_composition_entry_created.py +93 -0
- api_sdk_py/models/public_composition_entry_created_data.py +92 -0
- api_sdk_py/models/public_composition_entry_request.py +101 -0
- api_sdk_py/models/public_embed_failure.py +105 -0
- api_sdk_py/models/public_embed_failure_details.py +112 -0
- api_sdk_py/models/public_embed_failure_error.py +98 -0
- api_sdk_py/models/purpose_storage_bucket.py +89 -0
- api_sdk_py/models/remove_ai_answers_knowledge_document200_response.py +99 -0
- api_sdk_py/models/remove_user_adapter_connection200_response.py +99 -0
- api_sdk_py/models/request_extra_credits.py +88 -0
- api_sdk_py/models/response_meta.py +121 -0
- api_sdk_py/models/revoke_managed_user_editor_sessions_response.py +99 -0
- api_sdk_py/models/revoke_managed_user_editor_sessions_response_data.py +87 -0
- api_sdk_py/models/set_adapter_connection_request.py +88 -0
- api_sdk_py/models/set_composition_data_source_request.py +90 -0
- api_sdk_py/models/set_dynamic_content_request.py +95 -0
- api_sdk_py/models/set_dynamic_content_response.py +99 -0
- api_sdk_py/models/set_dynamic_content_response_data.py +99 -0
- api_sdk_py/models/set_dynamic_content_response_data_validation_result.py +91 -0
- api_sdk_py/models/set_managed_user_limits_request.py +93 -0
- api_sdk_py/models/set_partner_data_database_request.py +87 -0
- api_sdk_py/models/set_partner_design_defaults_request.py +92 -0
- api_sdk_py/models/set_partner_preset_request.py +104 -0
- api_sdk_py/models/set_partner_storage_destination_request.py +101 -0
- api_sdk_py/models/set_user_adapter_connection200_response.py +99 -0
- api_sdk_py/models/success_response.py +95 -0
- api_sdk_py/models/update_canvas_request.py +96 -0
- api_sdk_py/models/update_composition.py +101 -0
- api_sdk_py/models/update_composition_status_request.py +94 -0
- api_sdk_py/models/update_domain_request.py +87 -0
- api_sdk_py/models/update_managed_user.py +91 -0
- api_sdk_py/models/update_partner_entry_context_signing_request.py +87 -0
- api_sdk_py/models/update_partner_notification_settings_request.py +110 -0
- api_sdk_py/models/update_user_api_key_request.py +90 -0
- api_sdk_py/models/upload.py +167 -0
- api_sdk_py/models/upload_limits.py +97 -0
- api_sdk_py/models/upload_limits_response.py +99 -0
- api_sdk_py/models/upload_response.py +99 -0
- api_sdk_py/models/uploads_get200_response.py +103 -0
- api_sdk_py/models/uploads_id_delete200_response.py +99 -0
- api_sdk_py/models/uploads_id_delete200_response_data.py +87 -0
- api_sdk_py/models/user_api_key.py +122 -0
- api_sdk_py/models/user_api_key_response.py +99 -0
- api_sdk_py/models/user_api_key_usage_log.py +107 -0
- api_sdk_py/models/validate_composition_content_response.py +99 -0
- api_sdk_py/models/validate_composition_content_response_data.py +108 -0
- api_sdk_py/models/validate_token200_response.py +99 -0
- api_sdk_py/models/validate_token200_response_data.py +106 -0
- api_sdk_py/models/widget.py +205 -0
- api_sdk_py/py.typed +0 -0
- api_sdk_py/rest.py +257 -0
- api_sdk_py-1.11.66.dist-info/METADATA +28 -0
- api_sdk_py-1.11.66.dist-info/RECORD +294 -0
- api_sdk_py-1.11.66.dist-info/WHEEL +5 -0
- api_sdk_py-1.11.66.dist-info/licenses/LICENSE +122 -0
- api_sdk_py-1.11.66.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,1605 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Widgetic API Gateway
|
|
5
|
+
|
|
6
|
+
API documentation for the Widgetic API Gateway
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
import warnings
|
|
15
|
+
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
|
|
16
|
+
from typing import Any, Dict, List, Optional, Tuple, Union
|
|
17
|
+
from typing_extensions import Annotated
|
|
18
|
+
|
|
19
|
+
from datetime import datetime
|
|
20
|
+
from pydantic import Field, StrictStr
|
|
21
|
+
from typing import Optional
|
|
22
|
+
from typing_extensions import Annotated
|
|
23
|
+
from api_sdk_py.models.canvas_response import CanvasResponse
|
|
24
|
+
from api_sdk_py.models.create_canvas_request import CreateCanvasRequest
|
|
25
|
+
from api_sdk_py.models.get_all_canvases_response import GetAllCanvasesResponse
|
|
26
|
+
from api_sdk_py.models.update_canvas_request import UpdateCanvasRequest
|
|
27
|
+
|
|
28
|
+
from api_sdk_py.api_client import ApiClient, RequestSerialized
|
|
29
|
+
from api_sdk_py.api_response import ApiResponse
|
|
30
|
+
from api_sdk_py.rest import RESTResponseType
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
class CanvasesApi:
|
|
34
|
+
"""NOTE: This class is auto generated by OpenAPI Generator
|
|
35
|
+
Ref: https://openapi-generator.tech
|
|
36
|
+
|
|
37
|
+
Do not edit the class manually.
|
|
38
|
+
"""
|
|
39
|
+
|
|
40
|
+
def __init__(self, api_client=None) -> None:
|
|
41
|
+
if api_client is None:
|
|
42
|
+
api_client = ApiClient.get_default()
|
|
43
|
+
self.api_client = api_client
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
@validate_call
|
|
47
|
+
def create_canvas_0(
|
|
48
|
+
self,
|
|
49
|
+
create_canvas_request: CreateCanvasRequest,
|
|
50
|
+
_request_timeout: Union[
|
|
51
|
+
None,
|
|
52
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
53
|
+
Tuple[
|
|
54
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
55
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
56
|
+
]
|
|
57
|
+
] = None,
|
|
58
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
59
|
+
_content_type: Optional[StrictStr] = None,
|
|
60
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
61
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
62
|
+
) -> CanvasResponse:
|
|
63
|
+
"""Create Canvas
|
|
64
|
+
|
|
65
|
+
Creates a new canvas with the specified properties. To make the canvas for one of your managed users, send `managedUserId` or `managedUserExternalId`. The canvas stays in your account and is yours to edit; the tag lets you list one user's canvases with `getAllCanvases`. The managed user must be yours and active: one that is not yours, or does not exist, is answered with 404 and `MANAGED_USER_NOT_FOUND`, and one that is switched off with 409 and `MANAGED_USER_INACTIVE`. The tag is set here and does not change afterwards. Called with an editor session, the canvas is always made for the session's managed user.
|
|
66
|
+
|
|
67
|
+
:param create_canvas_request: (required)
|
|
68
|
+
:type create_canvas_request: CreateCanvasRequest
|
|
69
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
70
|
+
number provided, it will be total request
|
|
71
|
+
timeout. It can also be a pair (tuple) of
|
|
72
|
+
(connection, read) timeouts.
|
|
73
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
74
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
75
|
+
request; this effectively ignores the
|
|
76
|
+
authentication in the spec for a single request.
|
|
77
|
+
:type _request_auth: dict, optional
|
|
78
|
+
:param _content_type: force content-type for the request.
|
|
79
|
+
:type _content_type: str, Optional
|
|
80
|
+
:param _headers: set to override the headers for a single
|
|
81
|
+
request; this effectively ignores the headers
|
|
82
|
+
in the spec for a single request.
|
|
83
|
+
:type _headers: dict, optional
|
|
84
|
+
:param _host_index: set to override the host_index for a single
|
|
85
|
+
request; this effectively ignores the host_index
|
|
86
|
+
in the spec for a single request.
|
|
87
|
+
:type _host_index: int, optional
|
|
88
|
+
:return: Returns the result object.
|
|
89
|
+
""" # noqa: E501
|
|
90
|
+
|
|
91
|
+
_param = self._create_canvas_0_serialize(
|
|
92
|
+
create_canvas_request=create_canvas_request,
|
|
93
|
+
_request_auth=_request_auth,
|
|
94
|
+
_content_type=_content_type,
|
|
95
|
+
_headers=_headers,
|
|
96
|
+
_host_index=_host_index
|
|
97
|
+
)
|
|
98
|
+
|
|
99
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
100
|
+
'201': "CanvasResponse",
|
|
101
|
+
'400': "ErrorResponse",
|
|
102
|
+
'401': "ErrorResponse",
|
|
103
|
+
'404': "ErrorResponse",
|
|
104
|
+
'409': "ErrorResponse",
|
|
105
|
+
}
|
|
106
|
+
response_data = self.api_client.call_api(
|
|
107
|
+
*_param,
|
|
108
|
+
_request_timeout=_request_timeout
|
|
109
|
+
)
|
|
110
|
+
response_data.read()
|
|
111
|
+
return self.api_client.response_deserialize(
|
|
112
|
+
response_data=response_data,
|
|
113
|
+
response_types_map=_response_types_map,
|
|
114
|
+
).data
|
|
115
|
+
|
|
116
|
+
|
|
117
|
+
@validate_call
|
|
118
|
+
def create_canvas_0_with_http_info(
|
|
119
|
+
self,
|
|
120
|
+
create_canvas_request: CreateCanvasRequest,
|
|
121
|
+
_request_timeout: Union[
|
|
122
|
+
None,
|
|
123
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
124
|
+
Tuple[
|
|
125
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
126
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
127
|
+
]
|
|
128
|
+
] = None,
|
|
129
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
130
|
+
_content_type: Optional[StrictStr] = None,
|
|
131
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
132
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
133
|
+
) -> ApiResponse[CanvasResponse]:
|
|
134
|
+
"""Create Canvas
|
|
135
|
+
|
|
136
|
+
Creates a new canvas with the specified properties. To make the canvas for one of your managed users, send `managedUserId` or `managedUserExternalId`. The canvas stays in your account and is yours to edit; the tag lets you list one user's canvases with `getAllCanvases`. The managed user must be yours and active: one that is not yours, or does not exist, is answered with 404 and `MANAGED_USER_NOT_FOUND`, and one that is switched off with 409 and `MANAGED_USER_INACTIVE`. The tag is set here and does not change afterwards. Called with an editor session, the canvas is always made for the session's managed user.
|
|
137
|
+
|
|
138
|
+
:param create_canvas_request: (required)
|
|
139
|
+
:type create_canvas_request: CreateCanvasRequest
|
|
140
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
141
|
+
number provided, it will be total request
|
|
142
|
+
timeout. It can also be a pair (tuple) of
|
|
143
|
+
(connection, read) timeouts.
|
|
144
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
145
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
146
|
+
request; this effectively ignores the
|
|
147
|
+
authentication in the spec for a single request.
|
|
148
|
+
:type _request_auth: dict, optional
|
|
149
|
+
:param _content_type: force content-type for the request.
|
|
150
|
+
:type _content_type: str, Optional
|
|
151
|
+
:param _headers: set to override the headers for a single
|
|
152
|
+
request; this effectively ignores the headers
|
|
153
|
+
in the spec for a single request.
|
|
154
|
+
:type _headers: dict, optional
|
|
155
|
+
:param _host_index: set to override the host_index for a single
|
|
156
|
+
request; this effectively ignores the host_index
|
|
157
|
+
in the spec for a single request.
|
|
158
|
+
:type _host_index: int, optional
|
|
159
|
+
:return: Returns the result object.
|
|
160
|
+
""" # noqa: E501
|
|
161
|
+
|
|
162
|
+
_param = self._create_canvas_0_serialize(
|
|
163
|
+
create_canvas_request=create_canvas_request,
|
|
164
|
+
_request_auth=_request_auth,
|
|
165
|
+
_content_type=_content_type,
|
|
166
|
+
_headers=_headers,
|
|
167
|
+
_host_index=_host_index
|
|
168
|
+
)
|
|
169
|
+
|
|
170
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
171
|
+
'201': "CanvasResponse",
|
|
172
|
+
'400': "ErrorResponse",
|
|
173
|
+
'401': "ErrorResponse",
|
|
174
|
+
'404': "ErrorResponse",
|
|
175
|
+
'409': "ErrorResponse",
|
|
176
|
+
}
|
|
177
|
+
response_data = self.api_client.call_api(
|
|
178
|
+
*_param,
|
|
179
|
+
_request_timeout=_request_timeout
|
|
180
|
+
)
|
|
181
|
+
response_data.read()
|
|
182
|
+
return self.api_client.response_deserialize(
|
|
183
|
+
response_data=response_data,
|
|
184
|
+
response_types_map=_response_types_map,
|
|
185
|
+
)
|
|
186
|
+
|
|
187
|
+
|
|
188
|
+
@validate_call
|
|
189
|
+
def create_canvas_0_without_preload_content(
|
|
190
|
+
self,
|
|
191
|
+
create_canvas_request: CreateCanvasRequest,
|
|
192
|
+
_request_timeout: Union[
|
|
193
|
+
None,
|
|
194
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
195
|
+
Tuple[
|
|
196
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
197
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
198
|
+
]
|
|
199
|
+
] = None,
|
|
200
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
201
|
+
_content_type: Optional[StrictStr] = None,
|
|
202
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
203
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
204
|
+
) -> RESTResponseType:
|
|
205
|
+
"""Create Canvas
|
|
206
|
+
|
|
207
|
+
Creates a new canvas with the specified properties. To make the canvas for one of your managed users, send `managedUserId` or `managedUserExternalId`. The canvas stays in your account and is yours to edit; the tag lets you list one user's canvases with `getAllCanvases`. The managed user must be yours and active: one that is not yours, or does not exist, is answered with 404 and `MANAGED_USER_NOT_FOUND`, and one that is switched off with 409 and `MANAGED_USER_INACTIVE`. The tag is set here and does not change afterwards. Called with an editor session, the canvas is always made for the session's managed user.
|
|
208
|
+
|
|
209
|
+
:param create_canvas_request: (required)
|
|
210
|
+
:type create_canvas_request: CreateCanvasRequest
|
|
211
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
212
|
+
number provided, it will be total request
|
|
213
|
+
timeout. It can also be a pair (tuple) of
|
|
214
|
+
(connection, read) timeouts.
|
|
215
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
216
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
217
|
+
request; this effectively ignores the
|
|
218
|
+
authentication in the spec for a single request.
|
|
219
|
+
:type _request_auth: dict, optional
|
|
220
|
+
:param _content_type: force content-type for the request.
|
|
221
|
+
:type _content_type: str, Optional
|
|
222
|
+
:param _headers: set to override the headers for a single
|
|
223
|
+
request; this effectively ignores the headers
|
|
224
|
+
in the spec for a single request.
|
|
225
|
+
:type _headers: dict, optional
|
|
226
|
+
:param _host_index: set to override the host_index for a single
|
|
227
|
+
request; this effectively ignores the host_index
|
|
228
|
+
in the spec for a single request.
|
|
229
|
+
:type _host_index: int, optional
|
|
230
|
+
:return: Returns the result object.
|
|
231
|
+
""" # noqa: E501
|
|
232
|
+
|
|
233
|
+
_param = self._create_canvas_0_serialize(
|
|
234
|
+
create_canvas_request=create_canvas_request,
|
|
235
|
+
_request_auth=_request_auth,
|
|
236
|
+
_content_type=_content_type,
|
|
237
|
+
_headers=_headers,
|
|
238
|
+
_host_index=_host_index
|
|
239
|
+
)
|
|
240
|
+
|
|
241
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
242
|
+
'201': "CanvasResponse",
|
|
243
|
+
'400': "ErrorResponse",
|
|
244
|
+
'401': "ErrorResponse",
|
|
245
|
+
'404': "ErrorResponse",
|
|
246
|
+
'409': "ErrorResponse",
|
|
247
|
+
}
|
|
248
|
+
response_data = self.api_client.call_api(
|
|
249
|
+
*_param,
|
|
250
|
+
_request_timeout=_request_timeout
|
|
251
|
+
)
|
|
252
|
+
return response_data.response
|
|
253
|
+
|
|
254
|
+
|
|
255
|
+
def _create_canvas_0_serialize(
|
|
256
|
+
self,
|
|
257
|
+
create_canvas_request,
|
|
258
|
+
_request_auth,
|
|
259
|
+
_content_type,
|
|
260
|
+
_headers,
|
|
261
|
+
_host_index,
|
|
262
|
+
) -> RequestSerialized:
|
|
263
|
+
|
|
264
|
+
_host = None
|
|
265
|
+
|
|
266
|
+
_collection_formats: Dict[str, str] = {
|
|
267
|
+
}
|
|
268
|
+
|
|
269
|
+
_path_params: Dict[str, str] = {}
|
|
270
|
+
_query_params: List[Tuple[str, str]] = []
|
|
271
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
272
|
+
_form_params: List[Tuple[str, str]] = []
|
|
273
|
+
_files: Dict[
|
|
274
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
275
|
+
] = {}
|
|
276
|
+
_body_params: Optional[bytes] = None
|
|
277
|
+
|
|
278
|
+
# process the path parameters
|
|
279
|
+
# process the query parameters
|
|
280
|
+
# process the header parameters
|
|
281
|
+
# process the form parameters
|
|
282
|
+
# process the body parameter
|
|
283
|
+
if create_canvas_request is not None:
|
|
284
|
+
_body_params = create_canvas_request
|
|
285
|
+
|
|
286
|
+
|
|
287
|
+
# set the HTTP header `Accept`
|
|
288
|
+
if 'Accept' not in _header_params:
|
|
289
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
290
|
+
[
|
|
291
|
+
'application/json'
|
|
292
|
+
]
|
|
293
|
+
)
|
|
294
|
+
|
|
295
|
+
# set the HTTP header `Content-Type`
|
|
296
|
+
if _content_type:
|
|
297
|
+
_header_params['Content-Type'] = _content_type
|
|
298
|
+
else:
|
|
299
|
+
_default_content_type = (
|
|
300
|
+
self.api_client.select_header_content_type(
|
|
301
|
+
[
|
|
302
|
+
'application/json'
|
|
303
|
+
]
|
|
304
|
+
)
|
|
305
|
+
)
|
|
306
|
+
if _default_content_type is not None:
|
|
307
|
+
_header_params['Content-Type'] = _default_content_type
|
|
308
|
+
|
|
309
|
+
# authentication setting
|
|
310
|
+
_auth_settings: List[str] = [
|
|
311
|
+
'apiKeyAuth'
|
|
312
|
+
]
|
|
313
|
+
|
|
314
|
+
return self.api_client.param_serialize(
|
|
315
|
+
method='POST',
|
|
316
|
+
resource_path='/canvases',
|
|
317
|
+
path_params=_path_params,
|
|
318
|
+
query_params=_query_params,
|
|
319
|
+
header_params=_header_params,
|
|
320
|
+
body=_body_params,
|
|
321
|
+
post_params=_form_params,
|
|
322
|
+
files=_files,
|
|
323
|
+
auth_settings=_auth_settings,
|
|
324
|
+
collection_formats=_collection_formats,
|
|
325
|
+
_host=_host,
|
|
326
|
+
_request_auth=_request_auth
|
|
327
|
+
)
|
|
328
|
+
|
|
329
|
+
|
|
330
|
+
|
|
331
|
+
|
|
332
|
+
@validate_call
|
|
333
|
+
def delete_canvas_0(
|
|
334
|
+
self,
|
|
335
|
+
id: Annotated[StrictStr, Field(description="ID of the canvas")],
|
|
336
|
+
_request_timeout: Union[
|
|
337
|
+
None,
|
|
338
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
339
|
+
Tuple[
|
|
340
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
341
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
342
|
+
]
|
|
343
|
+
] = None,
|
|
344
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
345
|
+
_content_type: Optional[StrictStr] = None,
|
|
346
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
347
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
348
|
+
) -> CanvasResponse:
|
|
349
|
+
"""Delete Canvas
|
|
350
|
+
|
|
351
|
+
Deletes a canvas together with every widget on it. Called with an editor session, only a canvas whose widgets were all made for the session's managed user can be deleted; one that also holds somebody else's widgets is refused with 409 and `CANVAS_HAS_OTHER_WIDGETS`, and nothing is deleted. Delete such a canvas with your API key.
|
|
352
|
+
|
|
353
|
+
:param id: ID of the canvas (required)
|
|
354
|
+
:type id: str
|
|
355
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
356
|
+
number provided, it will be total request
|
|
357
|
+
timeout. It can also be a pair (tuple) of
|
|
358
|
+
(connection, read) timeouts.
|
|
359
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
360
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
361
|
+
request; this effectively ignores the
|
|
362
|
+
authentication in the spec for a single request.
|
|
363
|
+
:type _request_auth: dict, optional
|
|
364
|
+
:param _content_type: force content-type for the request.
|
|
365
|
+
:type _content_type: str, Optional
|
|
366
|
+
:param _headers: set to override the headers for a single
|
|
367
|
+
request; this effectively ignores the headers
|
|
368
|
+
in the spec for a single request.
|
|
369
|
+
:type _headers: dict, optional
|
|
370
|
+
:param _host_index: set to override the host_index for a single
|
|
371
|
+
request; this effectively ignores the host_index
|
|
372
|
+
in the spec for a single request.
|
|
373
|
+
:type _host_index: int, optional
|
|
374
|
+
:return: Returns the result object.
|
|
375
|
+
""" # noqa: E501
|
|
376
|
+
|
|
377
|
+
_param = self._delete_canvas_0_serialize(
|
|
378
|
+
id=id,
|
|
379
|
+
_request_auth=_request_auth,
|
|
380
|
+
_content_type=_content_type,
|
|
381
|
+
_headers=_headers,
|
|
382
|
+
_host_index=_host_index
|
|
383
|
+
)
|
|
384
|
+
|
|
385
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
386
|
+
'200': "CanvasResponse",
|
|
387
|
+
'401': "ErrorResponse",
|
|
388
|
+
'404': "ErrorResponse",
|
|
389
|
+
'409': "ErrorResponse",
|
|
390
|
+
}
|
|
391
|
+
response_data = self.api_client.call_api(
|
|
392
|
+
*_param,
|
|
393
|
+
_request_timeout=_request_timeout
|
|
394
|
+
)
|
|
395
|
+
response_data.read()
|
|
396
|
+
return self.api_client.response_deserialize(
|
|
397
|
+
response_data=response_data,
|
|
398
|
+
response_types_map=_response_types_map,
|
|
399
|
+
).data
|
|
400
|
+
|
|
401
|
+
|
|
402
|
+
@validate_call
|
|
403
|
+
def delete_canvas_0_with_http_info(
|
|
404
|
+
self,
|
|
405
|
+
id: Annotated[StrictStr, Field(description="ID of the canvas")],
|
|
406
|
+
_request_timeout: Union[
|
|
407
|
+
None,
|
|
408
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
409
|
+
Tuple[
|
|
410
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
411
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
412
|
+
]
|
|
413
|
+
] = None,
|
|
414
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
415
|
+
_content_type: Optional[StrictStr] = None,
|
|
416
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
417
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
418
|
+
) -> ApiResponse[CanvasResponse]:
|
|
419
|
+
"""Delete Canvas
|
|
420
|
+
|
|
421
|
+
Deletes a canvas together with every widget on it. Called with an editor session, only a canvas whose widgets were all made for the session's managed user can be deleted; one that also holds somebody else's widgets is refused with 409 and `CANVAS_HAS_OTHER_WIDGETS`, and nothing is deleted. Delete such a canvas with your API key.
|
|
422
|
+
|
|
423
|
+
:param id: ID of the canvas (required)
|
|
424
|
+
:type id: str
|
|
425
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
426
|
+
number provided, it will be total request
|
|
427
|
+
timeout. It can also be a pair (tuple) of
|
|
428
|
+
(connection, read) timeouts.
|
|
429
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
430
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
431
|
+
request; this effectively ignores the
|
|
432
|
+
authentication in the spec for a single request.
|
|
433
|
+
:type _request_auth: dict, optional
|
|
434
|
+
:param _content_type: force content-type for the request.
|
|
435
|
+
:type _content_type: str, Optional
|
|
436
|
+
:param _headers: set to override the headers for a single
|
|
437
|
+
request; this effectively ignores the headers
|
|
438
|
+
in the spec for a single request.
|
|
439
|
+
:type _headers: dict, optional
|
|
440
|
+
:param _host_index: set to override the host_index for a single
|
|
441
|
+
request; this effectively ignores the host_index
|
|
442
|
+
in the spec for a single request.
|
|
443
|
+
:type _host_index: int, optional
|
|
444
|
+
:return: Returns the result object.
|
|
445
|
+
""" # noqa: E501
|
|
446
|
+
|
|
447
|
+
_param = self._delete_canvas_0_serialize(
|
|
448
|
+
id=id,
|
|
449
|
+
_request_auth=_request_auth,
|
|
450
|
+
_content_type=_content_type,
|
|
451
|
+
_headers=_headers,
|
|
452
|
+
_host_index=_host_index
|
|
453
|
+
)
|
|
454
|
+
|
|
455
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
456
|
+
'200': "CanvasResponse",
|
|
457
|
+
'401': "ErrorResponse",
|
|
458
|
+
'404': "ErrorResponse",
|
|
459
|
+
'409': "ErrorResponse",
|
|
460
|
+
}
|
|
461
|
+
response_data = self.api_client.call_api(
|
|
462
|
+
*_param,
|
|
463
|
+
_request_timeout=_request_timeout
|
|
464
|
+
)
|
|
465
|
+
response_data.read()
|
|
466
|
+
return self.api_client.response_deserialize(
|
|
467
|
+
response_data=response_data,
|
|
468
|
+
response_types_map=_response_types_map,
|
|
469
|
+
)
|
|
470
|
+
|
|
471
|
+
|
|
472
|
+
@validate_call
|
|
473
|
+
def delete_canvas_0_without_preload_content(
|
|
474
|
+
self,
|
|
475
|
+
id: Annotated[StrictStr, Field(description="ID of the canvas")],
|
|
476
|
+
_request_timeout: Union[
|
|
477
|
+
None,
|
|
478
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
479
|
+
Tuple[
|
|
480
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
481
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
482
|
+
]
|
|
483
|
+
] = None,
|
|
484
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
485
|
+
_content_type: Optional[StrictStr] = None,
|
|
486
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
487
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
488
|
+
) -> RESTResponseType:
|
|
489
|
+
"""Delete Canvas
|
|
490
|
+
|
|
491
|
+
Deletes a canvas together with every widget on it. Called with an editor session, only a canvas whose widgets were all made for the session's managed user can be deleted; one that also holds somebody else's widgets is refused with 409 and `CANVAS_HAS_OTHER_WIDGETS`, and nothing is deleted. Delete such a canvas with your API key.
|
|
492
|
+
|
|
493
|
+
:param id: ID of the canvas (required)
|
|
494
|
+
:type id: str
|
|
495
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
496
|
+
number provided, it will be total request
|
|
497
|
+
timeout. It can also be a pair (tuple) of
|
|
498
|
+
(connection, read) timeouts.
|
|
499
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
500
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
501
|
+
request; this effectively ignores the
|
|
502
|
+
authentication in the spec for a single request.
|
|
503
|
+
:type _request_auth: dict, optional
|
|
504
|
+
:param _content_type: force content-type for the request.
|
|
505
|
+
:type _content_type: str, Optional
|
|
506
|
+
:param _headers: set to override the headers for a single
|
|
507
|
+
request; this effectively ignores the headers
|
|
508
|
+
in the spec for a single request.
|
|
509
|
+
:type _headers: dict, optional
|
|
510
|
+
:param _host_index: set to override the host_index for a single
|
|
511
|
+
request; this effectively ignores the host_index
|
|
512
|
+
in the spec for a single request.
|
|
513
|
+
:type _host_index: int, optional
|
|
514
|
+
:return: Returns the result object.
|
|
515
|
+
""" # noqa: E501
|
|
516
|
+
|
|
517
|
+
_param = self._delete_canvas_0_serialize(
|
|
518
|
+
id=id,
|
|
519
|
+
_request_auth=_request_auth,
|
|
520
|
+
_content_type=_content_type,
|
|
521
|
+
_headers=_headers,
|
|
522
|
+
_host_index=_host_index
|
|
523
|
+
)
|
|
524
|
+
|
|
525
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
526
|
+
'200': "CanvasResponse",
|
|
527
|
+
'401': "ErrorResponse",
|
|
528
|
+
'404': "ErrorResponse",
|
|
529
|
+
'409': "ErrorResponse",
|
|
530
|
+
}
|
|
531
|
+
response_data = self.api_client.call_api(
|
|
532
|
+
*_param,
|
|
533
|
+
_request_timeout=_request_timeout
|
|
534
|
+
)
|
|
535
|
+
return response_data.response
|
|
536
|
+
|
|
537
|
+
|
|
538
|
+
def _delete_canvas_0_serialize(
|
|
539
|
+
self,
|
|
540
|
+
id,
|
|
541
|
+
_request_auth,
|
|
542
|
+
_content_type,
|
|
543
|
+
_headers,
|
|
544
|
+
_host_index,
|
|
545
|
+
) -> RequestSerialized:
|
|
546
|
+
|
|
547
|
+
_host = None
|
|
548
|
+
|
|
549
|
+
_collection_formats: Dict[str, str] = {
|
|
550
|
+
}
|
|
551
|
+
|
|
552
|
+
_path_params: Dict[str, str] = {}
|
|
553
|
+
_query_params: List[Tuple[str, str]] = []
|
|
554
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
555
|
+
_form_params: List[Tuple[str, str]] = []
|
|
556
|
+
_files: Dict[
|
|
557
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
558
|
+
] = {}
|
|
559
|
+
_body_params: Optional[bytes] = None
|
|
560
|
+
|
|
561
|
+
# process the path parameters
|
|
562
|
+
if id is not None:
|
|
563
|
+
_path_params['id'] = id
|
|
564
|
+
# process the query parameters
|
|
565
|
+
# process the header parameters
|
|
566
|
+
# process the form parameters
|
|
567
|
+
# process the body parameter
|
|
568
|
+
|
|
569
|
+
|
|
570
|
+
# set the HTTP header `Accept`
|
|
571
|
+
if 'Accept' not in _header_params:
|
|
572
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
573
|
+
[
|
|
574
|
+
'application/json'
|
|
575
|
+
]
|
|
576
|
+
)
|
|
577
|
+
|
|
578
|
+
|
|
579
|
+
# authentication setting
|
|
580
|
+
_auth_settings: List[str] = [
|
|
581
|
+
'apiKeyAuth'
|
|
582
|
+
]
|
|
583
|
+
|
|
584
|
+
return self.api_client.param_serialize(
|
|
585
|
+
method='DELETE',
|
|
586
|
+
resource_path='/canvases/{id}',
|
|
587
|
+
path_params=_path_params,
|
|
588
|
+
query_params=_query_params,
|
|
589
|
+
header_params=_header_params,
|
|
590
|
+
body=_body_params,
|
|
591
|
+
post_params=_form_params,
|
|
592
|
+
files=_files,
|
|
593
|
+
auth_settings=_auth_settings,
|
|
594
|
+
collection_formats=_collection_formats,
|
|
595
|
+
_host=_host,
|
|
596
|
+
_request_auth=_request_auth
|
|
597
|
+
)
|
|
598
|
+
|
|
599
|
+
|
|
600
|
+
|
|
601
|
+
|
|
602
|
+
@validate_call
|
|
603
|
+
def get_all_canvases_0(
|
|
604
|
+
self,
|
|
605
|
+
page: Annotated[Optional[Annotated[int, Field(strict=True, ge=1)]], Field(description="Page number for pagination")] = None,
|
|
606
|
+
size: Annotated[Optional[Annotated[int, Field(le=100, strict=True, ge=1)]], Field(description="Number of items per page")] = None,
|
|
607
|
+
sort: Annotated[Optional[StrictStr], Field(description="Sort field and direction (e.g., \"created_at:desc\")")] = None,
|
|
608
|
+
created_after: Annotated[Optional[datetime], Field(description="Filter canvases created after the specified date (ISO 8601 format)")] = None,
|
|
609
|
+
created_before: Annotated[Optional[datetime], Field(description="Filter canvases created before the specified date (ISO 8601 format)")] = None,
|
|
610
|
+
updated_after: Annotated[Optional[datetime], Field(description="Filter canvases updated after the specified date (ISO 8601 format)")] = None,
|
|
611
|
+
updated_before: Annotated[Optional[datetime], Field(description="Filter canvases updated before the specified date (ISO 8601 format)")] = None,
|
|
612
|
+
managed_user_id: Annotated[Optional[StrictStr], Field(description="List only the canvases made for this managed user (Widgetic's id for the user). Send this or `managedUserExternalId`, not both.")] = None,
|
|
613
|
+
managed_user_external_id: Annotated[Optional[Annotated[str, Field(strict=True, max_length=255)]], Field(description="List only the canvases made for the managed user you registered with this `externalId` (your own identifier for the user). Send this or `managedUserId`, not both.")] = None,
|
|
614
|
+
_request_timeout: Union[
|
|
615
|
+
None,
|
|
616
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
617
|
+
Tuple[
|
|
618
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
619
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
620
|
+
]
|
|
621
|
+
] = None,
|
|
622
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
623
|
+
_content_type: Optional[StrictStr] = None,
|
|
624
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
625
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
626
|
+
) -> GetAllCanvasesResponse:
|
|
627
|
+
"""Get All Canvases
|
|
628
|
+
|
|
629
|
+
Retrieves all canvases with pagination support and filtering options. Pass `managedUserId` (Widgetic's id for one of your managed users) or `managedUserExternalId` (your own identifier for the user) to list only the canvases made for that managed user. The canvases of your other managed users, and your own, are left out. A managed user that is not yours, or does not exist, is answered with 404 and `MANAGED_USER_NOT_FOUND`. Called with an editor session, the list is always the session's managed user's.
|
|
630
|
+
|
|
631
|
+
:param page: Page number for pagination
|
|
632
|
+
:type page: int
|
|
633
|
+
:param size: Number of items per page
|
|
634
|
+
:type size: int
|
|
635
|
+
:param sort: Sort field and direction (e.g., \"created_at:desc\")
|
|
636
|
+
:type sort: str
|
|
637
|
+
:param created_after: Filter canvases created after the specified date (ISO 8601 format)
|
|
638
|
+
:type created_after: datetime
|
|
639
|
+
:param created_before: Filter canvases created before the specified date (ISO 8601 format)
|
|
640
|
+
:type created_before: datetime
|
|
641
|
+
:param updated_after: Filter canvases updated after the specified date (ISO 8601 format)
|
|
642
|
+
:type updated_after: datetime
|
|
643
|
+
:param updated_before: Filter canvases updated before the specified date (ISO 8601 format)
|
|
644
|
+
:type updated_before: datetime
|
|
645
|
+
:param managed_user_id: List only the canvases made for this managed user (Widgetic's id for the user). Send this or `managedUserExternalId`, not both.
|
|
646
|
+
:type managed_user_id: str
|
|
647
|
+
:param managed_user_external_id: List only the canvases made for the managed user you registered with this `externalId` (your own identifier for the user). Send this or `managedUserId`, not both.
|
|
648
|
+
:type managed_user_external_id: str
|
|
649
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
650
|
+
number provided, it will be total request
|
|
651
|
+
timeout. It can also be a pair (tuple) of
|
|
652
|
+
(connection, read) timeouts.
|
|
653
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
654
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
655
|
+
request; this effectively ignores the
|
|
656
|
+
authentication in the spec for a single request.
|
|
657
|
+
:type _request_auth: dict, optional
|
|
658
|
+
:param _content_type: force content-type for the request.
|
|
659
|
+
:type _content_type: str, Optional
|
|
660
|
+
:param _headers: set to override the headers for a single
|
|
661
|
+
request; this effectively ignores the headers
|
|
662
|
+
in the spec for a single request.
|
|
663
|
+
:type _headers: dict, optional
|
|
664
|
+
:param _host_index: set to override the host_index for a single
|
|
665
|
+
request; this effectively ignores the host_index
|
|
666
|
+
in the spec for a single request.
|
|
667
|
+
:type _host_index: int, optional
|
|
668
|
+
:return: Returns the result object.
|
|
669
|
+
""" # noqa: E501
|
|
670
|
+
|
|
671
|
+
_param = self._get_all_canvases_0_serialize(
|
|
672
|
+
page=page,
|
|
673
|
+
size=size,
|
|
674
|
+
sort=sort,
|
|
675
|
+
created_after=created_after,
|
|
676
|
+
created_before=created_before,
|
|
677
|
+
updated_after=updated_after,
|
|
678
|
+
updated_before=updated_before,
|
|
679
|
+
managed_user_id=managed_user_id,
|
|
680
|
+
managed_user_external_id=managed_user_external_id,
|
|
681
|
+
_request_auth=_request_auth,
|
|
682
|
+
_content_type=_content_type,
|
|
683
|
+
_headers=_headers,
|
|
684
|
+
_host_index=_host_index
|
|
685
|
+
)
|
|
686
|
+
|
|
687
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
688
|
+
'200': "GetAllCanvasesResponse",
|
|
689
|
+
'400': "ErrorResponse",
|
|
690
|
+
'401': "ErrorResponse",
|
|
691
|
+
'404': "ErrorResponse",
|
|
692
|
+
}
|
|
693
|
+
response_data = self.api_client.call_api(
|
|
694
|
+
*_param,
|
|
695
|
+
_request_timeout=_request_timeout
|
|
696
|
+
)
|
|
697
|
+
response_data.read()
|
|
698
|
+
return self.api_client.response_deserialize(
|
|
699
|
+
response_data=response_data,
|
|
700
|
+
response_types_map=_response_types_map,
|
|
701
|
+
).data
|
|
702
|
+
|
|
703
|
+
|
|
704
|
+
@validate_call
|
|
705
|
+
def get_all_canvases_0_with_http_info(
|
|
706
|
+
self,
|
|
707
|
+
page: Annotated[Optional[Annotated[int, Field(strict=True, ge=1)]], Field(description="Page number for pagination")] = None,
|
|
708
|
+
size: Annotated[Optional[Annotated[int, Field(le=100, strict=True, ge=1)]], Field(description="Number of items per page")] = None,
|
|
709
|
+
sort: Annotated[Optional[StrictStr], Field(description="Sort field and direction (e.g., \"created_at:desc\")")] = None,
|
|
710
|
+
created_after: Annotated[Optional[datetime], Field(description="Filter canvases created after the specified date (ISO 8601 format)")] = None,
|
|
711
|
+
created_before: Annotated[Optional[datetime], Field(description="Filter canvases created before the specified date (ISO 8601 format)")] = None,
|
|
712
|
+
updated_after: Annotated[Optional[datetime], Field(description="Filter canvases updated after the specified date (ISO 8601 format)")] = None,
|
|
713
|
+
updated_before: Annotated[Optional[datetime], Field(description="Filter canvases updated before the specified date (ISO 8601 format)")] = None,
|
|
714
|
+
managed_user_id: Annotated[Optional[StrictStr], Field(description="List only the canvases made for this managed user (Widgetic's id for the user). Send this or `managedUserExternalId`, not both.")] = None,
|
|
715
|
+
managed_user_external_id: Annotated[Optional[Annotated[str, Field(strict=True, max_length=255)]], Field(description="List only the canvases made for the managed user you registered with this `externalId` (your own identifier for the user). Send this or `managedUserId`, not both.")] = None,
|
|
716
|
+
_request_timeout: Union[
|
|
717
|
+
None,
|
|
718
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
719
|
+
Tuple[
|
|
720
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
721
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
722
|
+
]
|
|
723
|
+
] = None,
|
|
724
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
725
|
+
_content_type: Optional[StrictStr] = None,
|
|
726
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
727
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
728
|
+
) -> ApiResponse[GetAllCanvasesResponse]:
|
|
729
|
+
"""Get All Canvases
|
|
730
|
+
|
|
731
|
+
Retrieves all canvases with pagination support and filtering options. Pass `managedUserId` (Widgetic's id for one of your managed users) or `managedUserExternalId` (your own identifier for the user) to list only the canvases made for that managed user. The canvases of your other managed users, and your own, are left out. A managed user that is not yours, or does not exist, is answered with 404 and `MANAGED_USER_NOT_FOUND`. Called with an editor session, the list is always the session's managed user's.
|
|
732
|
+
|
|
733
|
+
:param page: Page number for pagination
|
|
734
|
+
:type page: int
|
|
735
|
+
:param size: Number of items per page
|
|
736
|
+
:type size: int
|
|
737
|
+
:param sort: Sort field and direction (e.g., \"created_at:desc\")
|
|
738
|
+
:type sort: str
|
|
739
|
+
:param created_after: Filter canvases created after the specified date (ISO 8601 format)
|
|
740
|
+
:type created_after: datetime
|
|
741
|
+
:param created_before: Filter canvases created before the specified date (ISO 8601 format)
|
|
742
|
+
:type created_before: datetime
|
|
743
|
+
:param updated_after: Filter canvases updated after the specified date (ISO 8601 format)
|
|
744
|
+
:type updated_after: datetime
|
|
745
|
+
:param updated_before: Filter canvases updated before the specified date (ISO 8601 format)
|
|
746
|
+
:type updated_before: datetime
|
|
747
|
+
:param managed_user_id: List only the canvases made for this managed user (Widgetic's id for the user). Send this or `managedUserExternalId`, not both.
|
|
748
|
+
:type managed_user_id: str
|
|
749
|
+
:param managed_user_external_id: List only the canvases made for the managed user you registered with this `externalId` (your own identifier for the user). Send this or `managedUserId`, not both.
|
|
750
|
+
:type managed_user_external_id: str
|
|
751
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
752
|
+
number provided, it will be total request
|
|
753
|
+
timeout. It can also be a pair (tuple) of
|
|
754
|
+
(connection, read) timeouts.
|
|
755
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
756
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
757
|
+
request; this effectively ignores the
|
|
758
|
+
authentication in the spec for a single request.
|
|
759
|
+
:type _request_auth: dict, optional
|
|
760
|
+
:param _content_type: force content-type for the request.
|
|
761
|
+
:type _content_type: str, Optional
|
|
762
|
+
:param _headers: set to override the headers for a single
|
|
763
|
+
request; this effectively ignores the headers
|
|
764
|
+
in the spec for a single request.
|
|
765
|
+
:type _headers: dict, optional
|
|
766
|
+
:param _host_index: set to override the host_index for a single
|
|
767
|
+
request; this effectively ignores the host_index
|
|
768
|
+
in the spec for a single request.
|
|
769
|
+
:type _host_index: int, optional
|
|
770
|
+
:return: Returns the result object.
|
|
771
|
+
""" # noqa: E501
|
|
772
|
+
|
|
773
|
+
_param = self._get_all_canvases_0_serialize(
|
|
774
|
+
page=page,
|
|
775
|
+
size=size,
|
|
776
|
+
sort=sort,
|
|
777
|
+
created_after=created_after,
|
|
778
|
+
created_before=created_before,
|
|
779
|
+
updated_after=updated_after,
|
|
780
|
+
updated_before=updated_before,
|
|
781
|
+
managed_user_id=managed_user_id,
|
|
782
|
+
managed_user_external_id=managed_user_external_id,
|
|
783
|
+
_request_auth=_request_auth,
|
|
784
|
+
_content_type=_content_type,
|
|
785
|
+
_headers=_headers,
|
|
786
|
+
_host_index=_host_index
|
|
787
|
+
)
|
|
788
|
+
|
|
789
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
790
|
+
'200': "GetAllCanvasesResponse",
|
|
791
|
+
'400': "ErrorResponse",
|
|
792
|
+
'401': "ErrorResponse",
|
|
793
|
+
'404': "ErrorResponse",
|
|
794
|
+
}
|
|
795
|
+
response_data = self.api_client.call_api(
|
|
796
|
+
*_param,
|
|
797
|
+
_request_timeout=_request_timeout
|
|
798
|
+
)
|
|
799
|
+
response_data.read()
|
|
800
|
+
return self.api_client.response_deserialize(
|
|
801
|
+
response_data=response_data,
|
|
802
|
+
response_types_map=_response_types_map,
|
|
803
|
+
)
|
|
804
|
+
|
|
805
|
+
|
|
806
|
+
@validate_call
|
|
807
|
+
def get_all_canvases_0_without_preload_content(
|
|
808
|
+
self,
|
|
809
|
+
page: Annotated[Optional[Annotated[int, Field(strict=True, ge=1)]], Field(description="Page number for pagination")] = None,
|
|
810
|
+
size: Annotated[Optional[Annotated[int, Field(le=100, strict=True, ge=1)]], Field(description="Number of items per page")] = None,
|
|
811
|
+
sort: Annotated[Optional[StrictStr], Field(description="Sort field and direction (e.g., \"created_at:desc\")")] = None,
|
|
812
|
+
created_after: Annotated[Optional[datetime], Field(description="Filter canvases created after the specified date (ISO 8601 format)")] = None,
|
|
813
|
+
created_before: Annotated[Optional[datetime], Field(description="Filter canvases created before the specified date (ISO 8601 format)")] = None,
|
|
814
|
+
updated_after: Annotated[Optional[datetime], Field(description="Filter canvases updated after the specified date (ISO 8601 format)")] = None,
|
|
815
|
+
updated_before: Annotated[Optional[datetime], Field(description="Filter canvases updated before the specified date (ISO 8601 format)")] = None,
|
|
816
|
+
managed_user_id: Annotated[Optional[StrictStr], Field(description="List only the canvases made for this managed user (Widgetic's id for the user). Send this or `managedUserExternalId`, not both.")] = None,
|
|
817
|
+
managed_user_external_id: Annotated[Optional[Annotated[str, Field(strict=True, max_length=255)]], Field(description="List only the canvases made for the managed user you registered with this `externalId` (your own identifier for the user). Send this or `managedUserId`, not both.")] = None,
|
|
818
|
+
_request_timeout: Union[
|
|
819
|
+
None,
|
|
820
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
821
|
+
Tuple[
|
|
822
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
823
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
824
|
+
]
|
|
825
|
+
] = None,
|
|
826
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
827
|
+
_content_type: Optional[StrictStr] = None,
|
|
828
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
829
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
830
|
+
) -> RESTResponseType:
|
|
831
|
+
"""Get All Canvases
|
|
832
|
+
|
|
833
|
+
Retrieves all canvases with pagination support and filtering options. Pass `managedUserId` (Widgetic's id for one of your managed users) or `managedUserExternalId` (your own identifier for the user) to list only the canvases made for that managed user. The canvases of your other managed users, and your own, are left out. A managed user that is not yours, or does not exist, is answered with 404 and `MANAGED_USER_NOT_FOUND`. Called with an editor session, the list is always the session's managed user's.
|
|
834
|
+
|
|
835
|
+
:param page: Page number for pagination
|
|
836
|
+
:type page: int
|
|
837
|
+
:param size: Number of items per page
|
|
838
|
+
:type size: int
|
|
839
|
+
:param sort: Sort field and direction (e.g., \"created_at:desc\")
|
|
840
|
+
:type sort: str
|
|
841
|
+
:param created_after: Filter canvases created after the specified date (ISO 8601 format)
|
|
842
|
+
:type created_after: datetime
|
|
843
|
+
:param created_before: Filter canvases created before the specified date (ISO 8601 format)
|
|
844
|
+
:type created_before: datetime
|
|
845
|
+
:param updated_after: Filter canvases updated after the specified date (ISO 8601 format)
|
|
846
|
+
:type updated_after: datetime
|
|
847
|
+
:param updated_before: Filter canvases updated before the specified date (ISO 8601 format)
|
|
848
|
+
:type updated_before: datetime
|
|
849
|
+
:param managed_user_id: List only the canvases made for this managed user (Widgetic's id for the user). Send this or `managedUserExternalId`, not both.
|
|
850
|
+
:type managed_user_id: str
|
|
851
|
+
:param managed_user_external_id: List only the canvases made for the managed user you registered with this `externalId` (your own identifier for the user). Send this or `managedUserId`, not both.
|
|
852
|
+
:type managed_user_external_id: str
|
|
853
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
854
|
+
number provided, it will be total request
|
|
855
|
+
timeout. It can also be a pair (tuple) of
|
|
856
|
+
(connection, read) timeouts.
|
|
857
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
858
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
859
|
+
request; this effectively ignores the
|
|
860
|
+
authentication in the spec for a single request.
|
|
861
|
+
:type _request_auth: dict, optional
|
|
862
|
+
:param _content_type: force content-type for the request.
|
|
863
|
+
:type _content_type: str, Optional
|
|
864
|
+
:param _headers: set to override the headers for a single
|
|
865
|
+
request; this effectively ignores the headers
|
|
866
|
+
in the spec for a single request.
|
|
867
|
+
:type _headers: dict, optional
|
|
868
|
+
:param _host_index: set to override the host_index for a single
|
|
869
|
+
request; this effectively ignores the host_index
|
|
870
|
+
in the spec for a single request.
|
|
871
|
+
:type _host_index: int, optional
|
|
872
|
+
:return: Returns the result object.
|
|
873
|
+
""" # noqa: E501
|
|
874
|
+
|
|
875
|
+
_param = self._get_all_canvases_0_serialize(
|
|
876
|
+
page=page,
|
|
877
|
+
size=size,
|
|
878
|
+
sort=sort,
|
|
879
|
+
created_after=created_after,
|
|
880
|
+
created_before=created_before,
|
|
881
|
+
updated_after=updated_after,
|
|
882
|
+
updated_before=updated_before,
|
|
883
|
+
managed_user_id=managed_user_id,
|
|
884
|
+
managed_user_external_id=managed_user_external_id,
|
|
885
|
+
_request_auth=_request_auth,
|
|
886
|
+
_content_type=_content_type,
|
|
887
|
+
_headers=_headers,
|
|
888
|
+
_host_index=_host_index
|
|
889
|
+
)
|
|
890
|
+
|
|
891
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
892
|
+
'200': "GetAllCanvasesResponse",
|
|
893
|
+
'400': "ErrorResponse",
|
|
894
|
+
'401': "ErrorResponse",
|
|
895
|
+
'404': "ErrorResponse",
|
|
896
|
+
}
|
|
897
|
+
response_data = self.api_client.call_api(
|
|
898
|
+
*_param,
|
|
899
|
+
_request_timeout=_request_timeout
|
|
900
|
+
)
|
|
901
|
+
return response_data.response
|
|
902
|
+
|
|
903
|
+
|
|
904
|
+
def _get_all_canvases_0_serialize(
|
|
905
|
+
self,
|
|
906
|
+
page,
|
|
907
|
+
size,
|
|
908
|
+
sort,
|
|
909
|
+
created_after,
|
|
910
|
+
created_before,
|
|
911
|
+
updated_after,
|
|
912
|
+
updated_before,
|
|
913
|
+
managed_user_id,
|
|
914
|
+
managed_user_external_id,
|
|
915
|
+
_request_auth,
|
|
916
|
+
_content_type,
|
|
917
|
+
_headers,
|
|
918
|
+
_host_index,
|
|
919
|
+
) -> RequestSerialized:
|
|
920
|
+
|
|
921
|
+
_host = None
|
|
922
|
+
|
|
923
|
+
_collection_formats: Dict[str, str] = {
|
|
924
|
+
}
|
|
925
|
+
|
|
926
|
+
_path_params: Dict[str, str] = {}
|
|
927
|
+
_query_params: List[Tuple[str, str]] = []
|
|
928
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
929
|
+
_form_params: List[Tuple[str, str]] = []
|
|
930
|
+
_files: Dict[
|
|
931
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
932
|
+
] = {}
|
|
933
|
+
_body_params: Optional[bytes] = None
|
|
934
|
+
|
|
935
|
+
# process the path parameters
|
|
936
|
+
# process the query parameters
|
|
937
|
+
if page is not None:
|
|
938
|
+
|
|
939
|
+
_query_params.append(('page', page))
|
|
940
|
+
|
|
941
|
+
if size is not None:
|
|
942
|
+
|
|
943
|
+
_query_params.append(('size', size))
|
|
944
|
+
|
|
945
|
+
if sort is not None:
|
|
946
|
+
|
|
947
|
+
_query_params.append(('sort', sort))
|
|
948
|
+
|
|
949
|
+
if created_after is not None:
|
|
950
|
+
if isinstance(created_after, datetime):
|
|
951
|
+
_query_params.append(
|
|
952
|
+
(
|
|
953
|
+
'createdAfter',
|
|
954
|
+
created_after.strftime(
|
|
955
|
+
self.api_client.configuration.datetime_format
|
|
956
|
+
)
|
|
957
|
+
)
|
|
958
|
+
)
|
|
959
|
+
else:
|
|
960
|
+
_query_params.append(('createdAfter', created_after))
|
|
961
|
+
|
|
962
|
+
if created_before is not None:
|
|
963
|
+
if isinstance(created_before, datetime):
|
|
964
|
+
_query_params.append(
|
|
965
|
+
(
|
|
966
|
+
'createdBefore',
|
|
967
|
+
created_before.strftime(
|
|
968
|
+
self.api_client.configuration.datetime_format
|
|
969
|
+
)
|
|
970
|
+
)
|
|
971
|
+
)
|
|
972
|
+
else:
|
|
973
|
+
_query_params.append(('createdBefore', created_before))
|
|
974
|
+
|
|
975
|
+
if updated_after is not None:
|
|
976
|
+
if isinstance(updated_after, datetime):
|
|
977
|
+
_query_params.append(
|
|
978
|
+
(
|
|
979
|
+
'updatedAfter',
|
|
980
|
+
updated_after.strftime(
|
|
981
|
+
self.api_client.configuration.datetime_format
|
|
982
|
+
)
|
|
983
|
+
)
|
|
984
|
+
)
|
|
985
|
+
else:
|
|
986
|
+
_query_params.append(('updatedAfter', updated_after))
|
|
987
|
+
|
|
988
|
+
if updated_before is not None:
|
|
989
|
+
if isinstance(updated_before, datetime):
|
|
990
|
+
_query_params.append(
|
|
991
|
+
(
|
|
992
|
+
'updatedBefore',
|
|
993
|
+
updated_before.strftime(
|
|
994
|
+
self.api_client.configuration.datetime_format
|
|
995
|
+
)
|
|
996
|
+
)
|
|
997
|
+
)
|
|
998
|
+
else:
|
|
999
|
+
_query_params.append(('updatedBefore', updated_before))
|
|
1000
|
+
|
|
1001
|
+
if managed_user_id is not None:
|
|
1002
|
+
|
|
1003
|
+
_query_params.append(('managedUserId', managed_user_id))
|
|
1004
|
+
|
|
1005
|
+
if managed_user_external_id is not None:
|
|
1006
|
+
|
|
1007
|
+
_query_params.append(('managedUserExternalId', managed_user_external_id))
|
|
1008
|
+
|
|
1009
|
+
# process the header parameters
|
|
1010
|
+
# process the form parameters
|
|
1011
|
+
# process the body parameter
|
|
1012
|
+
|
|
1013
|
+
|
|
1014
|
+
# set the HTTP header `Accept`
|
|
1015
|
+
if 'Accept' not in _header_params:
|
|
1016
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
1017
|
+
[
|
|
1018
|
+
'application/json'
|
|
1019
|
+
]
|
|
1020
|
+
)
|
|
1021
|
+
|
|
1022
|
+
|
|
1023
|
+
# authentication setting
|
|
1024
|
+
_auth_settings: List[str] = [
|
|
1025
|
+
'apiKeyAuth'
|
|
1026
|
+
]
|
|
1027
|
+
|
|
1028
|
+
return self.api_client.param_serialize(
|
|
1029
|
+
method='GET',
|
|
1030
|
+
resource_path='/canvases',
|
|
1031
|
+
path_params=_path_params,
|
|
1032
|
+
query_params=_query_params,
|
|
1033
|
+
header_params=_header_params,
|
|
1034
|
+
body=_body_params,
|
|
1035
|
+
post_params=_form_params,
|
|
1036
|
+
files=_files,
|
|
1037
|
+
auth_settings=_auth_settings,
|
|
1038
|
+
collection_formats=_collection_formats,
|
|
1039
|
+
_host=_host,
|
|
1040
|
+
_request_auth=_request_auth
|
|
1041
|
+
)
|
|
1042
|
+
|
|
1043
|
+
|
|
1044
|
+
|
|
1045
|
+
|
|
1046
|
+
@validate_call
|
|
1047
|
+
def get_canvas_0(
|
|
1048
|
+
self,
|
|
1049
|
+
id: Annotated[StrictStr, Field(description="ID of the canvas")],
|
|
1050
|
+
_request_timeout: Union[
|
|
1051
|
+
None,
|
|
1052
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1053
|
+
Tuple[
|
|
1054
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1055
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1056
|
+
]
|
|
1057
|
+
] = None,
|
|
1058
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1059
|
+
_content_type: Optional[StrictStr] = None,
|
|
1060
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1061
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1062
|
+
) -> CanvasResponse:
|
|
1063
|
+
"""Get Canvas
|
|
1064
|
+
|
|
1065
|
+
Retrieves a specific canvas by ID.
|
|
1066
|
+
|
|
1067
|
+
:param id: ID of the canvas (required)
|
|
1068
|
+
:type id: str
|
|
1069
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1070
|
+
number provided, it will be total request
|
|
1071
|
+
timeout. It can also be a pair (tuple) of
|
|
1072
|
+
(connection, read) timeouts.
|
|
1073
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1074
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1075
|
+
request; this effectively ignores the
|
|
1076
|
+
authentication in the spec for a single request.
|
|
1077
|
+
:type _request_auth: dict, optional
|
|
1078
|
+
:param _content_type: force content-type for the request.
|
|
1079
|
+
:type _content_type: str, Optional
|
|
1080
|
+
:param _headers: set to override the headers for a single
|
|
1081
|
+
request; this effectively ignores the headers
|
|
1082
|
+
in the spec for a single request.
|
|
1083
|
+
:type _headers: dict, optional
|
|
1084
|
+
:param _host_index: set to override the host_index for a single
|
|
1085
|
+
request; this effectively ignores the host_index
|
|
1086
|
+
in the spec for a single request.
|
|
1087
|
+
:type _host_index: int, optional
|
|
1088
|
+
:return: Returns the result object.
|
|
1089
|
+
""" # noqa: E501
|
|
1090
|
+
|
|
1091
|
+
_param = self._get_canvas_0_serialize(
|
|
1092
|
+
id=id,
|
|
1093
|
+
_request_auth=_request_auth,
|
|
1094
|
+
_content_type=_content_type,
|
|
1095
|
+
_headers=_headers,
|
|
1096
|
+
_host_index=_host_index
|
|
1097
|
+
)
|
|
1098
|
+
|
|
1099
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1100
|
+
'200': "CanvasResponse",
|
|
1101
|
+
'401': "ErrorResponse",
|
|
1102
|
+
'404': "ErrorResponse",
|
|
1103
|
+
}
|
|
1104
|
+
response_data = self.api_client.call_api(
|
|
1105
|
+
*_param,
|
|
1106
|
+
_request_timeout=_request_timeout
|
|
1107
|
+
)
|
|
1108
|
+
response_data.read()
|
|
1109
|
+
return self.api_client.response_deserialize(
|
|
1110
|
+
response_data=response_data,
|
|
1111
|
+
response_types_map=_response_types_map,
|
|
1112
|
+
).data
|
|
1113
|
+
|
|
1114
|
+
|
|
1115
|
+
@validate_call
|
|
1116
|
+
def get_canvas_0_with_http_info(
|
|
1117
|
+
self,
|
|
1118
|
+
id: Annotated[StrictStr, Field(description="ID of the canvas")],
|
|
1119
|
+
_request_timeout: Union[
|
|
1120
|
+
None,
|
|
1121
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1122
|
+
Tuple[
|
|
1123
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1124
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1125
|
+
]
|
|
1126
|
+
] = None,
|
|
1127
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1128
|
+
_content_type: Optional[StrictStr] = None,
|
|
1129
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1130
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1131
|
+
) -> ApiResponse[CanvasResponse]:
|
|
1132
|
+
"""Get Canvas
|
|
1133
|
+
|
|
1134
|
+
Retrieves a specific canvas by ID.
|
|
1135
|
+
|
|
1136
|
+
:param id: ID of the canvas (required)
|
|
1137
|
+
:type id: str
|
|
1138
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1139
|
+
number provided, it will be total request
|
|
1140
|
+
timeout. It can also be a pair (tuple) of
|
|
1141
|
+
(connection, read) timeouts.
|
|
1142
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1143
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1144
|
+
request; this effectively ignores the
|
|
1145
|
+
authentication in the spec for a single request.
|
|
1146
|
+
:type _request_auth: dict, optional
|
|
1147
|
+
:param _content_type: force content-type for the request.
|
|
1148
|
+
:type _content_type: str, Optional
|
|
1149
|
+
:param _headers: set to override the headers for a single
|
|
1150
|
+
request; this effectively ignores the headers
|
|
1151
|
+
in the spec for a single request.
|
|
1152
|
+
:type _headers: dict, optional
|
|
1153
|
+
:param _host_index: set to override the host_index for a single
|
|
1154
|
+
request; this effectively ignores the host_index
|
|
1155
|
+
in the spec for a single request.
|
|
1156
|
+
:type _host_index: int, optional
|
|
1157
|
+
:return: Returns the result object.
|
|
1158
|
+
""" # noqa: E501
|
|
1159
|
+
|
|
1160
|
+
_param = self._get_canvas_0_serialize(
|
|
1161
|
+
id=id,
|
|
1162
|
+
_request_auth=_request_auth,
|
|
1163
|
+
_content_type=_content_type,
|
|
1164
|
+
_headers=_headers,
|
|
1165
|
+
_host_index=_host_index
|
|
1166
|
+
)
|
|
1167
|
+
|
|
1168
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1169
|
+
'200': "CanvasResponse",
|
|
1170
|
+
'401': "ErrorResponse",
|
|
1171
|
+
'404': "ErrorResponse",
|
|
1172
|
+
}
|
|
1173
|
+
response_data = self.api_client.call_api(
|
|
1174
|
+
*_param,
|
|
1175
|
+
_request_timeout=_request_timeout
|
|
1176
|
+
)
|
|
1177
|
+
response_data.read()
|
|
1178
|
+
return self.api_client.response_deserialize(
|
|
1179
|
+
response_data=response_data,
|
|
1180
|
+
response_types_map=_response_types_map,
|
|
1181
|
+
)
|
|
1182
|
+
|
|
1183
|
+
|
|
1184
|
+
@validate_call
|
|
1185
|
+
def get_canvas_0_without_preload_content(
|
|
1186
|
+
self,
|
|
1187
|
+
id: Annotated[StrictStr, Field(description="ID of the canvas")],
|
|
1188
|
+
_request_timeout: Union[
|
|
1189
|
+
None,
|
|
1190
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1191
|
+
Tuple[
|
|
1192
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1193
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1194
|
+
]
|
|
1195
|
+
] = None,
|
|
1196
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1197
|
+
_content_type: Optional[StrictStr] = None,
|
|
1198
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1199
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1200
|
+
) -> RESTResponseType:
|
|
1201
|
+
"""Get Canvas
|
|
1202
|
+
|
|
1203
|
+
Retrieves a specific canvas by ID.
|
|
1204
|
+
|
|
1205
|
+
:param id: ID of the canvas (required)
|
|
1206
|
+
:type id: str
|
|
1207
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1208
|
+
number provided, it will be total request
|
|
1209
|
+
timeout. It can also be a pair (tuple) of
|
|
1210
|
+
(connection, read) timeouts.
|
|
1211
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1212
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1213
|
+
request; this effectively ignores the
|
|
1214
|
+
authentication in the spec for a single request.
|
|
1215
|
+
:type _request_auth: dict, optional
|
|
1216
|
+
:param _content_type: force content-type for the request.
|
|
1217
|
+
:type _content_type: str, Optional
|
|
1218
|
+
:param _headers: set to override the headers for a single
|
|
1219
|
+
request; this effectively ignores the headers
|
|
1220
|
+
in the spec for a single request.
|
|
1221
|
+
:type _headers: dict, optional
|
|
1222
|
+
:param _host_index: set to override the host_index for a single
|
|
1223
|
+
request; this effectively ignores the host_index
|
|
1224
|
+
in the spec for a single request.
|
|
1225
|
+
:type _host_index: int, optional
|
|
1226
|
+
:return: Returns the result object.
|
|
1227
|
+
""" # noqa: E501
|
|
1228
|
+
|
|
1229
|
+
_param = self._get_canvas_0_serialize(
|
|
1230
|
+
id=id,
|
|
1231
|
+
_request_auth=_request_auth,
|
|
1232
|
+
_content_type=_content_type,
|
|
1233
|
+
_headers=_headers,
|
|
1234
|
+
_host_index=_host_index
|
|
1235
|
+
)
|
|
1236
|
+
|
|
1237
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1238
|
+
'200': "CanvasResponse",
|
|
1239
|
+
'401': "ErrorResponse",
|
|
1240
|
+
'404': "ErrorResponse",
|
|
1241
|
+
}
|
|
1242
|
+
response_data = self.api_client.call_api(
|
|
1243
|
+
*_param,
|
|
1244
|
+
_request_timeout=_request_timeout
|
|
1245
|
+
)
|
|
1246
|
+
return response_data.response
|
|
1247
|
+
|
|
1248
|
+
|
|
1249
|
+
def _get_canvas_0_serialize(
|
|
1250
|
+
self,
|
|
1251
|
+
id,
|
|
1252
|
+
_request_auth,
|
|
1253
|
+
_content_type,
|
|
1254
|
+
_headers,
|
|
1255
|
+
_host_index,
|
|
1256
|
+
) -> RequestSerialized:
|
|
1257
|
+
|
|
1258
|
+
_host = None
|
|
1259
|
+
|
|
1260
|
+
_collection_formats: Dict[str, str] = {
|
|
1261
|
+
}
|
|
1262
|
+
|
|
1263
|
+
_path_params: Dict[str, str] = {}
|
|
1264
|
+
_query_params: List[Tuple[str, str]] = []
|
|
1265
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
1266
|
+
_form_params: List[Tuple[str, str]] = []
|
|
1267
|
+
_files: Dict[
|
|
1268
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
1269
|
+
] = {}
|
|
1270
|
+
_body_params: Optional[bytes] = None
|
|
1271
|
+
|
|
1272
|
+
# process the path parameters
|
|
1273
|
+
if id is not None:
|
|
1274
|
+
_path_params['id'] = id
|
|
1275
|
+
# process the query parameters
|
|
1276
|
+
# process the header parameters
|
|
1277
|
+
# process the form parameters
|
|
1278
|
+
# process the body parameter
|
|
1279
|
+
|
|
1280
|
+
|
|
1281
|
+
# set the HTTP header `Accept`
|
|
1282
|
+
if 'Accept' not in _header_params:
|
|
1283
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
1284
|
+
[
|
|
1285
|
+
'application/json'
|
|
1286
|
+
]
|
|
1287
|
+
)
|
|
1288
|
+
|
|
1289
|
+
|
|
1290
|
+
# authentication setting
|
|
1291
|
+
_auth_settings: List[str] = [
|
|
1292
|
+
'apiKeyAuth'
|
|
1293
|
+
]
|
|
1294
|
+
|
|
1295
|
+
return self.api_client.param_serialize(
|
|
1296
|
+
method='GET',
|
|
1297
|
+
resource_path='/canvases/{id}',
|
|
1298
|
+
path_params=_path_params,
|
|
1299
|
+
query_params=_query_params,
|
|
1300
|
+
header_params=_header_params,
|
|
1301
|
+
body=_body_params,
|
|
1302
|
+
post_params=_form_params,
|
|
1303
|
+
files=_files,
|
|
1304
|
+
auth_settings=_auth_settings,
|
|
1305
|
+
collection_formats=_collection_formats,
|
|
1306
|
+
_host=_host,
|
|
1307
|
+
_request_auth=_request_auth
|
|
1308
|
+
)
|
|
1309
|
+
|
|
1310
|
+
|
|
1311
|
+
|
|
1312
|
+
|
|
1313
|
+
@validate_call
|
|
1314
|
+
def update_canvas_0(
|
|
1315
|
+
self,
|
|
1316
|
+
id: Annotated[StrictStr, Field(description="ID of the canvas to update")],
|
|
1317
|
+
update_canvas_request: UpdateCanvasRequest,
|
|
1318
|
+
_request_timeout: Union[
|
|
1319
|
+
None,
|
|
1320
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1321
|
+
Tuple[
|
|
1322
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1323
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1324
|
+
]
|
|
1325
|
+
] = None,
|
|
1326
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1327
|
+
_content_type: Optional[StrictStr] = None,
|
|
1328
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1329
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1330
|
+
) -> CanvasResponse:
|
|
1331
|
+
"""Update Canvas
|
|
1332
|
+
|
|
1333
|
+
Updates an existing canvas with the specified properties.
|
|
1334
|
+
|
|
1335
|
+
:param id: ID of the canvas to update (required)
|
|
1336
|
+
:type id: str
|
|
1337
|
+
:param update_canvas_request: (required)
|
|
1338
|
+
:type update_canvas_request: UpdateCanvasRequest
|
|
1339
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1340
|
+
number provided, it will be total request
|
|
1341
|
+
timeout. It can also be a pair (tuple) of
|
|
1342
|
+
(connection, read) timeouts.
|
|
1343
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1344
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1345
|
+
request; this effectively ignores the
|
|
1346
|
+
authentication in the spec for a single request.
|
|
1347
|
+
:type _request_auth: dict, optional
|
|
1348
|
+
:param _content_type: force content-type for the request.
|
|
1349
|
+
:type _content_type: str, Optional
|
|
1350
|
+
:param _headers: set to override the headers for a single
|
|
1351
|
+
request; this effectively ignores the headers
|
|
1352
|
+
in the spec for a single request.
|
|
1353
|
+
:type _headers: dict, optional
|
|
1354
|
+
:param _host_index: set to override the host_index for a single
|
|
1355
|
+
request; this effectively ignores the host_index
|
|
1356
|
+
in the spec for a single request.
|
|
1357
|
+
:type _host_index: int, optional
|
|
1358
|
+
:return: Returns the result object.
|
|
1359
|
+
""" # noqa: E501
|
|
1360
|
+
|
|
1361
|
+
_param = self._update_canvas_0_serialize(
|
|
1362
|
+
id=id,
|
|
1363
|
+
update_canvas_request=update_canvas_request,
|
|
1364
|
+
_request_auth=_request_auth,
|
|
1365
|
+
_content_type=_content_type,
|
|
1366
|
+
_headers=_headers,
|
|
1367
|
+
_host_index=_host_index
|
|
1368
|
+
)
|
|
1369
|
+
|
|
1370
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1371
|
+
'200': "CanvasResponse",
|
|
1372
|
+
'401': "ErrorResponse",
|
|
1373
|
+
'404': "ErrorResponse",
|
|
1374
|
+
}
|
|
1375
|
+
response_data = self.api_client.call_api(
|
|
1376
|
+
*_param,
|
|
1377
|
+
_request_timeout=_request_timeout
|
|
1378
|
+
)
|
|
1379
|
+
response_data.read()
|
|
1380
|
+
return self.api_client.response_deserialize(
|
|
1381
|
+
response_data=response_data,
|
|
1382
|
+
response_types_map=_response_types_map,
|
|
1383
|
+
).data
|
|
1384
|
+
|
|
1385
|
+
|
|
1386
|
+
@validate_call
|
|
1387
|
+
def update_canvas_0_with_http_info(
|
|
1388
|
+
self,
|
|
1389
|
+
id: Annotated[StrictStr, Field(description="ID of the canvas to update")],
|
|
1390
|
+
update_canvas_request: UpdateCanvasRequest,
|
|
1391
|
+
_request_timeout: Union[
|
|
1392
|
+
None,
|
|
1393
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1394
|
+
Tuple[
|
|
1395
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1396
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1397
|
+
]
|
|
1398
|
+
] = None,
|
|
1399
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1400
|
+
_content_type: Optional[StrictStr] = None,
|
|
1401
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1402
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1403
|
+
) -> ApiResponse[CanvasResponse]:
|
|
1404
|
+
"""Update Canvas
|
|
1405
|
+
|
|
1406
|
+
Updates an existing canvas with the specified properties.
|
|
1407
|
+
|
|
1408
|
+
:param id: ID of the canvas to update (required)
|
|
1409
|
+
:type id: str
|
|
1410
|
+
:param update_canvas_request: (required)
|
|
1411
|
+
:type update_canvas_request: UpdateCanvasRequest
|
|
1412
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1413
|
+
number provided, it will be total request
|
|
1414
|
+
timeout. It can also be a pair (tuple) of
|
|
1415
|
+
(connection, read) timeouts.
|
|
1416
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1417
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1418
|
+
request; this effectively ignores the
|
|
1419
|
+
authentication in the spec for a single request.
|
|
1420
|
+
:type _request_auth: dict, optional
|
|
1421
|
+
:param _content_type: force content-type for the request.
|
|
1422
|
+
:type _content_type: str, Optional
|
|
1423
|
+
:param _headers: set to override the headers for a single
|
|
1424
|
+
request; this effectively ignores the headers
|
|
1425
|
+
in the spec for a single request.
|
|
1426
|
+
:type _headers: dict, optional
|
|
1427
|
+
:param _host_index: set to override the host_index for a single
|
|
1428
|
+
request; this effectively ignores the host_index
|
|
1429
|
+
in the spec for a single request.
|
|
1430
|
+
:type _host_index: int, optional
|
|
1431
|
+
:return: Returns the result object.
|
|
1432
|
+
""" # noqa: E501
|
|
1433
|
+
|
|
1434
|
+
_param = self._update_canvas_0_serialize(
|
|
1435
|
+
id=id,
|
|
1436
|
+
update_canvas_request=update_canvas_request,
|
|
1437
|
+
_request_auth=_request_auth,
|
|
1438
|
+
_content_type=_content_type,
|
|
1439
|
+
_headers=_headers,
|
|
1440
|
+
_host_index=_host_index
|
|
1441
|
+
)
|
|
1442
|
+
|
|
1443
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1444
|
+
'200': "CanvasResponse",
|
|
1445
|
+
'401': "ErrorResponse",
|
|
1446
|
+
'404': "ErrorResponse",
|
|
1447
|
+
}
|
|
1448
|
+
response_data = self.api_client.call_api(
|
|
1449
|
+
*_param,
|
|
1450
|
+
_request_timeout=_request_timeout
|
|
1451
|
+
)
|
|
1452
|
+
response_data.read()
|
|
1453
|
+
return self.api_client.response_deserialize(
|
|
1454
|
+
response_data=response_data,
|
|
1455
|
+
response_types_map=_response_types_map,
|
|
1456
|
+
)
|
|
1457
|
+
|
|
1458
|
+
|
|
1459
|
+
@validate_call
|
|
1460
|
+
def update_canvas_0_without_preload_content(
|
|
1461
|
+
self,
|
|
1462
|
+
id: Annotated[StrictStr, Field(description="ID of the canvas to update")],
|
|
1463
|
+
update_canvas_request: UpdateCanvasRequest,
|
|
1464
|
+
_request_timeout: Union[
|
|
1465
|
+
None,
|
|
1466
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1467
|
+
Tuple[
|
|
1468
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1469
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1470
|
+
]
|
|
1471
|
+
] = None,
|
|
1472
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1473
|
+
_content_type: Optional[StrictStr] = None,
|
|
1474
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1475
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1476
|
+
) -> RESTResponseType:
|
|
1477
|
+
"""Update Canvas
|
|
1478
|
+
|
|
1479
|
+
Updates an existing canvas with the specified properties.
|
|
1480
|
+
|
|
1481
|
+
:param id: ID of the canvas to update (required)
|
|
1482
|
+
:type id: str
|
|
1483
|
+
:param update_canvas_request: (required)
|
|
1484
|
+
:type update_canvas_request: UpdateCanvasRequest
|
|
1485
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1486
|
+
number provided, it will be total request
|
|
1487
|
+
timeout. It can also be a pair (tuple) of
|
|
1488
|
+
(connection, read) timeouts.
|
|
1489
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1490
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1491
|
+
request; this effectively ignores the
|
|
1492
|
+
authentication in the spec for a single request.
|
|
1493
|
+
:type _request_auth: dict, optional
|
|
1494
|
+
:param _content_type: force content-type for the request.
|
|
1495
|
+
:type _content_type: str, Optional
|
|
1496
|
+
:param _headers: set to override the headers for a single
|
|
1497
|
+
request; this effectively ignores the headers
|
|
1498
|
+
in the spec for a single request.
|
|
1499
|
+
:type _headers: dict, optional
|
|
1500
|
+
:param _host_index: set to override the host_index for a single
|
|
1501
|
+
request; this effectively ignores the host_index
|
|
1502
|
+
in the spec for a single request.
|
|
1503
|
+
:type _host_index: int, optional
|
|
1504
|
+
:return: Returns the result object.
|
|
1505
|
+
""" # noqa: E501
|
|
1506
|
+
|
|
1507
|
+
_param = self._update_canvas_0_serialize(
|
|
1508
|
+
id=id,
|
|
1509
|
+
update_canvas_request=update_canvas_request,
|
|
1510
|
+
_request_auth=_request_auth,
|
|
1511
|
+
_content_type=_content_type,
|
|
1512
|
+
_headers=_headers,
|
|
1513
|
+
_host_index=_host_index
|
|
1514
|
+
)
|
|
1515
|
+
|
|
1516
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1517
|
+
'200': "CanvasResponse",
|
|
1518
|
+
'401': "ErrorResponse",
|
|
1519
|
+
'404': "ErrorResponse",
|
|
1520
|
+
}
|
|
1521
|
+
response_data = self.api_client.call_api(
|
|
1522
|
+
*_param,
|
|
1523
|
+
_request_timeout=_request_timeout
|
|
1524
|
+
)
|
|
1525
|
+
return response_data.response
|
|
1526
|
+
|
|
1527
|
+
|
|
1528
|
+
def _update_canvas_0_serialize(
|
|
1529
|
+
self,
|
|
1530
|
+
id,
|
|
1531
|
+
update_canvas_request,
|
|
1532
|
+
_request_auth,
|
|
1533
|
+
_content_type,
|
|
1534
|
+
_headers,
|
|
1535
|
+
_host_index,
|
|
1536
|
+
) -> RequestSerialized:
|
|
1537
|
+
|
|
1538
|
+
_host = None
|
|
1539
|
+
|
|
1540
|
+
_collection_formats: Dict[str, str] = {
|
|
1541
|
+
}
|
|
1542
|
+
|
|
1543
|
+
_path_params: Dict[str, str] = {}
|
|
1544
|
+
_query_params: List[Tuple[str, str]] = []
|
|
1545
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
1546
|
+
_form_params: List[Tuple[str, str]] = []
|
|
1547
|
+
_files: Dict[
|
|
1548
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
1549
|
+
] = {}
|
|
1550
|
+
_body_params: Optional[bytes] = None
|
|
1551
|
+
|
|
1552
|
+
# process the path parameters
|
|
1553
|
+
if id is not None:
|
|
1554
|
+
_path_params['id'] = id
|
|
1555
|
+
# process the query parameters
|
|
1556
|
+
# process the header parameters
|
|
1557
|
+
# process the form parameters
|
|
1558
|
+
# process the body parameter
|
|
1559
|
+
if update_canvas_request is not None:
|
|
1560
|
+
_body_params = update_canvas_request
|
|
1561
|
+
|
|
1562
|
+
|
|
1563
|
+
# set the HTTP header `Accept`
|
|
1564
|
+
if 'Accept' not in _header_params:
|
|
1565
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
1566
|
+
[
|
|
1567
|
+
'application/json'
|
|
1568
|
+
]
|
|
1569
|
+
)
|
|
1570
|
+
|
|
1571
|
+
# set the HTTP header `Content-Type`
|
|
1572
|
+
if _content_type:
|
|
1573
|
+
_header_params['Content-Type'] = _content_type
|
|
1574
|
+
else:
|
|
1575
|
+
_default_content_type = (
|
|
1576
|
+
self.api_client.select_header_content_type(
|
|
1577
|
+
[
|
|
1578
|
+
'application/json'
|
|
1579
|
+
]
|
|
1580
|
+
)
|
|
1581
|
+
)
|
|
1582
|
+
if _default_content_type is not None:
|
|
1583
|
+
_header_params['Content-Type'] = _default_content_type
|
|
1584
|
+
|
|
1585
|
+
# authentication setting
|
|
1586
|
+
_auth_settings: List[str] = [
|
|
1587
|
+
'apiKeyAuth'
|
|
1588
|
+
]
|
|
1589
|
+
|
|
1590
|
+
return self.api_client.param_serialize(
|
|
1591
|
+
method='PUT',
|
|
1592
|
+
resource_path='/canvases/{id}',
|
|
1593
|
+
path_params=_path_params,
|
|
1594
|
+
query_params=_query_params,
|
|
1595
|
+
header_params=_header_params,
|
|
1596
|
+
body=_body_params,
|
|
1597
|
+
post_params=_form_params,
|
|
1598
|
+
files=_files,
|
|
1599
|
+
auth_settings=_auth_settings,
|
|
1600
|
+
collection_formats=_collection_formats,
|
|
1601
|
+
_host=_host,
|
|
1602
|
+
_request_auth=_request_auth
|
|
1603
|
+
)
|
|
1604
|
+
|
|
1605
|
+
|