hyperstack 0.1.23__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.
- hyperstack/__init__.py +420 -0
- hyperstack/api/__init__.py +48 -0
- hyperstack/api/alive_api.py +270 -0
- hyperstack/api/api_key_api.py +1161 -0
- hyperstack/api/assigning_member_role_api.py +615 -0
- hyperstack/api/auth_api.py +292 -0
- hyperstack/api/billing_api.py +5946 -0
- hyperstack/api/calculate_api.py +326 -0
- hyperstack/api/callbacks_api.py +1795 -0
- hyperstack/api/cluster_events_api.py +308 -0
- hyperstack/api/clusters_api.py +1651 -0
- hyperstack/api/compliance_api.py +1169 -0
- hyperstack/api/credit_api.py +295 -0
- hyperstack/api/customer_contract_api.py +922 -0
- hyperstack/api/dashboard_api.py +292 -0
- hyperstack/api/deployment_api.py +1122 -0
- hyperstack/api/environment_api.py +1490 -0
- hyperstack/api/firewall_attachment_api.py +343 -0
- hyperstack/api/firewalls_api.py +1819 -0
- hyperstack/api/flavor_api.py +315 -0
- hyperstack/api/floating_ip_api.py +585 -0
- hyperstack/api/gpu_api.py +292 -0
- hyperstack/api/image_api.py +1228 -0
- hyperstack/api/invite_api.py +857 -0
- hyperstack/api/keypair_api.py +1217 -0
- hyperstack/api/organization_api.py +864 -0
- hyperstack/api/payment_api.py +584 -0
- hyperstack/api/permission_api.py +292 -0
- hyperstack/api/policy_api.py +292 -0
- hyperstack/api/pricebook_api.py +293 -0
- hyperstack/api/profile_api.py +1131 -0
- hyperstack/api/rbac_role_api.py +1434 -0
- hyperstack/api/region_api.py +292 -0
- hyperstack/api/security_rules_api.py +292 -0
- hyperstack/api/snapshot_events_api.py +291 -0
- hyperstack/api/snapshots_api.py +1779 -0
- hyperstack/api/stock_api.py +292 -0
- hyperstack/api/template_api.py +1497 -0
- hyperstack/api/user_api.py +871 -0
- hyperstack/api/user_detail_choice_api.py +295 -0
- hyperstack/api/user_permission_api.py +567 -0
- hyperstack/api/virtual_machine_api.py +5289 -0
- hyperstack/api/virtual_machine_events_api.py +311 -0
- hyperstack/api/vnc_url_api.py +595 -0
- hyperstack/api/volume_api.py +1742 -0
- hyperstack/api/volume_attachment_api.py +650 -0
- hyperstack/api_client.py +797 -0
- hyperstack/api_response.py +21 -0
- hyperstack/configuration.py +488 -0
- hyperstack/exceptions.py +199 -0
- hyperstack/models/__init__.py +360 -0
- hyperstack/models/add_update_flavor_organization_payload.py +111 -0
- hyperstack/models/add_user_info_success_response_model.py +95 -0
- hyperstack/models/allocated_gpu_count_graph.py +89 -0
- hyperstack/models/api_key_fields.py +96 -0
- hyperstack/models/api_key_verify_fields.py +93 -0
- hyperstack/models/assign_rbac_role_payload.py +87 -0
- hyperstack/models/attach_callback_payload.py +87 -0
- hyperstack/models/attach_callback_response.py +91 -0
- hyperstack/models/attach_firewall_with_vm.py +87 -0
- hyperstack/models/attach_firewalls_to_vm_payload.py +87 -0
- hyperstack/models/attach_volume_fields.py +96 -0
- hyperstack/models/attach_volumes.py +99 -0
- hyperstack/models/attach_volumes_payload.py +87 -0
- hyperstack/models/auth_get_token_response_model.py +97 -0
- hyperstack/models/auth_request_login_fields.py +89 -0
- hyperstack/models/auth_request_login_response_model.py +95 -0
- hyperstack/models/auth_user_fields.py +94 -0
- hyperstack/models/auth_user_info_response_model.py +95 -0
- hyperstack/models/billing_immune_resources_response.py +95 -0
- hyperstack/models/billing_response.py +100 -0
- hyperstack/models/billingmetricesfields.py +108 -0
- hyperstack/models/billingmetricesresponse.py +99 -0
- hyperstack/models/cluster_events.py +99 -0
- hyperstack/models/cluster_events_fields.py +104 -0
- hyperstack/models/cluster_fields.py +114 -0
- hyperstack/models/cluster_list_response.py +99 -0
- hyperstack/models/cluster_response.py +95 -0
- hyperstack/models/cluster_versions.py +91 -0
- hyperstack/models/common_response_model.py +89 -0
- hyperstack/models/compliance_fields.py +93 -0
- hyperstack/models/compliance_model_fields.py +99 -0
- hyperstack/models/compliance_payload.py +97 -0
- hyperstack/models/compliance_response.py +95 -0
- hyperstack/models/container_overview_fields.py +95 -0
- hyperstack/models/contract.py +105 -0
- hyperstack/models/contract_billing_history.py +97 -0
- hyperstack/models/contract_billing_history_response_attributes.py +99 -0
- hyperstack/models/contract_billing_history_response_model.py +95 -0
- hyperstack/models/contract_change_payload.py +101 -0
- hyperstack/models/contract_discount_plan_fields.py +103 -0
- hyperstack/models/contract_eligible_instance_fields.py +99 -0
- hyperstack/models/contract_eligible_instances_response.py +101 -0
- hyperstack/models/contract_event_create_model.py +91 -0
- hyperstack/models/contract_gpu_allocation_graph_response.py +95 -0
- hyperstack/models/contract_instance_fields.py +102 -0
- hyperstack/models/contract_instances_response.py +99 -0
- hyperstack/models/contract_resource_payload.py +95 -0
- hyperstack/models/contractl_billing_history_response_metrics.py +87 -0
- hyperstack/models/create_cluster_payload.py +101 -0
- hyperstack/models/create_contract_fields.py +110 -0
- hyperstack/models/create_contract_payload.py +106 -0
- hyperstack/models/create_discount_response.py +95 -0
- hyperstack/models/create_discounts_payload.py +112 -0
- hyperstack/models/create_environment.py +90 -0
- hyperstack/models/create_firewall_payload.py +91 -0
- hyperstack/models/create_firewall_rule_payload.py +104 -0
- hyperstack/models/create_gpu.py +91 -0
- hyperstack/models/create_image.py +91 -0
- hyperstack/models/create_image_payload.py +89 -0
- hyperstack/models/create_instances_payload.py +132 -0
- hyperstack/models/create_instances_response.py +99 -0
- hyperstack/models/create_profile_payload.py +92 -0
- hyperstack/models/create_profile_response.py +95 -0
- hyperstack/models/create_security_rule_payload.py +104 -0
- hyperstack/models/create_snapshot_payload.py +93 -0
- hyperstack/models/create_snapshot_response.py +95 -0
- hyperstack/models/create_update_compliance_response.py +95 -0
- hyperstack/models/create_update_permission_payload.py +93 -0
- hyperstack/models/create_update_permission_response_model.py +95 -0
- hyperstack/models/create_update_policy_payload.py +93 -0
- hyperstack/models/create_update_policy_response_model.py +95 -0
- hyperstack/models/create_update_rbac_role_payload.py +94 -0
- hyperstack/models/create_volume_payload.py +100 -0
- hyperstack/models/creditrechargelimitfield.py +93 -0
- hyperstack/models/creditrechargelimitresponse.py +99 -0
- hyperstack/models/creditrequestresponse.py +99 -0
- hyperstack/models/creditrequests.py +96 -0
- hyperstack/models/customer_contract_detail_response_model.py +95 -0
- hyperstack/models/customer_contract_fields.py +112 -0
- hyperstack/models/customer_fields.py +89 -0
- hyperstack/models/customer_payload.py +89 -0
- hyperstack/models/dashboard_info_response.py +95 -0
- hyperstack/models/data.py +91 -0
- hyperstack/models/deployment_fields.py +98 -0
- hyperstack/models/deployment_fieldsforstartdeployments.py +100 -0
- hyperstack/models/deployments.py +99 -0
- hyperstack/models/detach_volumes.py +99 -0
- hyperstack/models/detach_volumes_payload.py +87 -0
- hyperstack/models/discount_entity_model.py +97 -0
- hyperstack/models/discount_fields.py +100 -0
- hyperstack/models/discount_plan_fields.py +108 -0
- hyperstack/models/discount_resource_fields.py +93 -0
- hyperstack/models/discount_resource_payload.py +93 -0
- hyperstack/models/editlabelofanexisting_vm_payload.py +87 -0
- hyperstack/models/environment.py +95 -0
- hyperstack/models/environment_features.py +87 -0
- hyperstack/models/environment_fields.py +100 -0
- hyperstack/models/environment_fieldsfor_volume.py +87 -0
- hyperstack/models/environments.py +105 -0
- hyperstack/models/error_response_model.py +91 -0
- hyperstack/models/exclude_billing_post_payload.py +91 -0
- hyperstack/models/exclude_billing_post_response.py +91 -0
- hyperstack/models/export_billing_data_request.py +105 -0
- hyperstack/models/export_billing_data_response.py +89 -0
- hyperstack/models/field_change.py +91 -0
- hyperstack/models/firewall_attachment_model.py +98 -0
- hyperstack/models/firewall_attachment_vm_model.py +98 -0
- hyperstack/models/firewall_detail_fields.py +122 -0
- hyperstack/models/firewall_detail_response.py +95 -0
- hyperstack/models/firewall_environment_fields.py +91 -0
- hyperstack/models/firewall_fields.py +102 -0
- hyperstack/models/firewall_response.py +95 -0
- hyperstack/models/firewall_rule.py +95 -0
- hyperstack/models/firewalls_list_response.py +105 -0
- hyperstack/models/flavor_fields.py +120 -0
- hyperstack/models/flavor_item_get_response.py +99 -0
- hyperstack/models/flavor_list_response.py +99 -0
- hyperstack/models/flavor_object_fields.py +95 -0
- hyperstack/models/flavor_payload.py +101 -0
- hyperstack/models/flavor_response.py +95 -0
- hyperstack/models/flavor_vm_fields.py +100 -0
- hyperstack/models/flavor_vms_response.py +99 -0
- hyperstack/models/future_node_model.py +106 -0
- hyperstack/models/future_node_response_model.py +97 -0
- hyperstack/models/future_node_stock_model.py +93 -0
- hyperstack/models/future_node_update_model.py +98 -0
- hyperstack/models/future_nodes_stock_model.py +95 -0
- hyperstack/models/generate_update_api_key_payload.py +89 -0
- hyperstack/models/generate_update_api_key_response_model.py +95 -0
- hyperstack/models/get_all_contract_fields.py +100 -0
- hyperstack/models/get_all_contracts_response_model.py +99 -0
- hyperstack/models/get_all_discount_for_all_organization_response.py +99 -0
- hyperstack/models/get_all_discounts_fields.py +106 -0
- hyperstack/models/get_api_keys_response_model.py +99 -0
- hyperstack/models/get_customer_contracts_list_response_model.py +101 -0
- hyperstack/models/get_discount_detail_response.py +95 -0
- hyperstack/models/get_discount_response.py +99 -0
- hyperstack/models/get_entity_discount_detail_response.py +108 -0
- hyperstack/models/get_invites_response_model.py +99 -0
- hyperstack/models/get_organization_response_model.py +95 -0
- hyperstack/models/get_permissions_response_model.py +99 -0
- hyperstack/models/get_policies_response_model.py +99 -0
- hyperstack/models/get_rbac_roles_response_model.py +99 -0
- hyperstack/models/get_token_payload.py +89 -0
- hyperstack/models/get_user_permissions_response_model.py +99 -0
- hyperstack/models/get_version_response.py +91 -0
- hyperstack/models/getcreditandthresholdinfo.py +91 -0
- hyperstack/models/getcreditandthresholdinfoinresponse.py +95 -0
- hyperstack/models/gpu.py +95 -0
- hyperstack/models/gpu_fields.py +106 -0
- hyperstack/models/gpu_list.py +99 -0
- hyperstack/models/gpu_region_fields.py +89 -0
- hyperstack/models/graph_datetime_value_model.py +89 -0
- hyperstack/models/historical_instance.py +101 -0
- hyperstack/models/historical_instances_fields.py +110 -0
- hyperstack/models/image.py +91 -0
- hyperstack/models/image_fields.py +113 -0
- hyperstack/models/image_get_response.py +101 -0
- hyperstack/models/image_logos.py +99 -0
- hyperstack/models/images.py +99 -0
- hyperstack/models/import_keypair_payload.py +92 -0
- hyperstack/models/import_keypair_response.py +95 -0
- hyperstack/models/infrahub_resource_object_response.py +119 -0
- hyperstack/models/infrahub_resource_object_response_for_customer.py +109 -0
- hyperstack/models/insert_discount_plan_fields.py +112 -0
- hyperstack/models/instance.py +95 -0
- hyperstack/models/instance_environment_fields.py +99 -0
- hyperstack/models/instance_events.py +99 -0
- hyperstack/models/instance_events_fields.py +102 -0
- hyperstack/models/instance_fields.py +156 -0
- hyperstack/models/instance_flavor_fields.py +101 -0
- hyperstack/models/instance_image_fields.py +87 -0
- hyperstack/models/instance_keypair_fields.py +87 -0
- hyperstack/models/instance_overview_fields.py +95 -0
- hyperstack/models/instance_resize_payload.py +93 -0
- hyperstack/models/instances.py +105 -0
- hyperstack/models/instances_summary_fields.py +120 -0
- hyperstack/models/internal_environment_fields.py +94 -0
- hyperstack/models/internal_instance_fields.py +156 -0
- hyperstack/models/internal_instance_flavor_fields.py +104 -0
- hyperstack/models/internal_instance_image_fields.py +95 -0
- hyperstack/models/internal_instance_keypair_fields.py +98 -0
- hyperstack/models/internal_instances_response.py +99 -0
- hyperstack/models/internal_security_rules_fields_for_instance.py +104 -0
- hyperstack/models/internal_volume_attachment_fields.py +98 -0
- hyperstack/models/internal_volume_fields.py +95 -0
- hyperstack/models/internal_volumes_response.py +99 -0
- hyperstack/models/invite_fields.py +94 -0
- hyperstack/models/invite_user_payload.py +88 -0
- hyperstack/models/invite_user_response_model.py +95 -0
- hyperstack/models/keypair_fields.py +98 -0
- hyperstack/models/keypairs.py +105 -0
- hyperstack/models/lable_resonse.py +89 -0
- hyperstack/models/lastdaycostfields.py +93 -0
- hyperstack/models/lastdaycostresponse.py +95 -0
- hyperstack/models/logo_get_response.py +91 -0
- hyperstack/models/logout_payload.py +87 -0
- hyperstack/models/metric_item_fields.py +91 -0
- hyperstack/models/metrics_fields.py +116 -0
- hyperstack/models/name_available_model.py +91 -0
- hyperstack/models/new_configurations_response.py +95 -0
- hyperstack/models/new_model_response.py +101 -0
- hyperstack/models/new_stock_response.py +99 -0
- hyperstack/models/new_stock_retrive_response.py +95 -0
- hyperstack/models/new_stock_update_response_model.py +89 -0
- hyperstack/models/node_model.py +114 -0
- hyperstack/models/node_payload_model.py +97 -0
- hyperstack/models/node_power_usage_model.py +120 -0
- hyperstack/models/node_response_model.py +97 -0
- hyperstack/models/node_stock_payload_model.py +95 -0
- hyperstack/models/node_stock_response_model.py +95 -0
- hyperstack/models/node_stocks_payload.py +93 -0
- hyperstack/models/organization_fields.py +114 -0
- hyperstack/models/organization_level_billing_history.py +99 -0
- hyperstack/models/organization_level_billing_history_resources.py +97 -0
- hyperstack/models/organization_level_billing_history_response_attributes.py +87 -0
- hyperstack/models/organization_level_billing_history_response_metrics.py +97 -0
- hyperstack/models/organization_level_billing_history_response_model.py +95 -0
- hyperstack/models/organization_object_response.py +97 -0
- hyperstack/models/organization_thresholdfields.py +95 -0
- hyperstack/models/organization_user_response_model.py +112 -0
- hyperstack/models/organizationcreditrechargelimitresponse.py +95 -0
- hyperstack/models/organizationthresholdsresponse.py +99 -0
- hyperstack/models/organizationthresholdupdateresponse.py +95 -0
- hyperstack/models/overview_info.py +103 -0
- hyperstack/models/pagination_data.py +91 -0
- hyperstack/models/payment_details_fields.py +106 -0
- hyperstack/models/payment_details_response.py +95 -0
- hyperstack/models/payment_initiate_fields.py +87 -0
- hyperstack/models/payment_initiate_payload.py +87 -0
- hyperstack/models/payment_initiate_response.py +95 -0
- hyperstack/models/permission_fields.py +98 -0
- hyperstack/models/policy_fields.py +104 -0
- hyperstack/models/policy_permission_fields.py +91 -0
- hyperstack/models/power_usage_model.py +89 -0
- hyperstack/models/pricebook_model.py +100 -0
- hyperstack/models/pricebook_resource_object_response.py +107 -0
- hyperstack/models/pricebook_resource_object_response_for_customer.py +99 -0
- hyperstack/models/profile_fields.py +96 -0
- hyperstack/models/profile_list_response.py +99 -0
- hyperstack/models/profile_object_fields.py +89 -0
- hyperstack/models/rbac_role_detail_response_model.py +95 -0
- hyperstack/models/rbac_role_detail_response_model_fixed.py +95 -0
- hyperstack/models/rbac_role_field.py +87 -0
- hyperstack/models/rbac_role_fields.py +114 -0
- hyperstack/models/refresh_token_payload.py +89 -0
- hyperstack/models/region_fields.py +91 -0
- hyperstack/models/region_payload.py +89 -0
- hyperstack/models/region_response.py +95 -0
- hyperstack/models/regions.py +99 -0
- hyperstack/models/remove_member_from_organization_response_model.py +89 -0
- hyperstack/models/remove_member_payload.py +88 -0
- hyperstack/models/request_console.py +91 -0
- hyperstack/models/resource_billing_events_history_metrics.py +95 -0
- hyperstack/models/resource_billing_events_history_response.py +99 -0
- hyperstack/models/resource_billing_response_for_customer.py +95 -0
- hyperstack/models/resource_level_billing_details_attributes.py +91 -0
- hyperstack/models/resource_level_billing_details_metrics.py +101 -0
- hyperstack/models/resource_level_billing_details_vm.py +99 -0
- hyperstack/models/resource_level_billing_details_volume.py +99 -0
- hyperstack/models/resource_level_billing_details_volume_attributes.py +95 -0
- hyperstack/models/resource_level_billing_details_volume_metrics.py +95 -0
- hyperstack/models/resource_level_billing_history.py +105 -0
- hyperstack/models/resource_level_billing_history_resources.py +97 -0
- hyperstack/models/resource_level_billing_history_response_attributes.py +93 -0
- hyperstack/models/resource_level_billing_history_response_metrics.py +91 -0
- hyperstack/models/resource_level_billing_vm_details_resources.py +97 -0
- hyperstack/models/resource_level_billing_volume_details_resources.py +97 -0
- hyperstack/models/resource_level_graph_billing_detail_volume.py +101 -0
- hyperstack/models/resource_level_graph_billing_details_attributes.py +91 -0
- hyperstack/models/resource_level_graph_billing_details_metrics.py +97 -0
- hyperstack/models/resource_level_graph_billing_details_vm.py +101 -0
- hyperstack/models/resource_level_graph_billing_vm_details_resources.py +97 -0
- hyperstack/models/resource_level_graph_billing_volume_details_resources.py +97 -0
- hyperstack/models/resource_level_vm_billing_details_response_model.py +95 -0
- hyperstack/models/resource_level_vm_billing_history_response_model.py +95 -0
- hyperstack/models/resource_level_vm_graph_billing_details_response_model.py +95 -0
- hyperstack/models/resource_level_volume_billing_details_response_model.py +95 -0
- hyperstack/models/resource_level_volume_billing_history_response_model.py +95 -0
- hyperstack/models/resource_level_volume_graph_billing_details_response_model.py +95 -0
- hyperstack/models/resource_object_response_for_customer.py +93 -0
- hyperstack/models/response_model.py +89 -0
- hyperstack/models/role_permission_fields.py +91 -0
- hyperstack/models/role_policy_fields.py +91 -0
- hyperstack/models/security_group_rule.py +95 -0
- hyperstack/models/security_group_rule_fields.py +104 -0
- hyperstack/models/security_rules_fieldsfor_instance.py +104 -0
- hyperstack/models/security_rules_protocol_fields.py +91 -0
- hyperstack/models/set_defaults_payload.py +89 -0
- hyperstack/models/single_visibility_user_response.py +91 -0
- hyperstack/models/snapshot_fields.py +105 -0
- hyperstack/models/snapshot_restore_request.py +89 -0
- hyperstack/models/snapshot_retrieve.py +95 -0
- hyperstack/models/snapshot_retrieve_fields.py +103 -0
- hyperstack/models/snapshots.py +105 -0
- hyperstack/models/start_deployment.py +95 -0
- hyperstack/models/start_deployment_payload.py +93 -0
- hyperstack/models/stock_visibility_user_list_response.py +99 -0
- hyperstack/models/stock_visibility_user_payload.py +87 -0
- hyperstack/models/sub_resource_graph_billing_details_metrics.py +152 -0
- hyperstack/models/sub_resources_costs_response_model.py +101 -0
- hyperstack/models/sub_resources_graph_billing_history_fields.py +97 -0
- hyperstack/models/sub_resources_graph_response_model.py +95 -0
- hyperstack/models/subscribeorunsubscribeupdatepayload.py +87 -0
- hyperstack/models/success_response_model.py +89 -0
- hyperstack/models/template.py +95 -0
- hyperstack/models/template_fields.py +98 -0
- hyperstack/models/templates.py +99 -0
- hyperstack/models/token_fields.py +91 -0
- hyperstack/models/update_contract_payload.py +104 -0
- hyperstack/models/update_discounts_payload.py +102 -0
- hyperstack/models/update_discounts_status_payload.py +87 -0
- hyperstack/models/update_environment.py +88 -0
- hyperstack/models/update_gpu.py +91 -0
- hyperstack/models/update_keypair_name.py +88 -0
- hyperstack/models/update_keypairnameresponse.py +95 -0
- hyperstack/models/update_organization_payload.py +88 -0
- hyperstack/models/update_organization_response_model.py +89 -0
- hyperstack/models/update_template.py +91 -0
- hyperstack/models/user_default_choice_for_user_fields.py +91 -0
- hyperstack/models/user_default_choices_for_user_response.py +99 -0
- hyperstack/models/user_permission_fields.py +91 -0
- hyperstack/models/user_transfer_payload.py +89 -0
- hyperstack/models/userinfopostpayload.py +107 -0
- hyperstack/models/users_info_fields.py +114 -0
- hyperstack/models/users_info_list_response.py +95 -0
- hyperstack/models/verify_api_key_payload.py +87 -0
- hyperstack/models/verify_api_key_response_model.py +95 -0
- hyperstack/models/virtual_machine_usage.py +93 -0
- hyperstack/models/vm_usage_request_payload.py +87 -0
- hyperstack/models/vm_usage_response.py +101 -0
- hyperstack/models/vncurl.py +95 -0
- hyperstack/models/vncurl_fields.py +89 -0
- hyperstack/models/volume.py +95 -0
- hyperstack/models/volume_attachment_fields.py +98 -0
- hyperstack/models/volume_fields.py +116 -0
- hyperstack/models/volume_fieldsfor_instance.py +97 -0
- hyperstack/models/volume_overview_fields.py +91 -0
- hyperstack/models/volume_status_change_fields.py +96 -0
- hyperstack/models/volume_types.py +91 -0
- hyperstack/models/volumes.py +99 -0
- hyperstack/models/volumes_last_status_change_response.py +99 -0
- hyperstack/models/warning_mail_log_fields.py +99 -0
- hyperstack/models/warning_mail_log_response.py +101 -0
- hyperstack/py.typed +0 -0
- hyperstack/rest.py +257 -0
- hyperstack-0.1.23.dist-info/METADATA +16 -0
- hyperstack-0.1.23.dist-info/RECORD +401 -0
- hyperstack-0.1.23.dist-info/WHEEL +5 -0
- hyperstack-0.1.23.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,1651 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Infrahub-API
|
|
5
|
+
|
|
6
|
+
Leverage the Infrahub API and Hyperstack platform to easily create, manage, and scale powerful GPU virtual machines and their associated resources. Access this SDK to automate the deployment of your workloads and streamline your infrastructure management. To contribute, please raise an issue with a bug report, feature request, feedback, or general inquiry.
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.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 StrictInt, StrictStr
|
|
20
|
+
from ..models.cluster_list_response import ClusterListResponse
|
|
21
|
+
from ..models.cluster_response import ClusterResponse
|
|
22
|
+
from ..models.cluster_versions import ClusterVersions
|
|
23
|
+
from ..models.create_cluster_payload import CreateClusterPayload
|
|
24
|
+
from ..models.name_available_model import NameAvailableModel
|
|
25
|
+
from ..models.response_model import ResponseModel
|
|
26
|
+
|
|
27
|
+
from ..api_client import ApiClient, RequestSerialized
|
|
28
|
+
from ..api_response import ApiResponse
|
|
29
|
+
from ..rest import RESTResponseType
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
class ClustersApi:
|
|
33
|
+
"""NOTE: This class is auto generated by OpenAPI Generator
|
|
34
|
+
Ref: https://openapi-generator.tech
|
|
35
|
+
|
|
36
|
+
Do not edit the class manually.
|
|
37
|
+
"""
|
|
38
|
+
|
|
39
|
+
def __init__(self, api_client=None) -> None:
|
|
40
|
+
if api_client is None:
|
|
41
|
+
api_client = ApiClient.get_default()
|
|
42
|
+
self.api_client = api_client
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
@validate_call
|
|
46
|
+
def create_cluster(
|
|
47
|
+
self,
|
|
48
|
+
payload: CreateClusterPayload,
|
|
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
|
+
) -> ClusterResponse:
|
|
62
|
+
"""Create Cluster
|
|
63
|
+
|
|
64
|
+
|
|
65
|
+
:param payload: (required)
|
|
66
|
+
:type payload: CreateClusterPayload
|
|
67
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
68
|
+
number provided, it will be total request
|
|
69
|
+
timeout. It can also be a pair (tuple) of
|
|
70
|
+
(connection, read) timeouts.
|
|
71
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
72
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
73
|
+
request; this effectively ignores the
|
|
74
|
+
authentication in the spec for a single request.
|
|
75
|
+
:type _request_auth: dict, optional
|
|
76
|
+
:param _content_type: force content-type for the request.
|
|
77
|
+
:type _content_type: str, Optional
|
|
78
|
+
:param _headers: set to override the headers for a single
|
|
79
|
+
request; this effectively ignores the headers
|
|
80
|
+
in the spec for a single request.
|
|
81
|
+
:type _headers: dict, optional
|
|
82
|
+
:param _host_index: set to override the host_index for a single
|
|
83
|
+
request; this effectively ignores the host_index
|
|
84
|
+
in the spec for a single request.
|
|
85
|
+
:type _host_index: int, optional
|
|
86
|
+
:return: Returns the result object.
|
|
87
|
+
""" # noqa: E501
|
|
88
|
+
|
|
89
|
+
_param = self._create_cluster_serialize(
|
|
90
|
+
payload=payload,
|
|
91
|
+
_request_auth=_request_auth,
|
|
92
|
+
_content_type=_content_type,
|
|
93
|
+
_headers=_headers,
|
|
94
|
+
_host_index=_host_index
|
|
95
|
+
)
|
|
96
|
+
|
|
97
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
98
|
+
'201': "ClusterResponse",
|
|
99
|
+
'400': "ErrorResponseModel",
|
|
100
|
+
'401': "ErrorResponseModel",
|
|
101
|
+
'404': "ErrorResponseModel",
|
|
102
|
+
'409': "ErrorResponseModel",
|
|
103
|
+
'500': None,
|
|
104
|
+
}
|
|
105
|
+
response_data = self.api_client.call_api(
|
|
106
|
+
*_param,
|
|
107
|
+
_request_timeout=_request_timeout
|
|
108
|
+
)
|
|
109
|
+
response_data.read()
|
|
110
|
+
return self.api_client.response_deserialize(
|
|
111
|
+
response_data=response_data,
|
|
112
|
+
response_types_map=_response_types_map,
|
|
113
|
+
).data
|
|
114
|
+
|
|
115
|
+
|
|
116
|
+
@validate_call
|
|
117
|
+
def create_cluster_with_http_info(
|
|
118
|
+
self,
|
|
119
|
+
payload: CreateClusterPayload,
|
|
120
|
+
_request_timeout: Union[
|
|
121
|
+
None,
|
|
122
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
123
|
+
Tuple[
|
|
124
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
125
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
126
|
+
]
|
|
127
|
+
] = None,
|
|
128
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
129
|
+
_content_type: Optional[StrictStr] = None,
|
|
130
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
131
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
132
|
+
) -> ApiResponse[ClusterResponse]:
|
|
133
|
+
"""Create Cluster
|
|
134
|
+
|
|
135
|
+
|
|
136
|
+
:param payload: (required)
|
|
137
|
+
:type payload: CreateClusterPayload
|
|
138
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
139
|
+
number provided, it will be total request
|
|
140
|
+
timeout. It can also be a pair (tuple) of
|
|
141
|
+
(connection, read) timeouts.
|
|
142
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
143
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
144
|
+
request; this effectively ignores the
|
|
145
|
+
authentication in the spec for a single request.
|
|
146
|
+
:type _request_auth: dict, optional
|
|
147
|
+
:param _content_type: force content-type for the request.
|
|
148
|
+
:type _content_type: str, Optional
|
|
149
|
+
:param _headers: set to override the headers for a single
|
|
150
|
+
request; this effectively ignores the headers
|
|
151
|
+
in the spec for a single request.
|
|
152
|
+
:type _headers: dict, optional
|
|
153
|
+
:param _host_index: set to override the host_index for a single
|
|
154
|
+
request; this effectively ignores the host_index
|
|
155
|
+
in the spec for a single request.
|
|
156
|
+
:type _host_index: int, optional
|
|
157
|
+
:return: Returns the result object.
|
|
158
|
+
""" # noqa: E501
|
|
159
|
+
|
|
160
|
+
_param = self._create_cluster_serialize(
|
|
161
|
+
payload=payload,
|
|
162
|
+
_request_auth=_request_auth,
|
|
163
|
+
_content_type=_content_type,
|
|
164
|
+
_headers=_headers,
|
|
165
|
+
_host_index=_host_index
|
|
166
|
+
)
|
|
167
|
+
|
|
168
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
169
|
+
'201': "ClusterResponse",
|
|
170
|
+
'400': "ErrorResponseModel",
|
|
171
|
+
'401': "ErrorResponseModel",
|
|
172
|
+
'404': "ErrorResponseModel",
|
|
173
|
+
'409': "ErrorResponseModel",
|
|
174
|
+
'500': None,
|
|
175
|
+
}
|
|
176
|
+
response_data = self.api_client.call_api(
|
|
177
|
+
*_param,
|
|
178
|
+
_request_timeout=_request_timeout
|
|
179
|
+
)
|
|
180
|
+
response_data.read()
|
|
181
|
+
return self.api_client.response_deserialize(
|
|
182
|
+
response_data=response_data,
|
|
183
|
+
response_types_map=_response_types_map,
|
|
184
|
+
)
|
|
185
|
+
|
|
186
|
+
|
|
187
|
+
@validate_call
|
|
188
|
+
def create_cluster_without_preload_content(
|
|
189
|
+
self,
|
|
190
|
+
payload: CreateClusterPayload,
|
|
191
|
+
_request_timeout: Union[
|
|
192
|
+
None,
|
|
193
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
194
|
+
Tuple[
|
|
195
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
196
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
197
|
+
]
|
|
198
|
+
] = None,
|
|
199
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
200
|
+
_content_type: Optional[StrictStr] = None,
|
|
201
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
202
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
203
|
+
) -> RESTResponseType:
|
|
204
|
+
"""Create Cluster
|
|
205
|
+
|
|
206
|
+
|
|
207
|
+
:param payload: (required)
|
|
208
|
+
:type payload: CreateClusterPayload
|
|
209
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
210
|
+
number provided, it will be total request
|
|
211
|
+
timeout. It can also be a pair (tuple) of
|
|
212
|
+
(connection, read) timeouts.
|
|
213
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
214
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
215
|
+
request; this effectively ignores the
|
|
216
|
+
authentication in the spec for a single request.
|
|
217
|
+
:type _request_auth: dict, optional
|
|
218
|
+
:param _content_type: force content-type for the request.
|
|
219
|
+
:type _content_type: str, Optional
|
|
220
|
+
:param _headers: set to override the headers for a single
|
|
221
|
+
request; this effectively ignores the headers
|
|
222
|
+
in the spec for a single request.
|
|
223
|
+
:type _headers: dict, optional
|
|
224
|
+
:param _host_index: set to override the host_index for a single
|
|
225
|
+
request; this effectively ignores the host_index
|
|
226
|
+
in the spec for a single request.
|
|
227
|
+
:type _host_index: int, optional
|
|
228
|
+
:return: Returns the result object.
|
|
229
|
+
""" # noqa: E501
|
|
230
|
+
|
|
231
|
+
_param = self._create_cluster_serialize(
|
|
232
|
+
payload=payload,
|
|
233
|
+
_request_auth=_request_auth,
|
|
234
|
+
_content_type=_content_type,
|
|
235
|
+
_headers=_headers,
|
|
236
|
+
_host_index=_host_index
|
|
237
|
+
)
|
|
238
|
+
|
|
239
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
240
|
+
'201': "ClusterResponse",
|
|
241
|
+
'400': "ErrorResponseModel",
|
|
242
|
+
'401': "ErrorResponseModel",
|
|
243
|
+
'404': "ErrorResponseModel",
|
|
244
|
+
'409': "ErrorResponseModel",
|
|
245
|
+
'500': None,
|
|
246
|
+
}
|
|
247
|
+
response_data = self.api_client.call_api(
|
|
248
|
+
*_param,
|
|
249
|
+
_request_timeout=_request_timeout
|
|
250
|
+
)
|
|
251
|
+
return response_data.response
|
|
252
|
+
|
|
253
|
+
|
|
254
|
+
def _create_cluster_serialize(
|
|
255
|
+
self,
|
|
256
|
+
payload,
|
|
257
|
+
_request_auth,
|
|
258
|
+
_content_type,
|
|
259
|
+
_headers,
|
|
260
|
+
_host_index,
|
|
261
|
+
) -> RequestSerialized:
|
|
262
|
+
|
|
263
|
+
_host = None
|
|
264
|
+
|
|
265
|
+
_collection_formats: Dict[str, str] = {
|
|
266
|
+
}
|
|
267
|
+
|
|
268
|
+
_path_params: Dict[str, str] = {}
|
|
269
|
+
_query_params: List[Tuple[str, str]] = []
|
|
270
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
271
|
+
_form_params: List[Tuple[str, str]] = []
|
|
272
|
+
_files: Dict[
|
|
273
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
274
|
+
] = {}
|
|
275
|
+
_body_params: Optional[bytes] = None
|
|
276
|
+
|
|
277
|
+
# process the path parameters
|
|
278
|
+
# process the query parameters
|
|
279
|
+
# process the header parameters
|
|
280
|
+
# process the form parameters
|
|
281
|
+
# process the body parameter
|
|
282
|
+
if payload is not None:
|
|
283
|
+
_body_params = payload
|
|
284
|
+
|
|
285
|
+
|
|
286
|
+
# set the HTTP header `Accept`
|
|
287
|
+
if 'Accept' not in _header_params:
|
|
288
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
289
|
+
[
|
|
290
|
+
'application/json'
|
|
291
|
+
]
|
|
292
|
+
)
|
|
293
|
+
|
|
294
|
+
# set the HTTP header `Content-Type`
|
|
295
|
+
if _content_type:
|
|
296
|
+
_header_params['Content-Type'] = _content_type
|
|
297
|
+
else:
|
|
298
|
+
_default_content_type = (
|
|
299
|
+
self.api_client.select_header_content_type(
|
|
300
|
+
[
|
|
301
|
+
'application/json'
|
|
302
|
+
]
|
|
303
|
+
)
|
|
304
|
+
)
|
|
305
|
+
if _default_content_type is not None:
|
|
306
|
+
_header_params['Content-Type'] = _default_content_type
|
|
307
|
+
|
|
308
|
+
# authentication setting
|
|
309
|
+
_auth_settings: List[str] = [
|
|
310
|
+
'apiKey',
|
|
311
|
+
'accessToken'
|
|
312
|
+
]
|
|
313
|
+
|
|
314
|
+
return self.api_client.param_serialize(
|
|
315
|
+
method='POST',
|
|
316
|
+
resource_path='/core/clusters',
|
|
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_a_cluster(
|
|
334
|
+
self,
|
|
335
|
+
id: StrictInt,
|
|
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
|
+
) -> ResponseModel:
|
|
349
|
+
"""Delete a cluster
|
|
350
|
+
|
|
351
|
+
|
|
352
|
+
:param id: (required)
|
|
353
|
+
:type id: int
|
|
354
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
355
|
+
number provided, it will be total request
|
|
356
|
+
timeout. It can also be a pair (tuple) of
|
|
357
|
+
(connection, read) timeouts.
|
|
358
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
359
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
360
|
+
request; this effectively ignores the
|
|
361
|
+
authentication in the spec for a single request.
|
|
362
|
+
:type _request_auth: dict, optional
|
|
363
|
+
:param _content_type: force content-type for the request.
|
|
364
|
+
:type _content_type: str, Optional
|
|
365
|
+
:param _headers: set to override the headers for a single
|
|
366
|
+
request; this effectively ignores the headers
|
|
367
|
+
in the spec for a single request.
|
|
368
|
+
:type _headers: dict, optional
|
|
369
|
+
:param _host_index: set to override the host_index for a single
|
|
370
|
+
request; this effectively ignores the host_index
|
|
371
|
+
in the spec for a single request.
|
|
372
|
+
:type _host_index: int, optional
|
|
373
|
+
:return: Returns the result object.
|
|
374
|
+
""" # noqa: E501
|
|
375
|
+
|
|
376
|
+
_param = self._delete_a_cluster_serialize(
|
|
377
|
+
id=id,
|
|
378
|
+
_request_auth=_request_auth,
|
|
379
|
+
_content_type=_content_type,
|
|
380
|
+
_headers=_headers,
|
|
381
|
+
_host_index=_host_index
|
|
382
|
+
)
|
|
383
|
+
|
|
384
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
385
|
+
'200': "ResponseModel",
|
|
386
|
+
'400': "ErrorResponseModel",
|
|
387
|
+
'401': "ErrorResponseModel",
|
|
388
|
+
'404': "ErrorResponseModel",
|
|
389
|
+
'500': None,
|
|
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_a_cluster_with_http_info(
|
|
404
|
+
self,
|
|
405
|
+
id: StrictInt,
|
|
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[ResponseModel]:
|
|
419
|
+
"""Delete a cluster
|
|
420
|
+
|
|
421
|
+
|
|
422
|
+
:param id: (required)
|
|
423
|
+
:type id: int
|
|
424
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
425
|
+
number provided, it will be total request
|
|
426
|
+
timeout. It can also be a pair (tuple) of
|
|
427
|
+
(connection, read) timeouts.
|
|
428
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
429
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
430
|
+
request; this effectively ignores the
|
|
431
|
+
authentication in the spec for a single request.
|
|
432
|
+
:type _request_auth: dict, optional
|
|
433
|
+
:param _content_type: force content-type for the request.
|
|
434
|
+
:type _content_type: str, Optional
|
|
435
|
+
:param _headers: set to override the headers for a single
|
|
436
|
+
request; this effectively ignores the headers
|
|
437
|
+
in the spec for a single request.
|
|
438
|
+
:type _headers: dict, optional
|
|
439
|
+
:param _host_index: set to override the host_index for a single
|
|
440
|
+
request; this effectively ignores the host_index
|
|
441
|
+
in the spec for a single request.
|
|
442
|
+
:type _host_index: int, optional
|
|
443
|
+
:return: Returns the result object.
|
|
444
|
+
""" # noqa: E501
|
|
445
|
+
|
|
446
|
+
_param = self._delete_a_cluster_serialize(
|
|
447
|
+
id=id,
|
|
448
|
+
_request_auth=_request_auth,
|
|
449
|
+
_content_type=_content_type,
|
|
450
|
+
_headers=_headers,
|
|
451
|
+
_host_index=_host_index
|
|
452
|
+
)
|
|
453
|
+
|
|
454
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
455
|
+
'200': "ResponseModel",
|
|
456
|
+
'400': "ErrorResponseModel",
|
|
457
|
+
'401': "ErrorResponseModel",
|
|
458
|
+
'404': "ErrorResponseModel",
|
|
459
|
+
'500': None,
|
|
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_a_cluster_without_preload_content(
|
|
474
|
+
self,
|
|
475
|
+
id: StrictInt,
|
|
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 a cluster
|
|
490
|
+
|
|
491
|
+
|
|
492
|
+
:param id: (required)
|
|
493
|
+
:type id: int
|
|
494
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
495
|
+
number provided, it will be total request
|
|
496
|
+
timeout. It can also be a pair (tuple) of
|
|
497
|
+
(connection, read) timeouts.
|
|
498
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
499
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
500
|
+
request; this effectively ignores the
|
|
501
|
+
authentication in the spec for a single request.
|
|
502
|
+
:type _request_auth: dict, optional
|
|
503
|
+
:param _content_type: force content-type for the request.
|
|
504
|
+
:type _content_type: str, Optional
|
|
505
|
+
:param _headers: set to override the headers for a single
|
|
506
|
+
request; this effectively ignores the headers
|
|
507
|
+
in the spec for a single request.
|
|
508
|
+
:type _headers: dict, optional
|
|
509
|
+
:param _host_index: set to override the host_index for a single
|
|
510
|
+
request; this effectively ignores the host_index
|
|
511
|
+
in the spec for a single request.
|
|
512
|
+
:type _host_index: int, optional
|
|
513
|
+
:return: Returns the result object.
|
|
514
|
+
""" # noqa: E501
|
|
515
|
+
|
|
516
|
+
_param = self._delete_a_cluster_serialize(
|
|
517
|
+
id=id,
|
|
518
|
+
_request_auth=_request_auth,
|
|
519
|
+
_content_type=_content_type,
|
|
520
|
+
_headers=_headers,
|
|
521
|
+
_host_index=_host_index
|
|
522
|
+
)
|
|
523
|
+
|
|
524
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
525
|
+
'200': "ResponseModel",
|
|
526
|
+
'400': "ErrorResponseModel",
|
|
527
|
+
'401': "ErrorResponseModel",
|
|
528
|
+
'404': "ErrorResponseModel",
|
|
529
|
+
'500': None,
|
|
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_a_cluster_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
|
+
'apiKey',
|
|
582
|
+
'accessToken'
|
|
583
|
+
]
|
|
584
|
+
|
|
585
|
+
return self.api_client.param_serialize(
|
|
586
|
+
method='DELETE',
|
|
587
|
+
resource_path='/core/clusters/{id}',
|
|
588
|
+
path_params=_path_params,
|
|
589
|
+
query_params=_query_params,
|
|
590
|
+
header_params=_header_params,
|
|
591
|
+
body=_body_params,
|
|
592
|
+
post_params=_form_params,
|
|
593
|
+
files=_files,
|
|
594
|
+
auth_settings=_auth_settings,
|
|
595
|
+
collection_formats=_collection_formats,
|
|
596
|
+
_host=_host,
|
|
597
|
+
_request_auth=_request_auth
|
|
598
|
+
)
|
|
599
|
+
|
|
600
|
+
|
|
601
|
+
|
|
602
|
+
|
|
603
|
+
@validate_call
|
|
604
|
+
def fetch_cluster_name_availability(
|
|
605
|
+
self,
|
|
606
|
+
name: StrictStr,
|
|
607
|
+
_request_timeout: Union[
|
|
608
|
+
None,
|
|
609
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
610
|
+
Tuple[
|
|
611
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
612
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
613
|
+
]
|
|
614
|
+
] = None,
|
|
615
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
616
|
+
_content_type: Optional[StrictStr] = None,
|
|
617
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
618
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
619
|
+
) -> NameAvailableModel:
|
|
620
|
+
"""Fetch cluster name availability
|
|
621
|
+
|
|
622
|
+
Check if a Cluster name is available
|
|
623
|
+
|
|
624
|
+
:param name: (required)
|
|
625
|
+
:type name: str
|
|
626
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
627
|
+
number provided, it will be total request
|
|
628
|
+
timeout. It can also be a pair (tuple) of
|
|
629
|
+
(connection, read) timeouts.
|
|
630
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
631
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
632
|
+
request; this effectively ignores the
|
|
633
|
+
authentication in the spec for a single request.
|
|
634
|
+
:type _request_auth: dict, optional
|
|
635
|
+
:param _content_type: force content-type for the request.
|
|
636
|
+
:type _content_type: str, Optional
|
|
637
|
+
:param _headers: set to override the headers for a single
|
|
638
|
+
request; this effectively ignores the headers
|
|
639
|
+
in the spec for a single request.
|
|
640
|
+
:type _headers: dict, optional
|
|
641
|
+
:param _host_index: set to override the host_index for a single
|
|
642
|
+
request; this effectively ignores the host_index
|
|
643
|
+
in the spec for a single request.
|
|
644
|
+
:type _host_index: int, optional
|
|
645
|
+
:return: Returns the result object.
|
|
646
|
+
""" # noqa: E501
|
|
647
|
+
|
|
648
|
+
_param = self._fetch_cluster_name_availability_serialize(
|
|
649
|
+
name=name,
|
|
650
|
+
_request_auth=_request_auth,
|
|
651
|
+
_content_type=_content_type,
|
|
652
|
+
_headers=_headers,
|
|
653
|
+
_host_index=_host_index
|
|
654
|
+
)
|
|
655
|
+
|
|
656
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
657
|
+
'200': "NameAvailableModel",
|
|
658
|
+
'400': "ErrorResponseModel",
|
|
659
|
+
'401': "ErrorResponseModel",
|
|
660
|
+
'404': "ErrorResponseModel",
|
|
661
|
+
'500': None,
|
|
662
|
+
}
|
|
663
|
+
response_data = self.api_client.call_api(
|
|
664
|
+
*_param,
|
|
665
|
+
_request_timeout=_request_timeout
|
|
666
|
+
)
|
|
667
|
+
response_data.read()
|
|
668
|
+
return self.api_client.response_deserialize(
|
|
669
|
+
response_data=response_data,
|
|
670
|
+
response_types_map=_response_types_map,
|
|
671
|
+
).data
|
|
672
|
+
|
|
673
|
+
|
|
674
|
+
@validate_call
|
|
675
|
+
def fetch_cluster_name_availability_with_http_info(
|
|
676
|
+
self,
|
|
677
|
+
name: StrictStr,
|
|
678
|
+
_request_timeout: Union[
|
|
679
|
+
None,
|
|
680
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
681
|
+
Tuple[
|
|
682
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
683
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
684
|
+
]
|
|
685
|
+
] = None,
|
|
686
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
687
|
+
_content_type: Optional[StrictStr] = None,
|
|
688
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
689
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
690
|
+
) -> ApiResponse[NameAvailableModel]:
|
|
691
|
+
"""Fetch cluster name availability
|
|
692
|
+
|
|
693
|
+
Check if a Cluster name is available
|
|
694
|
+
|
|
695
|
+
:param name: (required)
|
|
696
|
+
:type name: str
|
|
697
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
698
|
+
number provided, it will be total request
|
|
699
|
+
timeout. It can also be a pair (tuple) of
|
|
700
|
+
(connection, read) timeouts.
|
|
701
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
702
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
703
|
+
request; this effectively ignores the
|
|
704
|
+
authentication in the spec for a single request.
|
|
705
|
+
:type _request_auth: dict, optional
|
|
706
|
+
:param _content_type: force content-type for the request.
|
|
707
|
+
:type _content_type: str, Optional
|
|
708
|
+
:param _headers: set to override the headers for a single
|
|
709
|
+
request; this effectively ignores the headers
|
|
710
|
+
in the spec for a single request.
|
|
711
|
+
:type _headers: dict, optional
|
|
712
|
+
:param _host_index: set to override the host_index for a single
|
|
713
|
+
request; this effectively ignores the host_index
|
|
714
|
+
in the spec for a single request.
|
|
715
|
+
:type _host_index: int, optional
|
|
716
|
+
:return: Returns the result object.
|
|
717
|
+
""" # noqa: E501
|
|
718
|
+
|
|
719
|
+
_param = self._fetch_cluster_name_availability_serialize(
|
|
720
|
+
name=name,
|
|
721
|
+
_request_auth=_request_auth,
|
|
722
|
+
_content_type=_content_type,
|
|
723
|
+
_headers=_headers,
|
|
724
|
+
_host_index=_host_index
|
|
725
|
+
)
|
|
726
|
+
|
|
727
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
728
|
+
'200': "NameAvailableModel",
|
|
729
|
+
'400': "ErrorResponseModel",
|
|
730
|
+
'401': "ErrorResponseModel",
|
|
731
|
+
'404': "ErrorResponseModel",
|
|
732
|
+
'500': None,
|
|
733
|
+
}
|
|
734
|
+
response_data = self.api_client.call_api(
|
|
735
|
+
*_param,
|
|
736
|
+
_request_timeout=_request_timeout
|
|
737
|
+
)
|
|
738
|
+
response_data.read()
|
|
739
|
+
return self.api_client.response_deserialize(
|
|
740
|
+
response_data=response_data,
|
|
741
|
+
response_types_map=_response_types_map,
|
|
742
|
+
)
|
|
743
|
+
|
|
744
|
+
|
|
745
|
+
@validate_call
|
|
746
|
+
def fetch_cluster_name_availability_without_preload_content(
|
|
747
|
+
self,
|
|
748
|
+
name: StrictStr,
|
|
749
|
+
_request_timeout: Union[
|
|
750
|
+
None,
|
|
751
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
752
|
+
Tuple[
|
|
753
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
754
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
755
|
+
]
|
|
756
|
+
] = None,
|
|
757
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
758
|
+
_content_type: Optional[StrictStr] = None,
|
|
759
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
760
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
761
|
+
) -> RESTResponseType:
|
|
762
|
+
"""Fetch cluster name availability
|
|
763
|
+
|
|
764
|
+
Check if a Cluster name is available
|
|
765
|
+
|
|
766
|
+
:param name: (required)
|
|
767
|
+
:type name: str
|
|
768
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
769
|
+
number provided, it will be total request
|
|
770
|
+
timeout. It can also be a pair (tuple) of
|
|
771
|
+
(connection, read) timeouts.
|
|
772
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
773
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
774
|
+
request; this effectively ignores the
|
|
775
|
+
authentication in the spec for a single request.
|
|
776
|
+
:type _request_auth: dict, optional
|
|
777
|
+
:param _content_type: force content-type for the request.
|
|
778
|
+
:type _content_type: str, Optional
|
|
779
|
+
:param _headers: set to override the headers for a single
|
|
780
|
+
request; this effectively ignores the headers
|
|
781
|
+
in the spec for a single request.
|
|
782
|
+
:type _headers: dict, optional
|
|
783
|
+
:param _host_index: set to override the host_index for a single
|
|
784
|
+
request; this effectively ignores the host_index
|
|
785
|
+
in the spec for a single request.
|
|
786
|
+
:type _host_index: int, optional
|
|
787
|
+
:return: Returns the result object.
|
|
788
|
+
""" # noqa: E501
|
|
789
|
+
|
|
790
|
+
_param = self._fetch_cluster_name_availability_serialize(
|
|
791
|
+
name=name,
|
|
792
|
+
_request_auth=_request_auth,
|
|
793
|
+
_content_type=_content_type,
|
|
794
|
+
_headers=_headers,
|
|
795
|
+
_host_index=_host_index
|
|
796
|
+
)
|
|
797
|
+
|
|
798
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
799
|
+
'200': "NameAvailableModel",
|
|
800
|
+
'400': "ErrorResponseModel",
|
|
801
|
+
'401': "ErrorResponseModel",
|
|
802
|
+
'404': "ErrorResponseModel",
|
|
803
|
+
'500': None,
|
|
804
|
+
}
|
|
805
|
+
response_data = self.api_client.call_api(
|
|
806
|
+
*_param,
|
|
807
|
+
_request_timeout=_request_timeout
|
|
808
|
+
)
|
|
809
|
+
return response_data.response
|
|
810
|
+
|
|
811
|
+
|
|
812
|
+
def _fetch_cluster_name_availability_serialize(
|
|
813
|
+
self,
|
|
814
|
+
name,
|
|
815
|
+
_request_auth,
|
|
816
|
+
_content_type,
|
|
817
|
+
_headers,
|
|
818
|
+
_host_index,
|
|
819
|
+
) -> RequestSerialized:
|
|
820
|
+
|
|
821
|
+
_host = None
|
|
822
|
+
|
|
823
|
+
_collection_formats: Dict[str, str] = {
|
|
824
|
+
}
|
|
825
|
+
|
|
826
|
+
_path_params: Dict[str, str] = {}
|
|
827
|
+
_query_params: List[Tuple[str, str]] = []
|
|
828
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
829
|
+
_form_params: List[Tuple[str, str]] = []
|
|
830
|
+
_files: Dict[
|
|
831
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
832
|
+
] = {}
|
|
833
|
+
_body_params: Optional[bytes] = None
|
|
834
|
+
|
|
835
|
+
# process the path parameters
|
|
836
|
+
if name is not None:
|
|
837
|
+
_path_params['name'] = name
|
|
838
|
+
# process the query parameters
|
|
839
|
+
# process the header parameters
|
|
840
|
+
# process the form parameters
|
|
841
|
+
# process the body parameter
|
|
842
|
+
|
|
843
|
+
|
|
844
|
+
# set the HTTP header `Accept`
|
|
845
|
+
if 'Accept' not in _header_params:
|
|
846
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
847
|
+
[
|
|
848
|
+
'application/json'
|
|
849
|
+
]
|
|
850
|
+
)
|
|
851
|
+
|
|
852
|
+
|
|
853
|
+
# authentication setting
|
|
854
|
+
_auth_settings: List[str] = [
|
|
855
|
+
'apiKey',
|
|
856
|
+
'accessToken'
|
|
857
|
+
]
|
|
858
|
+
|
|
859
|
+
return self.api_client.param_serialize(
|
|
860
|
+
method='GET',
|
|
861
|
+
resource_path='/core/clusters/name-availability/{name}',
|
|
862
|
+
path_params=_path_params,
|
|
863
|
+
query_params=_query_params,
|
|
864
|
+
header_params=_header_params,
|
|
865
|
+
body=_body_params,
|
|
866
|
+
post_params=_form_params,
|
|
867
|
+
files=_files,
|
|
868
|
+
auth_settings=_auth_settings,
|
|
869
|
+
collection_formats=_collection_formats,
|
|
870
|
+
_host=_host,
|
|
871
|
+
_request_auth=_request_auth
|
|
872
|
+
)
|
|
873
|
+
|
|
874
|
+
|
|
875
|
+
|
|
876
|
+
|
|
877
|
+
@validate_call
|
|
878
|
+
def get_cluster_versions(
|
|
879
|
+
self,
|
|
880
|
+
_request_timeout: Union[
|
|
881
|
+
None,
|
|
882
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
883
|
+
Tuple[
|
|
884
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
885
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
886
|
+
]
|
|
887
|
+
] = None,
|
|
888
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
889
|
+
_content_type: Optional[StrictStr] = None,
|
|
890
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
891
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
892
|
+
) -> ClusterVersions:
|
|
893
|
+
"""GET Cluster Versions
|
|
894
|
+
|
|
895
|
+
|
|
896
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
897
|
+
number provided, it will be total request
|
|
898
|
+
timeout. It can also be a pair (tuple) of
|
|
899
|
+
(connection, read) timeouts.
|
|
900
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
901
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
902
|
+
request; this effectively ignores the
|
|
903
|
+
authentication in the spec for a single request.
|
|
904
|
+
:type _request_auth: dict, optional
|
|
905
|
+
:param _content_type: force content-type for the request.
|
|
906
|
+
:type _content_type: str, Optional
|
|
907
|
+
:param _headers: set to override the headers for a single
|
|
908
|
+
request; this effectively ignores the headers
|
|
909
|
+
in the spec for a single request.
|
|
910
|
+
:type _headers: dict, optional
|
|
911
|
+
:param _host_index: set to override the host_index for a single
|
|
912
|
+
request; this effectively ignores the host_index
|
|
913
|
+
in the spec for a single request.
|
|
914
|
+
:type _host_index: int, optional
|
|
915
|
+
:return: Returns the result object.
|
|
916
|
+
""" # noqa: E501
|
|
917
|
+
|
|
918
|
+
_param = self._get_cluster_versions_serialize(
|
|
919
|
+
_request_auth=_request_auth,
|
|
920
|
+
_content_type=_content_type,
|
|
921
|
+
_headers=_headers,
|
|
922
|
+
_host_index=_host_index
|
|
923
|
+
)
|
|
924
|
+
|
|
925
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
926
|
+
'200': "ClusterVersions",
|
|
927
|
+
'400': "ErrorResponseModel",
|
|
928
|
+
'401': "ErrorResponseModel",
|
|
929
|
+
'500': None,
|
|
930
|
+
}
|
|
931
|
+
response_data = self.api_client.call_api(
|
|
932
|
+
*_param,
|
|
933
|
+
_request_timeout=_request_timeout
|
|
934
|
+
)
|
|
935
|
+
response_data.read()
|
|
936
|
+
return self.api_client.response_deserialize(
|
|
937
|
+
response_data=response_data,
|
|
938
|
+
response_types_map=_response_types_map,
|
|
939
|
+
).data
|
|
940
|
+
|
|
941
|
+
|
|
942
|
+
@validate_call
|
|
943
|
+
def get_cluster_versions_with_http_info(
|
|
944
|
+
self,
|
|
945
|
+
_request_timeout: Union[
|
|
946
|
+
None,
|
|
947
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
948
|
+
Tuple[
|
|
949
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
950
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
951
|
+
]
|
|
952
|
+
] = None,
|
|
953
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
954
|
+
_content_type: Optional[StrictStr] = None,
|
|
955
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
956
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
957
|
+
) -> ApiResponse[ClusterVersions]:
|
|
958
|
+
"""GET Cluster Versions
|
|
959
|
+
|
|
960
|
+
|
|
961
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
962
|
+
number provided, it will be total request
|
|
963
|
+
timeout. It can also be a pair (tuple) of
|
|
964
|
+
(connection, read) timeouts.
|
|
965
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
966
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
967
|
+
request; this effectively ignores the
|
|
968
|
+
authentication in the spec for a single request.
|
|
969
|
+
:type _request_auth: dict, optional
|
|
970
|
+
:param _content_type: force content-type for the request.
|
|
971
|
+
:type _content_type: str, Optional
|
|
972
|
+
:param _headers: set to override the headers for a single
|
|
973
|
+
request; this effectively ignores the headers
|
|
974
|
+
in the spec for a single request.
|
|
975
|
+
:type _headers: dict, optional
|
|
976
|
+
:param _host_index: set to override the host_index for a single
|
|
977
|
+
request; this effectively ignores the host_index
|
|
978
|
+
in the spec for a single request.
|
|
979
|
+
:type _host_index: int, optional
|
|
980
|
+
:return: Returns the result object.
|
|
981
|
+
""" # noqa: E501
|
|
982
|
+
|
|
983
|
+
_param = self._get_cluster_versions_serialize(
|
|
984
|
+
_request_auth=_request_auth,
|
|
985
|
+
_content_type=_content_type,
|
|
986
|
+
_headers=_headers,
|
|
987
|
+
_host_index=_host_index
|
|
988
|
+
)
|
|
989
|
+
|
|
990
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
991
|
+
'200': "ClusterVersions",
|
|
992
|
+
'400': "ErrorResponseModel",
|
|
993
|
+
'401': "ErrorResponseModel",
|
|
994
|
+
'500': None,
|
|
995
|
+
}
|
|
996
|
+
response_data = self.api_client.call_api(
|
|
997
|
+
*_param,
|
|
998
|
+
_request_timeout=_request_timeout
|
|
999
|
+
)
|
|
1000
|
+
response_data.read()
|
|
1001
|
+
return self.api_client.response_deserialize(
|
|
1002
|
+
response_data=response_data,
|
|
1003
|
+
response_types_map=_response_types_map,
|
|
1004
|
+
)
|
|
1005
|
+
|
|
1006
|
+
|
|
1007
|
+
@validate_call
|
|
1008
|
+
def get_cluster_versions_without_preload_content(
|
|
1009
|
+
self,
|
|
1010
|
+
_request_timeout: Union[
|
|
1011
|
+
None,
|
|
1012
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1013
|
+
Tuple[
|
|
1014
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1015
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1016
|
+
]
|
|
1017
|
+
] = None,
|
|
1018
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1019
|
+
_content_type: Optional[StrictStr] = None,
|
|
1020
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1021
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1022
|
+
) -> RESTResponseType:
|
|
1023
|
+
"""GET Cluster Versions
|
|
1024
|
+
|
|
1025
|
+
|
|
1026
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1027
|
+
number provided, it will be total request
|
|
1028
|
+
timeout. It can also be a pair (tuple) of
|
|
1029
|
+
(connection, read) timeouts.
|
|
1030
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1031
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1032
|
+
request; this effectively ignores the
|
|
1033
|
+
authentication in the spec for a single request.
|
|
1034
|
+
:type _request_auth: dict, optional
|
|
1035
|
+
:param _content_type: force content-type for the request.
|
|
1036
|
+
:type _content_type: str, Optional
|
|
1037
|
+
:param _headers: set to override the headers for a single
|
|
1038
|
+
request; this effectively ignores the headers
|
|
1039
|
+
in the spec for a single request.
|
|
1040
|
+
:type _headers: dict, optional
|
|
1041
|
+
:param _host_index: set to override the host_index for a single
|
|
1042
|
+
request; this effectively ignores the host_index
|
|
1043
|
+
in the spec for a single request.
|
|
1044
|
+
:type _host_index: int, optional
|
|
1045
|
+
:return: Returns the result object.
|
|
1046
|
+
""" # noqa: E501
|
|
1047
|
+
|
|
1048
|
+
_param = self._get_cluster_versions_serialize(
|
|
1049
|
+
_request_auth=_request_auth,
|
|
1050
|
+
_content_type=_content_type,
|
|
1051
|
+
_headers=_headers,
|
|
1052
|
+
_host_index=_host_index
|
|
1053
|
+
)
|
|
1054
|
+
|
|
1055
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1056
|
+
'200': "ClusterVersions",
|
|
1057
|
+
'400': "ErrorResponseModel",
|
|
1058
|
+
'401': "ErrorResponseModel",
|
|
1059
|
+
'500': None,
|
|
1060
|
+
}
|
|
1061
|
+
response_data = self.api_client.call_api(
|
|
1062
|
+
*_param,
|
|
1063
|
+
_request_timeout=_request_timeout
|
|
1064
|
+
)
|
|
1065
|
+
return response_data.response
|
|
1066
|
+
|
|
1067
|
+
|
|
1068
|
+
def _get_cluster_versions_serialize(
|
|
1069
|
+
self,
|
|
1070
|
+
_request_auth,
|
|
1071
|
+
_content_type,
|
|
1072
|
+
_headers,
|
|
1073
|
+
_host_index,
|
|
1074
|
+
) -> RequestSerialized:
|
|
1075
|
+
|
|
1076
|
+
_host = None
|
|
1077
|
+
|
|
1078
|
+
_collection_formats: Dict[str, str] = {
|
|
1079
|
+
}
|
|
1080
|
+
|
|
1081
|
+
_path_params: Dict[str, str] = {}
|
|
1082
|
+
_query_params: List[Tuple[str, str]] = []
|
|
1083
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
1084
|
+
_form_params: List[Tuple[str, str]] = []
|
|
1085
|
+
_files: Dict[
|
|
1086
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
1087
|
+
] = {}
|
|
1088
|
+
_body_params: Optional[bytes] = None
|
|
1089
|
+
|
|
1090
|
+
# process the path parameters
|
|
1091
|
+
# process the query parameters
|
|
1092
|
+
# process the header parameters
|
|
1093
|
+
# process the form parameters
|
|
1094
|
+
# process the body parameter
|
|
1095
|
+
|
|
1096
|
+
|
|
1097
|
+
# set the HTTP header `Accept`
|
|
1098
|
+
if 'Accept' not in _header_params:
|
|
1099
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
1100
|
+
[
|
|
1101
|
+
'application/json'
|
|
1102
|
+
]
|
|
1103
|
+
)
|
|
1104
|
+
|
|
1105
|
+
|
|
1106
|
+
# authentication setting
|
|
1107
|
+
_auth_settings: List[str] = [
|
|
1108
|
+
'apiKey',
|
|
1109
|
+
'accessToken'
|
|
1110
|
+
]
|
|
1111
|
+
|
|
1112
|
+
return self.api_client.param_serialize(
|
|
1113
|
+
method='GET',
|
|
1114
|
+
resource_path='/core/clusters/versions',
|
|
1115
|
+
path_params=_path_params,
|
|
1116
|
+
query_params=_query_params,
|
|
1117
|
+
header_params=_header_params,
|
|
1118
|
+
body=_body_params,
|
|
1119
|
+
post_params=_form_params,
|
|
1120
|
+
files=_files,
|
|
1121
|
+
auth_settings=_auth_settings,
|
|
1122
|
+
collection_formats=_collection_formats,
|
|
1123
|
+
_host=_host,
|
|
1124
|
+
_request_auth=_request_auth
|
|
1125
|
+
)
|
|
1126
|
+
|
|
1127
|
+
|
|
1128
|
+
|
|
1129
|
+
|
|
1130
|
+
@validate_call
|
|
1131
|
+
def getting_cluster_detail(
|
|
1132
|
+
self,
|
|
1133
|
+
id: StrictInt,
|
|
1134
|
+
_request_timeout: Union[
|
|
1135
|
+
None,
|
|
1136
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1137
|
+
Tuple[
|
|
1138
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1139
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1140
|
+
]
|
|
1141
|
+
] = None,
|
|
1142
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1143
|
+
_content_type: Optional[StrictStr] = None,
|
|
1144
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1145
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1146
|
+
) -> ClusterResponse:
|
|
1147
|
+
"""Getting Cluster Detail
|
|
1148
|
+
|
|
1149
|
+
|
|
1150
|
+
:param id: (required)
|
|
1151
|
+
:type id: int
|
|
1152
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1153
|
+
number provided, it will be total request
|
|
1154
|
+
timeout. It can also be a pair (tuple) of
|
|
1155
|
+
(connection, read) timeouts.
|
|
1156
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1157
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1158
|
+
request; this effectively ignores the
|
|
1159
|
+
authentication in the spec for a single request.
|
|
1160
|
+
:type _request_auth: dict, optional
|
|
1161
|
+
:param _content_type: force content-type for the request.
|
|
1162
|
+
:type _content_type: str, Optional
|
|
1163
|
+
:param _headers: set to override the headers for a single
|
|
1164
|
+
request; this effectively ignores the headers
|
|
1165
|
+
in the spec for a single request.
|
|
1166
|
+
:type _headers: dict, optional
|
|
1167
|
+
:param _host_index: set to override the host_index for a single
|
|
1168
|
+
request; this effectively ignores the host_index
|
|
1169
|
+
in the spec for a single request.
|
|
1170
|
+
:type _host_index: int, optional
|
|
1171
|
+
:return: Returns the result object.
|
|
1172
|
+
""" # noqa: E501
|
|
1173
|
+
|
|
1174
|
+
_param = self._getting_cluster_detail_serialize(
|
|
1175
|
+
id=id,
|
|
1176
|
+
_request_auth=_request_auth,
|
|
1177
|
+
_content_type=_content_type,
|
|
1178
|
+
_headers=_headers,
|
|
1179
|
+
_host_index=_host_index
|
|
1180
|
+
)
|
|
1181
|
+
|
|
1182
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1183
|
+
'200': "ClusterResponse",
|
|
1184
|
+
'400': "ErrorResponseModel",
|
|
1185
|
+
'401': "ErrorResponseModel",
|
|
1186
|
+
'404': "ErrorResponseModel",
|
|
1187
|
+
'500': None,
|
|
1188
|
+
}
|
|
1189
|
+
response_data = self.api_client.call_api(
|
|
1190
|
+
*_param,
|
|
1191
|
+
_request_timeout=_request_timeout
|
|
1192
|
+
)
|
|
1193
|
+
response_data.read()
|
|
1194
|
+
return self.api_client.response_deserialize(
|
|
1195
|
+
response_data=response_data,
|
|
1196
|
+
response_types_map=_response_types_map,
|
|
1197
|
+
).data
|
|
1198
|
+
|
|
1199
|
+
|
|
1200
|
+
@validate_call
|
|
1201
|
+
def getting_cluster_detail_with_http_info(
|
|
1202
|
+
self,
|
|
1203
|
+
id: StrictInt,
|
|
1204
|
+
_request_timeout: Union[
|
|
1205
|
+
None,
|
|
1206
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1207
|
+
Tuple[
|
|
1208
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1209
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1210
|
+
]
|
|
1211
|
+
] = None,
|
|
1212
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1213
|
+
_content_type: Optional[StrictStr] = None,
|
|
1214
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1215
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1216
|
+
) -> ApiResponse[ClusterResponse]:
|
|
1217
|
+
"""Getting Cluster Detail
|
|
1218
|
+
|
|
1219
|
+
|
|
1220
|
+
:param id: (required)
|
|
1221
|
+
:type id: int
|
|
1222
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1223
|
+
number provided, it will be total request
|
|
1224
|
+
timeout. It can also be a pair (tuple) of
|
|
1225
|
+
(connection, read) timeouts.
|
|
1226
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1227
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1228
|
+
request; this effectively ignores the
|
|
1229
|
+
authentication in the spec for a single request.
|
|
1230
|
+
:type _request_auth: dict, optional
|
|
1231
|
+
:param _content_type: force content-type for the request.
|
|
1232
|
+
:type _content_type: str, Optional
|
|
1233
|
+
:param _headers: set to override the headers for a single
|
|
1234
|
+
request; this effectively ignores the headers
|
|
1235
|
+
in the spec for a single request.
|
|
1236
|
+
:type _headers: dict, optional
|
|
1237
|
+
:param _host_index: set to override the host_index for a single
|
|
1238
|
+
request; this effectively ignores the host_index
|
|
1239
|
+
in the spec for a single request.
|
|
1240
|
+
:type _host_index: int, optional
|
|
1241
|
+
:return: Returns the result object.
|
|
1242
|
+
""" # noqa: E501
|
|
1243
|
+
|
|
1244
|
+
_param = self._getting_cluster_detail_serialize(
|
|
1245
|
+
id=id,
|
|
1246
|
+
_request_auth=_request_auth,
|
|
1247
|
+
_content_type=_content_type,
|
|
1248
|
+
_headers=_headers,
|
|
1249
|
+
_host_index=_host_index
|
|
1250
|
+
)
|
|
1251
|
+
|
|
1252
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1253
|
+
'200': "ClusterResponse",
|
|
1254
|
+
'400': "ErrorResponseModel",
|
|
1255
|
+
'401': "ErrorResponseModel",
|
|
1256
|
+
'404': "ErrorResponseModel",
|
|
1257
|
+
'500': None,
|
|
1258
|
+
}
|
|
1259
|
+
response_data = self.api_client.call_api(
|
|
1260
|
+
*_param,
|
|
1261
|
+
_request_timeout=_request_timeout
|
|
1262
|
+
)
|
|
1263
|
+
response_data.read()
|
|
1264
|
+
return self.api_client.response_deserialize(
|
|
1265
|
+
response_data=response_data,
|
|
1266
|
+
response_types_map=_response_types_map,
|
|
1267
|
+
)
|
|
1268
|
+
|
|
1269
|
+
|
|
1270
|
+
@validate_call
|
|
1271
|
+
def getting_cluster_detail_without_preload_content(
|
|
1272
|
+
self,
|
|
1273
|
+
id: StrictInt,
|
|
1274
|
+
_request_timeout: Union[
|
|
1275
|
+
None,
|
|
1276
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1277
|
+
Tuple[
|
|
1278
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1279
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1280
|
+
]
|
|
1281
|
+
] = None,
|
|
1282
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1283
|
+
_content_type: Optional[StrictStr] = None,
|
|
1284
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1285
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1286
|
+
) -> RESTResponseType:
|
|
1287
|
+
"""Getting Cluster Detail
|
|
1288
|
+
|
|
1289
|
+
|
|
1290
|
+
:param id: (required)
|
|
1291
|
+
:type id: int
|
|
1292
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1293
|
+
number provided, it will be total request
|
|
1294
|
+
timeout. It can also be a pair (tuple) of
|
|
1295
|
+
(connection, read) timeouts.
|
|
1296
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1297
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1298
|
+
request; this effectively ignores the
|
|
1299
|
+
authentication in the spec for a single request.
|
|
1300
|
+
:type _request_auth: dict, optional
|
|
1301
|
+
:param _content_type: force content-type for the request.
|
|
1302
|
+
:type _content_type: str, Optional
|
|
1303
|
+
:param _headers: set to override the headers for a single
|
|
1304
|
+
request; this effectively ignores the headers
|
|
1305
|
+
in the spec for a single request.
|
|
1306
|
+
:type _headers: dict, optional
|
|
1307
|
+
:param _host_index: set to override the host_index for a single
|
|
1308
|
+
request; this effectively ignores the host_index
|
|
1309
|
+
in the spec for a single request.
|
|
1310
|
+
:type _host_index: int, optional
|
|
1311
|
+
:return: Returns the result object.
|
|
1312
|
+
""" # noqa: E501
|
|
1313
|
+
|
|
1314
|
+
_param = self._getting_cluster_detail_serialize(
|
|
1315
|
+
id=id,
|
|
1316
|
+
_request_auth=_request_auth,
|
|
1317
|
+
_content_type=_content_type,
|
|
1318
|
+
_headers=_headers,
|
|
1319
|
+
_host_index=_host_index
|
|
1320
|
+
)
|
|
1321
|
+
|
|
1322
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1323
|
+
'200': "ClusterResponse",
|
|
1324
|
+
'400': "ErrorResponseModel",
|
|
1325
|
+
'401': "ErrorResponseModel",
|
|
1326
|
+
'404': "ErrorResponseModel",
|
|
1327
|
+
'500': None,
|
|
1328
|
+
}
|
|
1329
|
+
response_data = self.api_client.call_api(
|
|
1330
|
+
*_param,
|
|
1331
|
+
_request_timeout=_request_timeout
|
|
1332
|
+
)
|
|
1333
|
+
return response_data.response
|
|
1334
|
+
|
|
1335
|
+
|
|
1336
|
+
def _getting_cluster_detail_serialize(
|
|
1337
|
+
self,
|
|
1338
|
+
id,
|
|
1339
|
+
_request_auth,
|
|
1340
|
+
_content_type,
|
|
1341
|
+
_headers,
|
|
1342
|
+
_host_index,
|
|
1343
|
+
) -> RequestSerialized:
|
|
1344
|
+
|
|
1345
|
+
_host = None
|
|
1346
|
+
|
|
1347
|
+
_collection_formats: Dict[str, str] = {
|
|
1348
|
+
}
|
|
1349
|
+
|
|
1350
|
+
_path_params: Dict[str, str] = {}
|
|
1351
|
+
_query_params: List[Tuple[str, str]] = []
|
|
1352
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
1353
|
+
_form_params: List[Tuple[str, str]] = []
|
|
1354
|
+
_files: Dict[
|
|
1355
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
1356
|
+
] = {}
|
|
1357
|
+
_body_params: Optional[bytes] = None
|
|
1358
|
+
|
|
1359
|
+
# process the path parameters
|
|
1360
|
+
if id is not None:
|
|
1361
|
+
_path_params['id'] = id
|
|
1362
|
+
# process the query parameters
|
|
1363
|
+
# process the header parameters
|
|
1364
|
+
# process the form parameters
|
|
1365
|
+
# process the body parameter
|
|
1366
|
+
|
|
1367
|
+
|
|
1368
|
+
# set the HTTP header `Accept`
|
|
1369
|
+
if 'Accept' not in _header_params:
|
|
1370
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
1371
|
+
[
|
|
1372
|
+
'application/json'
|
|
1373
|
+
]
|
|
1374
|
+
)
|
|
1375
|
+
|
|
1376
|
+
|
|
1377
|
+
# authentication setting
|
|
1378
|
+
_auth_settings: List[str] = [
|
|
1379
|
+
'apiKey',
|
|
1380
|
+
'accessToken'
|
|
1381
|
+
]
|
|
1382
|
+
|
|
1383
|
+
return self.api_client.param_serialize(
|
|
1384
|
+
method='GET',
|
|
1385
|
+
resource_path='/core/clusters/{id}',
|
|
1386
|
+
path_params=_path_params,
|
|
1387
|
+
query_params=_query_params,
|
|
1388
|
+
header_params=_header_params,
|
|
1389
|
+
body=_body_params,
|
|
1390
|
+
post_params=_form_params,
|
|
1391
|
+
files=_files,
|
|
1392
|
+
auth_settings=_auth_settings,
|
|
1393
|
+
collection_formats=_collection_formats,
|
|
1394
|
+
_host=_host,
|
|
1395
|
+
_request_auth=_request_auth
|
|
1396
|
+
)
|
|
1397
|
+
|
|
1398
|
+
|
|
1399
|
+
|
|
1400
|
+
|
|
1401
|
+
@validate_call
|
|
1402
|
+
def list_clusters(
|
|
1403
|
+
self,
|
|
1404
|
+
_request_timeout: Union[
|
|
1405
|
+
None,
|
|
1406
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1407
|
+
Tuple[
|
|
1408
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1409
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1410
|
+
]
|
|
1411
|
+
] = None,
|
|
1412
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1413
|
+
_content_type: Optional[StrictStr] = None,
|
|
1414
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1415
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1416
|
+
) -> ClusterListResponse:
|
|
1417
|
+
"""List Clusters
|
|
1418
|
+
|
|
1419
|
+
|
|
1420
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1421
|
+
number provided, it will be total request
|
|
1422
|
+
timeout. It can also be a pair (tuple) of
|
|
1423
|
+
(connection, read) timeouts.
|
|
1424
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1425
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1426
|
+
request; this effectively ignores the
|
|
1427
|
+
authentication in the spec for a single request.
|
|
1428
|
+
:type _request_auth: dict, optional
|
|
1429
|
+
:param _content_type: force content-type for the request.
|
|
1430
|
+
:type _content_type: str, Optional
|
|
1431
|
+
:param _headers: set to override the headers for a single
|
|
1432
|
+
request; this effectively ignores the headers
|
|
1433
|
+
in the spec for a single request.
|
|
1434
|
+
:type _headers: dict, optional
|
|
1435
|
+
:param _host_index: set to override the host_index for a single
|
|
1436
|
+
request; this effectively ignores the host_index
|
|
1437
|
+
in the spec for a single request.
|
|
1438
|
+
:type _host_index: int, optional
|
|
1439
|
+
:return: Returns the result object.
|
|
1440
|
+
""" # noqa: E501
|
|
1441
|
+
|
|
1442
|
+
_param = self._list_clusters_serialize(
|
|
1443
|
+
_request_auth=_request_auth,
|
|
1444
|
+
_content_type=_content_type,
|
|
1445
|
+
_headers=_headers,
|
|
1446
|
+
_host_index=_host_index
|
|
1447
|
+
)
|
|
1448
|
+
|
|
1449
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1450
|
+
'200': "ClusterListResponse",
|
|
1451
|
+
'400': "ErrorResponseModel",
|
|
1452
|
+
'401': "ErrorResponseModel",
|
|
1453
|
+
'500': None,
|
|
1454
|
+
}
|
|
1455
|
+
response_data = self.api_client.call_api(
|
|
1456
|
+
*_param,
|
|
1457
|
+
_request_timeout=_request_timeout
|
|
1458
|
+
)
|
|
1459
|
+
response_data.read()
|
|
1460
|
+
return self.api_client.response_deserialize(
|
|
1461
|
+
response_data=response_data,
|
|
1462
|
+
response_types_map=_response_types_map,
|
|
1463
|
+
).data
|
|
1464
|
+
|
|
1465
|
+
|
|
1466
|
+
@validate_call
|
|
1467
|
+
def list_clusters_with_http_info(
|
|
1468
|
+
self,
|
|
1469
|
+
_request_timeout: Union[
|
|
1470
|
+
None,
|
|
1471
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1472
|
+
Tuple[
|
|
1473
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1474
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1475
|
+
]
|
|
1476
|
+
] = None,
|
|
1477
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1478
|
+
_content_type: Optional[StrictStr] = None,
|
|
1479
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1480
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1481
|
+
) -> ApiResponse[ClusterListResponse]:
|
|
1482
|
+
"""List Clusters
|
|
1483
|
+
|
|
1484
|
+
|
|
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._list_clusters_serialize(
|
|
1508
|
+
_request_auth=_request_auth,
|
|
1509
|
+
_content_type=_content_type,
|
|
1510
|
+
_headers=_headers,
|
|
1511
|
+
_host_index=_host_index
|
|
1512
|
+
)
|
|
1513
|
+
|
|
1514
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1515
|
+
'200': "ClusterListResponse",
|
|
1516
|
+
'400': "ErrorResponseModel",
|
|
1517
|
+
'401': "ErrorResponseModel",
|
|
1518
|
+
'500': None,
|
|
1519
|
+
}
|
|
1520
|
+
response_data = self.api_client.call_api(
|
|
1521
|
+
*_param,
|
|
1522
|
+
_request_timeout=_request_timeout
|
|
1523
|
+
)
|
|
1524
|
+
response_data.read()
|
|
1525
|
+
return self.api_client.response_deserialize(
|
|
1526
|
+
response_data=response_data,
|
|
1527
|
+
response_types_map=_response_types_map,
|
|
1528
|
+
)
|
|
1529
|
+
|
|
1530
|
+
|
|
1531
|
+
@validate_call
|
|
1532
|
+
def list_clusters_without_preload_content(
|
|
1533
|
+
self,
|
|
1534
|
+
_request_timeout: Union[
|
|
1535
|
+
None,
|
|
1536
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1537
|
+
Tuple[
|
|
1538
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1539
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1540
|
+
]
|
|
1541
|
+
] = None,
|
|
1542
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1543
|
+
_content_type: Optional[StrictStr] = None,
|
|
1544
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1545
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1546
|
+
) -> RESTResponseType:
|
|
1547
|
+
"""List Clusters
|
|
1548
|
+
|
|
1549
|
+
|
|
1550
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1551
|
+
number provided, it will be total request
|
|
1552
|
+
timeout. It can also be a pair (tuple) of
|
|
1553
|
+
(connection, read) timeouts.
|
|
1554
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1555
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1556
|
+
request; this effectively ignores the
|
|
1557
|
+
authentication in the spec for a single request.
|
|
1558
|
+
:type _request_auth: dict, optional
|
|
1559
|
+
:param _content_type: force content-type for the request.
|
|
1560
|
+
:type _content_type: str, Optional
|
|
1561
|
+
:param _headers: set to override the headers for a single
|
|
1562
|
+
request; this effectively ignores the headers
|
|
1563
|
+
in the spec for a single request.
|
|
1564
|
+
:type _headers: dict, optional
|
|
1565
|
+
:param _host_index: set to override the host_index for a single
|
|
1566
|
+
request; this effectively ignores the host_index
|
|
1567
|
+
in the spec for a single request.
|
|
1568
|
+
:type _host_index: int, optional
|
|
1569
|
+
:return: Returns the result object.
|
|
1570
|
+
""" # noqa: E501
|
|
1571
|
+
|
|
1572
|
+
_param = self._list_clusters_serialize(
|
|
1573
|
+
_request_auth=_request_auth,
|
|
1574
|
+
_content_type=_content_type,
|
|
1575
|
+
_headers=_headers,
|
|
1576
|
+
_host_index=_host_index
|
|
1577
|
+
)
|
|
1578
|
+
|
|
1579
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1580
|
+
'200': "ClusterListResponse",
|
|
1581
|
+
'400': "ErrorResponseModel",
|
|
1582
|
+
'401': "ErrorResponseModel",
|
|
1583
|
+
'500': None,
|
|
1584
|
+
}
|
|
1585
|
+
response_data = self.api_client.call_api(
|
|
1586
|
+
*_param,
|
|
1587
|
+
_request_timeout=_request_timeout
|
|
1588
|
+
)
|
|
1589
|
+
return response_data.response
|
|
1590
|
+
|
|
1591
|
+
|
|
1592
|
+
def _list_clusters_serialize(
|
|
1593
|
+
self,
|
|
1594
|
+
_request_auth,
|
|
1595
|
+
_content_type,
|
|
1596
|
+
_headers,
|
|
1597
|
+
_host_index,
|
|
1598
|
+
) -> RequestSerialized:
|
|
1599
|
+
|
|
1600
|
+
_host = None
|
|
1601
|
+
|
|
1602
|
+
_collection_formats: Dict[str, str] = {
|
|
1603
|
+
}
|
|
1604
|
+
|
|
1605
|
+
_path_params: Dict[str, str] = {}
|
|
1606
|
+
_query_params: List[Tuple[str, str]] = []
|
|
1607
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
1608
|
+
_form_params: List[Tuple[str, str]] = []
|
|
1609
|
+
_files: Dict[
|
|
1610
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
1611
|
+
] = {}
|
|
1612
|
+
_body_params: Optional[bytes] = None
|
|
1613
|
+
|
|
1614
|
+
# process the path parameters
|
|
1615
|
+
# process the query parameters
|
|
1616
|
+
# process the header parameters
|
|
1617
|
+
# process the form parameters
|
|
1618
|
+
# process the body parameter
|
|
1619
|
+
|
|
1620
|
+
|
|
1621
|
+
# set the HTTP header `Accept`
|
|
1622
|
+
if 'Accept' not in _header_params:
|
|
1623
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
1624
|
+
[
|
|
1625
|
+
'application/json'
|
|
1626
|
+
]
|
|
1627
|
+
)
|
|
1628
|
+
|
|
1629
|
+
|
|
1630
|
+
# authentication setting
|
|
1631
|
+
_auth_settings: List[str] = [
|
|
1632
|
+
'apiKey',
|
|
1633
|
+
'accessToken'
|
|
1634
|
+
]
|
|
1635
|
+
|
|
1636
|
+
return self.api_client.param_serialize(
|
|
1637
|
+
method='GET',
|
|
1638
|
+
resource_path='/core/clusters',
|
|
1639
|
+
path_params=_path_params,
|
|
1640
|
+
query_params=_query_params,
|
|
1641
|
+
header_params=_header_params,
|
|
1642
|
+
body=_body_params,
|
|
1643
|
+
post_params=_form_params,
|
|
1644
|
+
files=_files,
|
|
1645
|
+
auth_settings=_auth_settings,
|
|
1646
|
+
collection_formats=_collection_formats,
|
|
1647
|
+
_host=_host,
|
|
1648
|
+
_request_auth=_request_auth
|
|
1649
|
+
)
|
|
1650
|
+
|
|
1651
|
+
|