quantcdn-client 4.8.0__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.
- quantcdn/__init__.py +341 -0
- quantcdn/__version__.py +2 -0
- quantcdn/api/__init__.py +32 -0
- quantcdn/api/ai_agents_api.py +1831 -0
- quantcdn/api/ai_custom_tools_api.py +894 -0
- quantcdn/api/ai_inference_api.py +1224 -0
- quantcdn/api/ai_models_api.py +600 -0
- quantcdn/api/ai_monitoring_api.py +317 -0
- quantcdn/api/ai_sessions_api.py +1875 -0
- quantcdn/api/ai_tools_api.py +1165 -0
- quantcdn/api/ai_vector_database_api.py +1816 -0
- quantcdn/api/applications_api.py +1394 -0
- quantcdn/api/backup_management_api.py +1440 -0
- quantcdn/api/commands_api.py +901 -0
- quantcdn/api/compose_api.py +968 -0
- quantcdn/api/containers_api.py +649 -0
- quantcdn/api/crawler_schedules_api.py +1611 -0
- quantcdn/api/crawlers_api.py +2479 -0
- quantcdn/api/cron_api.py +2212 -0
- quantcdn/api/domains_api.py +1508 -0
- quantcdn/api/environments_api.py +3256 -0
- quantcdn/api/headers_api.py +932 -0
- quantcdn/api/kv_api.py +2868 -0
- quantcdn/api/organizations_api.py +556 -0
- quantcdn/api/projects_api.py +1478 -0
- quantcdn/api/purge_api.py +345 -0
- quantcdn/api/rules_api.py +13520 -0
- quantcdn/api/scaling_policy_api.py +924 -0
- quantcdn/api/ssh_access_api.py +335 -0
- quantcdn/api/variables_api.py +1255 -0
- quantcdn/api/volumes_api.py +1254 -0
- quantcdn/api_client.py +797 -0
- quantcdn/api_response.py +21 -0
- quantcdn/configuration.py +586 -0
- quantcdn/exceptions.py +216 -0
- quantcdn/models/__init__.py +297 -0
- quantcdn/models/application.py +200 -0
- quantcdn/models/application_database.py +103 -0
- quantcdn/models/application_deployment_information_inner.py +96 -0
- quantcdn/models/application_environments_inner.py +93 -0
- quantcdn/models/application_filesystem.py +89 -0
- quantcdn/models/application_image_reference.py +99 -0
- quantcdn/models/bulk_set_environment_variables_request.py +95 -0
- quantcdn/models/bulk_set_environment_variables_request_environment_inner.py +89 -0
- quantcdn/models/chat_inference200_response.py +113 -0
- quantcdn/models/chat_inference200_response_response.py +105 -0
- quantcdn/models/chat_inference200_response_response_tool_use.py +141 -0
- quantcdn/models/chat_inference200_response_response_tool_use_one_of.py +101 -0
- quantcdn/models/chat_inference200_response_response_tool_use_one_of1_inner.py +97 -0
- quantcdn/models/chat_inference200_response_response_tool_use_one_of_result.py +89 -0
- quantcdn/models/chat_inference200_response_usage.py +91 -0
- quantcdn/models/chat_inference_request.py +122 -0
- quantcdn/models/chat_inference_request_messages_inner.py +100 -0
- quantcdn/models/chat_inference_request_messages_inner_content.py +144 -0
- quantcdn/models/chat_inference_request_messages_inner_content_one_of_inner.py +165 -0
- quantcdn/models/chat_inference_request_messages_inner_content_one_of_inner_one_of.py +87 -0
- quantcdn/models/chat_inference_request_messages_inner_content_one_of_inner_one_of1.py +91 -0
- quantcdn/models/chat_inference_request_messages_inner_content_one_of_inner_one_of1_image.py +100 -0
- quantcdn/models/chat_inference_request_messages_inner_content_one_of_inner_one_of1_image_source.py +87 -0
- quantcdn/models/chat_inference_request_messages_inner_content_one_of_inner_one_of2.py +91 -0
- quantcdn/models/chat_inference_request_messages_inner_content_one_of_inner_one_of2_video.py +100 -0
- quantcdn/models/chat_inference_request_messages_inner_content_one_of_inner_one_of2_video_source.py +87 -0
- quantcdn/models/chat_inference_request_messages_inner_content_one_of_inner_one_of3.py +91 -0
- quantcdn/models/chat_inference_request_messages_inner_content_one_of_inner_one_of3_document.py +102 -0
- quantcdn/models/chat_inference_request_messages_inner_content_one_of_inner_one_of3_document_source.py +87 -0
- quantcdn/models/chat_inference_request_response_format.py +99 -0
- quantcdn/models/chat_inference_request_tool_config.py +99 -0
- quantcdn/models/chat_inference_request_tool_config_tools_inner.py +91 -0
- quantcdn/models/chat_inference_request_tool_config_tools_inner_tool_spec.py +95 -0
- quantcdn/models/chat_inference_request_tool_config_tools_inner_tool_spec_input_schema.py +87 -0
- quantcdn/models/chat_inference_stream_request.py +120 -0
- quantcdn/models/chat_inference_stream_request_messages_inner.py +100 -0
- quantcdn/models/chat_inference_stream_request_messages_inner_content.py +143 -0
- quantcdn/models/chat_with_ai_agent200_response.py +93 -0
- quantcdn/models/chat_with_ai_agent200_response_response.py +97 -0
- quantcdn/models/chat_with_ai_agent200_response_response_usage.py +89 -0
- quantcdn/models/chat_with_ai_agent_request.py +93 -0
- quantcdn/models/command.py +105 -0
- quantcdn/models/compose.py +125 -0
- quantcdn/models/container.py +260 -0
- quantcdn/models/container_depends_on_inner.py +99 -0
- quantcdn/models/container_environment_inner.py +89 -0
- quantcdn/models/container_health_check.py +101 -0
- quantcdn/models/container_image_reference.py +96 -0
- quantcdn/models/container_mount_points_inner.py +91 -0
- quantcdn/models/container_origin_protection_config.py +94 -0
- quantcdn/models/container_secrets_inner.py +89 -0
- quantcdn/models/crawlers_run200_response.py +87 -0
- quantcdn/models/crawlers_run_request.py +87 -0
- quantcdn/models/create_ai_agent201_response.py +91 -0
- quantcdn/models/create_ai_agent_request.py +106 -0
- quantcdn/models/create_ai_session201_response.py +104 -0
- quantcdn/models/create_ai_session_request.py +104 -0
- quantcdn/models/create_ai_session_request_initial_messages_inner.py +99 -0
- quantcdn/models/create_application403_response.py +89 -0
- quantcdn/models/create_application_request.py +144 -0
- quantcdn/models/create_application_request_database.py +103 -0
- quantcdn/models/create_application_request_environment_inner.py +89 -0
- quantcdn/models/create_application_request_filesystem.py +89 -0
- quantcdn/models/create_backup202_response.py +91 -0
- quantcdn/models/create_backup_request.py +87 -0
- quantcdn/models/create_command_request.py +87 -0
- quantcdn/models/create_cron_job_request.py +112 -0
- quantcdn/models/create_custom_tool201_response.py +91 -0
- quantcdn/models/create_custom_tool_request.py +98 -0
- quantcdn/models/create_environment403_response.py +89 -0
- quantcdn/models/create_environment_request.py +130 -0
- quantcdn/models/create_environment_request_environment_inner.py +89 -0
- quantcdn/models/create_vector_collection201_response.py +95 -0
- quantcdn/models/create_vector_collection201_response_collection.py +95 -0
- quantcdn/models/create_vector_collection_request.py +93 -0
- quantcdn/models/create_volume_request.py +101 -0
- quantcdn/models/cron.py +91 -0
- quantcdn/models/cron_run.py +156 -0
- quantcdn/models/delete_ai_agent200_response.py +89 -0
- quantcdn/models/delete_ai_session200_response.py +87 -0
- quantcdn/models/delete_backup200_response.py +89 -0
- quantcdn/models/delete_custom_tool200_response.py +89 -0
- quantcdn/models/delete_vector_collection200_response.py +89 -0
- quantcdn/models/download_backup200_response.py +92 -0
- quantcdn/models/embeddings200_response.py +101 -0
- quantcdn/models/embeddings200_response_embeddings.py +143 -0
- quantcdn/models/embeddings200_response_usage.py +89 -0
- quantcdn/models/embeddings_request.py +107 -0
- quantcdn/models/embeddings_request_input.py +143 -0
- quantcdn/models/environment.py +108 -0
- quantcdn/models/environment_response.py +171 -0
- quantcdn/models/environment_summary.py +109 -0
- quantcdn/models/extend_ai_session200_response.py +92 -0
- quantcdn/models/extend_ai_session_request.py +88 -0
- quantcdn/models/get_ai_agent200_response.py +91 -0
- quantcdn/models/get_ai_agent200_response_agent.py +112 -0
- quantcdn/models/get_ai_model200_response.py +116 -0
- quantcdn/models/get_ai_model200_response_capabilities.py +95 -0
- quantcdn/models/get_ai_model200_response_pricing.py +91 -0
- quantcdn/models/get_ai_model404_response.py +89 -0
- quantcdn/models/get_ai_session200_response.py +96 -0
- quantcdn/models/get_ai_tool_execution_status200_response.py +107 -0
- quantcdn/models/get_ai_tool_execution_status200_response_result.py +89 -0
- quantcdn/models/get_ai_tool_execution_status404_response.py +89 -0
- quantcdn/models/get_ai_usage_stats200_response.py +104 -0
- quantcdn/models/get_ai_usage_stats200_response_by_model_value.py +89 -0
- quantcdn/models/get_ecr_login_credentials200_response.py +93 -0
- quantcdn/models/get_environment_logs200_response.py +102 -0
- quantcdn/models/get_environment_logs200_response_log_events_inner.py +89 -0
- quantcdn/models/get_ssh_access_credentials200_response.py +107 -0
- quantcdn/models/get_ssh_access_credentials200_response_credentials.py +94 -0
- quantcdn/models/get_vector_collection200_response.py +91 -0
- quantcdn/models/get_vector_collection200_response_collection.py +102 -0
- quantcdn/models/image_generation200_response.py +91 -0
- quantcdn/models/image_generation_request.py +152 -0
- quantcdn/models/image_generation_request_background_removal_params.py +87 -0
- quantcdn/models/image_generation_request_color_guided_generation_params.py +94 -0
- quantcdn/models/image_generation_request_image_generation_config.py +108 -0
- quantcdn/models/image_generation_request_image_variation_params.py +94 -0
- quantcdn/models/image_generation_request_in_painting_params.py +96 -0
- quantcdn/models/image_generation_request_out_painting_params.py +107 -0
- quantcdn/models/image_generation_request_text_to_image_params.py +118 -0
- quantcdn/models/kv_items_create200_response.py +91 -0
- quantcdn/models/kv_items_delete200_response.py +89 -0
- quantcdn/models/kv_items_show200_response.py +93 -0
- quantcdn/models/kv_items_show200_response_value.py +143 -0
- quantcdn/models/list_ai_agents200_response.py +95 -0
- quantcdn/models/list_ai_agents200_response_agents_inner.py +106 -0
- quantcdn/models/list_ai_models200_response.py +97 -0
- quantcdn/models/list_ai_models200_response_models_inner.py +97 -0
- quantcdn/models/list_ai_models200_response_models_inner_capabilities.py +95 -0
- quantcdn/models/list_ai_sessions200_response_inner.py +96 -0
- quantcdn/models/list_ai_tool_executions200_response.py +101 -0
- quantcdn/models/list_ai_tool_executions200_response_executions_inner.py +96 -0
- quantcdn/models/list_ai_tool_names200_response.py +89 -0
- quantcdn/models/list_ai_tools200_response.py +97 -0
- quantcdn/models/list_ai_tools200_response_tools_inner.py +91 -0
- quantcdn/models/list_ai_tools200_response_tools_inner_tool_spec.py +95 -0
- quantcdn/models/list_ai_tools200_response_tools_inner_tool_spec_input_schema.py +87 -0
- quantcdn/models/list_backups200_response.py +106 -0
- quantcdn/models/list_backups200_response_backups_inner.py +112 -0
- quantcdn/models/list_backups422_response.py +87 -0
- quantcdn/models/list_custom_tools200_response.py +97 -0
- quantcdn/models/list_custom_tools200_response_tools_inner.py +98 -0
- quantcdn/models/list_vector_collections200_response.py +97 -0
- quantcdn/models/list_vector_collections200_response_collections_inner.py +98 -0
- quantcdn/models/organizations_list200_response_inner.py +89 -0
- quantcdn/models/patch_environment_compose202_response.py +107 -0
- quantcdn/models/patch_environment_compose202_response_spot_configuration.py +89 -0
- quantcdn/models/patch_environment_compose400_response.py +89 -0
- quantcdn/models/patch_environment_compose_request.py +153 -0
- quantcdn/models/patch_environment_compose_request_spot_configuration.py +97 -0
- quantcdn/models/purge_create_request.py +93 -0
- quantcdn/models/query_vector_collection200_response.py +101 -0
- quantcdn/models/query_vector_collection200_response_results_inner.py +95 -0
- quantcdn/models/query_vector_collection200_response_results_inner_metadata.py +91 -0
- quantcdn/models/query_vector_collection_request.py +90 -0
- quantcdn/models/scaling_policy.py +103 -0
- quantcdn/models/spot_configuration.py +94 -0
- quantcdn/models/sync_operation.py +99 -0
- quantcdn/models/sync_to_environment_request.py +87 -0
- quantcdn/models/update_ai_agent200_response.py +91 -0
- quantcdn/models/update_ai_agent_request.py +104 -0
- quantcdn/models/update_ai_session200_response.py +96 -0
- quantcdn/models/update_ai_session_request.py +111 -0
- quantcdn/models/update_ai_session_request_new_messages_inner.py +99 -0
- quantcdn/models/update_cron_job_request.py +120 -0
- quantcdn/models/update_environment_request.py +106 -0
- quantcdn/models/update_environment_state_request.py +89 -0
- quantcdn/models/update_environment_variable_request.py +87 -0
- quantcdn/models/upload_vector_documents200_response.py +93 -0
- quantcdn/models/upload_vector_documents_request.py +95 -0
- quantcdn/models/upload_vector_documents_request_documents_inner.py +93 -0
- quantcdn/models/upload_vector_documents_request_documents_inner_metadata.py +93 -0
- quantcdn/models/v1_content_item.py +97 -0
- quantcdn/models/v1_content_list_response.py +101 -0
- quantcdn/models/v1_content_request.py +110 -0
- quantcdn/models/v1_delete_response.py +99 -0
- quantcdn/models/v1_error.py +89 -0
- quantcdn/models/v1_form_submission_item.py +97 -0
- quantcdn/models/v1_form_submission_list_response.py +101 -0
- quantcdn/models/v1_get_metric_series_response.py +93 -0
- quantcdn/models/v1_get_metric_series_response_data.py +162 -0
- quantcdn/models/v1_get_metrics_response.py +93 -0
- quantcdn/models/v1_get_metrics_response_data.py +163 -0
- quantcdn/models/v1_global_meta_response.py +101 -0
- quantcdn/models/v1_global_meta_response_global_meta.py +87 -0
- quantcdn/models/v1_info.py +99 -0
- quantcdn/models/v1_meta.py +113 -0
- quantcdn/models/v1_metric_day_stats.py +93 -0
- quantcdn/models/v1_metric_minute_stats.py +93 -0
- quantcdn/models/v1_metric_month_stats.py +93 -0
- quantcdn/models/v1_ping_response.py +89 -0
- quantcdn/models/v1_proxy_item.py +95 -0
- quantcdn/models/v1_proxy_list_response.py +101 -0
- quantcdn/models/v1_redirect_item.py +97 -0
- quantcdn/models/v1_redirect_list_response.py +101 -0
- quantcdn/models/v1_redirect_request.py +111 -0
- quantcdn/models/v1_redirect_response.py +121 -0
- quantcdn/models/v1_revision.py +115 -0
- quantcdn/models/v1_revisions_response.py +107 -0
- quantcdn/models/v1_search_hit.py +97 -0
- quantcdn/models/v1_search_items_response.py +97 -0
- quantcdn/models/v1_search_mutation_response.py +91 -0
- quantcdn/models/v1_search_record.py +93 -0
- quantcdn/models/v1_search_response.py +89 -0
- quantcdn/models/v1_series_point_day.py +89 -0
- quantcdn/models/v1_series_point_month.py +89 -0
- quantcdn/models/v1_transition.py +99 -0
- quantcdn/models/v1_upload_response.py +89 -0
- quantcdn/models/v1_url_meta_request.py +87 -0
- quantcdn/models/v1_url_meta_response.py +91 -0
- quantcdn/models/v1_waf_log_item.py +107 -0
- quantcdn/models/v1_waf_log_list_response.py +101 -0
- quantcdn/models/v2_crawler.py +165 -0
- quantcdn/models/v2_crawler_assets.py +97 -0
- quantcdn/models/v2_crawler_assets_network_intercept.py +91 -0
- quantcdn/models/v2_crawler_assets_parser.py +87 -0
- quantcdn/models/v2_crawler_request.py +142 -0
- quantcdn/models/v2_crawler_run.py +114 -0
- quantcdn/models/v2_crawler_schedule.py +104 -0
- quantcdn/models/v2_crawler_schedule_request.py +89 -0
- quantcdn/models/v2_crawler_sitemap_inner.py +89 -0
- quantcdn/models/v2_custom_header_request.py +87 -0
- quantcdn/models/v2_domain.py +121 -0
- quantcdn/models/v2_domain_dns_go_live_records_inner.py +98 -0
- quantcdn/models/v2_domain_dns_validation_records_inner.py +91 -0
- quantcdn/models/v2_domain_request.py +87 -0
- quantcdn/models/v2_error.py +89 -0
- quantcdn/models/v2_organization.py +100 -0
- quantcdn/models/v2_organization_request.py +89 -0
- quantcdn/models/v2_project.py +95 -0
- quantcdn/models/v2_project_request.py +101 -0
- quantcdn/models/v2_rule.py +121 -0
- quantcdn/models/v2_rule_auth.py +127 -0
- quantcdn/models/v2_rule_auth_action.py +89 -0
- quantcdn/models/v2_rule_auth_request.py +119 -0
- quantcdn/models/v2_rule_bot_challenge.py +127 -0
- quantcdn/models/v2_rule_bot_challenge_action.py +91 -0
- quantcdn/models/v2_rule_bot_challenge_request.py +121 -0
- quantcdn/models/v2_rule_content_filter.py +127 -0
- quantcdn/models/v2_rule_content_filter_action.py +87 -0
- quantcdn/models/v2_rule_content_filter_request.py +117 -0
- quantcdn/models/v2_rule_custom_response.py +127 -0
- quantcdn/models/v2_rule_custom_response_action.py +89 -0
- quantcdn/models/v2_rule_custom_response_request.py +123 -0
- quantcdn/models/v2_rule_function.py +127 -0
- quantcdn/models/v2_rule_function_action.py +87 -0
- quantcdn/models/v2_rule_function_request.py +117 -0
- quantcdn/models/v2_rule_header.py +127 -0
- quantcdn/models/v2_rule_header_action.py +87 -0
- quantcdn/models/v2_rule_header_request.py +117 -0
- quantcdn/models/v2_rule_proxy.py +127 -0
- quantcdn/models/v2_rule_proxy_action.py +195 -0
- quantcdn/models/v2_rule_proxy_action_notify_config.py +87 -0
- quantcdn/models/v2_rule_proxy_action_quant_cloud_selection.py +93 -0
- quantcdn/models/v2_rule_proxy_request.py +189 -0
- quantcdn/models/v2_rule_redirect.py +127 -0
- quantcdn/models/v2_rule_redirect_action.py +89 -0
- quantcdn/models/v2_rule_redirect_request.py +119 -0
- quantcdn/models/v2_rule_request.py +115 -0
- quantcdn/models/v2_rule_serve_static.py +127 -0
- quantcdn/models/v2_rule_serve_static_action.py +87 -0
- quantcdn/models/v2_rule_serve_static_request.py +117 -0
- quantcdn/models/v2_secret_store.py +89 -0
- quantcdn/models/v2_secret_store_request.py +87 -0
- quantcdn/models/v2_store.py +89 -0
- quantcdn/models/v2_store_item.py +89 -0
- quantcdn/models/v2_store_item_request.py +91 -0
- quantcdn/models/v2_store_item_update_request.py +89 -0
- quantcdn/models/v2_store_items_list_response.py +94 -0
- quantcdn/models/v2_store_request.py +87 -0
- quantcdn/models/validate_compose200_response.py +96 -0
- quantcdn/models/validate_compose422_response.py +87 -0
- quantcdn/models/validate_compose_request.py +102 -0
- quantcdn/models/variable.py +89 -0
- quantcdn/models/volume.py +101 -0
- quantcdn/models/waf_config.py +140 -0
- quantcdn/models/waf_config_block_lists.py +93 -0
- quantcdn/models/waf_config_httpbl.py +97 -0
- quantcdn/models/waf_config_thresholds_inner.py +131 -0
- quantcdn/py.typed +0 -0
- quantcdn/rest.py +258 -0
- quantcdn_client-4.8.0.dist-info/METADATA +23 -0
- quantcdn_client-4.8.0.dist-info/RECORD +323 -0
- quantcdn_client-4.8.0.dist-info/WHEEL +5 -0
- quantcdn_client-4.8.0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,894 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
QuantCDN API
|
|
5
|
+
|
|
6
|
+
Unified API for QuantCDN Admin and QuantCloud Platform services
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 4.8.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 pydantic import Field, StrictStr
|
|
20
|
+
from typing_extensions import Annotated
|
|
21
|
+
from quantcdn.models.create_custom_tool201_response import CreateCustomTool201Response
|
|
22
|
+
from quantcdn.models.create_custom_tool_request import CreateCustomToolRequest
|
|
23
|
+
from quantcdn.models.delete_custom_tool200_response import DeleteCustomTool200Response
|
|
24
|
+
from quantcdn.models.list_custom_tools200_response import ListCustomTools200Response
|
|
25
|
+
|
|
26
|
+
from quantcdn.api_client import ApiClient, RequestSerialized
|
|
27
|
+
from quantcdn.api_response import ApiResponse
|
|
28
|
+
from quantcdn.rest import RESTResponseType
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
class AICustomToolsApi:
|
|
32
|
+
"""NOTE: This class is auto generated by OpenAPI Generator
|
|
33
|
+
Ref: https://openapi-generator.tech
|
|
34
|
+
|
|
35
|
+
Do not edit the class manually.
|
|
36
|
+
"""
|
|
37
|
+
|
|
38
|
+
def __init__(self, api_client=None) -> None:
|
|
39
|
+
if api_client is None:
|
|
40
|
+
api_client = ApiClient.get_default()
|
|
41
|
+
self.api_client = api_client
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
@validate_call
|
|
45
|
+
def create_custom_tool(
|
|
46
|
+
self,
|
|
47
|
+
organisation: Annotated[StrictStr, Field(description="The organisation ID")],
|
|
48
|
+
create_custom_tool_request: CreateCustomToolRequest,
|
|
49
|
+
_request_timeout: Union[
|
|
50
|
+
None,
|
|
51
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
52
|
+
Tuple[
|
|
53
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
54
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
55
|
+
]
|
|
56
|
+
] = None,
|
|
57
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
58
|
+
_content_type: Optional[StrictStr] = None,
|
|
59
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
60
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
61
|
+
) -> CreateCustomTool201Response:
|
|
62
|
+
"""Register Custom Edge Function Tool
|
|
63
|
+
|
|
64
|
+
Registers a custom edge function as a tool that AI models can invoke. This enables customers to create their own tools backed by edge functions. * * **Edge Function Contract:** * - Edge functions must accept POST requests with JSON payload * - Expected request format: `{ 'toolName': '...', 'input': {...}, 'orgId': '...' }` * - Must return JSON response with either `result` or `error` field * * **Async Tools:** * Set `isAsync: true` for operations >5 seconds. The edge function should return `{ executionId: '...' }` and the AI will poll for completion.
|
|
65
|
+
|
|
66
|
+
:param organisation: The organisation ID (required)
|
|
67
|
+
:type organisation: str
|
|
68
|
+
:param create_custom_tool_request: (required)
|
|
69
|
+
:type create_custom_tool_request: CreateCustomToolRequest
|
|
70
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
71
|
+
number provided, it will be total request
|
|
72
|
+
timeout. It can also be a pair (tuple) of
|
|
73
|
+
(connection, read) timeouts.
|
|
74
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
75
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
76
|
+
request; this effectively ignores the
|
|
77
|
+
authentication in the spec for a single request.
|
|
78
|
+
:type _request_auth: dict, optional
|
|
79
|
+
:param _content_type: force content-type for the request.
|
|
80
|
+
:type _content_type: str, Optional
|
|
81
|
+
:param _headers: set to override the headers for a single
|
|
82
|
+
request; this effectively ignores the headers
|
|
83
|
+
in the spec for a single request.
|
|
84
|
+
:type _headers: dict, optional
|
|
85
|
+
:param _host_index: set to override the host_index for a single
|
|
86
|
+
request; this effectively ignores the host_index
|
|
87
|
+
in the spec for a single request.
|
|
88
|
+
:type _host_index: int, optional
|
|
89
|
+
:return: Returns the result object.
|
|
90
|
+
""" # noqa: E501
|
|
91
|
+
|
|
92
|
+
_param = self._create_custom_tool_serialize(
|
|
93
|
+
organisation=organisation,
|
|
94
|
+
create_custom_tool_request=create_custom_tool_request,
|
|
95
|
+
_request_auth=_request_auth,
|
|
96
|
+
_content_type=_content_type,
|
|
97
|
+
_headers=_headers,
|
|
98
|
+
_host_index=_host_index
|
|
99
|
+
)
|
|
100
|
+
|
|
101
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
102
|
+
'201': "CreateCustomTool201Response",
|
|
103
|
+
'400': None,
|
|
104
|
+
'403': None,
|
|
105
|
+
'409': None,
|
|
106
|
+
'500': None,
|
|
107
|
+
}
|
|
108
|
+
response_data = self.api_client.call_api(
|
|
109
|
+
*_param,
|
|
110
|
+
_request_timeout=_request_timeout
|
|
111
|
+
)
|
|
112
|
+
response_data.read()
|
|
113
|
+
return self.api_client.response_deserialize(
|
|
114
|
+
response_data=response_data,
|
|
115
|
+
response_types_map=_response_types_map,
|
|
116
|
+
).data
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
@validate_call
|
|
120
|
+
def create_custom_tool_with_http_info(
|
|
121
|
+
self,
|
|
122
|
+
organisation: Annotated[StrictStr, Field(description="The organisation ID")],
|
|
123
|
+
create_custom_tool_request: CreateCustomToolRequest,
|
|
124
|
+
_request_timeout: Union[
|
|
125
|
+
None,
|
|
126
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
127
|
+
Tuple[
|
|
128
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
129
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
130
|
+
]
|
|
131
|
+
] = None,
|
|
132
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
133
|
+
_content_type: Optional[StrictStr] = None,
|
|
134
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
135
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
136
|
+
) -> ApiResponse[CreateCustomTool201Response]:
|
|
137
|
+
"""Register Custom Edge Function Tool
|
|
138
|
+
|
|
139
|
+
Registers a custom edge function as a tool that AI models can invoke. This enables customers to create their own tools backed by edge functions. * * **Edge Function Contract:** * - Edge functions must accept POST requests with JSON payload * - Expected request format: `{ 'toolName': '...', 'input': {...}, 'orgId': '...' }` * - Must return JSON response with either `result` or `error` field * * **Async Tools:** * Set `isAsync: true` for operations >5 seconds. The edge function should return `{ executionId: '...' }` and the AI will poll for completion.
|
|
140
|
+
|
|
141
|
+
:param organisation: The organisation ID (required)
|
|
142
|
+
:type organisation: str
|
|
143
|
+
:param create_custom_tool_request: (required)
|
|
144
|
+
:type create_custom_tool_request: CreateCustomToolRequest
|
|
145
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
146
|
+
number provided, it will be total request
|
|
147
|
+
timeout. It can also be a pair (tuple) of
|
|
148
|
+
(connection, read) timeouts.
|
|
149
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
150
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
151
|
+
request; this effectively ignores the
|
|
152
|
+
authentication in the spec for a single request.
|
|
153
|
+
:type _request_auth: dict, optional
|
|
154
|
+
:param _content_type: force content-type for the request.
|
|
155
|
+
:type _content_type: str, Optional
|
|
156
|
+
:param _headers: set to override the headers for a single
|
|
157
|
+
request; this effectively ignores the headers
|
|
158
|
+
in the spec for a single request.
|
|
159
|
+
:type _headers: dict, optional
|
|
160
|
+
:param _host_index: set to override the host_index for a single
|
|
161
|
+
request; this effectively ignores the host_index
|
|
162
|
+
in the spec for a single request.
|
|
163
|
+
:type _host_index: int, optional
|
|
164
|
+
:return: Returns the result object.
|
|
165
|
+
""" # noqa: E501
|
|
166
|
+
|
|
167
|
+
_param = self._create_custom_tool_serialize(
|
|
168
|
+
organisation=organisation,
|
|
169
|
+
create_custom_tool_request=create_custom_tool_request,
|
|
170
|
+
_request_auth=_request_auth,
|
|
171
|
+
_content_type=_content_type,
|
|
172
|
+
_headers=_headers,
|
|
173
|
+
_host_index=_host_index
|
|
174
|
+
)
|
|
175
|
+
|
|
176
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
177
|
+
'201': "CreateCustomTool201Response",
|
|
178
|
+
'400': None,
|
|
179
|
+
'403': None,
|
|
180
|
+
'409': None,
|
|
181
|
+
'500': None,
|
|
182
|
+
}
|
|
183
|
+
response_data = self.api_client.call_api(
|
|
184
|
+
*_param,
|
|
185
|
+
_request_timeout=_request_timeout
|
|
186
|
+
)
|
|
187
|
+
response_data.read()
|
|
188
|
+
return self.api_client.response_deserialize(
|
|
189
|
+
response_data=response_data,
|
|
190
|
+
response_types_map=_response_types_map,
|
|
191
|
+
)
|
|
192
|
+
|
|
193
|
+
|
|
194
|
+
@validate_call
|
|
195
|
+
def create_custom_tool_without_preload_content(
|
|
196
|
+
self,
|
|
197
|
+
organisation: Annotated[StrictStr, Field(description="The organisation ID")],
|
|
198
|
+
create_custom_tool_request: CreateCustomToolRequest,
|
|
199
|
+
_request_timeout: Union[
|
|
200
|
+
None,
|
|
201
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
202
|
+
Tuple[
|
|
203
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
204
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
205
|
+
]
|
|
206
|
+
] = None,
|
|
207
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
208
|
+
_content_type: Optional[StrictStr] = None,
|
|
209
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
210
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
211
|
+
) -> RESTResponseType:
|
|
212
|
+
"""Register Custom Edge Function Tool
|
|
213
|
+
|
|
214
|
+
Registers a custom edge function as a tool that AI models can invoke. This enables customers to create their own tools backed by edge functions. * * **Edge Function Contract:** * - Edge functions must accept POST requests with JSON payload * - Expected request format: `{ 'toolName': '...', 'input': {...}, 'orgId': '...' }` * - Must return JSON response with either `result` or `error` field * * **Async Tools:** * Set `isAsync: true` for operations >5 seconds. The edge function should return `{ executionId: '...' }` and the AI will poll for completion.
|
|
215
|
+
|
|
216
|
+
:param organisation: The organisation ID (required)
|
|
217
|
+
:type organisation: str
|
|
218
|
+
:param create_custom_tool_request: (required)
|
|
219
|
+
:type create_custom_tool_request: CreateCustomToolRequest
|
|
220
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
221
|
+
number provided, it will be total request
|
|
222
|
+
timeout. It can also be a pair (tuple) of
|
|
223
|
+
(connection, read) timeouts.
|
|
224
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
225
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
226
|
+
request; this effectively ignores the
|
|
227
|
+
authentication in the spec for a single request.
|
|
228
|
+
:type _request_auth: dict, optional
|
|
229
|
+
:param _content_type: force content-type for the request.
|
|
230
|
+
:type _content_type: str, Optional
|
|
231
|
+
:param _headers: set to override the headers for a single
|
|
232
|
+
request; this effectively ignores the headers
|
|
233
|
+
in the spec for a single request.
|
|
234
|
+
:type _headers: dict, optional
|
|
235
|
+
:param _host_index: set to override the host_index for a single
|
|
236
|
+
request; this effectively ignores the host_index
|
|
237
|
+
in the spec for a single request.
|
|
238
|
+
:type _host_index: int, optional
|
|
239
|
+
:return: Returns the result object.
|
|
240
|
+
""" # noqa: E501
|
|
241
|
+
|
|
242
|
+
_param = self._create_custom_tool_serialize(
|
|
243
|
+
organisation=organisation,
|
|
244
|
+
create_custom_tool_request=create_custom_tool_request,
|
|
245
|
+
_request_auth=_request_auth,
|
|
246
|
+
_content_type=_content_type,
|
|
247
|
+
_headers=_headers,
|
|
248
|
+
_host_index=_host_index
|
|
249
|
+
)
|
|
250
|
+
|
|
251
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
252
|
+
'201': "CreateCustomTool201Response",
|
|
253
|
+
'400': None,
|
|
254
|
+
'403': None,
|
|
255
|
+
'409': None,
|
|
256
|
+
'500': None,
|
|
257
|
+
}
|
|
258
|
+
response_data = self.api_client.call_api(
|
|
259
|
+
*_param,
|
|
260
|
+
_request_timeout=_request_timeout
|
|
261
|
+
)
|
|
262
|
+
return response_data.response
|
|
263
|
+
|
|
264
|
+
|
|
265
|
+
def _create_custom_tool_serialize(
|
|
266
|
+
self,
|
|
267
|
+
organisation,
|
|
268
|
+
create_custom_tool_request,
|
|
269
|
+
_request_auth,
|
|
270
|
+
_content_type,
|
|
271
|
+
_headers,
|
|
272
|
+
_host_index,
|
|
273
|
+
) -> RequestSerialized:
|
|
274
|
+
|
|
275
|
+
_host = None
|
|
276
|
+
|
|
277
|
+
_collection_formats: Dict[str, str] = {
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
_path_params: Dict[str, str] = {}
|
|
281
|
+
_query_params: List[Tuple[str, str]] = []
|
|
282
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
283
|
+
_form_params: List[Tuple[str, str]] = []
|
|
284
|
+
_files: Dict[
|
|
285
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
286
|
+
] = {}
|
|
287
|
+
_body_params: Optional[bytes] = None
|
|
288
|
+
|
|
289
|
+
# process the path parameters
|
|
290
|
+
if organisation is not None:
|
|
291
|
+
_path_params['organisation'] = organisation
|
|
292
|
+
# process the query parameters
|
|
293
|
+
# process the header parameters
|
|
294
|
+
# process the form parameters
|
|
295
|
+
# process the body parameter
|
|
296
|
+
if create_custom_tool_request is not None:
|
|
297
|
+
_body_params = create_custom_tool_request
|
|
298
|
+
|
|
299
|
+
|
|
300
|
+
# set the HTTP header `Accept`
|
|
301
|
+
if 'Accept' not in _header_params:
|
|
302
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
303
|
+
[
|
|
304
|
+
'application/json'
|
|
305
|
+
]
|
|
306
|
+
)
|
|
307
|
+
|
|
308
|
+
# set the HTTP header `Content-Type`
|
|
309
|
+
if _content_type:
|
|
310
|
+
_header_params['Content-Type'] = _content_type
|
|
311
|
+
else:
|
|
312
|
+
_default_content_type = (
|
|
313
|
+
self.api_client.select_header_content_type(
|
|
314
|
+
[
|
|
315
|
+
'application/json'
|
|
316
|
+
]
|
|
317
|
+
)
|
|
318
|
+
)
|
|
319
|
+
if _default_content_type is not None:
|
|
320
|
+
_header_params['Content-Type'] = _default_content_type
|
|
321
|
+
|
|
322
|
+
# authentication setting
|
|
323
|
+
_auth_settings: List[str] = [
|
|
324
|
+
'BearerAuth'
|
|
325
|
+
]
|
|
326
|
+
|
|
327
|
+
return self.api_client.param_serialize(
|
|
328
|
+
method='POST',
|
|
329
|
+
resource_path='/api/v3/organizations/{organisation}/ai/custom-tools',
|
|
330
|
+
path_params=_path_params,
|
|
331
|
+
query_params=_query_params,
|
|
332
|
+
header_params=_header_params,
|
|
333
|
+
body=_body_params,
|
|
334
|
+
post_params=_form_params,
|
|
335
|
+
files=_files,
|
|
336
|
+
auth_settings=_auth_settings,
|
|
337
|
+
collection_formats=_collection_formats,
|
|
338
|
+
_host=_host,
|
|
339
|
+
_request_auth=_request_auth
|
|
340
|
+
)
|
|
341
|
+
|
|
342
|
+
|
|
343
|
+
|
|
344
|
+
|
|
345
|
+
@validate_call
|
|
346
|
+
def delete_custom_tool(
|
|
347
|
+
self,
|
|
348
|
+
organisation: Annotated[StrictStr, Field(description="The organisation ID")],
|
|
349
|
+
tool_name: Annotated[StrictStr, Field(description="The tool name to delete")],
|
|
350
|
+
_request_timeout: Union[
|
|
351
|
+
None,
|
|
352
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
353
|
+
Tuple[
|
|
354
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
355
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
356
|
+
]
|
|
357
|
+
] = None,
|
|
358
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
359
|
+
_content_type: Optional[StrictStr] = None,
|
|
360
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
361
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
362
|
+
) -> DeleteCustomTool200Response:
|
|
363
|
+
"""Delete Custom Tool
|
|
364
|
+
|
|
365
|
+
Deletes a custom tool registration. The underlying edge function is not affected.
|
|
366
|
+
|
|
367
|
+
:param organisation: The organisation ID (required)
|
|
368
|
+
:type organisation: str
|
|
369
|
+
:param tool_name: The tool name to delete (required)
|
|
370
|
+
:type tool_name: str
|
|
371
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
372
|
+
number provided, it will be total request
|
|
373
|
+
timeout. It can also be a pair (tuple) of
|
|
374
|
+
(connection, read) timeouts.
|
|
375
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
376
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
377
|
+
request; this effectively ignores the
|
|
378
|
+
authentication in the spec for a single request.
|
|
379
|
+
:type _request_auth: dict, optional
|
|
380
|
+
:param _content_type: force content-type for the request.
|
|
381
|
+
:type _content_type: str, Optional
|
|
382
|
+
:param _headers: set to override the headers for a single
|
|
383
|
+
request; this effectively ignores the headers
|
|
384
|
+
in the spec for a single request.
|
|
385
|
+
:type _headers: dict, optional
|
|
386
|
+
:param _host_index: set to override the host_index for a single
|
|
387
|
+
request; this effectively ignores the host_index
|
|
388
|
+
in the spec for a single request.
|
|
389
|
+
:type _host_index: int, optional
|
|
390
|
+
:return: Returns the result object.
|
|
391
|
+
""" # noqa: E501
|
|
392
|
+
|
|
393
|
+
_param = self._delete_custom_tool_serialize(
|
|
394
|
+
organisation=organisation,
|
|
395
|
+
tool_name=tool_name,
|
|
396
|
+
_request_auth=_request_auth,
|
|
397
|
+
_content_type=_content_type,
|
|
398
|
+
_headers=_headers,
|
|
399
|
+
_host_index=_host_index
|
|
400
|
+
)
|
|
401
|
+
|
|
402
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
403
|
+
'200': "DeleteCustomTool200Response",
|
|
404
|
+
'403': None,
|
|
405
|
+
'404': None,
|
|
406
|
+
'500': None,
|
|
407
|
+
}
|
|
408
|
+
response_data = self.api_client.call_api(
|
|
409
|
+
*_param,
|
|
410
|
+
_request_timeout=_request_timeout
|
|
411
|
+
)
|
|
412
|
+
response_data.read()
|
|
413
|
+
return self.api_client.response_deserialize(
|
|
414
|
+
response_data=response_data,
|
|
415
|
+
response_types_map=_response_types_map,
|
|
416
|
+
).data
|
|
417
|
+
|
|
418
|
+
|
|
419
|
+
@validate_call
|
|
420
|
+
def delete_custom_tool_with_http_info(
|
|
421
|
+
self,
|
|
422
|
+
organisation: Annotated[StrictStr, Field(description="The organisation ID")],
|
|
423
|
+
tool_name: Annotated[StrictStr, Field(description="The tool name to delete")],
|
|
424
|
+
_request_timeout: Union[
|
|
425
|
+
None,
|
|
426
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
427
|
+
Tuple[
|
|
428
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
429
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
430
|
+
]
|
|
431
|
+
] = None,
|
|
432
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
433
|
+
_content_type: Optional[StrictStr] = None,
|
|
434
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
435
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
436
|
+
) -> ApiResponse[DeleteCustomTool200Response]:
|
|
437
|
+
"""Delete Custom Tool
|
|
438
|
+
|
|
439
|
+
Deletes a custom tool registration. The underlying edge function is not affected.
|
|
440
|
+
|
|
441
|
+
:param organisation: The organisation ID (required)
|
|
442
|
+
:type organisation: str
|
|
443
|
+
:param tool_name: The tool name to delete (required)
|
|
444
|
+
:type tool_name: str
|
|
445
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
446
|
+
number provided, it will be total request
|
|
447
|
+
timeout. It can also be a pair (tuple) of
|
|
448
|
+
(connection, read) timeouts.
|
|
449
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
450
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
451
|
+
request; this effectively ignores the
|
|
452
|
+
authentication in the spec for a single request.
|
|
453
|
+
:type _request_auth: dict, optional
|
|
454
|
+
:param _content_type: force content-type for the request.
|
|
455
|
+
:type _content_type: str, Optional
|
|
456
|
+
:param _headers: set to override the headers for a single
|
|
457
|
+
request; this effectively ignores the headers
|
|
458
|
+
in the spec for a single request.
|
|
459
|
+
:type _headers: dict, optional
|
|
460
|
+
:param _host_index: set to override the host_index for a single
|
|
461
|
+
request; this effectively ignores the host_index
|
|
462
|
+
in the spec for a single request.
|
|
463
|
+
:type _host_index: int, optional
|
|
464
|
+
:return: Returns the result object.
|
|
465
|
+
""" # noqa: E501
|
|
466
|
+
|
|
467
|
+
_param = self._delete_custom_tool_serialize(
|
|
468
|
+
organisation=organisation,
|
|
469
|
+
tool_name=tool_name,
|
|
470
|
+
_request_auth=_request_auth,
|
|
471
|
+
_content_type=_content_type,
|
|
472
|
+
_headers=_headers,
|
|
473
|
+
_host_index=_host_index
|
|
474
|
+
)
|
|
475
|
+
|
|
476
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
477
|
+
'200': "DeleteCustomTool200Response",
|
|
478
|
+
'403': None,
|
|
479
|
+
'404': None,
|
|
480
|
+
'500': None,
|
|
481
|
+
}
|
|
482
|
+
response_data = self.api_client.call_api(
|
|
483
|
+
*_param,
|
|
484
|
+
_request_timeout=_request_timeout
|
|
485
|
+
)
|
|
486
|
+
response_data.read()
|
|
487
|
+
return self.api_client.response_deserialize(
|
|
488
|
+
response_data=response_data,
|
|
489
|
+
response_types_map=_response_types_map,
|
|
490
|
+
)
|
|
491
|
+
|
|
492
|
+
|
|
493
|
+
@validate_call
|
|
494
|
+
def delete_custom_tool_without_preload_content(
|
|
495
|
+
self,
|
|
496
|
+
organisation: Annotated[StrictStr, Field(description="The organisation ID")],
|
|
497
|
+
tool_name: Annotated[StrictStr, Field(description="The tool name to delete")],
|
|
498
|
+
_request_timeout: Union[
|
|
499
|
+
None,
|
|
500
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
501
|
+
Tuple[
|
|
502
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
503
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
504
|
+
]
|
|
505
|
+
] = None,
|
|
506
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
507
|
+
_content_type: Optional[StrictStr] = None,
|
|
508
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
509
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
510
|
+
) -> RESTResponseType:
|
|
511
|
+
"""Delete Custom Tool
|
|
512
|
+
|
|
513
|
+
Deletes a custom tool registration. The underlying edge function is not affected.
|
|
514
|
+
|
|
515
|
+
:param organisation: The organisation ID (required)
|
|
516
|
+
:type organisation: str
|
|
517
|
+
:param tool_name: The tool name to delete (required)
|
|
518
|
+
:type tool_name: str
|
|
519
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
520
|
+
number provided, it will be total request
|
|
521
|
+
timeout. It can also be a pair (tuple) of
|
|
522
|
+
(connection, read) timeouts.
|
|
523
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
524
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
525
|
+
request; this effectively ignores the
|
|
526
|
+
authentication in the spec for a single request.
|
|
527
|
+
:type _request_auth: dict, optional
|
|
528
|
+
:param _content_type: force content-type for the request.
|
|
529
|
+
:type _content_type: str, Optional
|
|
530
|
+
:param _headers: set to override the headers for a single
|
|
531
|
+
request; this effectively ignores the headers
|
|
532
|
+
in the spec for a single request.
|
|
533
|
+
:type _headers: dict, optional
|
|
534
|
+
:param _host_index: set to override the host_index for a single
|
|
535
|
+
request; this effectively ignores the host_index
|
|
536
|
+
in the spec for a single request.
|
|
537
|
+
:type _host_index: int, optional
|
|
538
|
+
:return: Returns the result object.
|
|
539
|
+
""" # noqa: E501
|
|
540
|
+
|
|
541
|
+
_param = self._delete_custom_tool_serialize(
|
|
542
|
+
organisation=organisation,
|
|
543
|
+
tool_name=tool_name,
|
|
544
|
+
_request_auth=_request_auth,
|
|
545
|
+
_content_type=_content_type,
|
|
546
|
+
_headers=_headers,
|
|
547
|
+
_host_index=_host_index
|
|
548
|
+
)
|
|
549
|
+
|
|
550
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
551
|
+
'200': "DeleteCustomTool200Response",
|
|
552
|
+
'403': None,
|
|
553
|
+
'404': None,
|
|
554
|
+
'500': None,
|
|
555
|
+
}
|
|
556
|
+
response_data = self.api_client.call_api(
|
|
557
|
+
*_param,
|
|
558
|
+
_request_timeout=_request_timeout
|
|
559
|
+
)
|
|
560
|
+
return response_data.response
|
|
561
|
+
|
|
562
|
+
|
|
563
|
+
def _delete_custom_tool_serialize(
|
|
564
|
+
self,
|
|
565
|
+
organisation,
|
|
566
|
+
tool_name,
|
|
567
|
+
_request_auth,
|
|
568
|
+
_content_type,
|
|
569
|
+
_headers,
|
|
570
|
+
_host_index,
|
|
571
|
+
) -> RequestSerialized:
|
|
572
|
+
|
|
573
|
+
_host = None
|
|
574
|
+
|
|
575
|
+
_collection_formats: Dict[str, str] = {
|
|
576
|
+
}
|
|
577
|
+
|
|
578
|
+
_path_params: Dict[str, str] = {}
|
|
579
|
+
_query_params: List[Tuple[str, str]] = []
|
|
580
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
581
|
+
_form_params: List[Tuple[str, str]] = []
|
|
582
|
+
_files: Dict[
|
|
583
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
584
|
+
] = {}
|
|
585
|
+
_body_params: Optional[bytes] = None
|
|
586
|
+
|
|
587
|
+
# process the path parameters
|
|
588
|
+
if organisation is not None:
|
|
589
|
+
_path_params['organisation'] = organisation
|
|
590
|
+
if tool_name is not None:
|
|
591
|
+
_path_params['toolName'] = tool_name
|
|
592
|
+
# process the query parameters
|
|
593
|
+
# process the header parameters
|
|
594
|
+
# process the form parameters
|
|
595
|
+
# process the body parameter
|
|
596
|
+
|
|
597
|
+
|
|
598
|
+
# set the HTTP header `Accept`
|
|
599
|
+
if 'Accept' not in _header_params:
|
|
600
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
601
|
+
[
|
|
602
|
+
'application/json'
|
|
603
|
+
]
|
|
604
|
+
)
|
|
605
|
+
|
|
606
|
+
|
|
607
|
+
# authentication setting
|
|
608
|
+
_auth_settings: List[str] = [
|
|
609
|
+
'BearerAuth'
|
|
610
|
+
]
|
|
611
|
+
|
|
612
|
+
return self.api_client.param_serialize(
|
|
613
|
+
method='DELETE',
|
|
614
|
+
resource_path='/api/v3/organizations/{organisation}/ai/custom-tools/{toolName}',
|
|
615
|
+
path_params=_path_params,
|
|
616
|
+
query_params=_query_params,
|
|
617
|
+
header_params=_header_params,
|
|
618
|
+
body=_body_params,
|
|
619
|
+
post_params=_form_params,
|
|
620
|
+
files=_files,
|
|
621
|
+
auth_settings=_auth_settings,
|
|
622
|
+
collection_formats=_collection_formats,
|
|
623
|
+
_host=_host,
|
|
624
|
+
_request_auth=_request_auth
|
|
625
|
+
)
|
|
626
|
+
|
|
627
|
+
|
|
628
|
+
|
|
629
|
+
|
|
630
|
+
@validate_call
|
|
631
|
+
def list_custom_tools(
|
|
632
|
+
self,
|
|
633
|
+
organisation: Annotated[StrictStr, Field(description="The organisation ID")],
|
|
634
|
+
_request_timeout: Union[
|
|
635
|
+
None,
|
|
636
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
637
|
+
Tuple[
|
|
638
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
639
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
640
|
+
]
|
|
641
|
+
] = None,
|
|
642
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
643
|
+
_content_type: Optional[StrictStr] = None,
|
|
644
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
645
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
646
|
+
) -> ListCustomTools200Response:
|
|
647
|
+
"""List Custom Tools
|
|
648
|
+
|
|
649
|
+
Lists all registered custom edge function tools for an organization.
|
|
650
|
+
|
|
651
|
+
:param organisation: The organisation ID (required)
|
|
652
|
+
:type organisation: str
|
|
653
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
654
|
+
number provided, it will be total request
|
|
655
|
+
timeout. It can also be a pair (tuple) of
|
|
656
|
+
(connection, read) timeouts.
|
|
657
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
658
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
659
|
+
request; this effectively ignores the
|
|
660
|
+
authentication in the spec for a single request.
|
|
661
|
+
:type _request_auth: dict, optional
|
|
662
|
+
:param _content_type: force content-type for the request.
|
|
663
|
+
:type _content_type: str, Optional
|
|
664
|
+
:param _headers: set to override the headers for a single
|
|
665
|
+
request; this effectively ignores the headers
|
|
666
|
+
in the spec for a single request.
|
|
667
|
+
:type _headers: dict, optional
|
|
668
|
+
:param _host_index: set to override the host_index for a single
|
|
669
|
+
request; this effectively ignores the host_index
|
|
670
|
+
in the spec for a single request.
|
|
671
|
+
:type _host_index: int, optional
|
|
672
|
+
:return: Returns the result object.
|
|
673
|
+
""" # noqa: E501
|
|
674
|
+
|
|
675
|
+
_param = self._list_custom_tools_serialize(
|
|
676
|
+
organisation=organisation,
|
|
677
|
+
_request_auth=_request_auth,
|
|
678
|
+
_content_type=_content_type,
|
|
679
|
+
_headers=_headers,
|
|
680
|
+
_host_index=_host_index
|
|
681
|
+
)
|
|
682
|
+
|
|
683
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
684
|
+
'200': "ListCustomTools200Response",
|
|
685
|
+
'403': None,
|
|
686
|
+
'500': None,
|
|
687
|
+
}
|
|
688
|
+
response_data = self.api_client.call_api(
|
|
689
|
+
*_param,
|
|
690
|
+
_request_timeout=_request_timeout
|
|
691
|
+
)
|
|
692
|
+
response_data.read()
|
|
693
|
+
return self.api_client.response_deserialize(
|
|
694
|
+
response_data=response_data,
|
|
695
|
+
response_types_map=_response_types_map,
|
|
696
|
+
).data
|
|
697
|
+
|
|
698
|
+
|
|
699
|
+
@validate_call
|
|
700
|
+
def list_custom_tools_with_http_info(
|
|
701
|
+
self,
|
|
702
|
+
organisation: Annotated[StrictStr, Field(description="The organisation ID")],
|
|
703
|
+
_request_timeout: Union[
|
|
704
|
+
None,
|
|
705
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
706
|
+
Tuple[
|
|
707
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
708
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
709
|
+
]
|
|
710
|
+
] = None,
|
|
711
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
712
|
+
_content_type: Optional[StrictStr] = None,
|
|
713
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
714
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
715
|
+
) -> ApiResponse[ListCustomTools200Response]:
|
|
716
|
+
"""List Custom Tools
|
|
717
|
+
|
|
718
|
+
Lists all registered custom edge function tools for an organization.
|
|
719
|
+
|
|
720
|
+
:param organisation: The organisation ID (required)
|
|
721
|
+
:type organisation: str
|
|
722
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
723
|
+
number provided, it will be total request
|
|
724
|
+
timeout. It can also be a pair (tuple) of
|
|
725
|
+
(connection, read) timeouts.
|
|
726
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
727
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
728
|
+
request; this effectively ignores the
|
|
729
|
+
authentication in the spec for a single request.
|
|
730
|
+
:type _request_auth: dict, optional
|
|
731
|
+
:param _content_type: force content-type for the request.
|
|
732
|
+
:type _content_type: str, Optional
|
|
733
|
+
:param _headers: set to override the headers for a single
|
|
734
|
+
request; this effectively ignores the headers
|
|
735
|
+
in the spec for a single request.
|
|
736
|
+
:type _headers: dict, optional
|
|
737
|
+
:param _host_index: set to override the host_index for a single
|
|
738
|
+
request; this effectively ignores the host_index
|
|
739
|
+
in the spec for a single request.
|
|
740
|
+
:type _host_index: int, optional
|
|
741
|
+
:return: Returns the result object.
|
|
742
|
+
""" # noqa: E501
|
|
743
|
+
|
|
744
|
+
_param = self._list_custom_tools_serialize(
|
|
745
|
+
organisation=organisation,
|
|
746
|
+
_request_auth=_request_auth,
|
|
747
|
+
_content_type=_content_type,
|
|
748
|
+
_headers=_headers,
|
|
749
|
+
_host_index=_host_index
|
|
750
|
+
)
|
|
751
|
+
|
|
752
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
753
|
+
'200': "ListCustomTools200Response",
|
|
754
|
+
'403': None,
|
|
755
|
+
'500': None,
|
|
756
|
+
}
|
|
757
|
+
response_data = self.api_client.call_api(
|
|
758
|
+
*_param,
|
|
759
|
+
_request_timeout=_request_timeout
|
|
760
|
+
)
|
|
761
|
+
response_data.read()
|
|
762
|
+
return self.api_client.response_deserialize(
|
|
763
|
+
response_data=response_data,
|
|
764
|
+
response_types_map=_response_types_map,
|
|
765
|
+
)
|
|
766
|
+
|
|
767
|
+
|
|
768
|
+
@validate_call
|
|
769
|
+
def list_custom_tools_without_preload_content(
|
|
770
|
+
self,
|
|
771
|
+
organisation: Annotated[StrictStr, Field(description="The organisation ID")],
|
|
772
|
+
_request_timeout: Union[
|
|
773
|
+
None,
|
|
774
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
775
|
+
Tuple[
|
|
776
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
777
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
778
|
+
]
|
|
779
|
+
] = None,
|
|
780
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
781
|
+
_content_type: Optional[StrictStr] = None,
|
|
782
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
783
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
784
|
+
) -> RESTResponseType:
|
|
785
|
+
"""List Custom Tools
|
|
786
|
+
|
|
787
|
+
Lists all registered custom edge function tools for an organization.
|
|
788
|
+
|
|
789
|
+
:param organisation: The organisation ID (required)
|
|
790
|
+
:type organisation: str
|
|
791
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
792
|
+
number provided, it will be total request
|
|
793
|
+
timeout. It can also be a pair (tuple) of
|
|
794
|
+
(connection, read) timeouts.
|
|
795
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
796
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
797
|
+
request; this effectively ignores the
|
|
798
|
+
authentication in the spec for a single request.
|
|
799
|
+
:type _request_auth: dict, optional
|
|
800
|
+
:param _content_type: force content-type for the request.
|
|
801
|
+
:type _content_type: str, Optional
|
|
802
|
+
:param _headers: set to override the headers for a single
|
|
803
|
+
request; this effectively ignores the headers
|
|
804
|
+
in the spec for a single request.
|
|
805
|
+
:type _headers: dict, optional
|
|
806
|
+
:param _host_index: set to override the host_index for a single
|
|
807
|
+
request; this effectively ignores the host_index
|
|
808
|
+
in the spec for a single request.
|
|
809
|
+
:type _host_index: int, optional
|
|
810
|
+
:return: Returns the result object.
|
|
811
|
+
""" # noqa: E501
|
|
812
|
+
|
|
813
|
+
_param = self._list_custom_tools_serialize(
|
|
814
|
+
organisation=organisation,
|
|
815
|
+
_request_auth=_request_auth,
|
|
816
|
+
_content_type=_content_type,
|
|
817
|
+
_headers=_headers,
|
|
818
|
+
_host_index=_host_index
|
|
819
|
+
)
|
|
820
|
+
|
|
821
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
822
|
+
'200': "ListCustomTools200Response",
|
|
823
|
+
'403': None,
|
|
824
|
+
'500': None,
|
|
825
|
+
}
|
|
826
|
+
response_data = self.api_client.call_api(
|
|
827
|
+
*_param,
|
|
828
|
+
_request_timeout=_request_timeout
|
|
829
|
+
)
|
|
830
|
+
return response_data.response
|
|
831
|
+
|
|
832
|
+
|
|
833
|
+
def _list_custom_tools_serialize(
|
|
834
|
+
self,
|
|
835
|
+
organisation,
|
|
836
|
+
_request_auth,
|
|
837
|
+
_content_type,
|
|
838
|
+
_headers,
|
|
839
|
+
_host_index,
|
|
840
|
+
) -> RequestSerialized:
|
|
841
|
+
|
|
842
|
+
_host = None
|
|
843
|
+
|
|
844
|
+
_collection_formats: Dict[str, str] = {
|
|
845
|
+
}
|
|
846
|
+
|
|
847
|
+
_path_params: Dict[str, str] = {}
|
|
848
|
+
_query_params: List[Tuple[str, str]] = []
|
|
849
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
850
|
+
_form_params: List[Tuple[str, str]] = []
|
|
851
|
+
_files: Dict[
|
|
852
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
853
|
+
] = {}
|
|
854
|
+
_body_params: Optional[bytes] = None
|
|
855
|
+
|
|
856
|
+
# process the path parameters
|
|
857
|
+
if organisation is not None:
|
|
858
|
+
_path_params['organisation'] = organisation
|
|
859
|
+
# process the query parameters
|
|
860
|
+
# process the header parameters
|
|
861
|
+
# process the form parameters
|
|
862
|
+
# process the body parameter
|
|
863
|
+
|
|
864
|
+
|
|
865
|
+
# set the HTTP header `Accept`
|
|
866
|
+
if 'Accept' not in _header_params:
|
|
867
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
868
|
+
[
|
|
869
|
+
'application/json'
|
|
870
|
+
]
|
|
871
|
+
)
|
|
872
|
+
|
|
873
|
+
|
|
874
|
+
# authentication setting
|
|
875
|
+
_auth_settings: List[str] = [
|
|
876
|
+
'BearerAuth'
|
|
877
|
+
]
|
|
878
|
+
|
|
879
|
+
return self.api_client.param_serialize(
|
|
880
|
+
method='GET',
|
|
881
|
+
resource_path='/api/v3/organizations/{organisation}/ai/custom-tools',
|
|
882
|
+
path_params=_path_params,
|
|
883
|
+
query_params=_query_params,
|
|
884
|
+
header_params=_header_params,
|
|
885
|
+
body=_body_params,
|
|
886
|
+
post_params=_form_params,
|
|
887
|
+
files=_files,
|
|
888
|
+
auth_settings=_auth_settings,
|
|
889
|
+
collection_formats=_collection_formats,
|
|
890
|
+
_host=_host,
|
|
891
|
+
_request_auth=_request_auth
|
|
892
|
+
)
|
|
893
|
+
|
|
894
|
+
|