hyperstack-async 1.55.1a0__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_async/__init__.py +434 -0
- hyperstack_async/api/__init__.py +60 -0
- hyperstack_async/api/access_keys_api.py +885 -0
- hyperstack_async/api/alive_api.py +510 -0
- hyperstack_async/api/api_key_api.py +1158 -0
- hyperstack_async/api/assigning_member_role_api.py +613 -0
- hyperstack_async/api/auth_api.py +1340 -0
- hyperstack_async/api/auto_topup_api.py +1376 -0
- hyperstack_async/api/beta_access_api.py +856 -0
- hyperstack_async/api/billing_api.py +12701 -0
- hyperstack_async/api/buckets_api.py +865 -0
- hyperstack_async/api/calculate_api.py +325 -0
- hyperstack_async/api/callbacks_api.py +1789 -0
- hyperstack_async/api/cluster_events_api.py +307 -0
- hyperstack_async/api/clusters_api.py +4884 -0
- hyperstack_async/api/compliance_api.py +1165 -0
- hyperstack_async/api/credit_api.py +297 -0
- hyperstack_async/api/customer_contract_api.py +919 -0
- hyperstack_async/api/dashboard_api.py +291 -0
- hyperstack_async/api/deployment_api.py +1118 -0
- hyperstack_async/api/email_opt_in_out_api.py +875 -0
- hyperstack_async/api/environment_api.py +2033 -0
- hyperstack_async/api/fip_exclusions_api.py +313 -0
- hyperstack_async/api/firewall_attachment_api.py +345 -0
- hyperstack_async/api/firewalls_api.py +1813 -0
- hyperstack_async/api/flavor_api.py +314 -0
- hyperstack_async/api/floating_ip_api.py +586 -0
- hyperstack_async/api/gpu_api.py +291 -0
- hyperstack_async/api/health_api.py +282 -0
- hyperstack_async/api/image_api.py +1224 -0
- hyperstack_async/api/invite_api.py +1127 -0
- hyperstack_async/api/keypair_api.py +1463 -0
- hyperstack_async/api/organization_api.py +861 -0
- hyperstack_async/api/partner_config_api.py +566 -0
- hyperstack_async/api/payment_api.py +865 -0
- hyperstack_async/api/permission_api.py +291 -0
- hyperstack_async/api/policy_api.py +291 -0
- hyperstack_async/api/pricebook_api.py +295 -0
- hyperstack_async/api/profile_api.py +1127 -0
- hyperstack_async/api/rbac_role_api.py +1429 -0
- hyperstack_async/api/region_api.py +291 -0
- hyperstack_async/api/regions_api.py +282 -0
- hyperstack_async/api/security_rules_api.py +291 -0
- hyperstack_async/api/snapshot_events_api.py +290 -0
- hyperstack_async/api/snapshots_api.py +1773 -0
- hyperstack_async/api/stock_api.py +291 -0
- hyperstack_async/api/template_api.py +1492 -0
- hyperstack_async/api/user_api.py +1130 -0
- hyperstack_async/api/user_consent_api.py +1416 -0
- hyperstack_async/api/user_consent_events_api.py +307 -0
- hyperstack_async/api/user_detail_choice_api.py +294 -0
- hyperstack_async/api/user_permission_api.py +565 -0
- hyperstack_async/api/virtual_machine_api.py +6246 -0
- hyperstack_async/api/virtual_machine_events_api.py +310 -0
- hyperstack_async/api/vnc_url_api.py +599 -0
- hyperstack_async/api/volume_api.py +2042 -0
- hyperstack_async/api/volume_attachment_api.py +950 -0
- hyperstack_async/api/vouchers_api.py +326 -0
- hyperstack_async/api_client.py +800 -0
- hyperstack_async/api_response.py +21 -0
- hyperstack_async/configuration.py +591 -0
- hyperstack_async/exceptions.py +199 -0
- hyperstack_async/models/__init__.py +362 -0
- hyperstack_async/models/access_token_field.py +100 -0
- hyperstack_async/models/add_user_info_success_response_model.py +108 -0
- hyperstack_async/models/allocated_gpu_count_graph.py +102 -0
- hyperstack_async/models/allowed_countries_response.py +102 -0
- hyperstack_async/models/api_key_fields.py +109 -0
- hyperstack_async/models/assign_rbac_role_payload.py +100 -0
- hyperstack_async/models/attach_callback_payload.py +100 -0
- hyperstack_async/models/attach_callback_response.py +104 -0
- hyperstack_async/models/attach_firewall_with_vm.py +100 -0
- hyperstack_async/models/attach_firewalls_to_vm_payload.py +100 -0
- hyperstack_async/models/attach_volume_fields.py +113 -0
- hyperstack_async/models/attach_volumes.py +112 -0
- hyperstack_async/models/attach_volumes_payload.py +102 -0
- hyperstack_async/models/attachments_fields_for_volume.py +108 -0
- hyperstack_async/models/attributes.py +110 -0
- hyperstack_async/models/auth_get_token_response_model.py +108 -0
- hyperstack_async/models/auth_user_fields.py +107 -0
- hyperstack_async/models/auth_user_info_response_model.py +108 -0
- hyperstack_async/models/auto_topup.py +108 -0
- hyperstack_async/models/auto_topup_error_response.py +104 -0
- hyperstack_async/models/auto_topup_status_schema.py +104 -0
- hyperstack_async/models/beta_access_request_fields.py +121 -0
- hyperstack_async/models/beta_access_request_payload.py +102 -0
- hyperstack_async/models/beta_access_request_response_model.py +108 -0
- hyperstack_async/models/beta_access_status_item.py +115 -0
- hyperstack_async/models/beta_access_status_response_model.py +112 -0
- hyperstack_async/models/billing_history.py +110 -0
- hyperstack_async/models/billing_history_data_synthesis_details.py +118 -0
- hyperstack_async/models/billing_history_fine_tuning.py +118 -0
- hyperstack_async/models/billing_history_image_generation_details.py +118 -0
- hyperstack_async/models/billing_history_model_evalutation_details.py +118 -0
- hyperstack_async/models/billing_history_serverless_inference.py +118 -0
- hyperstack_async/models/billing_history_serverless_inference_details.py +118 -0
- hyperstack_async/models/billing_metrices_fields.py +121 -0
- hyperstack_async/models/billing_metrices_response.py +112 -0
- hyperstack_async/models/cluster_events.py +112 -0
- hyperstack_async/models/cluster_events_fields.py +117 -0
- hyperstack_async/models/cluster_fields.py +147 -0
- hyperstack_async/models/cluster_flavor_fields.py +126 -0
- hyperstack_async/models/cluster_list_response.py +112 -0
- hyperstack_async/models/cluster_node_fields.py +125 -0
- hyperstack_async/models/cluster_node_group_fields.py +133 -0
- hyperstack_async/models/cluster_node_group_firewall_fields.py +104 -0
- hyperstack_async/models/cluster_node_groups_create_response.py +118 -0
- hyperstack_async/models/cluster_node_groups_get_response.py +108 -0
- hyperstack_async/models/cluster_node_groups_list_response.py +112 -0
- hyperstack_async/models/cluster_node_instance_fields.py +114 -0
- hyperstack_async/models/cluster_nodes_list_response.py +112 -0
- hyperstack_async/models/cluster_response.py +108 -0
- hyperstack_async/models/cluster_version.py +111 -0
- hyperstack_async/models/cluster_versions.py +112 -0
- hyperstack_async/models/colors.py +110 -0
- hyperstack_async/models/common_response_model.py +102 -0
- hyperstack_async/models/compatible_flavor.py +108 -0
- hyperstack_async/models/compliance_fields.py +106 -0
- hyperstack_async/models/compliance_model_fields.py +112 -0
- hyperstack_async/models/compliance_payload.py +110 -0
- hyperstack_async/models/compliance_response.py +108 -0
- hyperstack_async/models/consent_action_response.py +106 -0
- hyperstack_async/models/consent_block.py +112 -0
- hyperstack_async/models/consent_events_response.py +114 -0
- hyperstack_async/models/consent_template.py +110 -0
- hyperstack_async/models/consent_templates_response.py +100 -0
- hyperstack_async/models/container_overview_fields.py +108 -0
- hyperstack_async/models/contract.py +118 -0
- hyperstack_async/models/contract_discount_plan_fields.py +118 -0
- hyperstack_async/models/contract_gpu_allocation_graph_response.py +108 -0
- hyperstack_async/models/contract_instance_fields.py +121 -0
- hyperstack_async/models/contract_instances_response.py +112 -0
- hyperstack_async/models/create_auto_topup_payload.py +102 -0
- hyperstack_async/models/create_auto_topup_response.py +108 -0
- hyperstack_async/models/create_cluster_node_fields.py +115 -0
- hyperstack_async/models/create_cluster_node_group_payload.py +120 -0
- hyperstack_async/models/create_cluster_payload.py +137 -0
- hyperstack_async/models/create_environment.py +103 -0
- hyperstack_async/models/create_firewall_payload.py +104 -0
- hyperstack_async/models/create_firewall_rule_payload.py +117 -0
- hyperstack_async/models/create_image.py +104 -0
- hyperstack_async/models/create_image_payload.py +102 -0
- hyperstack_async/models/create_instances_payload.py +149 -0
- hyperstack_async/models/create_instances_response.py +112 -0
- hyperstack_async/models/create_profile_payload.py +105 -0
- hyperstack_async/models/create_profile_response.py +108 -0
- hyperstack_async/models/create_security_rule_payload.py +117 -0
- hyperstack_async/models/create_snapshot_payload.py +104 -0
- hyperstack_async/models/create_snapshot_response.py +108 -0
- hyperstack_async/models/create_update_compliance_response.py +108 -0
- hyperstack_async/models/create_update_rbac_role_payload.py +107 -0
- hyperstack_async/models/create_volume_payload.py +113 -0
- hyperstack_async/models/customer_contract_detail_response_model.py +108 -0
- hyperstack_async/models/customer_contract_fields.py +125 -0
- hyperstack_async/models/dashboard_info_response.py +108 -0
- hyperstack_async/models/data_synthesis_billing_history_details_response_schema.py +108 -0
- hyperstack_async/models/delete_cluster_nodes_fields.py +100 -0
- hyperstack_async/models/deployment_fields.py +111 -0
- hyperstack_async/models/deployment_fields_for_start_deployments.py +113 -0
- hyperstack_async/models/deployments.py +112 -0
- hyperstack_async/models/detach_volumes.py +112 -0
- hyperstack_async/models/detach_volumes_payload.py +100 -0
- hyperstack_async/models/disable_auto_topup_response.py +108 -0
- hyperstack_async/models/edit_label_of_an_existing_vm_payload.py +100 -0
- hyperstack_async/models/email_category.py +122 -0
- hyperstack_async/models/email_category_child.py +114 -0
- hyperstack_async/models/email_preferences_response.py +108 -0
- hyperstack_async/models/environment.py +108 -0
- hyperstack_async/models/environment_features.py +112 -0
- hyperstack_async/models/environment_fields.py +113 -0
- hyperstack_async/models/environment_fields_for_volume.py +104 -0
- hyperstack_async/models/environments.py +118 -0
- hyperstack_async/models/error_response_model.py +104 -0
- hyperstack_async/models/firewall_attachment_model.py +111 -0
- hyperstack_async/models/firewall_attachment_vm_model.py +111 -0
- hyperstack_async/models/firewall_detail_fields.py +135 -0
- hyperstack_async/models/firewall_detail_response.py +108 -0
- hyperstack_async/models/firewall_environment_fields.py +104 -0
- hyperstack_async/models/firewall_fields.py +115 -0
- hyperstack_async/models/firewall_response.py +108 -0
- hyperstack_async/models/firewall_rule.py +108 -0
- hyperstack_async/models/firewalls_list_response.py +118 -0
- hyperstack_async/models/flavor_fields.py +135 -0
- hyperstack_async/models/flavor_item_get_response.py +112 -0
- hyperstack_async/models/flavor_label_fields.py +102 -0
- hyperstack_async/models/flavor_list_response.py +112 -0
- hyperstack_async/models/flavor_object_fields.py +108 -0
- hyperstack_async/models/flavor_restrictions.py +112 -0
- hyperstack_async/models/generate_update_api_key_payload.py +103 -0
- hyperstack_async/models/generate_update_api_key_response_model.py +108 -0
- hyperstack_async/models/get_api_keys_response_model.py +112 -0
- hyperstack_async/models/get_auto_topup_response.py +108 -0
- hyperstack_async/models/get_credit_and_threshold_info.py +104 -0
- hyperstack_async/models/get_credit_and_threshold_info_in_response.py +108 -0
- hyperstack_async/models/get_customer_contracts_list_response_model.py +114 -0
- hyperstack_async/models/get_instance_logs_response.py +100 -0
- hyperstack_async/models/get_invites_response_model.py +112 -0
- hyperstack_async/models/get_organization_response_model.py +108 -0
- hyperstack_async/models/get_permissions_response_model.py +112 -0
- hyperstack_async/models/get_policies_response_model.py +112 -0
- hyperstack_async/models/get_rbac_roles_response_model.py +112 -0
- hyperstack_async/models/get_user_permissions_response_model.py +112 -0
- hyperstack_async/models/gpu_fields.py +119 -0
- hyperstack_async/models/gpu_list.py +112 -0
- hyperstack_async/models/gpu_region_fields.py +102 -0
- hyperstack_async/models/graph_datetime_value_model.py +102 -0
- hyperstack_async/models/image.py +104 -0
- hyperstack_async/models/image_fields.py +132 -0
- hyperstack_async/models/image_generation_billing_history_details_response_schema.py +108 -0
- hyperstack_async/models/image_get_response.py +114 -0
- hyperstack_async/models/images.py +112 -0
- hyperstack_async/models/import_keypair_payload.py +105 -0
- hyperstack_async/models/import_keypair_response.py +108 -0
- hyperstack_async/models/infrahub_resource_object_response_for_customer.py +122 -0
- hyperstack_async/models/instance.py +108 -0
- hyperstack_async/models/instance_enhanced_metrics_fields.py +100 -0
- hyperstack_async/models/instance_environment_fields.py +112 -0
- hyperstack_async/models/instance_events.py +112 -0
- hyperstack_async/models/instance_events_fields.py +115 -0
- hyperstack_async/models/instance_fields.py +185 -0
- hyperstack_async/models/instance_flavor_fields.py +126 -0
- hyperstack_async/models/instance_image_fields.py +100 -0
- hyperstack_async/models/instance_keypair_fields.py +100 -0
- hyperstack_async/models/instance_overview_fields.py +108 -0
- hyperstack_async/models/instance_resize_payload.py +106 -0
- hyperstack_async/models/instances.py +118 -0
- hyperstack_async/models/invite_fields.py +107 -0
- hyperstack_async/models/invite_user_payload.py +108 -0
- hyperstack_async/models/invite_user_response_model.py +108 -0
- hyperstack_async/models/keypair_environment_features.py +112 -0
- hyperstack_async/models/keypair_environment_fields.py +113 -0
- hyperstack_async/models/keypair_fields.py +115 -0
- hyperstack_async/models/keypairs.py +118 -0
- hyperstack_async/models/lable_resonse.py +102 -0
- hyperstack_async/models/last_day_cost_fields.py +106 -0
- hyperstack_async/models/last_day_cost_response.py +108 -0
- hyperstack_async/models/logos.py +106 -0
- hyperstack_async/models/manual_reconciliation_model.py +108 -0
- hyperstack_async/models/master_flavors_response.py +112 -0
- hyperstack_async/models/metric_item_fields.py +104 -0
- hyperstack_async/models/metrics.py +114 -0
- hyperstack_async/models/metrics_fields.py +129 -0
- hyperstack_async/models/mfa_status_fields.py +100 -0
- hyperstack_async/models/mfa_status_response.py +108 -0
- hyperstack_async/models/model_evaluation_billing_history_details_response_schema.py +108 -0
- hyperstack_async/models/name_available_model.py +104 -0
- hyperstack_async/models/new_configurations_response.py +108 -0
- hyperstack_async/models/new_model_response.py +114 -0
- hyperstack_async/models/new_stock_response.py +112 -0
- hyperstack_async/models/new_stock_retrive_response.py +108 -0
- hyperstack_async/models/object_storage_access_key_create_request.py +103 -0
- hyperstack_async/models/object_storage_access_key_create_response.py +114 -0
- hyperstack_async/models/object_storage_access_key_list_response.py +114 -0
- hyperstack_async/models/object_storage_access_key_response.py +112 -0
- hyperstack_async/models/object_storage_bucket_list_response.py +110 -0
- hyperstack_async/models/object_storage_bucket_response.py +114 -0
- hyperstack_async/models/object_storage_delete_response.py +100 -0
- hyperstack_async/models/object_storage_error_response.py +104 -0
- hyperstack_async/models/object_storage_health_response.py +100 -0
- hyperstack_async/models/object_storage_pagination_meta.py +104 -0
- hyperstack_async/models/object_storage_region_list_response.py +108 -0
- hyperstack_async/models/object_storage_region_response.py +100 -0
- hyperstack_async/models/object_storage_regions_enum.py +36 -0
- hyperstack_async/models/organization_fields.py +127 -0
- hyperstack_async/models/organization_level_billing_history.py +112 -0
- hyperstack_async/models/organization_level_billing_history_resources.py +110 -0
- hyperstack_async/models/organization_level_billing_history_response_attributes.py +100 -0
- hyperstack_async/models/organization_level_billing_history_response_metrics.py +110 -0
- hyperstack_async/models/organization_level_billing_history_response_model.py +108 -0
- hyperstack_async/models/organization_threshold_fields.py +108 -0
- hyperstack_async/models/organization_threshold_update_response.py +108 -0
- hyperstack_async/models/organization_thresholds_response.py +112 -0
- hyperstack_async/models/organization_user_response_model.py +125 -0
- hyperstack_async/models/overview_info.py +116 -0
- hyperstack_async/models/pagination.py +104 -0
- hyperstack_async/models/pagination_data.py +104 -0
- hyperstack_async/models/partner_config.py +124 -0
- hyperstack_async/models/payment_details_fields.py +131 -0
- hyperstack_async/models/payment_details_response.py +112 -0
- hyperstack_async/models/payment_initiate_fields.py +100 -0
- hyperstack_async/models/payment_initiate_payload.py +100 -0
- hyperstack_async/models/payment_initiate_response.py +108 -0
- hyperstack_async/models/permission_fields.py +111 -0
- hyperstack_async/models/policy_fields.py +117 -0
- hyperstack_async/models/policy_permission_fields.py +104 -0
- hyperstack_async/models/pricebook_model.py +113 -0
- hyperstack_async/models/pricebook_resource_object_response_for_customer.py +112 -0
- hyperstack_async/models/primary_color.py +102 -0
- hyperstack_async/models/profile_fields.py +109 -0
- hyperstack_async/models/profile_list_response.py +112 -0
- hyperstack_async/models/profile_object_fields.py +102 -0
- hyperstack_async/models/rbac_role_detail_response_model.py +108 -0
- hyperstack_async/models/rbac_role_detail_response_model_fixed.py +108 -0
- hyperstack_async/models/rbac_role_field.py +100 -0
- hyperstack_async/models/rbac_role_fields.py +127 -0
- hyperstack_async/models/record_consent_request.py +132 -0
- hyperstack_async/models/redeem_voucher_payload.py +100 -0
- hyperstack_async/models/region_fields.py +120 -0
- hyperstack_async/models/regions.py +112 -0
- hyperstack_async/models/remove_member_from_organization_response_model.py +102 -0
- hyperstack_async/models/remove_member_payload.py +101 -0
- hyperstack_async/models/request_console.py +104 -0
- hyperstack_async/models/request_instance_logs_payload.py +100 -0
- hyperstack_async/models/request_instance_logs_response.py +100 -0
- hyperstack_async/models/resource_billing_events_history_metrics.py +108 -0
- hyperstack_async/models/resource_billing_events_history_response.py +112 -0
- hyperstack_async/models/resource_billing_response_for_customer.py +108 -0
- hyperstack_async/models/resource_level_billing_bucket_details_resources.py +110 -0
- hyperstack_async/models/resource_level_billing_details_attributes.py +104 -0
- hyperstack_async/models/resource_level_billing_details_metrics.py +114 -0
- hyperstack_async/models/resource_level_billing_details_vm.py +112 -0
- hyperstack_async/models/resource_level_billing_details_volume.py +112 -0
- hyperstack_async/models/resource_level_billing_details_volume_attributes.py +108 -0
- hyperstack_async/models/resource_level_billing_details_volume_metrics.py +108 -0
- hyperstack_async/models/resource_level_billing_history.py +118 -0
- hyperstack_async/models/resource_level_billing_history_resources.py +110 -0
- hyperstack_async/models/resource_level_billing_history_resources_cluster.py +120 -0
- hyperstack_async/models/resource_level_billing_history_response_attributes.py +108 -0
- hyperstack_async/models/resource_level_billing_history_response_metrics.py +104 -0
- hyperstack_async/models/resource_level_billing_vm_details_resources.py +110 -0
- hyperstack_async/models/resource_level_billing_volume_details_resources.py +110 -0
- hyperstack_async/models/resource_level_bucket_billing_details_response_model.py +108 -0
- hyperstack_async/models/resource_level_bucket_billing_history_response_model.py +108 -0
- hyperstack_async/models/resource_level_cluster_billing_details_response_model.py +108 -0
- hyperstack_async/models/resource_level_cluster_billing_history_response_model.py +108 -0
- hyperstack_async/models/resource_level_cluster_graph_billing_details_response_model.py +108 -0
- hyperstack_async/models/resource_level_graph_billing_detail_volume.py +114 -0
- hyperstack_async/models/resource_level_graph_billing_details_attributes.py +104 -0
- hyperstack_async/models/resource_level_graph_billing_details_bucket.py +114 -0
- hyperstack_async/models/resource_level_graph_billing_details_metrics.py +110 -0
- hyperstack_async/models/resource_level_graph_billing_details_vm.py +114 -0
- hyperstack_async/models/resource_level_graph_billing_vm_details_resources.py +110 -0
- hyperstack_async/models/resource_level_graph_billing_volume_details_resources.py +110 -0
- hyperstack_async/models/resource_level_vm_billing_details_response_model.py +108 -0
- hyperstack_async/models/resource_level_vm_billing_history_response_model.py +108 -0
- hyperstack_async/models/resource_level_vm_graph_billing_details_response_model.py +108 -0
- hyperstack_async/models/resource_level_volume_billing_details_response_model.py +108 -0
- hyperstack_async/models/resource_level_volume_billing_history_response_model.py +108 -0
- hyperstack_async/models/resource_level_volume_graph_billing_details_response_model.py +108 -0
- hyperstack_async/models/resource_object_response_for_customer.py +106 -0
- hyperstack_async/models/response_model.py +102 -0
- hyperstack_async/models/role_permission_fields.py +104 -0
- hyperstack_async/models/role_policy_fields.py +104 -0
- hyperstack_async/models/secondary_color.py +102 -0
- hyperstack_async/models/security_group_rule.py +108 -0
- hyperstack_async/models/security_group_rule_fields.py +117 -0
- hyperstack_async/models/security_rules_fields_for_instance.py +117 -0
- hyperstack_async/models/security_rules_protocol_fields.py +104 -0
- hyperstack_async/models/serverless_inferenced_billing_history_details_response_schema.py +108 -0
- hyperstack_async/models/snapshot_fields.py +123 -0
- hyperstack_async/models/snapshot_restore_request.py +102 -0
- hyperstack_async/models/snapshot_retrieve.py +108 -0
- hyperstack_async/models/snapshot_retrieve_fields.py +143 -0
- hyperstack_async/models/snapshots.py +118 -0
- hyperstack_async/models/start_deployment.py +108 -0
- hyperstack_async/models/start_deployment_payload.py +106 -0
- hyperstack_async/models/sub_resource_graph_billing_details_metrics.py +165 -0
- hyperstack_async/models/sub_resources_costs_response_model.py +114 -0
- hyperstack_async/models/sub_resources_graph_billing_history_fields.py +110 -0
- hyperstack_async/models/sub_resources_graph_response_model.py +108 -0
- hyperstack_async/models/subscribe_or_unsubscribe_update_payload.py +100 -0
- hyperstack_async/models/supported_keypair_public_key_types_response.py +104 -0
- hyperstack_async/models/template.py +108 -0
- hyperstack_async/models/template_fields.py +111 -0
- hyperstack_async/models/templates.py +112 -0
- hyperstack_async/models/token_based_billing_history_response.py +108 -0
- hyperstack_async/models/update_auto_topup_payload.py +102 -0
- hyperstack_async/models/update_auto_topup_response.py +108 -0
- hyperstack_async/models/update_cluster_node_group_payload.py +105 -0
- hyperstack_async/models/update_consent_request.py +123 -0
- hyperstack_async/models/update_email_preference_input.py +100 -0
- hyperstack_async/models/update_email_preference_response.py +100 -0
- hyperstack_async/models/update_environment.py +101 -0
- hyperstack_async/models/update_keypair_name.py +101 -0
- hyperstack_async/models/update_keypair_name_response.py +108 -0
- hyperstack_async/models/update_organization_payload.py +101 -0
- hyperstack_async/models/update_organization_response_model.py +102 -0
- hyperstack_async/models/update_template.py +104 -0
- hyperstack_async/models/update_volume_attachment_payload.py +100 -0
- hyperstack_async/models/update_volume_payload.py +100 -0
- hyperstack_async/models/update_volume_response.py +110 -0
- hyperstack_async/models/uris.py +112 -0
- hyperstack_async/models/user_consent.py +116 -0
- hyperstack_async/models/user_consent_event.py +112 -0
- hyperstack_async/models/user_consents_response.py +108 -0
- hyperstack_async/models/user_default_choice_for_user_fields.py +104 -0
- hyperstack_async/models/user_default_choices_for_user_response.py +112 -0
- hyperstack_async/models/user_enhanced_metrics_payload.py +100 -0
- hyperstack_async/models/user_enhanced_metrics_response.py +110 -0
- hyperstack_async/models/user_enhanced_metrics_response_fields.py +100 -0
- hyperstack_async/models/user_info_post_payload.py +120 -0
- hyperstack_async/models/user_organizations_response.py +108 -0
- hyperstack_async/models/user_permission_fields.py +104 -0
- hyperstack_async/models/users_info_fields.py +129 -0
- hyperstack_async/models/users_info_list_response.py +108 -0
- hyperstack_async/models/vm_quota.py +112 -0
- hyperstack_async/models/vncurl.py +108 -0
- hyperstack_async/models/vncurl_fields.py +102 -0
- hyperstack_async/models/volume.py +108 -0
- hyperstack_async/models/volume_attachment_fields.py +115 -0
- hyperstack_async/models/volume_fields.py +139 -0
- hyperstack_async/models/volume_fields_for_instance.py +110 -0
- hyperstack_async/models/volume_overview_fields.py +104 -0
- hyperstack_async/models/volume_types.py +104 -0
- hyperstack_async/models/volumes.py +118 -0
- hyperstack_async/models/volumes_fields.py +137 -0
- hyperstack_async/models/voucher.py +110 -0
- hyperstack_async/models/voucher_redeem_response_schema.py +108 -0
- hyperstack_async/models/workload_billing_history_response.py +108 -0
- hyperstack_async/py.typed +0 -0
- hyperstack_async/rest.py +215 -0
- hyperstack_async-1.55.1a0.dist-info/METADATA +25 -0
- hyperstack_async-1.55.1a0.dist-info/RECORD +415 -0
- hyperstack_async-1.55.1a0.dist-info/WHEEL +5 -0
- hyperstack_async-1.55.1a0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,4884 @@
|
|
|
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 Field, StrictInt, StrictStr
|
|
20
|
+
from typing import Optional
|
|
21
|
+
from typing_extensions import Annotated
|
|
22
|
+
from ..models.cluster_list_response import ClusterListResponse
|
|
23
|
+
from ..models.cluster_node_groups_create_response import ClusterNodeGroupsCreateResponse
|
|
24
|
+
from ..models.cluster_node_groups_get_response import ClusterNodeGroupsGetResponse
|
|
25
|
+
from ..models.cluster_node_groups_list_response import ClusterNodeGroupsListResponse
|
|
26
|
+
from ..models.cluster_nodes_list_response import ClusterNodesListResponse
|
|
27
|
+
from ..models.cluster_response import ClusterResponse
|
|
28
|
+
from ..models.cluster_versions import ClusterVersions
|
|
29
|
+
from ..models.create_cluster_node_fields import CreateClusterNodeFields
|
|
30
|
+
from ..models.create_cluster_node_group_payload import CreateClusterNodeGroupPayload
|
|
31
|
+
from ..models.create_cluster_payload import CreateClusterPayload
|
|
32
|
+
from ..models.delete_cluster_nodes_fields import DeleteClusterNodesFields
|
|
33
|
+
from ..models.manual_reconciliation_model import ManualReconciliationModel
|
|
34
|
+
from ..models.master_flavors_response import MasterFlavorsResponse
|
|
35
|
+
from ..models.name_available_model import NameAvailableModel
|
|
36
|
+
from ..models.response_model import ResponseModel
|
|
37
|
+
from ..models.update_cluster_node_group_payload import UpdateClusterNodeGroupPayload
|
|
38
|
+
|
|
39
|
+
from ..api_client import ApiClient, RequestSerialized
|
|
40
|
+
from ..api_response import ApiResponse
|
|
41
|
+
from ..rest import RESTResponseType
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
class ClustersApi:
|
|
45
|
+
"""NOTE: This class is auto generated by OpenAPI Generator
|
|
46
|
+
Ref: https://openapi-generator.tech
|
|
47
|
+
|
|
48
|
+
Do not edit the class manually.
|
|
49
|
+
"""
|
|
50
|
+
|
|
51
|
+
def __init__(self, api_client=None) -> None:
|
|
52
|
+
if api_client is None:
|
|
53
|
+
api_client = ApiClient.get_default()
|
|
54
|
+
self.api_client = api_client
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
@validate_call
|
|
58
|
+
async def create_cluster(
|
|
59
|
+
self,
|
|
60
|
+
payload: CreateClusterPayload,
|
|
61
|
+
_request_timeout: Union[
|
|
62
|
+
None,
|
|
63
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
64
|
+
Tuple[
|
|
65
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
66
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
67
|
+
]
|
|
68
|
+
] = None,
|
|
69
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
70
|
+
_content_type: Optional[StrictStr] = None,
|
|
71
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
72
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
73
|
+
) -> ClusterResponse:
|
|
74
|
+
"""Create Cluster
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
:param payload: (required)
|
|
78
|
+
:type payload: CreateClusterPayload
|
|
79
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
80
|
+
number provided, it will be total request
|
|
81
|
+
timeout. It can also be a pair (tuple) of
|
|
82
|
+
(connection, read) timeouts.
|
|
83
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
84
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
85
|
+
request; this effectively ignores the
|
|
86
|
+
authentication in the spec for a single request.
|
|
87
|
+
:type _request_auth: dict, optional
|
|
88
|
+
:param _content_type: force content-type for the request.
|
|
89
|
+
:type _content_type: str, Optional
|
|
90
|
+
:param _headers: set to override the headers for a single
|
|
91
|
+
request; this effectively ignores the headers
|
|
92
|
+
in the spec for a single request.
|
|
93
|
+
:type _headers: dict, optional
|
|
94
|
+
:param _host_index: set to override the host_index for a single
|
|
95
|
+
request; this effectively ignores the host_index
|
|
96
|
+
in the spec for a single request.
|
|
97
|
+
:type _host_index: int, optional
|
|
98
|
+
:return: Returns the result object.
|
|
99
|
+
""" # noqa: E501
|
|
100
|
+
|
|
101
|
+
_param = self._create_cluster_serialize(
|
|
102
|
+
payload=payload,
|
|
103
|
+
_request_auth=_request_auth,
|
|
104
|
+
_content_type=_content_type,
|
|
105
|
+
_headers=_headers,
|
|
106
|
+
_host_index=_host_index
|
|
107
|
+
)
|
|
108
|
+
|
|
109
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
110
|
+
'201': "ClusterResponse",
|
|
111
|
+
'400': "ErrorResponseModel",
|
|
112
|
+
'401': "ErrorResponseModel",
|
|
113
|
+
'404': "ErrorResponseModel",
|
|
114
|
+
'409': "ErrorResponseModel",
|
|
115
|
+
'422': "ErrorResponseModel",
|
|
116
|
+
'500': None,
|
|
117
|
+
}
|
|
118
|
+
response_data = await self.api_client.call_api(
|
|
119
|
+
*_param,
|
|
120
|
+
_request_timeout=_request_timeout
|
|
121
|
+
)
|
|
122
|
+
await response_data.read()
|
|
123
|
+
return self.api_client.response_deserialize(
|
|
124
|
+
response_data=response_data,
|
|
125
|
+
response_types_map=_response_types_map,
|
|
126
|
+
).data
|
|
127
|
+
|
|
128
|
+
|
|
129
|
+
@validate_call
|
|
130
|
+
async def create_cluster_with_http_info(
|
|
131
|
+
self,
|
|
132
|
+
payload: CreateClusterPayload,
|
|
133
|
+
_request_timeout: Union[
|
|
134
|
+
None,
|
|
135
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
136
|
+
Tuple[
|
|
137
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
138
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
139
|
+
]
|
|
140
|
+
] = None,
|
|
141
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
142
|
+
_content_type: Optional[StrictStr] = None,
|
|
143
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
144
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
145
|
+
) -> ApiResponse[ClusterResponse]:
|
|
146
|
+
"""Create Cluster
|
|
147
|
+
|
|
148
|
+
|
|
149
|
+
:param payload: (required)
|
|
150
|
+
:type payload: CreateClusterPayload
|
|
151
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
152
|
+
number provided, it will be total request
|
|
153
|
+
timeout. It can also be a pair (tuple) of
|
|
154
|
+
(connection, read) timeouts.
|
|
155
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
156
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
157
|
+
request; this effectively ignores the
|
|
158
|
+
authentication in the spec for a single request.
|
|
159
|
+
:type _request_auth: dict, optional
|
|
160
|
+
:param _content_type: force content-type for the request.
|
|
161
|
+
:type _content_type: str, Optional
|
|
162
|
+
:param _headers: set to override the headers for a single
|
|
163
|
+
request; this effectively ignores the headers
|
|
164
|
+
in the spec for a single request.
|
|
165
|
+
:type _headers: dict, optional
|
|
166
|
+
:param _host_index: set to override the host_index for a single
|
|
167
|
+
request; this effectively ignores the host_index
|
|
168
|
+
in the spec for a single request.
|
|
169
|
+
:type _host_index: int, optional
|
|
170
|
+
:return: Returns the result object.
|
|
171
|
+
""" # noqa: E501
|
|
172
|
+
|
|
173
|
+
_param = self._create_cluster_serialize(
|
|
174
|
+
payload=payload,
|
|
175
|
+
_request_auth=_request_auth,
|
|
176
|
+
_content_type=_content_type,
|
|
177
|
+
_headers=_headers,
|
|
178
|
+
_host_index=_host_index
|
|
179
|
+
)
|
|
180
|
+
|
|
181
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
182
|
+
'201': "ClusterResponse",
|
|
183
|
+
'400': "ErrorResponseModel",
|
|
184
|
+
'401': "ErrorResponseModel",
|
|
185
|
+
'404': "ErrorResponseModel",
|
|
186
|
+
'409': "ErrorResponseModel",
|
|
187
|
+
'422': "ErrorResponseModel",
|
|
188
|
+
'500': None,
|
|
189
|
+
}
|
|
190
|
+
response_data = await self.api_client.call_api(
|
|
191
|
+
*_param,
|
|
192
|
+
_request_timeout=_request_timeout
|
|
193
|
+
)
|
|
194
|
+
await response_data.read()
|
|
195
|
+
return self.api_client.response_deserialize(
|
|
196
|
+
response_data=response_data,
|
|
197
|
+
response_types_map=_response_types_map,
|
|
198
|
+
)
|
|
199
|
+
|
|
200
|
+
|
|
201
|
+
@validate_call
|
|
202
|
+
async def create_cluster_without_preload_content(
|
|
203
|
+
self,
|
|
204
|
+
payload: CreateClusterPayload,
|
|
205
|
+
_request_timeout: Union[
|
|
206
|
+
None,
|
|
207
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
208
|
+
Tuple[
|
|
209
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
210
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
211
|
+
]
|
|
212
|
+
] = None,
|
|
213
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
214
|
+
_content_type: Optional[StrictStr] = None,
|
|
215
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
216
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
217
|
+
) -> RESTResponseType:
|
|
218
|
+
"""Create Cluster
|
|
219
|
+
|
|
220
|
+
|
|
221
|
+
:param payload: (required)
|
|
222
|
+
:type payload: CreateClusterPayload
|
|
223
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
224
|
+
number provided, it will be total request
|
|
225
|
+
timeout. It can also be a pair (tuple) of
|
|
226
|
+
(connection, read) timeouts.
|
|
227
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
228
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
229
|
+
request; this effectively ignores the
|
|
230
|
+
authentication in the spec for a single request.
|
|
231
|
+
:type _request_auth: dict, optional
|
|
232
|
+
:param _content_type: force content-type for the request.
|
|
233
|
+
:type _content_type: str, Optional
|
|
234
|
+
:param _headers: set to override the headers for a single
|
|
235
|
+
request; this effectively ignores the headers
|
|
236
|
+
in the spec for a single request.
|
|
237
|
+
:type _headers: dict, optional
|
|
238
|
+
:param _host_index: set to override the host_index for a single
|
|
239
|
+
request; this effectively ignores the host_index
|
|
240
|
+
in the spec for a single request.
|
|
241
|
+
:type _host_index: int, optional
|
|
242
|
+
:return: Returns the result object.
|
|
243
|
+
""" # noqa: E501
|
|
244
|
+
|
|
245
|
+
_param = self._create_cluster_serialize(
|
|
246
|
+
payload=payload,
|
|
247
|
+
_request_auth=_request_auth,
|
|
248
|
+
_content_type=_content_type,
|
|
249
|
+
_headers=_headers,
|
|
250
|
+
_host_index=_host_index
|
|
251
|
+
)
|
|
252
|
+
|
|
253
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
254
|
+
'201': "ClusterResponse",
|
|
255
|
+
'400': "ErrorResponseModel",
|
|
256
|
+
'401': "ErrorResponseModel",
|
|
257
|
+
'404': "ErrorResponseModel",
|
|
258
|
+
'409': "ErrorResponseModel",
|
|
259
|
+
'422': "ErrorResponseModel",
|
|
260
|
+
'500': None,
|
|
261
|
+
}
|
|
262
|
+
response_data = await self.api_client.call_api(
|
|
263
|
+
*_param,
|
|
264
|
+
_request_timeout=_request_timeout
|
|
265
|
+
)
|
|
266
|
+
return response_data.response
|
|
267
|
+
|
|
268
|
+
|
|
269
|
+
def _create_cluster_serialize(
|
|
270
|
+
self,
|
|
271
|
+
payload,
|
|
272
|
+
_request_auth,
|
|
273
|
+
_content_type,
|
|
274
|
+
_headers,
|
|
275
|
+
_host_index,
|
|
276
|
+
) -> RequestSerialized:
|
|
277
|
+
|
|
278
|
+
_host = None
|
|
279
|
+
|
|
280
|
+
_collection_formats: Dict[str, str] = {
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
_path_params: Dict[str, str] = {}
|
|
284
|
+
_query_params: List[Tuple[str, str]] = []
|
|
285
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
286
|
+
_form_params: List[Tuple[str, str]] = []
|
|
287
|
+
_files: Dict[
|
|
288
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
289
|
+
] = {}
|
|
290
|
+
_body_params: Optional[bytes] = None
|
|
291
|
+
|
|
292
|
+
# process the path parameters
|
|
293
|
+
# process the query parameters
|
|
294
|
+
# process the header parameters
|
|
295
|
+
# process the form parameters
|
|
296
|
+
# process the body parameter
|
|
297
|
+
if payload is not None:
|
|
298
|
+
_body_params = payload
|
|
299
|
+
|
|
300
|
+
|
|
301
|
+
# set the HTTP header `Accept`
|
|
302
|
+
if 'Accept' not in _header_params:
|
|
303
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
304
|
+
[
|
|
305
|
+
'application/json'
|
|
306
|
+
]
|
|
307
|
+
)
|
|
308
|
+
|
|
309
|
+
# set the HTTP header `Content-Type`
|
|
310
|
+
if _content_type:
|
|
311
|
+
_header_params['Content-Type'] = _content_type
|
|
312
|
+
else:
|
|
313
|
+
_default_content_type = (
|
|
314
|
+
self.api_client.select_header_content_type(
|
|
315
|
+
[
|
|
316
|
+
'application/json'
|
|
317
|
+
]
|
|
318
|
+
)
|
|
319
|
+
)
|
|
320
|
+
if _default_content_type is not None:
|
|
321
|
+
_header_params['Content-Type'] = _default_content_type
|
|
322
|
+
|
|
323
|
+
# authentication setting
|
|
324
|
+
_auth_settings: List[str] = [
|
|
325
|
+
'apiKey'
|
|
326
|
+
]
|
|
327
|
+
|
|
328
|
+
return self.api_client.param_serialize(
|
|
329
|
+
method='POST',
|
|
330
|
+
resource_path='/core/clusters',
|
|
331
|
+
path_params=_path_params,
|
|
332
|
+
query_params=_query_params,
|
|
333
|
+
header_params=_header_params,
|
|
334
|
+
body=_body_params,
|
|
335
|
+
post_params=_form_params,
|
|
336
|
+
files=_files,
|
|
337
|
+
auth_settings=_auth_settings,
|
|
338
|
+
collection_formats=_collection_formats,
|
|
339
|
+
_host=_host,
|
|
340
|
+
_request_auth=_request_auth
|
|
341
|
+
)
|
|
342
|
+
|
|
343
|
+
|
|
344
|
+
|
|
345
|
+
|
|
346
|
+
@validate_call
|
|
347
|
+
async def create_node(
|
|
348
|
+
self,
|
|
349
|
+
cluster_id: StrictInt,
|
|
350
|
+
payload: CreateClusterNodeFields,
|
|
351
|
+
_request_timeout: Union[
|
|
352
|
+
None,
|
|
353
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
354
|
+
Tuple[
|
|
355
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
356
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
357
|
+
]
|
|
358
|
+
] = None,
|
|
359
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
360
|
+
_content_type: Optional[StrictStr] = None,
|
|
361
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
362
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
363
|
+
) -> ClusterNodesListResponse:
|
|
364
|
+
"""Create Node
|
|
365
|
+
|
|
366
|
+
|
|
367
|
+
:param cluster_id: (required)
|
|
368
|
+
:type cluster_id: int
|
|
369
|
+
:param payload: (required)
|
|
370
|
+
:type payload: CreateClusterNodeFields
|
|
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._create_node_serialize(
|
|
394
|
+
cluster_id=cluster_id,
|
|
395
|
+
payload=payload,
|
|
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
|
+
'201': "ClusterNodesListResponse",
|
|
404
|
+
'400': "ErrorResponseModel",
|
|
405
|
+
'401': "ErrorResponseModel",
|
|
406
|
+
'404': "ErrorResponseModel",
|
|
407
|
+
'409': "ErrorResponseModel",
|
|
408
|
+
'500': None,
|
|
409
|
+
}
|
|
410
|
+
response_data = await self.api_client.call_api(
|
|
411
|
+
*_param,
|
|
412
|
+
_request_timeout=_request_timeout
|
|
413
|
+
)
|
|
414
|
+
await response_data.read()
|
|
415
|
+
return self.api_client.response_deserialize(
|
|
416
|
+
response_data=response_data,
|
|
417
|
+
response_types_map=_response_types_map,
|
|
418
|
+
).data
|
|
419
|
+
|
|
420
|
+
|
|
421
|
+
@validate_call
|
|
422
|
+
async def create_node_with_http_info(
|
|
423
|
+
self,
|
|
424
|
+
cluster_id: StrictInt,
|
|
425
|
+
payload: CreateClusterNodeFields,
|
|
426
|
+
_request_timeout: Union[
|
|
427
|
+
None,
|
|
428
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
429
|
+
Tuple[
|
|
430
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
431
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
432
|
+
]
|
|
433
|
+
] = None,
|
|
434
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
435
|
+
_content_type: Optional[StrictStr] = None,
|
|
436
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
437
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
438
|
+
) -> ApiResponse[ClusterNodesListResponse]:
|
|
439
|
+
"""Create Node
|
|
440
|
+
|
|
441
|
+
|
|
442
|
+
:param cluster_id: (required)
|
|
443
|
+
:type cluster_id: int
|
|
444
|
+
:param payload: (required)
|
|
445
|
+
:type payload: CreateClusterNodeFields
|
|
446
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
447
|
+
number provided, it will be total request
|
|
448
|
+
timeout. It can also be a pair (tuple) of
|
|
449
|
+
(connection, read) timeouts.
|
|
450
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
451
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
452
|
+
request; this effectively ignores the
|
|
453
|
+
authentication in the spec for a single request.
|
|
454
|
+
:type _request_auth: dict, optional
|
|
455
|
+
:param _content_type: force content-type for the request.
|
|
456
|
+
:type _content_type: str, Optional
|
|
457
|
+
:param _headers: set to override the headers for a single
|
|
458
|
+
request; this effectively ignores the headers
|
|
459
|
+
in the spec for a single request.
|
|
460
|
+
:type _headers: dict, optional
|
|
461
|
+
:param _host_index: set to override the host_index for a single
|
|
462
|
+
request; this effectively ignores the host_index
|
|
463
|
+
in the spec for a single request.
|
|
464
|
+
:type _host_index: int, optional
|
|
465
|
+
:return: Returns the result object.
|
|
466
|
+
""" # noqa: E501
|
|
467
|
+
|
|
468
|
+
_param = self._create_node_serialize(
|
|
469
|
+
cluster_id=cluster_id,
|
|
470
|
+
payload=payload,
|
|
471
|
+
_request_auth=_request_auth,
|
|
472
|
+
_content_type=_content_type,
|
|
473
|
+
_headers=_headers,
|
|
474
|
+
_host_index=_host_index
|
|
475
|
+
)
|
|
476
|
+
|
|
477
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
478
|
+
'201': "ClusterNodesListResponse",
|
|
479
|
+
'400': "ErrorResponseModel",
|
|
480
|
+
'401': "ErrorResponseModel",
|
|
481
|
+
'404': "ErrorResponseModel",
|
|
482
|
+
'409': "ErrorResponseModel",
|
|
483
|
+
'500': None,
|
|
484
|
+
}
|
|
485
|
+
response_data = await self.api_client.call_api(
|
|
486
|
+
*_param,
|
|
487
|
+
_request_timeout=_request_timeout
|
|
488
|
+
)
|
|
489
|
+
await response_data.read()
|
|
490
|
+
return self.api_client.response_deserialize(
|
|
491
|
+
response_data=response_data,
|
|
492
|
+
response_types_map=_response_types_map,
|
|
493
|
+
)
|
|
494
|
+
|
|
495
|
+
|
|
496
|
+
@validate_call
|
|
497
|
+
async def create_node_without_preload_content(
|
|
498
|
+
self,
|
|
499
|
+
cluster_id: StrictInt,
|
|
500
|
+
payload: CreateClusterNodeFields,
|
|
501
|
+
_request_timeout: Union[
|
|
502
|
+
None,
|
|
503
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
504
|
+
Tuple[
|
|
505
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
506
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
507
|
+
]
|
|
508
|
+
] = None,
|
|
509
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
510
|
+
_content_type: Optional[StrictStr] = None,
|
|
511
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
512
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
513
|
+
) -> RESTResponseType:
|
|
514
|
+
"""Create Node
|
|
515
|
+
|
|
516
|
+
|
|
517
|
+
:param cluster_id: (required)
|
|
518
|
+
:type cluster_id: int
|
|
519
|
+
:param payload: (required)
|
|
520
|
+
:type payload: CreateClusterNodeFields
|
|
521
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
522
|
+
number provided, it will be total request
|
|
523
|
+
timeout. It can also be a pair (tuple) of
|
|
524
|
+
(connection, read) timeouts.
|
|
525
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
526
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
527
|
+
request; this effectively ignores the
|
|
528
|
+
authentication in the spec for a single request.
|
|
529
|
+
:type _request_auth: dict, optional
|
|
530
|
+
:param _content_type: force content-type for the request.
|
|
531
|
+
:type _content_type: str, Optional
|
|
532
|
+
:param _headers: set to override the headers for a single
|
|
533
|
+
request; this effectively ignores the headers
|
|
534
|
+
in the spec for a single request.
|
|
535
|
+
:type _headers: dict, optional
|
|
536
|
+
:param _host_index: set to override the host_index for a single
|
|
537
|
+
request; this effectively ignores the host_index
|
|
538
|
+
in the spec for a single request.
|
|
539
|
+
:type _host_index: int, optional
|
|
540
|
+
:return: Returns the result object.
|
|
541
|
+
""" # noqa: E501
|
|
542
|
+
|
|
543
|
+
_param = self._create_node_serialize(
|
|
544
|
+
cluster_id=cluster_id,
|
|
545
|
+
payload=payload,
|
|
546
|
+
_request_auth=_request_auth,
|
|
547
|
+
_content_type=_content_type,
|
|
548
|
+
_headers=_headers,
|
|
549
|
+
_host_index=_host_index
|
|
550
|
+
)
|
|
551
|
+
|
|
552
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
553
|
+
'201': "ClusterNodesListResponse",
|
|
554
|
+
'400': "ErrorResponseModel",
|
|
555
|
+
'401': "ErrorResponseModel",
|
|
556
|
+
'404': "ErrorResponseModel",
|
|
557
|
+
'409': "ErrorResponseModel",
|
|
558
|
+
'500': None,
|
|
559
|
+
}
|
|
560
|
+
response_data = await self.api_client.call_api(
|
|
561
|
+
*_param,
|
|
562
|
+
_request_timeout=_request_timeout
|
|
563
|
+
)
|
|
564
|
+
return response_data.response
|
|
565
|
+
|
|
566
|
+
|
|
567
|
+
def _create_node_serialize(
|
|
568
|
+
self,
|
|
569
|
+
cluster_id,
|
|
570
|
+
payload,
|
|
571
|
+
_request_auth,
|
|
572
|
+
_content_type,
|
|
573
|
+
_headers,
|
|
574
|
+
_host_index,
|
|
575
|
+
) -> RequestSerialized:
|
|
576
|
+
|
|
577
|
+
_host = None
|
|
578
|
+
|
|
579
|
+
_collection_formats: Dict[str, str] = {
|
|
580
|
+
}
|
|
581
|
+
|
|
582
|
+
_path_params: Dict[str, str] = {}
|
|
583
|
+
_query_params: List[Tuple[str, str]] = []
|
|
584
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
585
|
+
_form_params: List[Tuple[str, str]] = []
|
|
586
|
+
_files: Dict[
|
|
587
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
588
|
+
] = {}
|
|
589
|
+
_body_params: Optional[bytes] = None
|
|
590
|
+
|
|
591
|
+
# process the path parameters
|
|
592
|
+
if cluster_id is not None:
|
|
593
|
+
_path_params['cluster_id'] = cluster_id
|
|
594
|
+
# process the query parameters
|
|
595
|
+
# process the header parameters
|
|
596
|
+
# process the form parameters
|
|
597
|
+
# process the body parameter
|
|
598
|
+
if payload is not None:
|
|
599
|
+
_body_params = payload
|
|
600
|
+
|
|
601
|
+
|
|
602
|
+
# set the HTTP header `Accept`
|
|
603
|
+
if 'Accept' not in _header_params:
|
|
604
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
605
|
+
[
|
|
606
|
+
'application/json'
|
|
607
|
+
]
|
|
608
|
+
)
|
|
609
|
+
|
|
610
|
+
# set the HTTP header `Content-Type`
|
|
611
|
+
if _content_type:
|
|
612
|
+
_header_params['Content-Type'] = _content_type
|
|
613
|
+
else:
|
|
614
|
+
_default_content_type = (
|
|
615
|
+
self.api_client.select_header_content_type(
|
|
616
|
+
[
|
|
617
|
+
'application/json'
|
|
618
|
+
]
|
|
619
|
+
)
|
|
620
|
+
)
|
|
621
|
+
if _default_content_type is not None:
|
|
622
|
+
_header_params['Content-Type'] = _default_content_type
|
|
623
|
+
|
|
624
|
+
# authentication setting
|
|
625
|
+
_auth_settings: List[str] = [
|
|
626
|
+
'apiKey'
|
|
627
|
+
]
|
|
628
|
+
|
|
629
|
+
return self.api_client.param_serialize(
|
|
630
|
+
method='POST',
|
|
631
|
+
resource_path='/core/clusters/{cluster_id}/nodes',
|
|
632
|
+
path_params=_path_params,
|
|
633
|
+
query_params=_query_params,
|
|
634
|
+
header_params=_header_params,
|
|
635
|
+
body=_body_params,
|
|
636
|
+
post_params=_form_params,
|
|
637
|
+
files=_files,
|
|
638
|
+
auth_settings=_auth_settings,
|
|
639
|
+
collection_formats=_collection_formats,
|
|
640
|
+
_host=_host,
|
|
641
|
+
_request_auth=_request_auth
|
|
642
|
+
)
|
|
643
|
+
|
|
644
|
+
|
|
645
|
+
|
|
646
|
+
|
|
647
|
+
@validate_call
|
|
648
|
+
async def create_node_group(
|
|
649
|
+
self,
|
|
650
|
+
cluster_id: StrictInt,
|
|
651
|
+
payload: CreateClusterNodeGroupPayload,
|
|
652
|
+
_request_timeout: Union[
|
|
653
|
+
None,
|
|
654
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
655
|
+
Tuple[
|
|
656
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
657
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
658
|
+
]
|
|
659
|
+
] = None,
|
|
660
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
661
|
+
_content_type: Optional[StrictStr] = None,
|
|
662
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
663
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
664
|
+
) -> ClusterNodeGroupsCreateResponse:
|
|
665
|
+
"""Create a node group in a cluster
|
|
666
|
+
|
|
667
|
+
|
|
668
|
+
:param cluster_id: (required)
|
|
669
|
+
:type cluster_id: int
|
|
670
|
+
:param payload: (required)
|
|
671
|
+
:type payload: CreateClusterNodeGroupPayload
|
|
672
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
673
|
+
number provided, it will be total request
|
|
674
|
+
timeout. It can also be a pair (tuple) of
|
|
675
|
+
(connection, read) timeouts.
|
|
676
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
677
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
678
|
+
request; this effectively ignores the
|
|
679
|
+
authentication in the spec for a single request.
|
|
680
|
+
:type _request_auth: dict, optional
|
|
681
|
+
:param _content_type: force content-type for the request.
|
|
682
|
+
:type _content_type: str, Optional
|
|
683
|
+
:param _headers: set to override the headers for a single
|
|
684
|
+
request; this effectively ignores the headers
|
|
685
|
+
in the spec for a single request.
|
|
686
|
+
:type _headers: dict, optional
|
|
687
|
+
:param _host_index: set to override the host_index for a single
|
|
688
|
+
request; this effectively ignores the host_index
|
|
689
|
+
in the spec for a single request.
|
|
690
|
+
:type _host_index: int, optional
|
|
691
|
+
:return: Returns the result object.
|
|
692
|
+
""" # noqa: E501
|
|
693
|
+
|
|
694
|
+
_param = self._create_node_group_serialize(
|
|
695
|
+
cluster_id=cluster_id,
|
|
696
|
+
payload=payload,
|
|
697
|
+
_request_auth=_request_auth,
|
|
698
|
+
_content_type=_content_type,
|
|
699
|
+
_headers=_headers,
|
|
700
|
+
_host_index=_host_index
|
|
701
|
+
)
|
|
702
|
+
|
|
703
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
704
|
+
'201': "ClusterNodeGroupsCreateResponse",
|
|
705
|
+
'400': "ErrorResponseModel",
|
|
706
|
+
'401': "ErrorResponseModel",
|
|
707
|
+
'404': "ErrorResponseModel",
|
|
708
|
+
'409': "ErrorResponseModel",
|
|
709
|
+
'500': None,
|
|
710
|
+
}
|
|
711
|
+
response_data = await self.api_client.call_api(
|
|
712
|
+
*_param,
|
|
713
|
+
_request_timeout=_request_timeout
|
|
714
|
+
)
|
|
715
|
+
await response_data.read()
|
|
716
|
+
return self.api_client.response_deserialize(
|
|
717
|
+
response_data=response_data,
|
|
718
|
+
response_types_map=_response_types_map,
|
|
719
|
+
).data
|
|
720
|
+
|
|
721
|
+
|
|
722
|
+
@validate_call
|
|
723
|
+
async def create_node_group_with_http_info(
|
|
724
|
+
self,
|
|
725
|
+
cluster_id: StrictInt,
|
|
726
|
+
payload: CreateClusterNodeGroupPayload,
|
|
727
|
+
_request_timeout: Union[
|
|
728
|
+
None,
|
|
729
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
730
|
+
Tuple[
|
|
731
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
732
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
733
|
+
]
|
|
734
|
+
] = None,
|
|
735
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
736
|
+
_content_type: Optional[StrictStr] = None,
|
|
737
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
738
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
739
|
+
) -> ApiResponse[ClusterNodeGroupsCreateResponse]:
|
|
740
|
+
"""Create a node group in a cluster
|
|
741
|
+
|
|
742
|
+
|
|
743
|
+
:param cluster_id: (required)
|
|
744
|
+
:type cluster_id: int
|
|
745
|
+
:param payload: (required)
|
|
746
|
+
:type payload: CreateClusterNodeGroupPayload
|
|
747
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
748
|
+
number provided, it will be total request
|
|
749
|
+
timeout. It can also be a pair (tuple) of
|
|
750
|
+
(connection, read) timeouts.
|
|
751
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
752
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
753
|
+
request; this effectively ignores the
|
|
754
|
+
authentication in the spec for a single request.
|
|
755
|
+
:type _request_auth: dict, optional
|
|
756
|
+
:param _content_type: force content-type for the request.
|
|
757
|
+
:type _content_type: str, Optional
|
|
758
|
+
:param _headers: set to override the headers for a single
|
|
759
|
+
request; this effectively ignores the headers
|
|
760
|
+
in the spec for a single request.
|
|
761
|
+
:type _headers: dict, optional
|
|
762
|
+
:param _host_index: set to override the host_index for a single
|
|
763
|
+
request; this effectively ignores the host_index
|
|
764
|
+
in the spec for a single request.
|
|
765
|
+
:type _host_index: int, optional
|
|
766
|
+
:return: Returns the result object.
|
|
767
|
+
""" # noqa: E501
|
|
768
|
+
|
|
769
|
+
_param = self._create_node_group_serialize(
|
|
770
|
+
cluster_id=cluster_id,
|
|
771
|
+
payload=payload,
|
|
772
|
+
_request_auth=_request_auth,
|
|
773
|
+
_content_type=_content_type,
|
|
774
|
+
_headers=_headers,
|
|
775
|
+
_host_index=_host_index
|
|
776
|
+
)
|
|
777
|
+
|
|
778
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
779
|
+
'201': "ClusterNodeGroupsCreateResponse",
|
|
780
|
+
'400': "ErrorResponseModel",
|
|
781
|
+
'401': "ErrorResponseModel",
|
|
782
|
+
'404': "ErrorResponseModel",
|
|
783
|
+
'409': "ErrorResponseModel",
|
|
784
|
+
'500': None,
|
|
785
|
+
}
|
|
786
|
+
response_data = await self.api_client.call_api(
|
|
787
|
+
*_param,
|
|
788
|
+
_request_timeout=_request_timeout
|
|
789
|
+
)
|
|
790
|
+
await response_data.read()
|
|
791
|
+
return self.api_client.response_deserialize(
|
|
792
|
+
response_data=response_data,
|
|
793
|
+
response_types_map=_response_types_map,
|
|
794
|
+
)
|
|
795
|
+
|
|
796
|
+
|
|
797
|
+
@validate_call
|
|
798
|
+
async def create_node_group_without_preload_content(
|
|
799
|
+
self,
|
|
800
|
+
cluster_id: StrictInt,
|
|
801
|
+
payload: CreateClusterNodeGroupPayload,
|
|
802
|
+
_request_timeout: Union[
|
|
803
|
+
None,
|
|
804
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
805
|
+
Tuple[
|
|
806
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
807
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
808
|
+
]
|
|
809
|
+
] = None,
|
|
810
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
811
|
+
_content_type: Optional[StrictStr] = None,
|
|
812
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
813
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
814
|
+
) -> RESTResponseType:
|
|
815
|
+
"""Create a node group in a cluster
|
|
816
|
+
|
|
817
|
+
|
|
818
|
+
:param cluster_id: (required)
|
|
819
|
+
:type cluster_id: int
|
|
820
|
+
:param payload: (required)
|
|
821
|
+
:type payload: CreateClusterNodeGroupPayload
|
|
822
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
823
|
+
number provided, it will be total request
|
|
824
|
+
timeout. It can also be a pair (tuple) of
|
|
825
|
+
(connection, read) timeouts.
|
|
826
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
827
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
828
|
+
request; this effectively ignores the
|
|
829
|
+
authentication in the spec for a single request.
|
|
830
|
+
:type _request_auth: dict, optional
|
|
831
|
+
:param _content_type: force content-type for the request.
|
|
832
|
+
:type _content_type: str, Optional
|
|
833
|
+
:param _headers: set to override the headers for a single
|
|
834
|
+
request; this effectively ignores the headers
|
|
835
|
+
in the spec for a single request.
|
|
836
|
+
:type _headers: dict, optional
|
|
837
|
+
:param _host_index: set to override the host_index for a single
|
|
838
|
+
request; this effectively ignores the host_index
|
|
839
|
+
in the spec for a single request.
|
|
840
|
+
:type _host_index: int, optional
|
|
841
|
+
:return: Returns the result object.
|
|
842
|
+
""" # noqa: E501
|
|
843
|
+
|
|
844
|
+
_param = self._create_node_group_serialize(
|
|
845
|
+
cluster_id=cluster_id,
|
|
846
|
+
payload=payload,
|
|
847
|
+
_request_auth=_request_auth,
|
|
848
|
+
_content_type=_content_type,
|
|
849
|
+
_headers=_headers,
|
|
850
|
+
_host_index=_host_index
|
|
851
|
+
)
|
|
852
|
+
|
|
853
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
854
|
+
'201': "ClusterNodeGroupsCreateResponse",
|
|
855
|
+
'400': "ErrorResponseModel",
|
|
856
|
+
'401': "ErrorResponseModel",
|
|
857
|
+
'404': "ErrorResponseModel",
|
|
858
|
+
'409': "ErrorResponseModel",
|
|
859
|
+
'500': None,
|
|
860
|
+
}
|
|
861
|
+
response_data = await self.api_client.call_api(
|
|
862
|
+
*_param,
|
|
863
|
+
_request_timeout=_request_timeout
|
|
864
|
+
)
|
|
865
|
+
return response_data.response
|
|
866
|
+
|
|
867
|
+
|
|
868
|
+
def _create_node_group_serialize(
|
|
869
|
+
self,
|
|
870
|
+
cluster_id,
|
|
871
|
+
payload,
|
|
872
|
+
_request_auth,
|
|
873
|
+
_content_type,
|
|
874
|
+
_headers,
|
|
875
|
+
_host_index,
|
|
876
|
+
) -> RequestSerialized:
|
|
877
|
+
|
|
878
|
+
_host = None
|
|
879
|
+
|
|
880
|
+
_collection_formats: Dict[str, str] = {
|
|
881
|
+
}
|
|
882
|
+
|
|
883
|
+
_path_params: Dict[str, str] = {}
|
|
884
|
+
_query_params: List[Tuple[str, str]] = []
|
|
885
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
886
|
+
_form_params: List[Tuple[str, str]] = []
|
|
887
|
+
_files: Dict[
|
|
888
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
889
|
+
] = {}
|
|
890
|
+
_body_params: Optional[bytes] = None
|
|
891
|
+
|
|
892
|
+
# process the path parameters
|
|
893
|
+
if cluster_id is not None:
|
|
894
|
+
_path_params['cluster_id'] = cluster_id
|
|
895
|
+
# process the query parameters
|
|
896
|
+
# process the header parameters
|
|
897
|
+
# process the form parameters
|
|
898
|
+
# process the body parameter
|
|
899
|
+
if payload is not None:
|
|
900
|
+
_body_params = payload
|
|
901
|
+
|
|
902
|
+
|
|
903
|
+
# set the HTTP header `Accept`
|
|
904
|
+
if 'Accept' not in _header_params:
|
|
905
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
906
|
+
[
|
|
907
|
+
'application/json'
|
|
908
|
+
]
|
|
909
|
+
)
|
|
910
|
+
|
|
911
|
+
# set the HTTP header `Content-Type`
|
|
912
|
+
if _content_type:
|
|
913
|
+
_header_params['Content-Type'] = _content_type
|
|
914
|
+
else:
|
|
915
|
+
_default_content_type = (
|
|
916
|
+
self.api_client.select_header_content_type(
|
|
917
|
+
[
|
|
918
|
+
'application/json'
|
|
919
|
+
]
|
|
920
|
+
)
|
|
921
|
+
)
|
|
922
|
+
if _default_content_type is not None:
|
|
923
|
+
_header_params['Content-Type'] = _default_content_type
|
|
924
|
+
|
|
925
|
+
# authentication setting
|
|
926
|
+
_auth_settings: List[str] = [
|
|
927
|
+
'apiKey'
|
|
928
|
+
]
|
|
929
|
+
|
|
930
|
+
return self.api_client.param_serialize(
|
|
931
|
+
method='POST',
|
|
932
|
+
resource_path='/core/clusters/{cluster_id}/node-groups',
|
|
933
|
+
path_params=_path_params,
|
|
934
|
+
query_params=_query_params,
|
|
935
|
+
header_params=_header_params,
|
|
936
|
+
body=_body_params,
|
|
937
|
+
post_params=_form_params,
|
|
938
|
+
files=_files,
|
|
939
|
+
auth_settings=_auth_settings,
|
|
940
|
+
collection_formats=_collection_formats,
|
|
941
|
+
_host=_host,
|
|
942
|
+
_request_auth=_request_auth
|
|
943
|
+
)
|
|
944
|
+
|
|
945
|
+
|
|
946
|
+
|
|
947
|
+
|
|
948
|
+
@validate_call
|
|
949
|
+
async def delete_cluster(
|
|
950
|
+
self,
|
|
951
|
+
id: StrictInt,
|
|
952
|
+
_request_timeout: Union[
|
|
953
|
+
None,
|
|
954
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
955
|
+
Tuple[
|
|
956
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
957
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
958
|
+
]
|
|
959
|
+
] = None,
|
|
960
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
961
|
+
_content_type: Optional[StrictStr] = None,
|
|
962
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
963
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
964
|
+
) -> ResponseModel:
|
|
965
|
+
"""Delete a cluster
|
|
966
|
+
|
|
967
|
+
|
|
968
|
+
:param id: (required)
|
|
969
|
+
:type id: int
|
|
970
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
971
|
+
number provided, it will be total request
|
|
972
|
+
timeout. It can also be a pair (tuple) of
|
|
973
|
+
(connection, read) timeouts.
|
|
974
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
975
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
976
|
+
request; this effectively ignores the
|
|
977
|
+
authentication in the spec for a single request.
|
|
978
|
+
:type _request_auth: dict, optional
|
|
979
|
+
:param _content_type: force content-type for the request.
|
|
980
|
+
:type _content_type: str, Optional
|
|
981
|
+
:param _headers: set to override the headers for a single
|
|
982
|
+
request; this effectively ignores the headers
|
|
983
|
+
in the spec for a single request.
|
|
984
|
+
:type _headers: dict, optional
|
|
985
|
+
:param _host_index: set to override the host_index for a single
|
|
986
|
+
request; this effectively ignores the host_index
|
|
987
|
+
in the spec for a single request.
|
|
988
|
+
:type _host_index: int, optional
|
|
989
|
+
:return: Returns the result object.
|
|
990
|
+
""" # noqa: E501
|
|
991
|
+
|
|
992
|
+
_param = self._delete_cluster_serialize(
|
|
993
|
+
id=id,
|
|
994
|
+
_request_auth=_request_auth,
|
|
995
|
+
_content_type=_content_type,
|
|
996
|
+
_headers=_headers,
|
|
997
|
+
_host_index=_host_index
|
|
998
|
+
)
|
|
999
|
+
|
|
1000
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1001
|
+
'200': "ResponseModel",
|
|
1002
|
+
'400': "ErrorResponseModel",
|
|
1003
|
+
'401': "ErrorResponseModel",
|
|
1004
|
+
'404': "ErrorResponseModel",
|
|
1005
|
+
'500': None,
|
|
1006
|
+
}
|
|
1007
|
+
response_data = await self.api_client.call_api(
|
|
1008
|
+
*_param,
|
|
1009
|
+
_request_timeout=_request_timeout
|
|
1010
|
+
)
|
|
1011
|
+
await response_data.read()
|
|
1012
|
+
return self.api_client.response_deserialize(
|
|
1013
|
+
response_data=response_data,
|
|
1014
|
+
response_types_map=_response_types_map,
|
|
1015
|
+
).data
|
|
1016
|
+
|
|
1017
|
+
|
|
1018
|
+
@validate_call
|
|
1019
|
+
async def delete_cluster_with_http_info(
|
|
1020
|
+
self,
|
|
1021
|
+
id: StrictInt,
|
|
1022
|
+
_request_timeout: Union[
|
|
1023
|
+
None,
|
|
1024
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1025
|
+
Tuple[
|
|
1026
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1027
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1028
|
+
]
|
|
1029
|
+
] = None,
|
|
1030
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1031
|
+
_content_type: Optional[StrictStr] = None,
|
|
1032
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1033
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1034
|
+
) -> ApiResponse[ResponseModel]:
|
|
1035
|
+
"""Delete a cluster
|
|
1036
|
+
|
|
1037
|
+
|
|
1038
|
+
:param id: (required)
|
|
1039
|
+
:type id: int
|
|
1040
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1041
|
+
number provided, it will be total request
|
|
1042
|
+
timeout. It can also be a pair (tuple) of
|
|
1043
|
+
(connection, read) timeouts.
|
|
1044
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1045
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1046
|
+
request; this effectively ignores the
|
|
1047
|
+
authentication in the spec for a single request.
|
|
1048
|
+
:type _request_auth: dict, optional
|
|
1049
|
+
:param _content_type: force content-type for the request.
|
|
1050
|
+
:type _content_type: str, Optional
|
|
1051
|
+
:param _headers: set to override the headers for a single
|
|
1052
|
+
request; this effectively ignores the headers
|
|
1053
|
+
in the spec for a single request.
|
|
1054
|
+
:type _headers: dict, optional
|
|
1055
|
+
:param _host_index: set to override the host_index for a single
|
|
1056
|
+
request; this effectively ignores the host_index
|
|
1057
|
+
in the spec for a single request.
|
|
1058
|
+
:type _host_index: int, optional
|
|
1059
|
+
:return: Returns the result object.
|
|
1060
|
+
""" # noqa: E501
|
|
1061
|
+
|
|
1062
|
+
_param = self._delete_cluster_serialize(
|
|
1063
|
+
id=id,
|
|
1064
|
+
_request_auth=_request_auth,
|
|
1065
|
+
_content_type=_content_type,
|
|
1066
|
+
_headers=_headers,
|
|
1067
|
+
_host_index=_host_index
|
|
1068
|
+
)
|
|
1069
|
+
|
|
1070
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1071
|
+
'200': "ResponseModel",
|
|
1072
|
+
'400': "ErrorResponseModel",
|
|
1073
|
+
'401': "ErrorResponseModel",
|
|
1074
|
+
'404': "ErrorResponseModel",
|
|
1075
|
+
'500': None,
|
|
1076
|
+
}
|
|
1077
|
+
response_data = await self.api_client.call_api(
|
|
1078
|
+
*_param,
|
|
1079
|
+
_request_timeout=_request_timeout
|
|
1080
|
+
)
|
|
1081
|
+
await response_data.read()
|
|
1082
|
+
return self.api_client.response_deserialize(
|
|
1083
|
+
response_data=response_data,
|
|
1084
|
+
response_types_map=_response_types_map,
|
|
1085
|
+
)
|
|
1086
|
+
|
|
1087
|
+
|
|
1088
|
+
@validate_call
|
|
1089
|
+
async def delete_cluster_without_preload_content(
|
|
1090
|
+
self,
|
|
1091
|
+
id: StrictInt,
|
|
1092
|
+
_request_timeout: Union[
|
|
1093
|
+
None,
|
|
1094
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1095
|
+
Tuple[
|
|
1096
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1097
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1098
|
+
]
|
|
1099
|
+
] = None,
|
|
1100
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1101
|
+
_content_type: Optional[StrictStr] = None,
|
|
1102
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1103
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1104
|
+
) -> RESTResponseType:
|
|
1105
|
+
"""Delete a cluster
|
|
1106
|
+
|
|
1107
|
+
|
|
1108
|
+
:param id: (required)
|
|
1109
|
+
:type id: int
|
|
1110
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1111
|
+
number provided, it will be total request
|
|
1112
|
+
timeout. It can also be a pair (tuple) of
|
|
1113
|
+
(connection, read) timeouts.
|
|
1114
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1115
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1116
|
+
request; this effectively ignores the
|
|
1117
|
+
authentication in the spec for a single request.
|
|
1118
|
+
:type _request_auth: dict, optional
|
|
1119
|
+
:param _content_type: force content-type for the request.
|
|
1120
|
+
:type _content_type: str, Optional
|
|
1121
|
+
:param _headers: set to override the headers for a single
|
|
1122
|
+
request; this effectively ignores the headers
|
|
1123
|
+
in the spec for a single request.
|
|
1124
|
+
:type _headers: dict, optional
|
|
1125
|
+
:param _host_index: set to override the host_index for a single
|
|
1126
|
+
request; this effectively ignores the host_index
|
|
1127
|
+
in the spec for a single request.
|
|
1128
|
+
:type _host_index: int, optional
|
|
1129
|
+
:return: Returns the result object.
|
|
1130
|
+
""" # noqa: E501
|
|
1131
|
+
|
|
1132
|
+
_param = self._delete_cluster_serialize(
|
|
1133
|
+
id=id,
|
|
1134
|
+
_request_auth=_request_auth,
|
|
1135
|
+
_content_type=_content_type,
|
|
1136
|
+
_headers=_headers,
|
|
1137
|
+
_host_index=_host_index
|
|
1138
|
+
)
|
|
1139
|
+
|
|
1140
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1141
|
+
'200': "ResponseModel",
|
|
1142
|
+
'400': "ErrorResponseModel",
|
|
1143
|
+
'401': "ErrorResponseModel",
|
|
1144
|
+
'404': "ErrorResponseModel",
|
|
1145
|
+
'500': None,
|
|
1146
|
+
}
|
|
1147
|
+
response_data = await self.api_client.call_api(
|
|
1148
|
+
*_param,
|
|
1149
|
+
_request_timeout=_request_timeout
|
|
1150
|
+
)
|
|
1151
|
+
return response_data.response
|
|
1152
|
+
|
|
1153
|
+
|
|
1154
|
+
def _delete_cluster_serialize(
|
|
1155
|
+
self,
|
|
1156
|
+
id,
|
|
1157
|
+
_request_auth,
|
|
1158
|
+
_content_type,
|
|
1159
|
+
_headers,
|
|
1160
|
+
_host_index,
|
|
1161
|
+
) -> RequestSerialized:
|
|
1162
|
+
|
|
1163
|
+
_host = None
|
|
1164
|
+
|
|
1165
|
+
_collection_formats: Dict[str, str] = {
|
|
1166
|
+
}
|
|
1167
|
+
|
|
1168
|
+
_path_params: Dict[str, str] = {}
|
|
1169
|
+
_query_params: List[Tuple[str, str]] = []
|
|
1170
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
1171
|
+
_form_params: List[Tuple[str, str]] = []
|
|
1172
|
+
_files: Dict[
|
|
1173
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
1174
|
+
] = {}
|
|
1175
|
+
_body_params: Optional[bytes] = None
|
|
1176
|
+
|
|
1177
|
+
# process the path parameters
|
|
1178
|
+
if id is not None:
|
|
1179
|
+
_path_params['id'] = id
|
|
1180
|
+
# process the query parameters
|
|
1181
|
+
# process the header parameters
|
|
1182
|
+
# process the form parameters
|
|
1183
|
+
# process the body parameter
|
|
1184
|
+
|
|
1185
|
+
|
|
1186
|
+
# set the HTTP header `Accept`
|
|
1187
|
+
if 'Accept' not in _header_params:
|
|
1188
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
1189
|
+
[
|
|
1190
|
+
'application/json'
|
|
1191
|
+
]
|
|
1192
|
+
)
|
|
1193
|
+
|
|
1194
|
+
|
|
1195
|
+
# authentication setting
|
|
1196
|
+
_auth_settings: List[str] = [
|
|
1197
|
+
'apiKey'
|
|
1198
|
+
]
|
|
1199
|
+
|
|
1200
|
+
return self.api_client.param_serialize(
|
|
1201
|
+
method='DELETE',
|
|
1202
|
+
resource_path='/core/clusters/{id}',
|
|
1203
|
+
path_params=_path_params,
|
|
1204
|
+
query_params=_query_params,
|
|
1205
|
+
header_params=_header_params,
|
|
1206
|
+
body=_body_params,
|
|
1207
|
+
post_params=_form_params,
|
|
1208
|
+
files=_files,
|
|
1209
|
+
auth_settings=_auth_settings,
|
|
1210
|
+
collection_formats=_collection_formats,
|
|
1211
|
+
_host=_host,
|
|
1212
|
+
_request_auth=_request_auth
|
|
1213
|
+
)
|
|
1214
|
+
|
|
1215
|
+
|
|
1216
|
+
|
|
1217
|
+
|
|
1218
|
+
@validate_call
|
|
1219
|
+
async def delete_cluster_node(
|
|
1220
|
+
self,
|
|
1221
|
+
cluster_id: StrictInt,
|
|
1222
|
+
node_id: StrictInt,
|
|
1223
|
+
_request_timeout: Union[
|
|
1224
|
+
None,
|
|
1225
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1226
|
+
Tuple[
|
|
1227
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1228
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1229
|
+
]
|
|
1230
|
+
] = None,
|
|
1231
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1232
|
+
_content_type: Optional[StrictStr] = None,
|
|
1233
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1234
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1235
|
+
) -> ResponseModel:
|
|
1236
|
+
"""Delete Cluster Node
|
|
1237
|
+
|
|
1238
|
+
|
|
1239
|
+
:param cluster_id: (required)
|
|
1240
|
+
:type cluster_id: int
|
|
1241
|
+
:param node_id: (required)
|
|
1242
|
+
:type node_id: int
|
|
1243
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1244
|
+
number provided, it will be total request
|
|
1245
|
+
timeout. It can also be a pair (tuple) of
|
|
1246
|
+
(connection, read) timeouts.
|
|
1247
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1248
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1249
|
+
request; this effectively ignores the
|
|
1250
|
+
authentication in the spec for a single request.
|
|
1251
|
+
:type _request_auth: dict, optional
|
|
1252
|
+
:param _content_type: force content-type for the request.
|
|
1253
|
+
:type _content_type: str, Optional
|
|
1254
|
+
:param _headers: set to override the headers for a single
|
|
1255
|
+
request; this effectively ignores the headers
|
|
1256
|
+
in the spec for a single request.
|
|
1257
|
+
:type _headers: dict, optional
|
|
1258
|
+
:param _host_index: set to override the host_index for a single
|
|
1259
|
+
request; this effectively ignores the host_index
|
|
1260
|
+
in the spec for a single request.
|
|
1261
|
+
:type _host_index: int, optional
|
|
1262
|
+
:return: Returns the result object.
|
|
1263
|
+
""" # noqa: E501
|
|
1264
|
+
|
|
1265
|
+
_param = self._delete_cluster_node_serialize(
|
|
1266
|
+
cluster_id=cluster_id,
|
|
1267
|
+
node_id=node_id,
|
|
1268
|
+
_request_auth=_request_auth,
|
|
1269
|
+
_content_type=_content_type,
|
|
1270
|
+
_headers=_headers,
|
|
1271
|
+
_host_index=_host_index
|
|
1272
|
+
)
|
|
1273
|
+
|
|
1274
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1275
|
+
'200': "ResponseModel",
|
|
1276
|
+
'400': "ErrorResponseModel",
|
|
1277
|
+
'401': "ErrorResponseModel",
|
|
1278
|
+
'404': "ErrorResponseModel",
|
|
1279
|
+
'500': None,
|
|
1280
|
+
}
|
|
1281
|
+
response_data = await self.api_client.call_api(
|
|
1282
|
+
*_param,
|
|
1283
|
+
_request_timeout=_request_timeout
|
|
1284
|
+
)
|
|
1285
|
+
await response_data.read()
|
|
1286
|
+
return self.api_client.response_deserialize(
|
|
1287
|
+
response_data=response_data,
|
|
1288
|
+
response_types_map=_response_types_map,
|
|
1289
|
+
).data
|
|
1290
|
+
|
|
1291
|
+
|
|
1292
|
+
@validate_call
|
|
1293
|
+
async def delete_cluster_node_with_http_info(
|
|
1294
|
+
self,
|
|
1295
|
+
cluster_id: StrictInt,
|
|
1296
|
+
node_id: StrictInt,
|
|
1297
|
+
_request_timeout: Union[
|
|
1298
|
+
None,
|
|
1299
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1300
|
+
Tuple[
|
|
1301
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1302
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1303
|
+
]
|
|
1304
|
+
] = None,
|
|
1305
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1306
|
+
_content_type: Optional[StrictStr] = None,
|
|
1307
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1308
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1309
|
+
) -> ApiResponse[ResponseModel]:
|
|
1310
|
+
"""Delete Cluster Node
|
|
1311
|
+
|
|
1312
|
+
|
|
1313
|
+
:param cluster_id: (required)
|
|
1314
|
+
:type cluster_id: int
|
|
1315
|
+
:param node_id: (required)
|
|
1316
|
+
:type node_id: int
|
|
1317
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1318
|
+
number provided, it will be total request
|
|
1319
|
+
timeout. It can also be a pair (tuple) of
|
|
1320
|
+
(connection, read) timeouts.
|
|
1321
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1322
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1323
|
+
request; this effectively ignores the
|
|
1324
|
+
authentication in the spec for a single request.
|
|
1325
|
+
:type _request_auth: dict, optional
|
|
1326
|
+
:param _content_type: force content-type for the request.
|
|
1327
|
+
:type _content_type: str, Optional
|
|
1328
|
+
:param _headers: set to override the headers for a single
|
|
1329
|
+
request; this effectively ignores the headers
|
|
1330
|
+
in the spec for a single request.
|
|
1331
|
+
:type _headers: dict, optional
|
|
1332
|
+
:param _host_index: set to override the host_index for a single
|
|
1333
|
+
request; this effectively ignores the host_index
|
|
1334
|
+
in the spec for a single request.
|
|
1335
|
+
:type _host_index: int, optional
|
|
1336
|
+
:return: Returns the result object.
|
|
1337
|
+
""" # noqa: E501
|
|
1338
|
+
|
|
1339
|
+
_param = self._delete_cluster_node_serialize(
|
|
1340
|
+
cluster_id=cluster_id,
|
|
1341
|
+
node_id=node_id,
|
|
1342
|
+
_request_auth=_request_auth,
|
|
1343
|
+
_content_type=_content_type,
|
|
1344
|
+
_headers=_headers,
|
|
1345
|
+
_host_index=_host_index
|
|
1346
|
+
)
|
|
1347
|
+
|
|
1348
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1349
|
+
'200': "ResponseModel",
|
|
1350
|
+
'400': "ErrorResponseModel",
|
|
1351
|
+
'401': "ErrorResponseModel",
|
|
1352
|
+
'404': "ErrorResponseModel",
|
|
1353
|
+
'500': None,
|
|
1354
|
+
}
|
|
1355
|
+
response_data = await self.api_client.call_api(
|
|
1356
|
+
*_param,
|
|
1357
|
+
_request_timeout=_request_timeout
|
|
1358
|
+
)
|
|
1359
|
+
await response_data.read()
|
|
1360
|
+
return self.api_client.response_deserialize(
|
|
1361
|
+
response_data=response_data,
|
|
1362
|
+
response_types_map=_response_types_map,
|
|
1363
|
+
)
|
|
1364
|
+
|
|
1365
|
+
|
|
1366
|
+
@validate_call
|
|
1367
|
+
async def delete_cluster_node_without_preload_content(
|
|
1368
|
+
self,
|
|
1369
|
+
cluster_id: StrictInt,
|
|
1370
|
+
node_id: StrictInt,
|
|
1371
|
+
_request_timeout: Union[
|
|
1372
|
+
None,
|
|
1373
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1374
|
+
Tuple[
|
|
1375
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1376
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1377
|
+
]
|
|
1378
|
+
] = None,
|
|
1379
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1380
|
+
_content_type: Optional[StrictStr] = None,
|
|
1381
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1382
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1383
|
+
) -> RESTResponseType:
|
|
1384
|
+
"""Delete Cluster Node
|
|
1385
|
+
|
|
1386
|
+
|
|
1387
|
+
:param cluster_id: (required)
|
|
1388
|
+
:type cluster_id: int
|
|
1389
|
+
:param node_id: (required)
|
|
1390
|
+
:type node_id: int
|
|
1391
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1392
|
+
number provided, it will be total request
|
|
1393
|
+
timeout. It can also be a pair (tuple) of
|
|
1394
|
+
(connection, read) timeouts.
|
|
1395
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1396
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1397
|
+
request; this effectively ignores the
|
|
1398
|
+
authentication in the spec for a single request.
|
|
1399
|
+
:type _request_auth: dict, optional
|
|
1400
|
+
:param _content_type: force content-type for the request.
|
|
1401
|
+
:type _content_type: str, Optional
|
|
1402
|
+
:param _headers: set to override the headers for a single
|
|
1403
|
+
request; this effectively ignores the headers
|
|
1404
|
+
in the spec for a single request.
|
|
1405
|
+
:type _headers: dict, optional
|
|
1406
|
+
:param _host_index: set to override the host_index for a single
|
|
1407
|
+
request; this effectively ignores the host_index
|
|
1408
|
+
in the spec for a single request.
|
|
1409
|
+
:type _host_index: int, optional
|
|
1410
|
+
:return: Returns the result object.
|
|
1411
|
+
""" # noqa: E501
|
|
1412
|
+
|
|
1413
|
+
_param = self._delete_cluster_node_serialize(
|
|
1414
|
+
cluster_id=cluster_id,
|
|
1415
|
+
node_id=node_id,
|
|
1416
|
+
_request_auth=_request_auth,
|
|
1417
|
+
_content_type=_content_type,
|
|
1418
|
+
_headers=_headers,
|
|
1419
|
+
_host_index=_host_index
|
|
1420
|
+
)
|
|
1421
|
+
|
|
1422
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1423
|
+
'200': "ResponseModel",
|
|
1424
|
+
'400': "ErrorResponseModel",
|
|
1425
|
+
'401': "ErrorResponseModel",
|
|
1426
|
+
'404': "ErrorResponseModel",
|
|
1427
|
+
'500': None,
|
|
1428
|
+
}
|
|
1429
|
+
response_data = await self.api_client.call_api(
|
|
1430
|
+
*_param,
|
|
1431
|
+
_request_timeout=_request_timeout
|
|
1432
|
+
)
|
|
1433
|
+
return response_data.response
|
|
1434
|
+
|
|
1435
|
+
|
|
1436
|
+
def _delete_cluster_node_serialize(
|
|
1437
|
+
self,
|
|
1438
|
+
cluster_id,
|
|
1439
|
+
node_id,
|
|
1440
|
+
_request_auth,
|
|
1441
|
+
_content_type,
|
|
1442
|
+
_headers,
|
|
1443
|
+
_host_index,
|
|
1444
|
+
) -> RequestSerialized:
|
|
1445
|
+
|
|
1446
|
+
_host = None
|
|
1447
|
+
|
|
1448
|
+
_collection_formats: Dict[str, str] = {
|
|
1449
|
+
}
|
|
1450
|
+
|
|
1451
|
+
_path_params: Dict[str, str] = {}
|
|
1452
|
+
_query_params: List[Tuple[str, str]] = []
|
|
1453
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
1454
|
+
_form_params: List[Tuple[str, str]] = []
|
|
1455
|
+
_files: Dict[
|
|
1456
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
1457
|
+
] = {}
|
|
1458
|
+
_body_params: Optional[bytes] = None
|
|
1459
|
+
|
|
1460
|
+
# process the path parameters
|
|
1461
|
+
if cluster_id is not None:
|
|
1462
|
+
_path_params['cluster_id'] = cluster_id
|
|
1463
|
+
if node_id is not None:
|
|
1464
|
+
_path_params['node_id'] = node_id
|
|
1465
|
+
# process the query parameters
|
|
1466
|
+
# process the header parameters
|
|
1467
|
+
# process the form parameters
|
|
1468
|
+
# process the body parameter
|
|
1469
|
+
|
|
1470
|
+
|
|
1471
|
+
# set the HTTP header `Accept`
|
|
1472
|
+
if 'Accept' not in _header_params:
|
|
1473
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
1474
|
+
[
|
|
1475
|
+
'application/json'
|
|
1476
|
+
]
|
|
1477
|
+
)
|
|
1478
|
+
|
|
1479
|
+
|
|
1480
|
+
# authentication setting
|
|
1481
|
+
_auth_settings: List[str] = [
|
|
1482
|
+
'apiKey'
|
|
1483
|
+
]
|
|
1484
|
+
|
|
1485
|
+
return self.api_client.param_serialize(
|
|
1486
|
+
method='DELETE',
|
|
1487
|
+
resource_path='/core/clusters/{cluster_id}/nodes/{node_id}',
|
|
1488
|
+
path_params=_path_params,
|
|
1489
|
+
query_params=_query_params,
|
|
1490
|
+
header_params=_header_params,
|
|
1491
|
+
body=_body_params,
|
|
1492
|
+
post_params=_form_params,
|
|
1493
|
+
files=_files,
|
|
1494
|
+
auth_settings=_auth_settings,
|
|
1495
|
+
collection_formats=_collection_formats,
|
|
1496
|
+
_host=_host,
|
|
1497
|
+
_request_auth=_request_auth
|
|
1498
|
+
)
|
|
1499
|
+
|
|
1500
|
+
|
|
1501
|
+
|
|
1502
|
+
|
|
1503
|
+
@validate_call
|
|
1504
|
+
async def delete_cluster_nodes(
|
|
1505
|
+
self,
|
|
1506
|
+
cluster_id: StrictInt,
|
|
1507
|
+
payload: DeleteClusterNodesFields,
|
|
1508
|
+
_request_timeout: Union[
|
|
1509
|
+
None,
|
|
1510
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1511
|
+
Tuple[
|
|
1512
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1513
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1514
|
+
]
|
|
1515
|
+
] = None,
|
|
1516
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1517
|
+
_content_type: Optional[StrictStr] = None,
|
|
1518
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1519
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1520
|
+
) -> ResponseModel:
|
|
1521
|
+
"""Delete Multiple Cluster Nodes
|
|
1522
|
+
|
|
1523
|
+
|
|
1524
|
+
:param cluster_id: (required)
|
|
1525
|
+
:type cluster_id: int
|
|
1526
|
+
:param payload: (required)
|
|
1527
|
+
:type payload: DeleteClusterNodesFields
|
|
1528
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1529
|
+
number provided, it will be total request
|
|
1530
|
+
timeout. It can also be a pair (tuple) of
|
|
1531
|
+
(connection, read) timeouts.
|
|
1532
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1533
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1534
|
+
request; this effectively ignores the
|
|
1535
|
+
authentication in the spec for a single request.
|
|
1536
|
+
:type _request_auth: dict, optional
|
|
1537
|
+
:param _content_type: force content-type for the request.
|
|
1538
|
+
:type _content_type: str, Optional
|
|
1539
|
+
:param _headers: set to override the headers for a single
|
|
1540
|
+
request; this effectively ignores the headers
|
|
1541
|
+
in the spec for a single request.
|
|
1542
|
+
:type _headers: dict, optional
|
|
1543
|
+
:param _host_index: set to override the host_index for a single
|
|
1544
|
+
request; this effectively ignores the host_index
|
|
1545
|
+
in the spec for a single request.
|
|
1546
|
+
:type _host_index: int, optional
|
|
1547
|
+
:return: Returns the result object.
|
|
1548
|
+
""" # noqa: E501
|
|
1549
|
+
|
|
1550
|
+
_param = self._delete_cluster_nodes_serialize(
|
|
1551
|
+
cluster_id=cluster_id,
|
|
1552
|
+
payload=payload,
|
|
1553
|
+
_request_auth=_request_auth,
|
|
1554
|
+
_content_type=_content_type,
|
|
1555
|
+
_headers=_headers,
|
|
1556
|
+
_host_index=_host_index
|
|
1557
|
+
)
|
|
1558
|
+
|
|
1559
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1560
|
+
'200': "ResponseModel",
|
|
1561
|
+
'400': "ErrorResponseModel",
|
|
1562
|
+
'401': "ErrorResponseModel",
|
|
1563
|
+
'404': "ErrorResponseModel",
|
|
1564
|
+
'500': None,
|
|
1565
|
+
}
|
|
1566
|
+
response_data = await self.api_client.call_api(
|
|
1567
|
+
*_param,
|
|
1568
|
+
_request_timeout=_request_timeout
|
|
1569
|
+
)
|
|
1570
|
+
await response_data.read()
|
|
1571
|
+
return self.api_client.response_deserialize(
|
|
1572
|
+
response_data=response_data,
|
|
1573
|
+
response_types_map=_response_types_map,
|
|
1574
|
+
).data
|
|
1575
|
+
|
|
1576
|
+
|
|
1577
|
+
@validate_call
|
|
1578
|
+
async def delete_cluster_nodes_with_http_info(
|
|
1579
|
+
self,
|
|
1580
|
+
cluster_id: StrictInt,
|
|
1581
|
+
payload: DeleteClusterNodesFields,
|
|
1582
|
+
_request_timeout: Union[
|
|
1583
|
+
None,
|
|
1584
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1585
|
+
Tuple[
|
|
1586
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1587
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1588
|
+
]
|
|
1589
|
+
] = None,
|
|
1590
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1591
|
+
_content_type: Optional[StrictStr] = None,
|
|
1592
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1593
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1594
|
+
) -> ApiResponse[ResponseModel]:
|
|
1595
|
+
"""Delete Multiple Cluster Nodes
|
|
1596
|
+
|
|
1597
|
+
|
|
1598
|
+
:param cluster_id: (required)
|
|
1599
|
+
:type cluster_id: int
|
|
1600
|
+
:param payload: (required)
|
|
1601
|
+
:type payload: DeleteClusterNodesFields
|
|
1602
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1603
|
+
number provided, it will be total request
|
|
1604
|
+
timeout. It can also be a pair (tuple) of
|
|
1605
|
+
(connection, read) timeouts.
|
|
1606
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1607
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1608
|
+
request; this effectively ignores the
|
|
1609
|
+
authentication in the spec for a single request.
|
|
1610
|
+
:type _request_auth: dict, optional
|
|
1611
|
+
:param _content_type: force content-type for the request.
|
|
1612
|
+
:type _content_type: str, Optional
|
|
1613
|
+
:param _headers: set to override the headers for a single
|
|
1614
|
+
request; this effectively ignores the headers
|
|
1615
|
+
in the spec for a single request.
|
|
1616
|
+
:type _headers: dict, optional
|
|
1617
|
+
:param _host_index: set to override the host_index for a single
|
|
1618
|
+
request; this effectively ignores the host_index
|
|
1619
|
+
in the spec for a single request.
|
|
1620
|
+
:type _host_index: int, optional
|
|
1621
|
+
:return: Returns the result object.
|
|
1622
|
+
""" # noqa: E501
|
|
1623
|
+
|
|
1624
|
+
_param = self._delete_cluster_nodes_serialize(
|
|
1625
|
+
cluster_id=cluster_id,
|
|
1626
|
+
payload=payload,
|
|
1627
|
+
_request_auth=_request_auth,
|
|
1628
|
+
_content_type=_content_type,
|
|
1629
|
+
_headers=_headers,
|
|
1630
|
+
_host_index=_host_index
|
|
1631
|
+
)
|
|
1632
|
+
|
|
1633
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1634
|
+
'200': "ResponseModel",
|
|
1635
|
+
'400': "ErrorResponseModel",
|
|
1636
|
+
'401': "ErrorResponseModel",
|
|
1637
|
+
'404': "ErrorResponseModel",
|
|
1638
|
+
'500': None,
|
|
1639
|
+
}
|
|
1640
|
+
response_data = await self.api_client.call_api(
|
|
1641
|
+
*_param,
|
|
1642
|
+
_request_timeout=_request_timeout
|
|
1643
|
+
)
|
|
1644
|
+
await response_data.read()
|
|
1645
|
+
return self.api_client.response_deserialize(
|
|
1646
|
+
response_data=response_data,
|
|
1647
|
+
response_types_map=_response_types_map,
|
|
1648
|
+
)
|
|
1649
|
+
|
|
1650
|
+
|
|
1651
|
+
@validate_call
|
|
1652
|
+
async def delete_cluster_nodes_without_preload_content(
|
|
1653
|
+
self,
|
|
1654
|
+
cluster_id: StrictInt,
|
|
1655
|
+
payload: DeleteClusterNodesFields,
|
|
1656
|
+
_request_timeout: Union[
|
|
1657
|
+
None,
|
|
1658
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1659
|
+
Tuple[
|
|
1660
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1661
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1662
|
+
]
|
|
1663
|
+
] = None,
|
|
1664
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1665
|
+
_content_type: Optional[StrictStr] = None,
|
|
1666
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1667
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1668
|
+
) -> RESTResponseType:
|
|
1669
|
+
"""Delete Multiple Cluster Nodes
|
|
1670
|
+
|
|
1671
|
+
|
|
1672
|
+
:param cluster_id: (required)
|
|
1673
|
+
:type cluster_id: int
|
|
1674
|
+
:param payload: (required)
|
|
1675
|
+
:type payload: DeleteClusterNodesFields
|
|
1676
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1677
|
+
number provided, it will be total request
|
|
1678
|
+
timeout. It can also be a pair (tuple) of
|
|
1679
|
+
(connection, read) timeouts.
|
|
1680
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1681
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1682
|
+
request; this effectively ignores the
|
|
1683
|
+
authentication in the spec for a single request.
|
|
1684
|
+
:type _request_auth: dict, optional
|
|
1685
|
+
:param _content_type: force content-type for the request.
|
|
1686
|
+
:type _content_type: str, Optional
|
|
1687
|
+
:param _headers: set to override the headers for a single
|
|
1688
|
+
request; this effectively ignores the headers
|
|
1689
|
+
in the spec for a single request.
|
|
1690
|
+
:type _headers: dict, optional
|
|
1691
|
+
:param _host_index: set to override the host_index for a single
|
|
1692
|
+
request; this effectively ignores the host_index
|
|
1693
|
+
in the spec for a single request.
|
|
1694
|
+
:type _host_index: int, optional
|
|
1695
|
+
:return: Returns the result object.
|
|
1696
|
+
""" # noqa: E501
|
|
1697
|
+
|
|
1698
|
+
_param = self._delete_cluster_nodes_serialize(
|
|
1699
|
+
cluster_id=cluster_id,
|
|
1700
|
+
payload=payload,
|
|
1701
|
+
_request_auth=_request_auth,
|
|
1702
|
+
_content_type=_content_type,
|
|
1703
|
+
_headers=_headers,
|
|
1704
|
+
_host_index=_host_index
|
|
1705
|
+
)
|
|
1706
|
+
|
|
1707
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1708
|
+
'200': "ResponseModel",
|
|
1709
|
+
'400': "ErrorResponseModel",
|
|
1710
|
+
'401': "ErrorResponseModel",
|
|
1711
|
+
'404': "ErrorResponseModel",
|
|
1712
|
+
'500': None,
|
|
1713
|
+
}
|
|
1714
|
+
response_data = await self.api_client.call_api(
|
|
1715
|
+
*_param,
|
|
1716
|
+
_request_timeout=_request_timeout
|
|
1717
|
+
)
|
|
1718
|
+
return response_data.response
|
|
1719
|
+
|
|
1720
|
+
|
|
1721
|
+
def _delete_cluster_nodes_serialize(
|
|
1722
|
+
self,
|
|
1723
|
+
cluster_id,
|
|
1724
|
+
payload,
|
|
1725
|
+
_request_auth,
|
|
1726
|
+
_content_type,
|
|
1727
|
+
_headers,
|
|
1728
|
+
_host_index,
|
|
1729
|
+
) -> RequestSerialized:
|
|
1730
|
+
|
|
1731
|
+
_host = None
|
|
1732
|
+
|
|
1733
|
+
_collection_formats: Dict[str, str] = {
|
|
1734
|
+
}
|
|
1735
|
+
|
|
1736
|
+
_path_params: Dict[str, str] = {}
|
|
1737
|
+
_query_params: List[Tuple[str, str]] = []
|
|
1738
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
1739
|
+
_form_params: List[Tuple[str, str]] = []
|
|
1740
|
+
_files: Dict[
|
|
1741
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
1742
|
+
] = {}
|
|
1743
|
+
_body_params: Optional[bytes] = None
|
|
1744
|
+
|
|
1745
|
+
# process the path parameters
|
|
1746
|
+
if cluster_id is not None:
|
|
1747
|
+
_path_params['cluster_id'] = cluster_id
|
|
1748
|
+
# process the query parameters
|
|
1749
|
+
# process the header parameters
|
|
1750
|
+
# process the form parameters
|
|
1751
|
+
# process the body parameter
|
|
1752
|
+
if payload is not None:
|
|
1753
|
+
_body_params = payload
|
|
1754
|
+
|
|
1755
|
+
|
|
1756
|
+
# set the HTTP header `Accept`
|
|
1757
|
+
if 'Accept' not in _header_params:
|
|
1758
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
1759
|
+
[
|
|
1760
|
+
'application/json'
|
|
1761
|
+
]
|
|
1762
|
+
)
|
|
1763
|
+
|
|
1764
|
+
# set the HTTP header `Content-Type`
|
|
1765
|
+
if _content_type:
|
|
1766
|
+
_header_params['Content-Type'] = _content_type
|
|
1767
|
+
else:
|
|
1768
|
+
_default_content_type = (
|
|
1769
|
+
self.api_client.select_header_content_type(
|
|
1770
|
+
[
|
|
1771
|
+
'application/json'
|
|
1772
|
+
]
|
|
1773
|
+
)
|
|
1774
|
+
)
|
|
1775
|
+
if _default_content_type is not None:
|
|
1776
|
+
_header_params['Content-Type'] = _default_content_type
|
|
1777
|
+
|
|
1778
|
+
# authentication setting
|
|
1779
|
+
_auth_settings: List[str] = [
|
|
1780
|
+
'apiKey'
|
|
1781
|
+
]
|
|
1782
|
+
|
|
1783
|
+
return self.api_client.param_serialize(
|
|
1784
|
+
method='POST',
|
|
1785
|
+
resource_path='/core/clusters/{cluster_id}/nodes/delete',
|
|
1786
|
+
path_params=_path_params,
|
|
1787
|
+
query_params=_query_params,
|
|
1788
|
+
header_params=_header_params,
|
|
1789
|
+
body=_body_params,
|
|
1790
|
+
post_params=_form_params,
|
|
1791
|
+
files=_files,
|
|
1792
|
+
auth_settings=_auth_settings,
|
|
1793
|
+
collection_formats=_collection_formats,
|
|
1794
|
+
_host=_host,
|
|
1795
|
+
_request_auth=_request_auth
|
|
1796
|
+
)
|
|
1797
|
+
|
|
1798
|
+
|
|
1799
|
+
|
|
1800
|
+
|
|
1801
|
+
@validate_call
|
|
1802
|
+
async def delete_node_group(
|
|
1803
|
+
self,
|
|
1804
|
+
cluster_id: StrictInt,
|
|
1805
|
+
node_group_id: StrictInt,
|
|
1806
|
+
_request_timeout: Union[
|
|
1807
|
+
None,
|
|
1808
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1809
|
+
Tuple[
|
|
1810
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1811
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1812
|
+
]
|
|
1813
|
+
] = None,
|
|
1814
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1815
|
+
_content_type: Optional[StrictStr] = None,
|
|
1816
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1817
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1818
|
+
) -> ResponseModel:
|
|
1819
|
+
"""Delete a node group
|
|
1820
|
+
|
|
1821
|
+
|
|
1822
|
+
:param cluster_id: (required)
|
|
1823
|
+
:type cluster_id: int
|
|
1824
|
+
:param node_group_id: (required)
|
|
1825
|
+
:type node_group_id: int
|
|
1826
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1827
|
+
number provided, it will be total request
|
|
1828
|
+
timeout. It can also be a pair (tuple) of
|
|
1829
|
+
(connection, read) timeouts.
|
|
1830
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1831
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1832
|
+
request; this effectively ignores the
|
|
1833
|
+
authentication in the spec for a single request.
|
|
1834
|
+
:type _request_auth: dict, optional
|
|
1835
|
+
:param _content_type: force content-type for the request.
|
|
1836
|
+
:type _content_type: str, Optional
|
|
1837
|
+
:param _headers: set to override the headers for a single
|
|
1838
|
+
request; this effectively ignores the headers
|
|
1839
|
+
in the spec for a single request.
|
|
1840
|
+
:type _headers: dict, optional
|
|
1841
|
+
:param _host_index: set to override the host_index for a single
|
|
1842
|
+
request; this effectively ignores the host_index
|
|
1843
|
+
in the spec for a single request.
|
|
1844
|
+
:type _host_index: int, optional
|
|
1845
|
+
:return: Returns the result object.
|
|
1846
|
+
""" # noqa: E501
|
|
1847
|
+
|
|
1848
|
+
_param = self._delete_node_group_serialize(
|
|
1849
|
+
cluster_id=cluster_id,
|
|
1850
|
+
node_group_id=node_group_id,
|
|
1851
|
+
_request_auth=_request_auth,
|
|
1852
|
+
_content_type=_content_type,
|
|
1853
|
+
_headers=_headers,
|
|
1854
|
+
_host_index=_host_index
|
|
1855
|
+
)
|
|
1856
|
+
|
|
1857
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1858
|
+
'200': "ResponseModel",
|
|
1859
|
+
'400': "ErrorResponseModel",
|
|
1860
|
+
'401': "ErrorResponseModel",
|
|
1861
|
+
'404': "ErrorResponseModel",
|
|
1862
|
+
'409': "ErrorResponseModel",
|
|
1863
|
+
'500': None,
|
|
1864
|
+
}
|
|
1865
|
+
response_data = await self.api_client.call_api(
|
|
1866
|
+
*_param,
|
|
1867
|
+
_request_timeout=_request_timeout
|
|
1868
|
+
)
|
|
1869
|
+
await response_data.read()
|
|
1870
|
+
return self.api_client.response_deserialize(
|
|
1871
|
+
response_data=response_data,
|
|
1872
|
+
response_types_map=_response_types_map,
|
|
1873
|
+
).data
|
|
1874
|
+
|
|
1875
|
+
|
|
1876
|
+
@validate_call
|
|
1877
|
+
async def delete_node_group_with_http_info(
|
|
1878
|
+
self,
|
|
1879
|
+
cluster_id: StrictInt,
|
|
1880
|
+
node_group_id: StrictInt,
|
|
1881
|
+
_request_timeout: Union[
|
|
1882
|
+
None,
|
|
1883
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1884
|
+
Tuple[
|
|
1885
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1886
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1887
|
+
]
|
|
1888
|
+
] = None,
|
|
1889
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1890
|
+
_content_type: Optional[StrictStr] = None,
|
|
1891
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1892
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1893
|
+
) -> ApiResponse[ResponseModel]:
|
|
1894
|
+
"""Delete a node group
|
|
1895
|
+
|
|
1896
|
+
|
|
1897
|
+
:param cluster_id: (required)
|
|
1898
|
+
:type cluster_id: int
|
|
1899
|
+
:param node_group_id: (required)
|
|
1900
|
+
:type node_group_id: int
|
|
1901
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1902
|
+
number provided, it will be total request
|
|
1903
|
+
timeout. It can also be a pair (tuple) of
|
|
1904
|
+
(connection, read) timeouts.
|
|
1905
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1906
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1907
|
+
request; this effectively ignores the
|
|
1908
|
+
authentication in the spec for a single request.
|
|
1909
|
+
:type _request_auth: dict, optional
|
|
1910
|
+
:param _content_type: force content-type for the request.
|
|
1911
|
+
:type _content_type: str, Optional
|
|
1912
|
+
:param _headers: set to override the headers for a single
|
|
1913
|
+
request; this effectively ignores the headers
|
|
1914
|
+
in the spec for a single request.
|
|
1915
|
+
:type _headers: dict, optional
|
|
1916
|
+
:param _host_index: set to override the host_index for a single
|
|
1917
|
+
request; this effectively ignores the host_index
|
|
1918
|
+
in the spec for a single request.
|
|
1919
|
+
:type _host_index: int, optional
|
|
1920
|
+
:return: Returns the result object.
|
|
1921
|
+
""" # noqa: E501
|
|
1922
|
+
|
|
1923
|
+
_param = self._delete_node_group_serialize(
|
|
1924
|
+
cluster_id=cluster_id,
|
|
1925
|
+
node_group_id=node_group_id,
|
|
1926
|
+
_request_auth=_request_auth,
|
|
1927
|
+
_content_type=_content_type,
|
|
1928
|
+
_headers=_headers,
|
|
1929
|
+
_host_index=_host_index
|
|
1930
|
+
)
|
|
1931
|
+
|
|
1932
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1933
|
+
'200': "ResponseModel",
|
|
1934
|
+
'400': "ErrorResponseModel",
|
|
1935
|
+
'401': "ErrorResponseModel",
|
|
1936
|
+
'404': "ErrorResponseModel",
|
|
1937
|
+
'409': "ErrorResponseModel",
|
|
1938
|
+
'500': None,
|
|
1939
|
+
}
|
|
1940
|
+
response_data = await self.api_client.call_api(
|
|
1941
|
+
*_param,
|
|
1942
|
+
_request_timeout=_request_timeout
|
|
1943
|
+
)
|
|
1944
|
+
await response_data.read()
|
|
1945
|
+
return self.api_client.response_deserialize(
|
|
1946
|
+
response_data=response_data,
|
|
1947
|
+
response_types_map=_response_types_map,
|
|
1948
|
+
)
|
|
1949
|
+
|
|
1950
|
+
|
|
1951
|
+
@validate_call
|
|
1952
|
+
async def delete_node_group_without_preload_content(
|
|
1953
|
+
self,
|
|
1954
|
+
cluster_id: StrictInt,
|
|
1955
|
+
node_group_id: StrictInt,
|
|
1956
|
+
_request_timeout: Union[
|
|
1957
|
+
None,
|
|
1958
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1959
|
+
Tuple[
|
|
1960
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1961
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
1962
|
+
]
|
|
1963
|
+
] = None,
|
|
1964
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1965
|
+
_content_type: Optional[StrictStr] = None,
|
|
1966
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1967
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1968
|
+
) -> RESTResponseType:
|
|
1969
|
+
"""Delete a node group
|
|
1970
|
+
|
|
1971
|
+
|
|
1972
|
+
:param cluster_id: (required)
|
|
1973
|
+
:type cluster_id: int
|
|
1974
|
+
:param node_group_id: (required)
|
|
1975
|
+
:type node_group_id: int
|
|
1976
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1977
|
+
number provided, it will be total request
|
|
1978
|
+
timeout. It can also be a pair (tuple) of
|
|
1979
|
+
(connection, read) timeouts.
|
|
1980
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1981
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1982
|
+
request; this effectively ignores the
|
|
1983
|
+
authentication in the spec for a single request.
|
|
1984
|
+
:type _request_auth: dict, optional
|
|
1985
|
+
:param _content_type: force content-type for the request.
|
|
1986
|
+
:type _content_type: str, Optional
|
|
1987
|
+
:param _headers: set to override the headers for a single
|
|
1988
|
+
request; this effectively ignores the headers
|
|
1989
|
+
in the spec for a single request.
|
|
1990
|
+
:type _headers: dict, optional
|
|
1991
|
+
:param _host_index: set to override the host_index for a single
|
|
1992
|
+
request; this effectively ignores the host_index
|
|
1993
|
+
in the spec for a single request.
|
|
1994
|
+
:type _host_index: int, optional
|
|
1995
|
+
:return: Returns the result object.
|
|
1996
|
+
""" # noqa: E501
|
|
1997
|
+
|
|
1998
|
+
_param = self._delete_node_group_serialize(
|
|
1999
|
+
cluster_id=cluster_id,
|
|
2000
|
+
node_group_id=node_group_id,
|
|
2001
|
+
_request_auth=_request_auth,
|
|
2002
|
+
_content_type=_content_type,
|
|
2003
|
+
_headers=_headers,
|
|
2004
|
+
_host_index=_host_index
|
|
2005
|
+
)
|
|
2006
|
+
|
|
2007
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
2008
|
+
'200': "ResponseModel",
|
|
2009
|
+
'400': "ErrorResponseModel",
|
|
2010
|
+
'401': "ErrorResponseModel",
|
|
2011
|
+
'404': "ErrorResponseModel",
|
|
2012
|
+
'409': "ErrorResponseModel",
|
|
2013
|
+
'500': None,
|
|
2014
|
+
}
|
|
2015
|
+
response_data = await self.api_client.call_api(
|
|
2016
|
+
*_param,
|
|
2017
|
+
_request_timeout=_request_timeout
|
|
2018
|
+
)
|
|
2019
|
+
return response_data.response
|
|
2020
|
+
|
|
2021
|
+
|
|
2022
|
+
def _delete_node_group_serialize(
|
|
2023
|
+
self,
|
|
2024
|
+
cluster_id,
|
|
2025
|
+
node_group_id,
|
|
2026
|
+
_request_auth,
|
|
2027
|
+
_content_type,
|
|
2028
|
+
_headers,
|
|
2029
|
+
_host_index,
|
|
2030
|
+
) -> RequestSerialized:
|
|
2031
|
+
|
|
2032
|
+
_host = None
|
|
2033
|
+
|
|
2034
|
+
_collection_formats: Dict[str, str] = {
|
|
2035
|
+
}
|
|
2036
|
+
|
|
2037
|
+
_path_params: Dict[str, str] = {}
|
|
2038
|
+
_query_params: List[Tuple[str, str]] = []
|
|
2039
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
2040
|
+
_form_params: List[Tuple[str, str]] = []
|
|
2041
|
+
_files: Dict[
|
|
2042
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
2043
|
+
] = {}
|
|
2044
|
+
_body_params: Optional[bytes] = None
|
|
2045
|
+
|
|
2046
|
+
# process the path parameters
|
|
2047
|
+
if cluster_id is not None:
|
|
2048
|
+
_path_params['cluster_id'] = cluster_id
|
|
2049
|
+
if node_group_id is not None:
|
|
2050
|
+
_path_params['node_group_id'] = node_group_id
|
|
2051
|
+
# process the query parameters
|
|
2052
|
+
# process the header parameters
|
|
2053
|
+
# process the form parameters
|
|
2054
|
+
# process the body parameter
|
|
2055
|
+
|
|
2056
|
+
|
|
2057
|
+
# set the HTTP header `Accept`
|
|
2058
|
+
if 'Accept' not in _header_params:
|
|
2059
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
2060
|
+
[
|
|
2061
|
+
'application/json'
|
|
2062
|
+
]
|
|
2063
|
+
)
|
|
2064
|
+
|
|
2065
|
+
|
|
2066
|
+
# authentication setting
|
|
2067
|
+
_auth_settings: List[str] = [
|
|
2068
|
+
'apiKey'
|
|
2069
|
+
]
|
|
2070
|
+
|
|
2071
|
+
return self.api_client.param_serialize(
|
|
2072
|
+
method='DELETE',
|
|
2073
|
+
resource_path='/core/clusters/{cluster_id}/node-groups/{node_group_id}',
|
|
2074
|
+
path_params=_path_params,
|
|
2075
|
+
query_params=_query_params,
|
|
2076
|
+
header_params=_header_params,
|
|
2077
|
+
body=_body_params,
|
|
2078
|
+
post_params=_form_params,
|
|
2079
|
+
files=_files,
|
|
2080
|
+
auth_settings=_auth_settings,
|
|
2081
|
+
collection_formats=_collection_formats,
|
|
2082
|
+
_host=_host,
|
|
2083
|
+
_request_auth=_request_auth
|
|
2084
|
+
)
|
|
2085
|
+
|
|
2086
|
+
|
|
2087
|
+
|
|
2088
|
+
|
|
2089
|
+
@validate_call
|
|
2090
|
+
async def fetch_cluster_name_availability(
|
|
2091
|
+
self,
|
|
2092
|
+
name: StrictStr,
|
|
2093
|
+
_request_timeout: Union[
|
|
2094
|
+
None,
|
|
2095
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2096
|
+
Tuple[
|
|
2097
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2098
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
2099
|
+
]
|
|
2100
|
+
] = None,
|
|
2101
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
2102
|
+
_content_type: Optional[StrictStr] = None,
|
|
2103
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
2104
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
2105
|
+
) -> NameAvailableModel:
|
|
2106
|
+
"""Fetch cluster name availability
|
|
2107
|
+
|
|
2108
|
+
Check if a Cluster name is available
|
|
2109
|
+
|
|
2110
|
+
:param name: (required)
|
|
2111
|
+
:type name: str
|
|
2112
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
2113
|
+
number provided, it will be total request
|
|
2114
|
+
timeout. It can also be a pair (tuple) of
|
|
2115
|
+
(connection, read) timeouts.
|
|
2116
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
2117
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
2118
|
+
request; this effectively ignores the
|
|
2119
|
+
authentication in the spec for a single request.
|
|
2120
|
+
:type _request_auth: dict, optional
|
|
2121
|
+
:param _content_type: force content-type for the request.
|
|
2122
|
+
:type _content_type: str, Optional
|
|
2123
|
+
:param _headers: set to override the headers for a single
|
|
2124
|
+
request; this effectively ignores the headers
|
|
2125
|
+
in the spec for a single request.
|
|
2126
|
+
:type _headers: dict, optional
|
|
2127
|
+
:param _host_index: set to override the host_index for a single
|
|
2128
|
+
request; this effectively ignores the host_index
|
|
2129
|
+
in the spec for a single request.
|
|
2130
|
+
:type _host_index: int, optional
|
|
2131
|
+
:return: Returns the result object.
|
|
2132
|
+
""" # noqa: E501
|
|
2133
|
+
|
|
2134
|
+
_param = self._fetch_cluster_name_availability_serialize(
|
|
2135
|
+
name=name,
|
|
2136
|
+
_request_auth=_request_auth,
|
|
2137
|
+
_content_type=_content_type,
|
|
2138
|
+
_headers=_headers,
|
|
2139
|
+
_host_index=_host_index
|
|
2140
|
+
)
|
|
2141
|
+
|
|
2142
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
2143
|
+
'200': "NameAvailableModel",
|
|
2144
|
+
'400': "ErrorResponseModel",
|
|
2145
|
+
'401': "ErrorResponseModel",
|
|
2146
|
+
'404': "ErrorResponseModel",
|
|
2147
|
+
'500': None,
|
|
2148
|
+
}
|
|
2149
|
+
response_data = await self.api_client.call_api(
|
|
2150
|
+
*_param,
|
|
2151
|
+
_request_timeout=_request_timeout
|
|
2152
|
+
)
|
|
2153
|
+
await response_data.read()
|
|
2154
|
+
return self.api_client.response_deserialize(
|
|
2155
|
+
response_data=response_data,
|
|
2156
|
+
response_types_map=_response_types_map,
|
|
2157
|
+
).data
|
|
2158
|
+
|
|
2159
|
+
|
|
2160
|
+
@validate_call
|
|
2161
|
+
async def fetch_cluster_name_availability_with_http_info(
|
|
2162
|
+
self,
|
|
2163
|
+
name: StrictStr,
|
|
2164
|
+
_request_timeout: Union[
|
|
2165
|
+
None,
|
|
2166
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2167
|
+
Tuple[
|
|
2168
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2169
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
2170
|
+
]
|
|
2171
|
+
] = None,
|
|
2172
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
2173
|
+
_content_type: Optional[StrictStr] = None,
|
|
2174
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
2175
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
2176
|
+
) -> ApiResponse[NameAvailableModel]:
|
|
2177
|
+
"""Fetch cluster name availability
|
|
2178
|
+
|
|
2179
|
+
Check if a Cluster name is available
|
|
2180
|
+
|
|
2181
|
+
:param name: (required)
|
|
2182
|
+
:type name: str
|
|
2183
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
2184
|
+
number provided, it will be total request
|
|
2185
|
+
timeout. It can also be a pair (tuple) of
|
|
2186
|
+
(connection, read) timeouts.
|
|
2187
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
2188
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
2189
|
+
request; this effectively ignores the
|
|
2190
|
+
authentication in the spec for a single request.
|
|
2191
|
+
:type _request_auth: dict, optional
|
|
2192
|
+
:param _content_type: force content-type for the request.
|
|
2193
|
+
:type _content_type: str, Optional
|
|
2194
|
+
:param _headers: set to override the headers for a single
|
|
2195
|
+
request; this effectively ignores the headers
|
|
2196
|
+
in the spec for a single request.
|
|
2197
|
+
:type _headers: dict, optional
|
|
2198
|
+
:param _host_index: set to override the host_index for a single
|
|
2199
|
+
request; this effectively ignores the host_index
|
|
2200
|
+
in the spec for a single request.
|
|
2201
|
+
:type _host_index: int, optional
|
|
2202
|
+
:return: Returns the result object.
|
|
2203
|
+
""" # noqa: E501
|
|
2204
|
+
|
|
2205
|
+
_param = self._fetch_cluster_name_availability_serialize(
|
|
2206
|
+
name=name,
|
|
2207
|
+
_request_auth=_request_auth,
|
|
2208
|
+
_content_type=_content_type,
|
|
2209
|
+
_headers=_headers,
|
|
2210
|
+
_host_index=_host_index
|
|
2211
|
+
)
|
|
2212
|
+
|
|
2213
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
2214
|
+
'200': "NameAvailableModel",
|
|
2215
|
+
'400': "ErrorResponseModel",
|
|
2216
|
+
'401': "ErrorResponseModel",
|
|
2217
|
+
'404': "ErrorResponseModel",
|
|
2218
|
+
'500': None,
|
|
2219
|
+
}
|
|
2220
|
+
response_data = await self.api_client.call_api(
|
|
2221
|
+
*_param,
|
|
2222
|
+
_request_timeout=_request_timeout
|
|
2223
|
+
)
|
|
2224
|
+
await response_data.read()
|
|
2225
|
+
return self.api_client.response_deserialize(
|
|
2226
|
+
response_data=response_data,
|
|
2227
|
+
response_types_map=_response_types_map,
|
|
2228
|
+
)
|
|
2229
|
+
|
|
2230
|
+
|
|
2231
|
+
@validate_call
|
|
2232
|
+
async def fetch_cluster_name_availability_without_preload_content(
|
|
2233
|
+
self,
|
|
2234
|
+
name: StrictStr,
|
|
2235
|
+
_request_timeout: Union[
|
|
2236
|
+
None,
|
|
2237
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2238
|
+
Tuple[
|
|
2239
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2240
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
2241
|
+
]
|
|
2242
|
+
] = None,
|
|
2243
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
2244
|
+
_content_type: Optional[StrictStr] = None,
|
|
2245
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
2246
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
2247
|
+
) -> RESTResponseType:
|
|
2248
|
+
"""Fetch cluster name availability
|
|
2249
|
+
|
|
2250
|
+
Check if a Cluster name is available
|
|
2251
|
+
|
|
2252
|
+
:param name: (required)
|
|
2253
|
+
:type name: str
|
|
2254
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
2255
|
+
number provided, it will be total request
|
|
2256
|
+
timeout. It can also be a pair (tuple) of
|
|
2257
|
+
(connection, read) timeouts.
|
|
2258
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
2259
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
2260
|
+
request; this effectively ignores the
|
|
2261
|
+
authentication in the spec for a single request.
|
|
2262
|
+
:type _request_auth: dict, optional
|
|
2263
|
+
:param _content_type: force content-type for the request.
|
|
2264
|
+
:type _content_type: str, Optional
|
|
2265
|
+
:param _headers: set to override the headers for a single
|
|
2266
|
+
request; this effectively ignores the headers
|
|
2267
|
+
in the spec for a single request.
|
|
2268
|
+
:type _headers: dict, optional
|
|
2269
|
+
:param _host_index: set to override the host_index for a single
|
|
2270
|
+
request; this effectively ignores the host_index
|
|
2271
|
+
in the spec for a single request.
|
|
2272
|
+
:type _host_index: int, optional
|
|
2273
|
+
:return: Returns the result object.
|
|
2274
|
+
""" # noqa: E501
|
|
2275
|
+
|
|
2276
|
+
_param = self._fetch_cluster_name_availability_serialize(
|
|
2277
|
+
name=name,
|
|
2278
|
+
_request_auth=_request_auth,
|
|
2279
|
+
_content_type=_content_type,
|
|
2280
|
+
_headers=_headers,
|
|
2281
|
+
_host_index=_host_index
|
|
2282
|
+
)
|
|
2283
|
+
|
|
2284
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
2285
|
+
'200': "NameAvailableModel",
|
|
2286
|
+
'400': "ErrorResponseModel",
|
|
2287
|
+
'401': "ErrorResponseModel",
|
|
2288
|
+
'404': "ErrorResponseModel",
|
|
2289
|
+
'500': None,
|
|
2290
|
+
}
|
|
2291
|
+
response_data = await self.api_client.call_api(
|
|
2292
|
+
*_param,
|
|
2293
|
+
_request_timeout=_request_timeout
|
|
2294
|
+
)
|
|
2295
|
+
return response_data.response
|
|
2296
|
+
|
|
2297
|
+
|
|
2298
|
+
def _fetch_cluster_name_availability_serialize(
|
|
2299
|
+
self,
|
|
2300
|
+
name,
|
|
2301
|
+
_request_auth,
|
|
2302
|
+
_content_type,
|
|
2303
|
+
_headers,
|
|
2304
|
+
_host_index,
|
|
2305
|
+
) -> RequestSerialized:
|
|
2306
|
+
|
|
2307
|
+
_host = None
|
|
2308
|
+
|
|
2309
|
+
_collection_formats: Dict[str, str] = {
|
|
2310
|
+
}
|
|
2311
|
+
|
|
2312
|
+
_path_params: Dict[str, str] = {}
|
|
2313
|
+
_query_params: List[Tuple[str, str]] = []
|
|
2314
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
2315
|
+
_form_params: List[Tuple[str, str]] = []
|
|
2316
|
+
_files: Dict[
|
|
2317
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
2318
|
+
] = {}
|
|
2319
|
+
_body_params: Optional[bytes] = None
|
|
2320
|
+
|
|
2321
|
+
# process the path parameters
|
|
2322
|
+
if name is not None:
|
|
2323
|
+
_path_params['name'] = name
|
|
2324
|
+
# process the query parameters
|
|
2325
|
+
# process the header parameters
|
|
2326
|
+
# process the form parameters
|
|
2327
|
+
# process the body parameter
|
|
2328
|
+
|
|
2329
|
+
|
|
2330
|
+
# set the HTTP header `Accept`
|
|
2331
|
+
if 'Accept' not in _header_params:
|
|
2332
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
2333
|
+
[
|
|
2334
|
+
'application/json'
|
|
2335
|
+
]
|
|
2336
|
+
)
|
|
2337
|
+
|
|
2338
|
+
|
|
2339
|
+
# authentication setting
|
|
2340
|
+
_auth_settings: List[str] = [
|
|
2341
|
+
'apiKey'
|
|
2342
|
+
]
|
|
2343
|
+
|
|
2344
|
+
return self.api_client.param_serialize(
|
|
2345
|
+
method='GET',
|
|
2346
|
+
resource_path='/core/clusters/name-availability/{name}',
|
|
2347
|
+
path_params=_path_params,
|
|
2348
|
+
query_params=_query_params,
|
|
2349
|
+
header_params=_header_params,
|
|
2350
|
+
body=_body_params,
|
|
2351
|
+
post_params=_form_params,
|
|
2352
|
+
files=_files,
|
|
2353
|
+
auth_settings=_auth_settings,
|
|
2354
|
+
collection_formats=_collection_formats,
|
|
2355
|
+
_host=_host,
|
|
2356
|
+
_request_auth=_request_auth
|
|
2357
|
+
)
|
|
2358
|
+
|
|
2359
|
+
|
|
2360
|
+
|
|
2361
|
+
|
|
2362
|
+
@validate_call
|
|
2363
|
+
async def get_cluster_master_flavors(
|
|
2364
|
+
self,
|
|
2365
|
+
_request_timeout: Union[
|
|
2366
|
+
None,
|
|
2367
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2368
|
+
Tuple[
|
|
2369
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2370
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
2371
|
+
]
|
|
2372
|
+
] = None,
|
|
2373
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
2374
|
+
_content_type: Optional[StrictStr] = None,
|
|
2375
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
2376
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
2377
|
+
) -> MasterFlavorsResponse:
|
|
2378
|
+
"""Get Cluster Master Flavors
|
|
2379
|
+
|
|
2380
|
+
|
|
2381
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
2382
|
+
number provided, it will be total request
|
|
2383
|
+
timeout. It can also be a pair (tuple) of
|
|
2384
|
+
(connection, read) timeouts.
|
|
2385
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
2386
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
2387
|
+
request; this effectively ignores the
|
|
2388
|
+
authentication in the spec for a single request.
|
|
2389
|
+
:type _request_auth: dict, optional
|
|
2390
|
+
:param _content_type: force content-type for the request.
|
|
2391
|
+
:type _content_type: str, Optional
|
|
2392
|
+
:param _headers: set to override the headers for a single
|
|
2393
|
+
request; this effectively ignores the headers
|
|
2394
|
+
in the spec for a single request.
|
|
2395
|
+
:type _headers: dict, optional
|
|
2396
|
+
:param _host_index: set to override the host_index for a single
|
|
2397
|
+
request; this effectively ignores the host_index
|
|
2398
|
+
in the spec for a single request.
|
|
2399
|
+
:type _host_index: int, optional
|
|
2400
|
+
:return: Returns the result object.
|
|
2401
|
+
""" # noqa: E501
|
|
2402
|
+
|
|
2403
|
+
_param = self._get_cluster_master_flavors_serialize(
|
|
2404
|
+
_request_auth=_request_auth,
|
|
2405
|
+
_content_type=_content_type,
|
|
2406
|
+
_headers=_headers,
|
|
2407
|
+
_host_index=_host_index
|
|
2408
|
+
)
|
|
2409
|
+
|
|
2410
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
2411
|
+
'200': "MasterFlavorsResponse",
|
|
2412
|
+
'400': "ErrorResponseModel",
|
|
2413
|
+
'401': "ErrorResponseModel",
|
|
2414
|
+
'500': None,
|
|
2415
|
+
}
|
|
2416
|
+
response_data = await self.api_client.call_api(
|
|
2417
|
+
*_param,
|
|
2418
|
+
_request_timeout=_request_timeout
|
|
2419
|
+
)
|
|
2420
|
+
await response_data.read()
|
|
2421
|
+
return self.api_client.response_deserialize(
|
|
2422
|
+
response_data=response_data,
|
|
2423
|
+
response_types_map=_response_types_map,
|
|
2424
|
+
).data
|
|
2425
|
+
|
|
2426
|
+
|
|
2427
|
+
@validate_call
|
|
2428
|
+
async def get_cluster_master_flavors_with_http_info(
|
|
2429
|
+
self,
|
|
2430
|
+
_request_timeout: Union[
|
|
2431
|
+
None,
|
|
2432
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2433
|
+
Tuple[
|
|
2434
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2435
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
2436
|
+
]
|
|
2437
|
+
] = None,
|
|
2438
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
2439
|
+
_content_type: Optional[StrictStr] = None,
|
|
2440
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
2441
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
2442
|
+
) -> ApiResponse[MasterFlavorsResponse]:
|
|
2443
|
+
"""Get Cluster Master Flavors
|
|
2444
|
+
|
|
2445
|
+
|
|
2446
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
2447
|
+
number provided, it will be total request
|
|
2448
|
+
timeout. It can also be a pair (tuple) of
|
|
2449
|
+
(connection, read) timeouts.
|
|
2450
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
2451
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
2452
|
+
request; this effectively ignores the
|
|
2453
|
+
authentication in the spec for a single request.
|
|
2454
|
+
:type _request_auth: dict, optional
|
|
2455
|
+
:param _content_type: force content-type for the request.
|
|
2456
|
+
:type _content_type: str, Optional
|
|
2457
|
+
:param _headers: set to override the headers for a single
|
|
2458
|
+
request; this effectively ignores the headers
|
|
2459
|
+
in the spec for a single request.
|
|
2460
|
+
:type _headers: dict, optional
|
|
2461
|
+
:param _host_index: set to override the host_index for a single
|
|
2462
|
+
request; this effectively ignores the host_index
|
|
2463
|
+
in the spec for a single request.
|
|
2464
|
+
:type _host_index: int, optional
|
|
2465
|
+
:return: Returns the result object.
|
|
2466
|
+
""" # noqa: E501
|
|
2467
|
+
|
|
2468
|
+
_param = self._get_cluster_master_flavors_serialize(
|
|
2469
|
+
_request_auth=_request_auth,
|
|
2470
|
+
_content_type=_content_type,
|
|
2471
|
+
_headers=_headers,
|
|
2472
|
+
_host_index=_host_index
|
|
2473
|
+
)
|
|
2474
|
+
|
|
2475
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
2476
|
+
'200': "MasterFlavorsResponse",
|
|
2477
|
+
'400': "ErrorResponseModel",
|
|
2478
|
+
'401': "ErrorResponseModel",
|
|
2479
|
+
'500': None,
|
|
2480
|
+
}
|
|
2481
|
+
response_data = await self.api_client.call_api(
|
|
2482
|
+
*_param,
|
|
2483
|
+
_request_timeout=_request_timeout
|
|
2484
|
+
)
|
|
2485
|
+
await response_data.read()
|
|
2486
|
+
return self.api_client.response_deserialize(
|
|
2487
|
+
response_data=response_data,
|
|
2488
|
+
response_types_map=_response_types_map,
|
|
2489
|
+
)
|
|
2490
|
+
|
|
2491
|
+
|
|
2492
|
+
@validate_call
|
|
2493
|
+
async def get_cluster_master_flavors_without_preload_content(
|
|
2494
|
+
self,
|
|
2495
|
+
_request_timeout: Union[
|
|
2496
|
+
None,
|
|
2497
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2498
|
+
Tuple[
|
|
2499
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2500
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
2501
|
+
]
|
|
2502
|
+
] = None,
|
|
2503
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
2504
|
+
_content_type: Optional[StrictStr] = None,
|
|
2505
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
2506
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
2507
|
+
) -> RESTResponseType:
|
|
2508
|
+
"""Get Cluster Master Flavors
|
|
2509
|
+
|
|
2510
|
+
|
|
2511
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
2512
|
+
number provided, it will be total request
|
|
2513
|
+
timeout. It can also be a pair (tuple) of
|
|
2514
|
+
(connection, read) timeouts.
|
|
2515
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
2516
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
2517
|
+
request; this effectively ignores the
|
|
2518
|
+
authentication in the spec for a single request.
|
|
2519
|
+
:type _request_auth: dict, optional
|
|
2520
|
+
:param _content_type: force content-type for the request.
|
|
2521
|
+
:type _content_type: str, Optional
|
|
2522
|
+
:param _headers: set to override the headers for a single
|
|
2523
|
+
request; this effectively ignores the headers
|
|
2524
|
+
in the spec for a single request.
|
|
2525
|
+
:type _headers: dict, optional
|
|
2526
|
+
:param _host_index: set to override the host_index for a single
|
|
2527
|
+
request; this effectively ignores the host_index
|
|
2528
|
+
in the spec for a single request.
|
|
2529
|
+
:type _host_index: int, optional
|
|
2530
|
+
:return: Returns the result object.
|
|
2531
|
+
""" # noqa: E501
|
|
2532
|
+
|
|
2533
|
+
_param = self._get_cluster_master_flavors_serialize(
|
|
2534
|
+
_request_auth=_request_auth,
|
|
2535
|
+
_content_type=_content_type,
|
|
2536
|
+
_headers=_headers,
|
|
2537
|
+
_host_index=_host_index
|
|
2538
|
+
)
|
|
2539
|
+
|
|
2540
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
2541
|
+
'200': "MasterFlavorsResponse",
|
|
2542
|
+
'400': "ErrorResponseModel",
|
|
2543
|
+
'401': "ErrorResponseModel",
|
|
2544
|
+
'500': None,
|
|
2545
|
+
}
|
|
2546
|
+
response_data = await self.api_client.call_api(
|
|
2547
|
+
*_param,
|
|
2548
|
+
_request_timeout=_request_timeout
|
|
2549
|
+
)
|
|
2550
|
+
return response_data.response
|
|
2551
|
+
|
|
2552
|
+
|
|
2553
|
+
def _get_cluster_master_flavors_serialize(
|
|
2554
|
+
self,
|
|
2555
|
+
_request_auth,
|
|
2556
|
+
_content_type,
|
|
2557
|
+
_headers,
|
|
2558
|
+
_host_index,
|
|
2559
|
+
) -> RequestSerialized:
|
|
2560
|
+
|
|
2561
|
+
_host = None
|
|
2562
|
+
|
|
2563
|
+
_collection_formats: Dict[str, str] = {
|
|
2564
|
+
}
|
|
2565
|
+
|
|
2566
|
+
_path_params: Dict[str, str] = {}
|
|
2567
|
+
_query_params: List[Tuple[str, str]] = []
|
|
2568
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
2569
|
+
_form_params: List[Tuple[str, str]] = []
|
|
2570
|
+
_files: Dict[
|
|
2571
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
2572
|
+
] = {}
|
|
2573
|
+
_body_params: Optional[bytes] = None
|
|
2574
|
+
|
|
2575
|
+
# process the path parameters
|
|
2576
|
+
# process the query parameters
|
|
2577
|
+
# process the header parameters
|
|
2578
|
+
# process the form parameters
|
|
2579
|
+
# process the body parameter
|
|
2580
|
+
|
|
2581
|
+
|
|
2582
|
+
# set the HTTP header `Accept`
|
|
2583
|
+
if 'Accept' not in _header_params:
|
|
2584
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
2585
|
+
[
|
|
2586
|
+
'application/json'
|
|
2587
|
+
]
|
|
2588
|
+
)
|
|
2589
|
+
|
|
2590
|
+
|
|
2591
|
+
# authentication setting
|
|
2592
|
+
_auth_settings: List[str] = [
|
|
2593
|
+
'apiKey'
|
|
2594
|
+
]
|
|
2595
|
+
|
|
2596
|
+
return self.api_client.param_serialize(
|
|
2597
|
+
method='GET',
|
|
2598
|
+
resource_path='/core/clusters/master-flavors',
|
|
2599
|
+
path_params=_path_params,
|
|
2600
|
+
query_params=_query_params,
|
|
2601
|
+
header_params=_header_params,
|
|
2602
|
+
body=_body_params,
|
|
2603
|
+
post_params=_form_params,
|
|
2604
|
+
files=_files,
|
|
2605
|
+
auth_settings=_auth_settings,
|
|
2606
|
+
collection_formats=_collection_formats,
|
|
2607
|
+
_host=_host,
|
|
2608
|
+
_request_auth=_request_auth
|
|
2609
|
+
)
|
|
2610
|
+
|
|
2611
|
+
|
|
2612
|
+
|
|
2613
|
+
|
|
2614
|
+
@validate_call
|
|
2615
|
+
async def get_cluster_nodes(
|
|
2616
|
+
self,
|
|
2617
|
+
cluster_id: StrictInt,
|
|
2618
|
+
_request_timeout: Union[
|
|
2619
|
+
None,
|
|
2620
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2621
|
+
Tuple[
|
|
2622
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2623
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
2624
|
+
]
|
|
2625
|
+
] = None,
|
|
2626
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
2627
|
+
_content_type: Optional[StrictStr] = None,
|
|
2628
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
2629
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
2630
|
+
) -> ClusterNodesListResponse:
|
|
2631
|
+
"""Get Cluster Nodes
|
|
2632
|
+
|
|
2633
|
+
|
|
2634
|
+
:param cluster_id: (required)
|
|
2635
|
+
:type cluster_id: int
|
|
2636
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
2637
|
+
number provided, it will be total request
|
|
2638
|
+
timeout. It can also be a pair (tuple) of
|
|
2639
|
+
(connection, read) timeouts.
|
|
2640
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
2641
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
2642
|
+
request; this effectively ignores the
|
|
2643
|
+
authentication in the spec for a single request.
|
|
2644
|
+
:type _request_auth: dict, optional
|
|
2645
|
+
:param _content_type: force content-type for the request.
|
|
2646
|
+
:type _content_type: str, Optional
|
|
2647
|
+
:param _headers: set to override the headers for a single
|
|
2648
|
+
request; this effectively ignores the headers
|
|
2649
|
+
in the spec for a single request.
|
|
2650
|
+
:type _headers: dict, optional
|
|
2651
|
+
:param _host_index: set to override the host_index for a single
|
|
2652
|
+
request; this effectively ignores the host_index
|
|
2653
|
+
in the spec for a single request.
|
|
2654
|
+
:type _host_index: int, optional
|
|
2655
|
+
:return: Returns the result object.
|
|
2656
|
+
""" # noqa: E501
|
|
2657
|
+
|
|
2658
|
+
_param = self._get_cluster_nodes_serialize(
|
|
2659
|
+
cluster_id=cluster_id,
|
|
2660
|
+
_request_auth=_request_auth,
|
|
2661
|
+
_content_type=_content_type,
|
|
2662
|
+
_headers=_headers,
|
|
2663
|
+
_host_index=_host_index
|
|
2664
|
+
)
|
|
2665
|
+
|
|
2666
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
2667
|
+
'200': "ClusterNodesListResponse",
|
|
2668
|
+
'400': "ErrorResponseModel",
|
|
2669
|
+
'401': "ErrorResponseModel",
|
|
2670
|
+
'404': "ErrorResponseModel",
|
|
2671
|
+
'500': None,
|
|
2672
|
+
}
|
|
2673
|
+
response_data = await self.api_client.call_api(
|
|
2674
|
+
*_param,
|
|
2675
|
+
_request_timeout=_request_timeout
|
|
2676
|
+
)
|
|
2677
|
+
await response_data.read()
|
|
2678
|
+
return self.api_client.response_deserialize(
|
|
2679
|
+
response_data=response_data,
|
|
2680
|
+
response_types_map=_response_types_map,
|
|
2681
|
+
).data
|
|
2682
|
+
|
|
2683
|
+
|
|
2684
|
+
@validate_call
|
|
2685
|
+
async def get_cluster_nodes_with_http_info(
|
|
2686
|
+
self,
|
|
2687
|
+
cluster_id: StrictInt,
|
|
2688
|
+
_request_timeout: Union[
|
|
2689
|
+
None,
|
|
2690
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2691
|
+
Tuple[
|
|
2692
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2693
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
2694
|
+
]
|
|
2695
|
+
] = None,
|
|
2696
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
2697
|
+
_content_type: Optional[StrictStr] = None,
|
|
2698
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
2699
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
2700
|
+
) -> ApiResponse[ClusterNodesListResponse]:
|
|
2701
|
+
"""Get Cluster Nodes
|
|
2702
|
+
|
|
2703
|
+
|
|
2704
|
+
:param cluster_id: (required)
|
|
2705
|
+
:type cluster_id: int
|
|
2706
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
2707
|
+
number provided, it will be total request
|
|
2708
|
+
timeout. It can also be a pair (tuple) of
|
|
2709
|
+
(connection, read) timeouts.
|
|
2710
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
2711
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
2712
|
+
request; this effectively ignores the
|
|
2713
|
+
authentication in the spec for a single request.
|
|
2714
|
+
:type _request_auth: dict, optional
|
|
2715
|
+
:param _content_type: force content-type for the request.
|
|
2716
|
+
:type _content_type: str, Optional
|
|
2717
|
+
:param _headers: set to override the headers for a single
|
|
2718
|
+
request; this effectively ignores the headers
|
|
2719
|
+
in the spec for a single request.
|
|
2720
|
+
:type _headers: dict, optional
|
|
2721
|
+
:param _host_index: set to override the host_index for a single
|
|
2722
|
+
request; this effectively ignores the host_index
|
|
2723
|
+
in the spec for a single request.
|
|
2724
|
+
:type _host_index: int, optional
|
|
2725
|
+
:return: Returns the result object.
|
|
2726
|
+
""" # noqa: E501
|
|
2727
|
+
|
|
2728
|
+
_param = self._get_cluster_nodes_serialize(
|
|
2729
|
+
cluster_id=cluster_id,
|
|
2730
|
+
_request_auth=_request_auth,
|
|
2731
|
+
_content_type=_content_type,
|
|
2732
|
+
_headers=_headers,
|
|
2733
|
+
_host_index=_host_index
|
|
2734
|
+
)
|
|
2735
|
+
|
|
2736
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
2737
|
+
'200': "ClusterNodesListResponse",
|
|
2738
|
+
'400': "ErrorResponseModel",
|
|
2739
|
+
'401': "ErrorResponseModel",
|
|
2740
|
+
'404': "ErrorResponseModel",
|
|
2741
|
+
'500': None,
|
|
2742
|
+
}
|
|
2743
|
+
response_data = await self.api_client.call_api(
|
|
2744
|
+
*_param,
|
|
2745
|
+
_request_timeout=_request_timeout
|
|
2746
|
+
)
|
|
2747
|
+
await response_data.read()
|
|
2748
|
+
return self.api_client.response_deserialize(
|
|
2749
|
+
response_data=response_data,
|
|
2750
|
+
response_types_map=_response_types_map,
|
|
2751
|
+
)
|
|
2752
|
+
|
|
2753
|
+
|
|
2754
|
+
@validate_call
|
|
2755
|
+
async def get_cluster_nodes_without_preload_content(
|
|
2756
|
+
self,
|
|
2757
|
+
cluster_id: StrictInt,
|
|
2758
|
+
_request_timeout: Union[
|
|
2759
|
+
None,
|
|
2760
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2761
|
+
Tuple[
|
|
2762
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2763
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
2764
|
+
]
|
|
2765
|
+
] = None,
|
|
2766
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
2767
|
+
_content_type: Optional[StrictStr] = None,
|
|
2768
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
2769
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
2770
|
+
) -> RESTResponseType:
|
|
2771
|
+
"""Get Cluster Nodes
|
|
2772
|
+
|
|
2773
|
+
|
|
2774
|
+
:param cluster_id: (required)
|
|
2775
|
+
:type cluster_id: int
|
|
2776
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
2777
|
+
number provided, it will be total request
|
|
2778
|
+
timeout. It can also be a pair (tuple) of
|
|
2779
|
+
(connection, read) timeouts.
|
|
2780
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
2781
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
2782
|
+
request; this effectively ignores the
|
|
2783
|
+
authentication in the spec for a single request.
|
|
2784
|
+
:type _request_auth: dict, optional
|
|
2785
|
+
:param _content_type: force content-type for the request.
|
|
2786
|
+
:type _content_type: str, Optional
|
|
2787
|
+
:param _headers: set to override the headers for a single
|
|
2788
|
+
request; this effectively ignores the headers
|
|
2789
|
+
in the spec for a single request.
|
|
2790
|
+
:type _headers: dict, optional
|
|
2791
|
+
:param _host_index: set to override the host_index for a single
|
|
2792
|
+
request; this effectively ignores the host_index
|
|
2793
|
+
in the spec for a single request.
|
|
2794
|
+
:type _host_index: int, optional
|
|
2795
|
+
:return: Returns the result object.
|
|
2796
|
+
""" # noqa: E501
|
|
2797
|
+
|
|
2798
|
+
_param = self._get_cluster_nodes_serialize(
|
|
2799
|
+
cluster_id=cluster_id,
|
|
2800
|
+
_request_auth=_request_auth,
|
|
2801
|
+
_content_type=_content_type,
|
|
2802
|
+
_headers=_headers,
|
|
2803
|
+
_host_index=_host_index
|
|
2804
|
+
)
|
|
2805
|
+
|
|
2806
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
2807
|
+
'200': "ClusterNodesListResponse",
|
|
2808
|
+
'400': "ErrorResponseModel",
|
|
2809
|
+
'401': "ErrorResponseModel",
|
|
2810
|
+
'404': "ErrorResponseModel",
|
|
2811
|
+
'500': None,
|
|
2812
|
+
}
|
|
2813
|
+
response_data = await self.api_client.call_api(
|
|
2814
|
+
*_param,
|
|
2815
|
+
_request_timeout=_request_timeout
|
|
2816
|
+
)
|
|
2817
|
+
return response_data.response
|
|
2818
|
+
|
|
2819
|
+
|
|
2820
|
+
def _get_cluster_nodes_serialize(
|
|
2821
|
+
self,
|
|
2822
|
+
cluster_id,
|
|
2823
|
+
_request_auth,
|
|
2824
|
+
_content_type,
|
|
2825
|
+
_headers,
|
|
2826
|
+
_host_index,
|
|
2827
|
+
) -> RequestSerialized:
|
|
2828
|
+
|
|
2829
|
+
_host = None
|
|
2830
|
+
|
|
2831
|
+
_collection_formats: Dict[str, str] = {
|
|
2832
|
+
}
|
|
2833
|
+
|
|
2834
|
+
_path_params: Dict[str, str] = {}
|
|
2835
|
+
_query_params: List[Tuple[str, str]] = []
|
|
2836
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
2837
|
+
_form_params: List[Tuple[str, str]] = []
|
|
2838
|
+
_files: Dict[
|
|
2839
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
2840
|
+
] = {}
|
|
2841
|
+
_body_params: Optional[bytes] = None
|
|
2842
|
+
|
|
2843
|
+
# process the path parameters
|
|
2844
|
+
if cluster_id is not None:
|
|
2845
|
+
_path_params['cluster_id'] = cluster_id
|
|
2846
|
+
# process the query parameters
|
|
2847
|
+
# process the header parameters
|
|
2848
|
+
# process the form parameters
|
|
2849
|
+
# process the body parameter
|
|
2850
|
+
|
|
2851
|
+
|
|
2852
|
+
# set the HTTP header `Accept`
|
|
2853
|
+
if 'Accept' not in _header_params:
|
|
2854
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
2855
|
+
[
|
|
2856
|
+
'application/json'
|
|
2857
|
+
]
|
|
2858
|
+
)
|
|
2859
|
+
|
|
2860
|
+
|
|
2861
|
+
# authentication setting
|
|
2862
|
+
_auth_settings: List[str] = [
|
|
2863
|
+
'apiKey'
|
|
2864
|
+
]
|
|
2865
|
+
|
|
2866
|
+
return self.api_client.param_serialize(
|
|
2867
|
+
method='GET',
|
|
2868
|
+
resource_path='/core/clusters/{cluster_id}/nodes',
|
|
2869
|
+
path_params=_path_params,
|
|
2870
|
+
query_params=_query_params,
|
|
2871
|
+
header_params=_header_params,
|
|
2872
|
+
body=_body_params,
|
|
2873
|
+
post_params=_form_params,
|
|
2874
|
+
files=_files,
|
|
2875
|
+
auth_settings=_auth_settings,
|
|
2876
|
+
collection_formats=_collection_formats,
|
|
2877
|
+
_host=_host,
|
|
2878
|
+
_request_auth=_request_auth
|
|
2879
|
+
)
|
|
2880
|
+
|
|
2881
|
+
|
|
2882
|
+
|
|
2883
|
+
|
|
2884
|
+
@validate_call
|
|
2885
|
+
async def get_cluster_versions(
|
|
2886
|
+
self,
|
|
2887
|
+
region: Annotated[Optional[StrictStr], Field(description="Filter versions by region name (optional)")] = None,
|
|
2888
|
+
_request_timeout: Union[
|
|
2889
|
+
None,
|
|
2890
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2891
|
+
Tuple[
|
|
2892
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2893
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
2894
|
+
]
|
|
2895
|
+
] = None,
|
|
2896
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
2897
|
+
_content_type: Optional[StrictStr] = None,
|
|
2898
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
2899
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
2900
|
+
) -> ClusterVersions:
|
|
2901
|
+
"""List Cluster Versions
|
|
2902
|
+
|
|
2903
|
+
Lists available Kubernetes versions, optionally filtered by region.
|
|
2904
|
+
|
|
2905
|
+
:param region: Filter versions by region name (optional)
|
|
2906
|
+
:type region: str
|
|
2907
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
2908
|
+
number provided, it will be total request
|
|
2909
|
+
timeout. It can also be a pair (tuple) of
|
|
2910
|
+
(connection, read) timeouts.
|
|
2911
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
2912
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
2913
|
+
request; this effectively ignores the
|
|
2914
|
+
authentication in the spec for a single request.
|
|
2915
|
+
:type _request_auth: dict, optional
|
|
2916
|
+
:param _content_type: force content-type for the request.
|
|
2917
|
+
:type _content_type: str, Optional
|
|
2918
|
+
:param _headers: set to override the headers for a single
|
|
2919
|
+
request; this effectively ignores the headers
|
|
2920
|
+
in the spec for a single request.
|
|
2921
|
+
:type _headers: dict, optional
|
|
2922
|
+
:param _host_index: set to override the host_index for a single
|
|
2923
|
+
request; this effectively ignores the host_index
|
|
2924
|
+
in the spec for a single request.
|
|
2925
|
+
:type _host_index: int, optional
|
|
2926
|
+
:return: Returns the result object.
|
|
2927
|
+
""" # noqa: E501
|
|
2928
|
+
|
|
2929
|
+
_param = self._get_cluster_versions_serialize(
|
|
2930
|
+
region=region,
|
|
2931
|
+
_request_auth=_request_auth,
|
|
2932
|
+
_content_type=_content_type,
|
|
2933
|
+
_headers=_headers,
|
|
2934
|
+
_host_index=_host_index
|
|
2935
|
+
)
|
|
2936
|
+
|
|
2937
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
2938
|
+
'200': "ClusterVersions",
|
|
2939
|
+
'400': "ErrorResponseModel",
|
|
2940
|
+
'401': "ErrorResponseModel",
|
|
2941
|
+
'500': None,
|
|
2942
|
+
}
|
|
2943
|
+
response_data = await self.api_client.call_api(
|
|
2944
|
+
*_param,
|
|
2945
|
+
_request_timeout=_request_timeout
|
|
2946
|
+
)
|
|
2947
|
+
await response_data.read()
|
|
2948
|
+
return self.api_client.response_deserialize(
|
|
2949
|
+
response_data=response_data,
|
|
2950
|
+
response_types_map=_response_types_map,
|
|
2951
|
+
).data
|
|
2952
|
+
|
|
2953
|
+
|
|
2954
|
+
@validate_call
|
|
2955
|
+
async def get_cluster_versions_with_http_info(
|
|
2956
|
+
self,
|
|
2957
|
+
region: Annotated[Optional[StrictStr], Field(description="Filter versions by region name (optional)")] = None,
|
|
2958
|
+
_request_timeout: Union[
|
|
2959
|
+
None,
|
|
2960
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2961
|
+
Tuple[
|
|
2962
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
2963
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
2964
|
+
]
|
|
2965
|
+
] = None,
|
|
2966
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
2967
|
+
_content_type: Optional[StrictStr] = None,
|
|
2968
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
2969
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
2970
|
+
) -> ApiResponse[ClusterVersions]:
|
|
2971
|
+
"""List Cluster Versions
|
|
2972
|
+
|
|
2973
|
+
Lists available Kubernetes versions, optionally filtered by region.
|
|
2974
|
+
|
|
2975
|
+
:param region: Filter versions by region name (optional)
|
|
2976
|
+
:type region: str
|
|
2977
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
2978
|
+
number provided, it will be total request
|
|
2979
|
+
timeout. It can also be a pair (tuple) of
|
|
2980
|
+
(connection, read) timeouts.
|
|
2981
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
2982
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
2983
|
+
request; this effectively ignores the
|
|
2984
|
+
authentication in the spec for a single request.
|
|
2985
|
+
:type _request_auth: dict, optional
|
|
2986
|
+
:param _content_type: force content-type for the request.
|
|
2987
|
+
:type _content_type: str, Optional
|
|
2988
|
+
:param _headers: set to override the headers for a single
|
|
2989
|
+
request; this effectively ignores the headers
|
|
2990
|
+
in the spec for a single request.
|
|
2991
|
+
:type _headers: dict, optional
|
|
2992
|
+
:param _host_index: set to override the host_index for a single
|
|
2993
|
+
request; this effectively ignores the host_index
|
|
2994
|
+
in the spec for a single request.
|
|
2995
|
+
:type _host_index: int, optional
|
|
2996
|
+
:return: Returns the result object.
|
|
2997
|
+
""" # noqa: E501
|
|
2998
|
+
|
|
2999
|
+
_param = self._get_cluster_versions_serialize(
|
|
3000
|
+
region=region,
|
|
3001
|
+
_request_auth=_request_auth,
|
|
3002
|
+
_content_type=_content_type,
|
|
3003
|
+
_headers=_headers,
|
|
3004
|
+
_host_index=_host_index
|
|
3005
|
+
)
|
|
3006
|
+
|
|
3007
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
3008
|
+
'200': "ClusterVersions",
|
|
3009
|
+
'400': "ErrorResponseModel",
|
|
3010
|
+
'401': "ErrorResponseModel",
|
|
3011
|
+
'500': None,
|
|
3012
|
+
}
|
|
3013
|
+
response_data = await self.api_client.call_api(
|
|
3014
|
+
*_param,
|
|
3015
|
+
_request_timeout=_request_timeout
|
|
3016
|
+
)
|
|
3017
|
+
await response_data.read()
|
|
3018
|
+
return self.api_client.response_deserialize(
|
|
3019
|
+
response_data=response_data,
|
|
3020
|
+
response_types_map=_response_types_map,
|
|
3021
|
+
)
|
|
3022
|
+
|
|
3023
|
+
|
|
3024
|
+
@validate_call
|
|
3025
|
+
async def get_cluster_versions_without_preload_content(
|
|
3026
|
+
self,
|
|
3027
|
+
region: Annotated[Optional[StrictStr], Field(description="Filter versions by region name (optional)")] = None,
|
|
3028
|
+
_request_timeout: Union[
|
|
3029
|
+
None,
|
|
3030
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3031
|
+
Tuple[
|
|
3032
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3033
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
3034
|
+
]
|
|
3035
|
+
] = None,
|
|
3036
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
3037
|
+
_content_type: Optional[StrictStr] = None,
|
|
3038
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
3039
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
3040
|
+
) -> RESTResponseType:
|
|
3041
|
+
"""List Cluster Versions
|
|
3042
|
+
|
|
3043
|
+
Lists available Kubernetes versions, optionally filtered by region.
|
|
3044
|
+
|
|
3045
|
+
:param region: Filter versions by region name (optional)
|
|
3046
|
+
:type region: str
|
|
3047
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
3048
|
+
number provided, it will be total request
|
|
3049
|
+
timeout. It can also be a pair (tuple) of
|
|
3050
|
+
(connection, read) timeouts.
|
|
3051
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
3052
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
3053
|
+
request; this effectively ignores the
|
|
3054
|
+
authentication in the spec for a single request.
|
|
3055
|
+
:type _request_auth: dict, optional
|
|
3056
|
+
:param _content_type: force content-type for the request.
|
|
3057
|
+
:type _content_type: str, Optional
|
|
3058
|
+
:param _headers: set to override the headers for a single
|
|
3059
|
+
request; this effectively ignores the headers
|
|
3060
|
+
in the spec for a single request.
|
|
3061
|
+
:type _headers: dict, optional
|
|
3062
|
+
:param _host_index: set to override the host_index for a single
|
|
3063
|
+
request; this effectively ignores the host_index
|
|
3064
|
+
in the spec for a single request.
|
|
3065
|
+
:type _host_index: int, optional
|
|
3066
|
+
:return: Returns the result object.
|
|
3067
|
+
""" # noqa: E501
|
|
3068
|
+
|
|
3069
|
+
_param = self._get_cluster_versions_serialize(
|
|
3070
|
+
region=region,
|
|
3071
|
+
_request_auth=_request_auth,
|
|
3072
|
+
_content_type=_content_type,
|
|
3073
|
+
_headers=_headers,
|
|
3074
|
+
_host_index=_host_index
|
|
3075
|
+
)
|
|
3076
|
+
|
|
3077
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
3078
|
+
'200': "ClusterVersions",
|
|
3079
|
+
'400': "ErrorResponseModel",
|
|
3080
|
+
'401': "ErrorResponseModel",
|
|
3081
|
+
'500': None,
|
|
3082
|
+
}
|
|
3083
|
+
response_data = await self.api_client.call_api(
|
|
3084
|
+
*_param,
|
|
3085
|
+
_request_timeout=_request_timeout
|
|
3086
|
+
)
|
|
3087
|
+
return response_data.response
|
|
3088
|
+
|
|
3089
|
+
|
|
3090
|
+
def _get_cluster_versions_serialize(
|
|
3091
|
+
self,
|
|
3092
|
+
region,
|
|
3093
|
+
_request_auth,
|
|
3094
|
+
_content_type,
|
|
3095
|
+
_headers,
|
|
3096
|
+
_host_index,
|
|
3097
|
+
) -> RequestSerialized:
|
|
3098
|
+
|
|
3099
|
+
_host = None
|
|
3100
|
+
|
|
3101
|
+
_collection_formats: Dict[str, str] = {
|
|
3102
|
+
}
|
|
3103
|
+
|
|
3104
|
+
_path_params: Dict[str, str] = {}
|
|
3105
|
+
_query_params: List[Tuple[str, str]] = []
|
|
3106
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
3107
|
+
_form_params: List[Tuple[str, str]] = []
|
|
3108
|
+
_files: Dict[
|
|
3109
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
3110
|
+
] = {}
|
|
3111
|
+
_body_params: Optional[bytes] = None
|
|
3112
|
+
|
|
3113
|
+
# process the path parameters
|
|
3114
|
+
# process the query parameters
|
|
3115
|
+
if region is not None:
|
|
3116
|
+
|
|
3117
|
+
_query_params.append(('region', region))
|
|
3118
|
+
|
|
3119
|
+
# process the header parameters
|
|
3120
|
+
# process the form parameters
|
|
3121
|
+
# process the body parameter
|
|
3122
|
+
|
|
3123
|
+
|
|
3124
|
+
# set the HTTP header `Accept`
|
|
3125
|
+
if 'Accept' not in _header_params:
|
|
3126
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
3127
|
+
[
|
|
3128
|
+
'application/json'
|
|
3129
|
+
]
|
|
3130
|
+
)
|
|
3131
|
+
|
|
3132
|
+
|
|
3133
|
+
# authentication setting
|
|
3134
|
+
_auth_settings: List[str] = [
|
|
3135
|
+
'apiKey'
|
|
3136
|
+
]
|
|
3137
|
+
|
|
3138
|
+
return self.api_client.param_serialize(
|
|
3139
|
+
method='GET',
|
|
3140
|
+
resource_path='/core/clusters/versions',
|
|
3141
|
+
path_params=_path_params,
|
|
3142
|
+
query_params=_query_params,
|
|
3143
|
+
header_params=_header_params,
|
|
3144
|
+
body=_body_params,
|
|
3145
|
+
post_params=_form_params,
|
|
3146
|
+
files=_files,
|
|
3147
|
+
auth_settings=_auth_settings,
|
|
3148
|
+
collection_formats=_collection_formats,
|
|
3149
|
+
_host=_host,
|
|
3150
|
+
_request_auth=_request_auth
|
|
3151
|
+
)
|
|
3152
|
+
|
|
3153
|
+
|
|
3154
|
+
|
|
3155
|
+
|
|
3156
|
+
@validate_call
|
|
3157
|
+
async def get_node_group(
|
|
3158
|
+
self,
|
|
3159
|
+
cluster_id: StrictInt,
|
|
3160
|
+
node_group_id: StrictInt,
|
|
3161
|
+
_request_timeout: Union[
|
|
3162
|
+
None,
|
|
3163
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3164
|
+
Tuple[
|
|
3165
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3166
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
3167
|
+
]
|
|
3168
|
+
] = None,
|
|
3169
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
3170
|
+
_content_type: Optional[StrictStr] = None,
|
|
3171
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
3172
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
3173
|
+
) -> ClusterNodeGroupsGetResponse:
|
|
3174
|
+
"""Retrieve a node group in a cluster
|
|
3175
|
+
|
|
3176
|
+
|
|
3177
|
+
:param cluster_id: (required)
|
|
3178
|
+
:type cluster_id: int
|
|
3179
|
+
:param node_group_id: (required)
|
|
3180
|
+
:type node_group_id: int
|
|
3181
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
3182
|
+
number provided, it will be total request
|
|
3183
|
+
timeout. It can also be a pair (tuple) of
|
|
3184
|
+
(connection, read) timeouts.
|
|
3185
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
3186
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
3187
|
+
request; this effectively ignores the
|
|
3188
|
+
authentication in the spec for a single request.
|
|
3189
|
+
:type _request_auth: dict, optional
|
|
3190
|
+
:param _content_type: force content-type for the request.
|
|
3191
|
+
:type _content_type: str, Optional
|
|
3192
|
+
:param _headers: set to override the headers for a single
|
|
3193
|
+
request; this effectively ignores the headers
|
|
3194
|
+
in the spec for a single request.
|
|
3195
|
+
:type _headers: dict, optional
|
|
3196
|
+
:param _host_index: set to override the host_index for a single
|
|
3197
|
+
request; this effectively ignores the host_index
|
|
3198
|
+
in the spec for a single request.
|
|
3199
|
+
:type _host_index: int, optional
|
|
3200
|
+
:return: Returns the result object.
|
|
3201
|
+
""" # noqa: E501
|
|
3202
|
+
|
|
3203
|
+
_param = self._get_node_group_serialize(
|
|
3204
|
+
cluster_id=cluster_id,
|
|
3205
|
+
node_group_id=node_group_id,
|
|
3206
|
+
_request_auth=_request_auth,
|
|
3207
|
+
_content_type=_content_type,
|
|
3208
|
+
_headers=_headers,
|
|
3209
|
+
_host_index=_host_index
|
|
3210
|
+
)
|
|
3211
|
+
|
|
3212
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
3213
|
+
'200': "ClusterNodeGroupsGetResponse",
|
|
3214
|
+
'400': "ErrorResponseModel",
|
|
3215
|
+
'401': "ErrorResponseModel",
|
|
3216
|
+
'404': "ErrorResponseModel",
|
|
3217
|
+
'500': None,
|
|
3218
|
+
}
|
|
3219
|
+
response_data = await self.api_client.call_api(
|
|
3220
|
+
*_param,
|
|
3221
|
+
_request_timeout=_request_timeout
|
|
3222
|
+
)
|
|
3223
|
+
await response_data.read()
|
|
3224
|
+
return self.api_client.response_deserialize(
|
|
3225
|
+
response_data=response_data,
|
|
3226
|
+
response_types_map=_response_types_map,
|
|
3227
|
+
).data
|
|
3228
|
+
|
|
3229
|
+
|
|
3230
|
+
@validate_call
|
|
3231
|
+
async def get_node_group_with_http_info(
|
|
3232
|
+
self,
|
|
3233
|
+
cluster_id: StrictInt,
|
|
3234
|
+
node_group_id: StrictInt,
|
|
3235
|
+
_request_timeout: Union[
|
|
3236
|
+
None,
|
|
3237
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3238
|
+
Tuple[
|
|
3239
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3240
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
3241
|
+
]
|
|
3242
|
+
] = None,
|
|
3243
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
3244
|
+
_content_type: Optional[StrictStr] = None,
|
|
3245
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
3246
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
3247
|
+
) -> ApiResponse[ClusterNodeGroupsGetResponse]:
|
|
3248
|
+
"""Retrieve a node group in a cluster
|
|
3249
|
+
|
|
3250
|
+
|
|
3251
|
+
:param cluster_id: (required)
|
|
3252
|
+
:type cluster_id: int
|
|
3253
|
+
:param node_group_id: (required)
|
|
3254
|
+
:type node_group_id: int
|
|
3255
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
3256
|
+
number provided, it will be total request
|
|
3257
|
+
timeout. It can also be a pair (tuple) of
|
|
3258
|
+
(connection, read) timeouts.
|
|
3259
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
3260
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
3261
|
+
request; this effectively ignores the
|
|
3262
|
+
authentication in the spec for a single request.
|
|
3263
|
+
:type _request_auth: dict, optional
|
|
3264
|
+
:param _content_type: force content-type for the request.
|
|
3265
|
+
:type _content_type: str, Optional
|
|
3266
|
+
:param _headers: set to override the headers for a single
|
|
3267
|
+
request; this effectively ignores the headers
|
|
3268
|
+
in the spec for a single request.
|
|
3269
|
+
:type _headers: dict, optional
|
|
3270
|
+
:param _host_index: set to override the host_index for a single
|
|
3271
|
+
request; this effectively ignores the host_index
|
|
3272
|
+
in the spec for a single request.
|
|
3273
|
+
:type _host_index: int, optional
|
|
3274
|
+
:return: Returns the result object.
|
|
3275
|
+
""" # noqa: E501
|
|
3276
|
+
|
|
3277
|
+
_param = self._get_node_group_serialize(
|
|
3278
|
+
cluster_id=cluster_id,
|
|
3279
|
+
node_group_id=node_group_id,
|
|
3280
|
+
_request_auth=_request_auth,
|
|
3281
|
+
_content_type=_content_type,
|
|
3282
|
+
_headers=_headers,
|
|
3283
|
+
_host_index=_host_index
|
|
3284
|
+
)
|
|
3285
|
+
|
|
3286
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
3287
|
+
'200': "ClusterNodeGroupsGetResponse",
|
|
3288
|
+
'400': "ErrorResponseModel",
|
|
3289
|
+
'401': "ErrorResponseModel",
|
|
3290
|
+
'404': "ErrorResponseModel",
|
|
3291
|
+
'500': None,
|
|
3292
|
+
}
|
|
3293
|
+
response_data = await self.api_client.call_api(
|
|
3294
|
+
*_param,
|
|
3295
|
+
_request_timeout=_request_timeout
|
|
3296
|
+
)
|
|
3297
|
+
await response_data.read()
|
|
3298
|
+
return self.api_client.response_deserialize(
|
|
3299
|
+
response_data=response_data,
|
|
3300
|
+
response_types_map=_response_types_map,
|
|
3301
|
+
)
|
|
3302
|
+
|
|
3303
|
+
|
|
3304
|
+
@validate_call
|
|
3305
|
+
async def get_node_group_without_preload_content(
|
|
3306
|
+
self,
|
|
3307
|
+
cluster_id: StrictInt,
|
|
3308
|
+
node_group_id: StrictInt,
|
|
3309
|
+
_request_timeout: Union[
|
|
3310
|
+
None,
|
|
3311
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3312
|
+
Tuple[
|
|
3313
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3314
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
3315
|
+
]
|
|
3316
|
+
] = None,
|
|
3317
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
3318
|
+
_content_type: Optional[StrictStr] = None,
|
|
3319
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
3320
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
3321
|
+
) -> RESTResponseType:
|
|
3322
|
+
"""Retrieve a node group in a cluster
|
|
3323
|
+
|
|
3324
|
+
|
|
3325
|
+
:param cluster_id: (required)
|
|
3326
|
+
:type cluster_id: int
|
|
3327
|
+
:param node_group_id: (required)
|
|
3328
|
+
:type node_group_id: int
|
|
3329
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
3330
|
+
number provided, it will be total request
|
|
3331
|
+
timeout. It can also be a pair (tuple) of
|
|
3332
|
+
(connection, read) timeouts.
|
|
3333
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
3334
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
3335
|
+
request; this effectively ignores the
|
|
3336
|
+
authentication in the spec for a single request.
|
|
3337
|
+
:type _request_auth: dict, optional
|
|
3338
|
+
:param _content_type: force content-type for the request.
|
|
3339
|
+
:type _content_type: str, Optional
|
|
3340
|
+
:param _headers: set to override the headers for a single
|
|
3341
|
+
request; this effectively ignores the headers
|
|
3342
|
+
in the spec for a single request.
|
|
3343
|
+
:type _headers: dict, optional
|
|
3344
|
+
:param _host_index: set to override the host_index for a single
|
|
3345
|
+
request; this effectively ignores the host_index
|
|
3346
|
+
in the spec for a single request.
|
|
3347
|
+
:type _host_index: int, optional
|
|
3348
|
+
:return: Returns the result object.
|
|
3349
|
+
""" # noqa: E501
|
|
3350
|
+
|
|
3351
|
+
_param = self._get_node_group_serialize(
|
|
3352
|
+
cluster_id=cluster_id,
|
|
3353
|
+
node_group_id=node_group_id,
|
|
3354
|
+
_request_auth=_request_auth,
|
|
3355
|
+
_content_type=_content_type,
|
|
3356
|
+
_headers=_headers,
|
|
3357
|
+
_host_index=_host_index
|
|
3358
|
+
)
|
|
3359
|
+
|
|
3360
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
3361
|
+
'200': "ClusterNodeGroupsGetResponse",
|
|
3362
|
+
'400': "ErrorResponseModel",
|
|
3363
|
+
'401': "ErrorResponseModel",
|
|
3364
|
+
'404': "ErrorResponseModel",
|
|
3365
|
+
'500': None,
|
|
3366
|
+
}
|
|
3367
|
+
response_data = await self.api_client.call_api(
|
|
3368
|
+
*_param,
|
|
3369
|
+
_request_timeout=_request_timeout
|
|
3370
|
+
)
|
|
3371
|
+
return response_data.response
|
|
3372
|
+
|
|
3373
|
+
|
|
3374
|
+
def _get_node_group_serialize(
|
|
3375
|
+
self,
|
|
3376
|
+
cluster_id,
|
|
3377
|
+
node_group_id,
|
|
3378
|
+
_request_auth,
|
|
3379
|
+
_content_type,
|
|
3380
|
+
_headers,
|
|
3381
|
+
_host_index,
|
|
3382
|
+
) -> RequestSerialized:
|
|
3383
|
+
|
|
3384
|
+
_host = None
|
|
3385
|
+
|
|
3386
|
+
_collection_formats: Dict[str, str] = {
|
|
3387
|
+
}
|
|
3388
|
+
|
|
3389
|
+
_path_params: Dict[str, str] = {}
|
|
3390
|
+
_query_params: List[Tuple[str, str]] = []
|
|
3391
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
3392
|
+
_form_params: List[Tuple[str, str]] = []
|
|
3393
|
+
_files: Dict[
|
|
3394
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
3395
|
+
] = {}
|
|
3396
|
+
_body_params: Optional[bytes] = None
|
|
3397
|
+
|
|
3398
|
+
# process the path parameters
|
|
3399
|
+
if cluster_id is not None:
|
|
3400
|
+
_path_params['cluster_id'] = cluster_id
|
|
3401
|
+
if node_group_id is not None:
|
|
3402
|
+
_path_params['node_group_id'] = node_group_id
|
|
3403
|
+
# process the query parameters
|
|
3404
|
+
# process the header parameters
|
|
3405
|
+
# process the form parameters
|
|
3406
|
+
# process the body parameter
|
|
3407
|
+
|
|
3408
|
+
|
|
3409
|
+
# set the HTTP header `Accept`
|
|
3410
|
+
if 'Accept' not in _header_params:
|
|
3411
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
3412
|
+
[
|
|
3413
|
+
'application/json'
|
|
3414
|
+
]
|
|
3415
|
+
)
|
|
3416
|
+
|
|
3417
|
+
|
|
3418
|
+
# authentication setting
|
|
3419
|
+
_auth_settings: List[str] = [
|
|
3420
|
+
'apiKey'
|
|
3421
|
+
]
|
|
3422
|
+
|
|
3423
|
+
return self.api_client.param_serialize(
|
|
3424
|
+
method='GET',
|
|
3425
|
+
resource_path='/core/clusters/{cluster_id}/node-groups/{node_group_id}',
|
|
3426
|
+
path_params=_path_params,
|
|
3427
|
+
query_params=_query_params,
|
|
3428
|
+
header_params=_header_params,
|
|
3429
|
+
body=_body_params,
|
|
3430
|
+
post_params=_form_params,
|
|
3431
|
+
files=_files,
|
|
3432
|
+
auth_settings=_auth_settings,
|
|
3433
|
+
collection_formats=_collection_formats,
|
|
3434
|
+
_host=_host,
|
|
3435
|
+
_request_auth=_request_auth
|
|
3436
|
+
)
|
|
3437
|
+
|
|
3438
|
+
|
|
3439
|
+
|
|
3440
|
+
|
|
3441
|
+
@validate_call
|
|
3442
|
+
async def getting_cluster_detail(
|
|
3443
|
+
self,
|
|
3444
|
+
id: StrictInt,
|
|
3445
|
+
_request_timeout: Union[
|
|
3446
|
+
None,
|
|
3447
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3448
|
+
Tuple[
|
|
3449
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3450
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
3451
|
+
]
|
|
3452
|
+
] = None,
|
|
3453
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
3454
|
+
_content_type: Optional[StrictStr] = None,
|
|
3455
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
3456
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
3457
|
+
) -> ClusterResponse:
|
|
3458
|
+
"""Getting Cluster Detail
|
|
3459
|
+
|
|
3460
|
+
|
|
3461
|
+
:param id: (required)
|
|
3462
|
+
:type id: int
|
|
3463
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
3464
|
+
number provided, it will be total request
|
|
3465
|
+
timeout. It can also be a pair (tuple) of
|
|
3466
|
+
(connection, read) timeouts.
|
|
3467
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
3468
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
3469
|
+
request; this effectively ignores the
|
|
3470
|
+
authentication in the spec for a single request.
|
|
3471
|
+
:type _request_auth: dict, optional
|
|
3472
|
+
:param _content_type: force content-type for the request.
|
|
3473
|
+
:type _content_type: str, Optional
|
|
3474
|
+
:param _headers: set to override the headers for a single
|
|
3475
|
+
request; this effectively ignores the headers
|
|
3476
|
+
in the spec for a single request.
|
|
3477
|
+
:type _headers: dict, optional
|
|
3478
|
+
:param _host_index: set to override the host_index for a single
|
|
3479
|
+
request; this effectively ignores the host_index
|
|
3480
|
+
in the spec for a single request.
|
|
3481
|
+
:type _host_index: int, optional
|
|
3482
|
+
:return: Returns the result object.
|
|
3483
|
+
""" # noqa: E501
|
|
3484
|
+
|
|
3485
|
+
_param = self._getting_cluster_detail_serialize(
|
|
3486
|
+
id=id,
|
|
3487
|
+
_request_auth=_request_auth,
|
|
3488
|
+
_content_type=_content_type,
|
|
3489
|
+
_headers=_headers,
|
|
3490
|
+
_host_index=_host_index
|
|
3491
|
+
)
|
|
3492
|
+
|
|
3493
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
3494
|
+
'200': "ClusterResponse",
|
|
3495
|
+
'400': "ErrorResponseModel",
|
|
3496
|
+
'401': "ErrorResponseModel",
|
|
3497
|
+
'404': "ErrorResponseModel",
|
|
3498
|
+
'500': None,
|
|
3499
|
+
}
|
|
3500
|
+
response_data = await self.api_client.call_api(
|
|
3501
|
+
*_param,
|
|
3502
|
+
_request_timeout=_request_timeout
|
|
3503
|
+
)
|
|
3504
|
+
await response_data.read()
|
|
3505
|
+
return self.api_client.response_deserialize(
|
|
3506
|
+
response_data=response_data,
|
|
3507
|
+
response_types_map=_response_types_map,
|
|
3508
|
+
).data
|
|
3509
|
+
|
|
3510
|
+
|
|
3511
|
+
@validate_call
|
|
3512
|
+
async def getting_cluster_detail_with_http_info(
|
|
3513
|
+
self,
|
|
3514
|
+
id: StrictInt,
|
|
3515
|
+
_request_timeout: Union[
|
|
3516
|
+
None,
|
|
3517
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3518
|
+
Tuple[
|
|
3519
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3520
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
3521
|
+
]
|
|
3522
|
+
] = None,
|
|
3523
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
3524
|
+
_content_type: Optional[StrictStr] = None,
|
|
3525
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
3526
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
3527
|
+
) -> ApiResponse[ClusterResponse]:
|
|
3528
|
+
"""Getting Cluster Detail
|
|
3529
|
+
|
|
3530
|
+
|
|
3531
|
+
:param id: (required)
|
|
3532
|
+
:type id: int
|
|
3533
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
3534
|
+
number provided, it will be total request
|
|
3535
|
+
timeout. It can also be a pair (tuple) of
|
|
3536
|
+
(connection, read) timeouts.
|
|
3537
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
3538
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
3539
|
+
request; this effectively ignores the
|
|
3540
|
+
authentication in the spec for a single request.
|
|
3541
|
+
:type _request_auth: dict, optional
|
|
3542
|
+
:param _content_type: force content-type for the request.
|
|
3543
|
+
:type _content_type: str, Optional
|
|
3544
|
+
:param _headers: set to override the headers for a single
|
|
3545
|
+
request; this effectively ignores the headers
|
|
3546
|
+
in the spec for a single request.
|
|
3547
|
+
:type _headers: dict, optional
|
|
3548
|
+
:param _host_index: set to override the host_index for a single
|
|
3549
|
+
request; this effectively ignores the host_index
|
|
3550
|
+
in the spec for a single request.
|
|
3551
|
+
:type _host_index: int, optional
|
|
3552
|
+
:return: Returns the result object.
|
|
3553
|
+
""" # noqa: E501
|
|
3554
|
+
|
|
3555
|
+
_param = self._getting_cluster_detail_serialize(
|
|
3556
|
+
id=id,
|
|
3557
|
+
_request_auth=_request_auth,
|
|
3558
|
+
_content_type=_content_type,
|
|
3559
|
+
_headers=_headers,
|
|
3560
|
+
_host_index=_host_index
|
|
3561
|
+
)
|
|
3562
|
+
|
|
3563
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
3564
|
+
'200': "ClusterResponse",
|
|
3565
|
+
'400': "ErrorResponseModel",
|
|
3566
|
+
'401': "ErrorResponseModel",
|
|
3567
|
+
'404': "ErrorResponseModel",
|
|
3568
|
+
'500': None,
|
|
3569
|
+
}
|
|
3570
|
+
response_data = await self.api_client.call_api(
|
|
3571
|
+
*_param,
|
|
3572
|
+
_request_timeout=_request_timeout
|
|
3573
|
+
)
|
|
3574
|
+
await response_data.read()
|
|
3575
|
+
return self.api_client.response_deserialize(
|
|
3576
|
+
response_data=response_data,
|
|
3577
|
+
response_types_map=_response_types_map,
|
|
3578
|
+
)
|
|
3579
|
+
|
|
3580
|
+
|
|
3581
|
+
@validate_call
|
|
3582
|
+
async def getting_cluster_detail_without_preload_content(
|
|
3583
|
+
self,
|
|
3584
|
+
id: StrictInt,
|
|
3585
|
+
_request_timeout: Union[
|
|
3586
|
+
None,
|
|
3587
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3588
|
+
Tuple[
|
|
3589
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3590
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
3591
|
+
]
|
|
3592
|
+
] = None,
|
|
3593
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
3594
|
+
_content_type: Optional[StrictStr] = None,
|
|
3595
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
3596
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
3597
|
+
) -> RESTResponseType:
|
|
3598
|
+
"""Getting Cluster Detail
|
|
3599
|
+
|
|
3600
|
+
|
|
3601
|
+
:param id: (required)
|
|
3602
|
+
:type id: int
|
|
3603
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
3604
|
+
number provided, it will be total request
|
|
3605
|
+
timeout. It can also be a pair (tuple) of
|
|
3606
|
+
(connection, read) timeouts.
|
|
3607
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
3608
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
3609
|
+
request; this effectively ignores the
|
|
3610
|
+
authentication in the spec for a single request.
|
|
3611
|
+
:type _request_auth: dict, optional
|
|
3612
|
+
:param _content_type: force content-type for the request.
|
|
3613
|
+
:type _content_type: str, Optional
|
|
3614
|
+
:param _headers: set to override the headers for a single
|
|
3615
|
+
request; this effectively ignores the headers
|
|
3616
|
+
in the spec for a single request.
|
|
3617
|
+
:type _headers: dict, optional
|
|
3618
|
+
:param _host_index: set to override the host_index for a single
|
|
3619
|
+
request; this effectively ignores the host_index
|
|
3620
|
+
in the spec for a single request.
|
|
3621
|
+
:type _host_index: int, optional
|
|
3622
|
+
:return: Returns the result object.
|
|
3623
|
+
""" # noqa: E501
|
|
3624
|
+
|
|
3625
|
+
_param = self._getting_cluster_detail_serialize(
|
|
3626
|
+
id=id,
|
|
3627
|
+
_request_auth=_request_auth,
|
|
3628
|
+
_content_type=_content_type,
|
|
3629
|
+
_headers=_headers,
|
|
3630
|
+
_host_index=_host_index
|
|
3631
|
+
)
|
|
3632
|
+
|
|
3633
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
3634
|
+
'200': "ClusterResponse",
|
|
3635
|
+
'400': "ErrorResponseModel",
|
|
3636
|
+
'401': "ErrorResponseModel",
|
|
3637
|
+
'404': "ErrorResponseModel",
|
|
3638
|
+
'500': None,
|
|
3639
|
+
}
|
|
3640
|
+
response_data = await self.api_client.call_api(
|
|
3641
|
+
*_param,
|
|
3642
|
+
_request_timeout=_request_timeout
|
|
3643
|
+
)
|
|
3644
|
+
return response_data.response
|
|
3645
|
+
|
|
3646
|
+
|
|
3647
|
+
def _getting_cluster_detail_serialize(
|
|
3648
|
+
self,
|
|
3649
|
+
id,
|
|
3650
|
+
_request_auth,
|
|
3651
|
+
_content_type,
|
|
3652
|
+
_headers,
|
|
3653
|
+
_host_index,
|
|
3654
|
+
) -> RequestSerialized:
|
|
3655
|
+
|
|
3656
|
+
_host = None
|
|
3657
|
+
|
|
3658
|
+
_collection_formats: Dict[str, str] = {
|
|
3659
|
+
}
|
|
3660
|
+
|
|
3661
|
+
_path_params: Dict[str, str] = {}
|
|
3662
|
+
_query_params: List[Tuple[str, str]] = []
|
|
3663
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
3664
|
+
_form_params: List[Tuple[str, str]] = []
|
|
3665
|
+
_files: Dict[
|
|
3666
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
3667
|
+
] = {}
|
|
3668
|
+
_body_params: Optional[bytes] = None
|
|
3669
|
+
|
|
3670
|
+
# process the path parameters
|
|
3671
|
+
if id is not None:
|
|
3672
|
+
_path_params['id'] = id
|
|
3673
|
+
# process the query parameters
|
|
3674
|
+
# process the header parameters
|
|
3675
|
+
# process the form parameters
|
|
3676
|
+
# process the body parameter
|
|
3677
|
+
|
|
3678
|
+
|
|
3679
|
+
# set the HTTP header `Accept`
|
|
3680
|
+
if 'Accept' not in _header_params:
|
|
3681
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
3682
|
+
[
|
|
3683
|
+
'application/json'
|
|
3684
|
+
]
|
|
3685
|
+
)
|
|
3686
|
+
|
|
3687
|
+
|
|
3688
|
+
# authentication setting
|
|
3689
|
+
_auth_settings: List[str] = [
|
|
3690
|
+
'apiKey'
|
|
3691
|
+
]
|
|
3692
|
+
|
|
3693
|
+
return self.api_client.param_serialize(
|
|
3694
|
+
method='GET',
|
|
3695
|
+
resource_path='/core/clusters/{id}',
|
|
3696
|
+
path_params=_path_params,
|
|
3697
|
+
query_params=_query_params,
|
|
3698
|
+
header_params=_header_params,
|
|
3699
|
+
body=_body_params,
|
|
3700
|
+
post_params=_form_params,
|
|
3701
|
+
files=_files,
|
|
3702
|
+
auth_settings=_auth_settings,
|
|
3703
|
+
collection_formats=_collection_formats,
|
|
3704
|
+
_host=_host,
|
|
3705
|
+
_request_auth=_request_auth
|
|
3706
|
+
)
|
|
3707
|
+
|
|
3708
|
+
|
|
3709
|
+
|
|
3710
|
+
|
|
3711
|
+
@validate_call
|
|
3712
|
+
async def list_clusters(
|
|
3713
|
+
self,
|
|
3714
|
+
page: Annotated[Optional[StrictInt], Field(description="Page number for pagination")] = None,
|
|
3715
|
+
page_size: Annotated[Optional[StrictInt], Field(description="Number of items per page")] = None,
|
|
3716
|
+
environment: Annotated[Optional[StrictStr], Field(description="Environment Filter")] = None,
|
|
3717
|
+
search: Annotated[Optional[StrictStr], Field(description="Search query to filter cluster by name")] = None,
|
|
3718
|
+
_request_timeout: Union[
|
|
3719
|
+
None,
|
|
3720
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3721
|
+
Tuple[
|
|
3722
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3723
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
3724
|
+
]
|
|
3725
|
+
] = None,
|
|
3726
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
3727
|
+
_content_type: Optional[StrictStr] = None,
|
|
3728
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
3729
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
3730
|
+
) -> ClusterListResponse:
|
|
3731
|
+
"""List Clusters
|
|
3732
|
+
|
|
3733
|
+
|
|
3734
|
+
:param page: Page number for pagination
|
|
3735
|
+
:type page: int
|
|
3736
|
+
:param page_size: Number of items per page
|
|
3737
|
+
:type page_size: int
|
|
3738
|
+
:param environment: Environment Filter
|
|
3739
|
+
:type environment: str
|
|
3740
|
+
:param search: Search query to filter cluster by name
|
|
3741
|
+
:type search: str
|
|
3742
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
3743
|
+
number provided, it will be total request
|
|
3744
|
+
timeout. It can also be a pair (tuple) of
|
|
3745
|
+
(connection, read) timeouts.
|
|
3746
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
3747
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
3748
|
+
request; this effectively ignores the
|
|
3749
|
+
authentication in the spec for a single request.
|
|
3750
|
+
:type _request_auth: dict, optional
|
|
3751
|
+
:param _content_type: force content-type for the request.
|
|
3752
|
+
:type _content_type: str, Optional
|
|
3753
|
+
:param _headers: set to override the headers for a single
|
|
3754
|
+
request; this effectively ignores the headers
|
|
3755
|
+
in the spec for a single request.
|
|
3756
|
+
:type _headers: dict, optional
|
|
3757
|
+
:param _host_index: set to override the host_index for a single
|
|
3758
|
+
request; this effectively ignores the host_index
|
|
3759
|
+
in the spec for a single request.
|
|
3760
|
+
:type _host_index: int, optional
|
|
3761
|
+
:return: Returns the result object.
|
|
3762
|
+
""" # noqa: E501
|
|
3763
|
+
|
|
3764
|
+
_param = self._list_clusters_serialize(
|
|
3765
|
+
page=page,
|
|
3766
|
+
page_size=page_size,
|
|
3767
|
+
environment=environment,
|
|
3768
|
+
search=search,
|
|
3769
|
+
_request_auth=_request_auth,
|
|
3770
|
+
_content_type=_content_type,
|
|
3771
|
+
_headers=_headers,
|
|
3772
|
+
_host_index=_host_index
|
|
3773
|
+
)
|
|
3774
|
+
|
|
3775
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
3776
|
+
'200': "ClusterListResponse",
|
|
3777
|
+
'400': "ErrorResponseModel",
|
|
3778
|
+
'401': "ErrorResponseModel",
|
|
3779
|
+
'500': None,
|
|
3780
|
+
}
|
|
3781
|
+
response_data = await self.api_client.call_api(
|
|
3782
|
+
*_param,
|
|
3783
|
+
_request_timeout=_request_timeout
|
|
3784
|
+
)
|
|
3785
|
+
await response_data.read()
|
|
3786
|
+
return self.api_client.response_deserialize(
|
|
3787
|
+
response_data=response_data,
|
|
3788
|
+
response_types_map=_response_types_map,
|
|
3789
|
+
).data
|
|
3790
|
+
|
|
3791
|
+
|
|
3792
|
+
@validate_call
|
|
3793
|
+
async def list_clusters_with_http_info(
|
|
3794
|
+
self,
|
|
3795
|
+
page: Annotated[Optional[StrictInt], Field(description="Page number for pagination")] = None,
|
|
3796
|
+
page_size: Annotated[Optional[StrictInt], Field(description="Number of items per page")] = None,
|
|
3797
|
+
environment: Annotated[Optional[StrictStr], Field(description="Environment Filter")] = None,
|
|
3798
|
+
search: Annotated[Optional[StrictStr], Field(description="Search query to filter cluster by name")] = None,
|
|
3799
|
+
_request_timeout: Union[
|
|
3800
|
+
None,
|
|
3801
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3802
|
+
Tuple[
|
|
3803
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3804
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
3805
|
+
]
|
|
3806
|
+
] = None,
|
|
3807
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
3808
|
+
_content_type: Optional[StrictStr] = None,
|
|
3809
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
3810
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
3811
|
+
) -> ApiResponse[ClusterListResponse]:
|
|
3812
|
+
"""List Clusters
|
|
3813
|
+
|
|
3814
|
+
|
|
3815
|
+
:param page: Page number for pagination
|
|
3816
|
+
:type page: int
|
|
3817
|
+
:param page_size: Number of items per page
|
|
3818
|
+
:type page_size: int
|
|
3819
|
+
:param environment: Environment Filter
|
|
3820
|
+
:type environment: str
|
|
3821
|
+
:param search: Search query to filter cluster by name
|
|
3822
|
+
:type search: str
|
|
3823
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
3824
|
+
number provided, it will be total request
|
|
3825
|
+
timeout. It can also be a pair (tuple) of
|
|
3826
|
+
(connection, read) timeouts.
|
|
3827
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
3828
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
3829
|
+
request; this effectively ignores the
|
|
3830
|
+
authentication in the spec for a single request.
|
|
3831
|
+
:type _request_auth: dict, optional
|
|
3832
|
+
:param _content_type: force content-type for the request.
|
|
3833
|
+
:type _content_type: str, Optional
|
|
3834
|
+
:param _headers: set to override the headers for a single
|
|
3835
|
+
request; this effectively ignores the headers
|
|
3836
|
+
in the spec for a single request.
|
|
3837
|
+
:type _headers: dict, optional
|
|
3838
|
+
:param _host_index: set to override the host_index for a single
|
|
3839
|
+
request; this effectively ignores the host_index
|
|
3840
|
+
in the spec for a single request.
|
|
3841
|
+
:type _host_index: int, optional
|
|
3842
|
+
:return: Returns the result object.
|
|
3843
|
+
""" # noqa: E501
|
|
3844
|
+
|
|
3845
|
+
_param = self._list_clusters_serialize(
|
|
3846
|
+
page=page,
|
|
3847
|
+
page_size=page_size,
|
|
3848
|
+
environment=environment,
|
|
3849
|
+
search=search,
|
|
3850
|
+
_request_auth=_request_auth,
|
|
3851
|
+
_content_type=_content_type,
|
|
3852
|
+
_headers=_headers,
|
|
3853
|
+
_host_index=_host_index
|
|
3854
|
+
)
|
|
3855
|
+
|
|
3856
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
3857
|
+
'200': "ClusterListResponse",
|
|
3858
|
+
'400': "ErrorResponseModel",
|
|
3859
|
+
'401': "ErrorResponseModel",
|
|
3860
|
+
'500': None,
|
|
3861
|
+
}
|
|
3862
|
+
response_data = await self.api_client.call_api(
|
|
3863
|
+
*_param,
|
|
3864
|
+
_request_timeout=_request_timeout
|
|
3865
|
+
)
|
|
3866
|
+
await response_data.read()
|
|
3867
|
+
return self.api_client.response_deserialize(
|
|
3868
|
+
response_data=response_data,
|
|
3869
|
+
response_types_map=_response_types_map,
|
|
3870
|
+
)
|
|
3871
|
+
|
|
3872
|
+
|
|
3873
|
+
@validate_call
|
|
3874
|
+
async def list_clusters_without_preload_content(
|
|
3875
|
+
self,
|
|
3876
|
+
page: Annotated[Optional[StrictInt], Field(description="Page number for pagination")] = None,
|
|
3877
|
+
page_size: Annotated[Optional[StrictInt], Field(description="Number of items per page")] = None,
|
|
3878
|
+
environment: Annotated[Optional[StrictStr], Field(description="Environment Filter")] = None,
|
|
3879
|
+
search: Annotated[Optional[StrictStr], Field(description="Search query to filter cluster by name")] = None,
|
|
3880
|
+
_request_timeout: Union[
|
|
3881
|
+
None,
|
|
3882
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3883
|
+
Tuple[
|
|
3884
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
3885
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
3886
|
+
]
|
|
3887
|
+
] = None,
|
|
3888
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
3889
|
+
_content_type: Optional[StrictStr] = None,
|
|
3890
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
3891
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
3892
|
+
) -> RESTResponseType:
|
|
3893
|
+
"""List Clusters
|
|
3894
|
+
|
|
3895
|
+
|
|
3896
|
+
:param page: Page number for pagination
|
|
3897
|
+
:type page: int
|
|
3898
|
+
:param page_size: Number of items per page
|
|
3899
|
+
:type page_size: int
|
|
3900
|
+
:param environment: Environment Filter
|
|
3901
|
+
:type environment: str
|
|
3902
|
+
:param search: Search query to filter cluster by name
|
|
3903
|
+
:type search: str
|
|
3904
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
3905
|
+
number provided, it will be total request
|
|
3906
|
+
timeout. It can also be a pair (tuple) of
|
|
3907
|
+
(connection, read) timeouts.
|
|
3908
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
3909
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
3910
|
+
request; this effectively ignores the
|
|
3911
|
+
authentication in the spec for a single request.
|
|
3912
|
+
:type _request_auth: dict, optional
|
|
3913
|
+
:param _content_type: force content-type for the request.
|
|
3914
|
+
:type _content_type: str, Optional
|
|
3915
|
+
:param _headers: set to override the headers for a single
|
|
3916
|
+
request; this effectively ignores the headers
|
|
3917
|
+
in the spec for a single request.
|
|
3918
|
+
:type _headers: dict, optional
|
|
3919
|
+
:param _host_index: set to override the host_index for a single
|
|
3920
|
+
request; this effectively ignores the host_index
|
|
3921
|
+
in the spec for a single request.
|
|
3922
|
+
:type _host_index: int, optional
|
|
3923
|
+
:return: Returns the result object.
|
|
3924
|
+
""" # noqa: E501
|
|
3925
|
+
|
|
3926
|
+
_param = self._list_clusters_serialize(
|
|
3927
|
+
page=page,
|
|
3928
|
+
page_size=page_size,
|
|
3929
|
+
environment=environment,
|
|
3930
|
+
search=search,
|
|
3931
|
+
_request_auth=_request_auth,
|
|
3932
|
+
_content_type=_content_type,
|
|
3933
|
+
_headers=_headers,
|
|
3934
|
+
_host_index=_host_index
|
|
3935
|
+
)
|
|
3936
|
+
|
|
3937
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
3938
|
+
'200': "ClusterListResponse",
|
|
3939
|
+
'400': "ErrorResponseModel",
|
|
3940
|
+
'401': "ErrorResponseModel",
|
|
3941
|
+
'500': None,
|
|
3942
|
+
}
|
|
3943
|
+
response_data = await self.api_client.call_api(
|
|
3944
|
+
*_param,
|
|
3945
|
+
_request_timeout=_request_timeout
|
|
3946
|
+
)
|
|
3947
|
+
return response_data.response
|
|
3948
|
+
|
|
3949
|
+
|
|
3950
|
+
def _list_clusters_serialize(
|
|
3951
|
+
self,
|
|
3952
|
+
page,
|
|
3953
|
+
page_size,
|
|
3954
|
+
environment,
|
|
3955
|
+
search,
|
|
3956
|
+
_request_auth,
|
|
3957
|
+
_content_type,
|
|
3958
|
+
_headers,
|
|
3959
|
+
_host_index,
|
|
3960
|
+
) -> RequestSerialized:
|
|
3961
|
+
|
|
3962
|
+
_host = None
|
|
3963
|
+
|
|
3964
|
+
_collection_formats: Dict[str, str] = {
|
|
3965
|
+
}
|
|
3966
|
+
|
|
3967
|
+
_path_params: Dict[str, str] = {}
|
|
3968
|
+
_query_params: List[Tuple[str, str]] = []
|
|
3969
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
3970
|
+
_form_params: List[Tuple[str, str]] = []
|
|
3971
|
+
_files: Dict[
|
|
3972
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
3973
|
+
] = {}
|
|
3974
|
+
_body_params: Optional[bytes] = None
|
|
3975
|
+
|
|
3976
|
+
# process the path parameters
|
|
3977
|
+
# process the query parameters
|
|
3978
|
+
if page is not None:
|
|
3979
|
+
|
|
3980
|
+
_query_params.append(('page', page))
|
|
3981
|
+
|
|
3982
|
+
if page_size is not None:
|
|
3983
|
+
|
|
3984
|
+
_query_params.append(('pageSize', page_size))
|
|
3985
|
+
|
|
3986
|
+
if environment is not None:
|
|
3987
|
+
|
|
3988
|
+
_query_params.append(('environment', environment))
|
|
3989
|
+
|
|
3990
|
+
if search is not None:
|
|
3991
|
+
|
|
3992
|
+
_query_params.append(('search', search))
|
|
3993
|
+
|
|
3994
|
+
# process the header parameters
|
|
3995
|
+
# process the form parameters
|
|
3996
|
+
# process the body parameter
|
|
3997
|
+
|
|
3998
|
+
|
|
3999
|
+
# set the HTTP header `Accept`
|
|
4000
|
+
if 'Accept' not in _header_params:
|
|
4001
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
4002
|
+
[
|
|
4003
|
+
'application/json'
|
|
4004
|
+
]
|
|
4005
|
+
)
|
|
4006
|
+
|
|
4007
|
+
|
|
4008
|
+
# authentication setting
|
|
4009
|
+
_auth_settings: List[str] = [
|
|
4010
|
+
'apiKey'
|
|
4011
|
+
]
|
|
4012
|
+
|
|
4013
|
+
return self.api_client.param_serialize(
|
|
4014
|
+
method='GET',
|
|
4015
|
+
resource_path='/core/clusters',
|
|
4016
|
+
path_params=_path_params,
|
|
4017
|
+
query_params=_query_params,
|
|
4018
|
+
header_params=_header_params,
|
|
4019
|
+
body=_body_params,
|
|
4020
|
+
post_params=_form_params,
|
|
4021
|
+
files=_files,
|
|
4022
|
+
auth_settings=_auth_settings,
|
|
4023
|
+
collection_formats=_collection_formats,
|
|
4024
|
+
_host=_host,
|
|
4025
|
+
_request_auth=_request_auth
|
|
4026
|
+
)
|
|
4027
|
+
|
|
4028
|
+
|
|
4029
|
+
|
|
4030
|
+
|
|
4031
|
+
@validate_call
|
|
4032
|
+
async def list_node_groups(
|
|
4033
|
+
self,
|
|
4034
|
+
cluster_id: StrictInt,
|
|
4035
|
+
_request_timeout: Union[
|
|
4036
|
+
None,
|
|
4037
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4038
|
+
Tuple[
|
|
4039
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4040
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
4041
|
+
]
|
|
4042
|
+
] = None,
|
|
4043
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
4044
|
+
_content_type: Optional[StrictStr] = None,
|
|
4045
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
4046
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
4047
|
+
) -> ClusterNodeGroupsListResponse:
|
|
4048
|
+
"""List node groups for a cluster
|
|
4049
|
+
|
|
4050
|
+
|
|
4051
|
+
:param cluster_id: (required)
|
|
4052
|
+
:type cluster_id: int
|
|
4053
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
4054
|
+
number provided, it will be total request
|
|
4055
|
+
timeout. It can also be a pair (tuple) of
|
|
4056
|
+
(connection, read) timeouts.
|
|
4057
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
4058
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
4059
|
+
request; this effectively ignores the
|
|
4060
|
+
authentication in the spec for a single request.
|
|
4061
|
+
:type _request_auth: dict, optional
|
|
4062
|
+
:param _content_type: force content-type for the request.
|
|
4063
|
+
:type _content_type: str, Optional
|
|
4064
|
+
:param _headers: set to override the headers for a single
|
|
4065
|
+
request; this effectively ignores the headers
|
|
4066
|
+
in the spec for a single request.
|
|
4067
|
+
:type _headers: dict, optional
|
|
4068
|
+
:param _host_index: set to override the host_index for a single
|
|
4069
|
+
request; this effectively ignores the host_index
|
|
4070
|
+
in the spec for a single request.
|
|
4071
|
+
:type _host_index: int, optional
|
|
4072
|
+
:return: Returns the result object.
|
|
4073
|
+
""" # noqa: E501
|
|
4074
|
+
|
|
4075
|
+
_param = self._list_node_groups_serialize(
|
|
4076
|
+
cluster_id=cluster_id,
|
|
4077
|
+
_request_auth=_request_auth,
|
|
4078
|
+
_content_type=_content_type,
|
|
4079
|
+
_headers=_headers,
|
|
4080
|
+
_host_index=_host_index
|
|
4081
|
+
)
|
|
4082
|
+
|
|
4083
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
4084
|
+
'200': "ClusterNodeGroupsListResponse",
|
|
4085
|
+
'400': "ErrorResponseModel",
|
|
4086
|
+
'401': "ErrorResponseModel",
|
|
4087
|
+
'404': "ErrorResponseModel",
|
|
4088
|
+
'500': None,
|
|
4089
|
+
}
|
|
4090
|
+
response_data = await self.api_client.call_api(
|
|
4091
|
+
*_param,
|
|
4092
|
+
_request_timeout=_request_timeout
|
|
4093
|
+
)
|
|
4094
|
+
await response_data.read()
|
|
4095
|
+
return self.api_client.response_deserialize(
|
|
4096
|
+
response_data=response_data,
|
|
4097
|
+
response_types_map=_response_types_map,
|
|
4098
|
+
).data
|
|
4099
|
+
|
|
4100
|
+
|
|
4101
|
+
@validate_call
|
|
4102
|
+
async def list_node_groups_with_http_info(
|
|
4103
|
+
self,
|
|
4104
|
+
cluster_id: StrictInt,
|
|
4105
|
+
_request_timeout: Union[
|
|
4106
|
+
None,
|
|
4107
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4108
|
+
Tuple[
|
|
4109
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4110
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
4111
|
+
]
|
|
4112
|
+
] = None,
|
|
4113
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
4114
|
+
_content_type: Optional[StrictStr] = None,
|
|
4115
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
4116
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
4117
|
+
) -> ApiResponse[ClusterNodeGroupsListResponse]:
|
|
4118
|
+
"""List node groups for a cluster
|
|
4119
|
+
|
|
4120
|
+
|
|
4121
|
+
:param cluster_id: (required)
|
|
4122
|
+
:type cluster_id: int
|
|
4123
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
4124
|
+
number provided, it will be total request
|
|
4125
|
+
timeout. It can also be a pair (tuple) of
|
|
4126
|
+
(connection, read) timeouts.
|
|
4127
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
4128
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
4129
|
+
request; this effectively ignores the
|
|
4130
|
+
authentication in the spec for a single request.
|
|
4131
|
+
:type _request_auth: dict, optional
|
|
4132
|
+
:param _content_type: force content-type for the request.
|
|
4133
|
+
:type _content_type: str, Optional
|
|
4134
|
+
:param _headers: set to override the headers for a single
|
|
4135
|
+
request; this effectively ignores the headers
|
|
4136
|
+
in the spec for a single request.
|
|
4137
|
+
:type _headers: dict, optional
|
|
4138
|
+
:param _host_index: set to override the host_index for a single
|
|
4139
|
+
request; this effectively ignores the host_index
|
|
4140
|
+
in the spec for a single request.
|
|
4141
|
+
:type _host_index: int, optional
|
|
4142
|
+
:return: Returns the result object.
|
|
4143
|
+
""" # noqa: E501
|
|
4144
|
+
|
|
4145
|
+
_param = self._list_node_groups_serialize(
|
|
4146
|
+
cluster_id=cluster_id,
|
|
4147
|
+
_request_auth=_request_auth,
|
|
4148
|
+
_content_type=_content_type,
|
|
4149
|
+
_headers=_headers,
|
|
4150
|
+
_host_index=_host_index
|
|
4151
|
+
)
|
|
4152
|
+
|
|
4153
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
4154
|
+
'200': "ClusterNodeGroupsListResponse",
|
|
4155
|
+
'400': "ErrorResponseModel",
|
|
4156
|
+
'401': "ErrorResponseModel",
|
|
4157
|
+
'404': "ErrorResponseModel",
|
|
4158
|
+
'500': None,
|
|
4159
|
+
}
|
|
4160
|
+
response_data = await self.api_client.call_api(
|
|
4161
|
+
*_param,
|
|
4162
|
+
_request_timeout=_request_timeout
|
|
4163
|
+
)
|
|
4164
|
+
await response_data.read()
|
|
4165
|
+
return self.api_client.response_deserialize(
|
|
4166
|
+
response_data=response_data,
|
|
4167
|
+
response_types_map=_response_types_map,
|
|
4168
|
+
)
|
|
4169
|
+
|
|
4170
|
+
|
|
4171
|
+
@validate_call
|
|
4172
|
+
async def list_node_groups_without_preload_content(
|
|
4173
|
+
self,
|
|
4174
|
+
cluster_id: StrictInt,
|
|
4175
|
+
_request_timeout: Union[
|
|
4176
|
+
None,
|
|
4177
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4178
|
+
Tuple[
|
|
4179
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4180
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
4181
|
+
]
|
|
4182
|
+
] = None,
|
|
4183
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
4184
|
+
_content_type: Optional[StrictStr] = None,
|
|
4185
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
4186
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
4187
|
+
) -> RESTResponseType:
|
|
4188
|
+
"""List node groups for a cluster
|
|
4189
|
+
|
|
4190
|
+
|
|
4191
|
+
:param cluster_id: (required)
|
|
4192
|
+
:type cluster_id: int
|
|
4193
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
4194
|
+
number provided, it will be total request
|
|
4195
|
+
timeout. It can also be a pair (tuple) of
|
|
4196
|
+
(connection, read) timeouts.
|
|
4197
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
4198
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
4199
|
+
request; this effectively ignores the
|
|
4200
|
+
authentication in the spec for a single request.
|
|
4201
|
+
:type _request_auth: dict, optional
|
|
4202
|
+
:param _content_type: force content-type for the request.
|
|
4203
|
+
:type _content_type: str, Optional
|
|
4204
|
+
:param _headers: set to override the headers for a single
|
|
4205
|
+
request; this effectively ignores the headers
|
|
4206
|
+
in the spec for a single request.
|
|
4207
|
+
:type _headers: dict, optional
|
|
4208
|
+
:param _host_index: set to override the host_index for a single
|
|
4209
|
+
request; this effectively ignores the host_index
|
|
4210
|
+
in the spec for a single request.
|
|
4211
|
+
:type _host_index: int, optional
|
|
4212
|
+
:return: Returns the result object.
|
|
4213
|
+
""" # noqa: E501
|
|
4214
|
+
|
|
4215
|
+
_param = self._list_node_groups_serialize(
|
|
4216
|
+
cluster_id=cluster_id,
|
|
4217
|
+
_request_auth=_request_auth,
|
|
4218
|
+
_content_type=_content_type,
|
|
4219
|
+
_headers=_headers,
|
|
4220
|
+
_host_index=_host_index
|
|
4221
|
+
)
|
|
4222
|
+
|
|
4223
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
4224
|
+
'200': "ClusterNodeGroupsListResponse",
|
|
4225
|
+
'400': "ErrorResponseModel",
|
|
4226
|
+
'401': "ErrorResponseModel",
|
|
4227
|
+
'404': "ErrorResponseModel",
|
|
4228
|
+
'500': None,
|
|
4229
|
+
}
|
|
4230
|
+
response_data = await self.api_client.call_api(
|
|
4231
|
+
*_param,
|
|
4232
|
+
_request_timeout=_request_timeout
|
|
4233
|
+
)
|
|
4234
|
+
return response_data.response
|
|
4235
|
+
|
|
4236
|
+
|
|
4237
|
+
def _list_node_groups_serialize(
|
|
4238
|
+
self,
|
|
4239
|
+
cluster_id,
|
|
4240
|
+
_request_auth,
|
|
4241
|
+
_content_type,
|
|
4242
|
+
_headers,
|
|
4243
|
+
_host_index,
|
|
4244
|
+
) -> RequestSerialized:
|
|
4245
|
+
|
|
4246
|
+
_host = None
|
|
4247
|
+
|
|
4248
|
+
_collection_formats: Dict[str, str] = {
|
|
4249
|
+
}
|
|
4250
|
+
|
|
4251
|
+
_path_params: Dict[str, str] = {}
|
|
4252
|
+
_query_params: List[Tuple[str, str]] = []
|
|
4253
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
4254
|
+
_form_params: List[Tuple[str, str]] = []
|
|
4255
|
+
_files: Dict[
|
|
4256
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
4257
|
+
] = {}
|
|
4258
|
+
_body_params: Optional[bytes] = None
|
|
4259
|
+
|
|
4260
|
+
# process the path parameters
|
|
4261
|
+
if cluster_id is not None:
|
|
4262
|
+
_path_params['cluster_id'] = cluster_id
|
|
4263
|
+
# process the query parameters
|
|
4264
|
+
# process the header parameters
|
|
4265
|
+
# process the form parameters
|
|
4266
|
+
# process the body parameter
|
|
4267
|
+
|
|
4268
|
+
|
|
4269
|
+
# set the HTTP header `Accept`
|
|
4270
|
+
if 'Accept' not in _header_params:
|
|
4271
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
4272
|
+
[
|
|
4273
|
+
'application/json'
|
|
4274
|
+
]
|
|
4275
|
+
)
|
|
4276
|
+
|
|
4277
|
+
|
|
4278
|
+
# authentication setting
|
|
4279
|
+
_auth_settings: List[str] = [
|
|
4280
|
+
'apiKey'
|
|
4281
|
+
]
|
|
4282
|
+
|
|
4283
|
+
return self.api_client.param_serialize(
|
|
4284
|
+
method='GET',
|
|
4285
|
+
resource_path='/core/clusters/{cluster_id}/node-groups',
|
|
4286
|
+
path_params=_path_params,
|
|
4287
|
+
query_params=_query_params,
|
|
4288
|
+
header_params=_header_params,
|
|
4289
|
+
body=_body_params,
|
|
4290
|
+
post_params=_form_params,
|
|
4291
|
+
files=_files,
|
|
4292
|
+
auth_settings=_auth_settings,
|
|
4293
|
+
collection_formats=_collection_formats,
|
|
4294
|
+
_host=_host,
|
|
4295
|
+
_request_auth=_request_auth
|
|
4296
|
+
)
|
|
4297
|
+
|
|
4298
|
+
|
|
4299
|
+
|
|
4300
|
+
|
|
4301
|
+
@validate_call
|
|
4302
|
+
async def reconcile_cluster(
|
|
4303
|
+
self,
|
|
4304
|
+
cluster_id: StrictInt,
|
|
4305
|
+
_request_timeout: Union[
|
|
4306
|
+
None,
|
|
4307
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4308
|
+
Tuple[
|
|
4309
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4310
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
4311
|
+
]
|
|
4312
|
+
] = None,
|
|
4313
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
4314
|
+
_content_type: Optional[StrictStr] = None,
|
|
4315
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
4316
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
4317
|
+
) -> ManualReconciliationModel:
|
|
4318
|
+
"""Reconcile a cluster
|
|
4319
|
+
|
|
4320
|
+
|
|
4321
|
+
:param cluster_id: (required)
|
|
4322
|
+
:type cluster_id: int
|
|
4323
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
4324
|
+
number provided, it will be total request
|
|
4325
|
+
timeout. It can also be a pair (tuple) of
|
|
4326
|
+
(connection, read) timeouts.
|
|
4327
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
4328
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
4329
|
+
request; this effectively ignores the
|
|
4330
|
+
authentication in the spec for a single request.
|
|
4331
|
+
:type _request_auth: dict, optional
|
|
4332
|
+
:param _content_type: force content-type for the request.
|
|
4333
|
+
:type _content_type: str, Optional
|
|
4334
|
+
:param _headers: set to override the headers for a single
|
|
4335
|
+
request; this effectively ignores the headers
|
|
4336
|
+
in the spec for a single request.
|
|
4337
|
+
:type _headers: dict, optional
|
|
4338
|
+
:param _host_index: set to override the host_index for a single
|
|
4339
|
+
request; this effectively ignores the host_index
|
|
4340
|
+
in the spec for a single request.
|
|
4341
|
+
:type _host_index: int, optional
|
|
4342
|
+
:return: Returns the result object.
|
|
4343
|
+
""" # noqa: E501
|
|
4344
|
+
|
|
4345
|
+
_param = self._reconcile_cluster_serialize(
|
|
4346
|
+
cluster_id=cluster_id,
|
|
4347
|
+
_request_auth=_request_auth,
|
|
4348
|
+
_content_type=_content_type,
|
|
4349
|
+
_headers=_headers,
|
|
4350
|
+
_host_index=_host_index
|
|
4351
|
+
)
|
|
4352
|
+
|
|
4353
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
4354
|
+
'200': "ManualReconciliationModel",
|
|
4355
|
+
'400': "ErrorResponseModel",
|
|
4356
|
+
'401': "ErrorResponseModel",
|
|
4357
|
+
'404': "ErrorResponseModel",
|
|
4358
|
+
'500': None,
|
|
4359
|
+
}
|
|
4360
|
+
response_data = await self.api_client.call_api(
|
|
4361
|
+
*_param,
|
|
4362
|
+
_request_timeout=_request_timeout
|
|
4363
|
+
)
|
|
4364
|
+
await response_data.read()
|
|
4365
|
+
return self.api_client.response_deserialize(
|
|
4366
|
+
response_data=response_data,
|
|
4367
|
+
response_types_map=_response_types_map,
|
|
4368
|
+
).data
|
|
4369
|
+
|
|
4370
|
+
|
|
4371
|
+
@validate_call
|
|
4372
|
+
async def reconcile_cluster_with_http_info(
|
|
4373
|
+
self,
|
|
4374
|
+
cluster_id: StrictInt,
|
|
4375
|
+
_request_timeout: Union[
|
|
4376
|
+
None,
|
|
4377
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4378
|
+
Tuple[
|
|
4379
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4380
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
4381
|
+
]
|
|
4382
|
+
] = None,
|
|
4383
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
4384
|
+
_content_type: Optional[StrictStr] = None,
|
|
4385
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
4386
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
4387
|
+
) -> ApiResponse[ManualReconciliationModel]:
|
|
4388
|
+
"""Reconcile a cluster
|
|
4389
|
+
|
|
4390
|
+
|
|
4391
|
+
:param cluster_id: (required)
|
|
4392
|
+
:type cluster_id: int
|
|
4393
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
4394
|
+
number provided, it will be total request
|
|
4395
|
+
timeout. It can also be a pair (tuple) of
|
|
4396
|
+
(connection, read) timeouts.
|
|
4397
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
4398
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
4399
|
+
request; this effectively ignores the
|
|
4400
|
+
authentication in the spec for a single request.
|
|
4401
|
+
:type _request_auth: dict, optional
|
|
4402
|
+
:param _content_type: force content-type for the request.
|
|
4403
|
+
:type _content_type: str, Optional
|
|
4404
|
+
:param _headers: set to override the headers for a single
|
|
4405
|
+
request; this effectively ignores the headers
|
|
4406
|
+
in the spec for a single request.
|
|
4407
|
+
:type _headers: dict, optional
|
|
4408
|
+
:param _host_index: set to override the host_index for a single
|
|
4409
|
+
request; this effectively ignores the host_index
|
|
4410
|
+
in the spec for a single request.
|
|
4411
|
+
:type _host_index: int, optional
|
|
4412
|
+
:return: Returns the result object.
|
|
4413
|
+
""" # noqa: E501
|
|
4414
|
+
|
|
4415
|
+
_param = self._reconcile_cluster_serialize(
|
|
4416
|
+
cluster_id=cluster_id,
|
|
4417
|
+
_request_auth=_request_auth,
|
|
4418
|
+
_content_type=_content_type,
|
|
4419
|
+
_headers=_headers,
|
|
4420
|
+
_host_index=_host_index
|
|
4421
|
+
)
|
|
4422
|
+
|
|
4423
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
4424
|
+
'200': "ManualReconciliationModel",
|
|
4425
|
+
'400': "ErrorResponseModel",
|
|
4426
|
+
'401': "ErrorResponseModel",
|
|
4427
|
+
'404': "ErrorResponseModel",
|
|
4428
|
+
'500': None,
|
|
4429
|
+
}
|
|
4430
|
+
response_data = await self.api_client.call_api(
|
|
4431
|
+
*_param,
|
|
4432
|
+
_request_timeout=_request_timeout
|
|
4433
|
+
)
|
|
4434
|
+
await response_data.read()
|
|
4435
|
+
return self.api_client.response_deserialize(
|
|
4436
|
+
response_data=response_data,
|
|
4437
|
+
response_types_map=_response_types_map,
|
|
4438
|
+
)
|
|
4439
|
+
|
|
4440
|
+
|
|
4441
|
+
@validate_call
|
|
4442
|
+
async def reconcile_cluster_without_preload_content(
|
|
4443
|
+
self,
|
|
4444
|
+
cluster_id: StrictInt,
|
|
4445
|
+
_request_timeout: Union[
|
|
4446
|
+
None,
|
|
4447
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4448
|
+
Tuple[
|
|
4449
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4450
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
4451
|
+
]
|
|
4452
|
+
] = None,
|
|
4453
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
4454
|
+
_content_type: Optional[StrictStr] = None,
|
|
4455
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
4456
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
4457
|
+
) -> RESTResponseType:
|
|
4458
|
+
"""Reconcile a cluster
|
|
4459
|
+
|
|
4460
|
+
|
|
4461
|
+
:param cluster_id: (required)
|
|
4462
|
+
:type cluster_id: int
|
|
4463
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
4464
|
+
number provided, it will be total request
|
|
4465
|
+
timeout. It can also be a pair (tuple) of
|
|
4466
|
+
(connection, read) timeouts.
|
|
4467
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
4468
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
4469
|
+
request; this effectively ignores the
|
|
4470
|
+
authentication in the spec for a single request.
|
|
4471
|
+
:type _request_auth: dict, optional
|
|
4472
|
+
:param _content_type: force content-type for the request.
|
|
4473
|
+
:type _content_type: str, Optional
|
|
4474
|
+
:param _headers: set to override the headers for a single
|
|
4475
|
+
request; this effectively ignores the headers
|
|
4476
|
+
in the spec for a single request.
|
|
4477
|
+
:type _headers: dict, optional
|
|
4478
|
+
:param _host_index: set to override the host_index for a single
|
|
4479
|
+
request; this effectively ignores the host_index
|
|
4480
|
+
in the spec for a single request.
|
|
4481
|
+
:type _host_index: int, optional
|
|
4482
|
+
:return: Returns the result object.
|
|
4483
|
+
""" # noqa: E501
|
|
4484
|
+
|
|
4485
|
+
_param = self._reconcile_cluster_serialize(
|
|
4486
|
+
cluster_id=cluster_id,
|
|
4487
|
+
_request_auth=_request_auth,
|
|
4488
|
+
_content_type=_content_type,
|
|
4489
|
+
_headers=_headers,
|
|
4490
|
+
_host_index=_host_index
|
|
4491
|
+
)
|
|
4492
|
+
|
|
4493
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
4494
|
+
'200': "ManualReconciliationModel",
|
|
4495
|
+
'400': "ErrorResponseModel",
|
|
4496
|
+
'401': "ErrorResponseModel",
|
|
4497
|
+
'404': "ErrorResponseModel",
|
|
4498
|
+
'500': None,
|
|
4499
|
+
}
|
|
4500
|
+
response_data = await self.api_client.call_api(
|
|
4501
|
+
*_param,
|
|
4502
|
+
_request_timeout=_request_timeout
|
|
4503
|
+
)
|
|
4504
|
+
return response_data.response
|
|
4505
|
+
|
|
4506
|
+
|
|
4507
|
+
def _reconcile_cluster_serialize(
|
|
4508
|
+
self,
|
|
4509
|
+
cluster_id,
|
|
4510
|
+
_request_auth,
|
|
4511
|
+
_content_type,
|
|
4512
|
+
_headers,
|
|
4513
|
+
_host_index,
|
|
4514
|
+
) -> RequestSerialized:
|
|
4515
|
+
|
|
4516
|
+
_host = None
|
|
4517
|
+
|
|
4518
|
+
_collection_formats: Dict[str, str] = {
|
|
4519
|
+
}
|
|
4520
|
+
|
|
4521
|
+
_path_params: Dict[str, str] = {}
|
|
4522
|
+
_query_params: List[Tuple[str, str]] = []
|
|
4523
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
4524
|
+
_form_params: List[Tuple[str, str]] = []
|
|
4525
|
+
_files: Dict[
|
|
4526
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
4527
|
+
] = {}
|
|
4528
|
+
_body_params: Optional[bytes] = None
|
|
4529
|
+
|
|
4530
|
+
# process the path parameters
|
|
4531
|
+
if cluster_id is not None:
|
|
4532
|
+
_path_params['cluster_id'] = cluster_id
|
|
4533
|
+
# process the query parameters
|
|
4534
|
+
# process the header parameters
|
|
4535
|
+
# process the form parameters
|
|
4536
|
+
# process the body parameter
|
|
4537
|
+
|
|
4538
|
+
|
|
4539
|
+
# set the HTTP header `Accept`
|
|
4540
|
+
if 'Accept' not in _header_params:
|
|
4541
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
4542
|
+
[
|
|
4543
|
+
'application/json'
|
|
4544
|
+
]
|
|
4545
|
+
)
|
|
4546
|
+
|
|
4547
|
+
|
|
4548
|
+
# authentication setting
|
|
4549
|
+
_auth_settings: List[str] = [
|
|
4550
|
+
'apiKey'
|
|
4551
|
+
]
|
|
4552
|
+
|
|
4553
|
+
return self.api_client.param_serialize(
|
|
4554
|
+
method='POST',
|
|
4555
|
+
resource_path='/core/clusters/{cluster_id}/reconcile',
|
|
4556
|
+
path_params=_path_params,
|
|
4557
|
+
query_params=_query_params,
|
|
4558
|
+
header_params=_header_params,
|
|
4559
|
+
body=_body_params,
|
|
4560
|
+
post_params=_form_params,
|
|
4561
|
+
files=_files,
|
|
4562
|
+
auth_settings=_auth_settings,
|
|
4563
|
+
collection_formats=_collection_formats,
|
|
4564
|
+
_host=_host,
|
|
4565
|
+
_request_auth=_request_auth
|
|
4566
|
+
)
|
|
4567
|
+
|
|
4568
|
+
|
|
4569
|
+
|
|
4570
|
+
|
|
4571
|
+
@validate_call
|
|
4572
|
+
async def update_node_group(
|
|
4573
|
+
self,
|
|
4574
|
+
cluster_id: StrictInt,
|
|
4575
|
+
node_group_id: StrictInt,
|
|
4576
|
+
payload: UpdateClusterNodeGroupPayload,
|
|
4577
|
+
_request_timeout: Union[
|
|
4578
|
+
None,
|
|
4579
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4580
|
+
Tuple[
|
|
4581
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4582
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
4583
|
+
]
|
|
4584
|
+
] = None,
|
|
4585
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
4586
|
+
_content_type: Optional[StrictStr] = None,
|
|
4587
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
4588
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
4589
|
+
) -> ClusterNodeGroupsCreateResponse:
|
|
4590
|
+
"""Update a node group in a cluster
|
|
4591
|
+
|
|
4592
|
+
|
|
4593
|
+
:param cluster_id: (required)
|
|
4594
|
+
:type cluster_id: int
|
|
4595
|
+
:param node_group_id: (required)
|
|
4596
|
+
:type node_group_id: int
|
|
4597
|
+
:param payload: (required)
|
|
4598
|
+
:type payload: UpdateClusterNodeGroupPayload
|
|
4599
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
4600
|
+
number provided, it will be total request
|
|
4601
|
+
timeout. It can also be a pair (tuple) of
|
|
4602
|
+
(connection, read) timeouts.
|
|
4603
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
4604
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
4605
|
+
request; this effectively ignores the
|
|
4606
|
+
authentication in the spec for a single request.
|
|
4607
|
+
:type _request_auth: dict, optional
|
|
4608
|
+
:param _content_type: force content-type for the request.
|
|
4609
|
+
:type _content_type: str, Optional
|
|
4610
|
+
:param _headers: set to override the headers for a single
|
|
4611
|
+
request; this effectively ignores the headers
|
|
4612
|
+
in the spec for a single request.
|
|
4613
|
+
:type _headers: dict, optional
|
|
4614
|
+
:param _host_index: set to override the host_index for a single
|
|
4615
|
+
request; this effectively ignores the host_index
|
|
4616
|
+
in the spec for a single request.
|
|
4617
|
+
:type _host_index: int, optional
|
|
4618
|
+
:return: Returns the result object.
|
|
4619
|
+
""" # noqa: E501
|
|
4620
|
+
|
|
4621
|
+
_param = self._update_node_group_serialize(
|
|
4622
|
+
cluster_id=cluster_id,
|
|
4623
|
+
node_group_id=node_group_id,
|
|
4624
|
+
payload=payload,
|
|
4625
|
+
_request_auth=_request_auth,
|
|
4626
|
+
_content_type=_content_type,
|
|
4627
|
+
_headers=_headers,
|
|
4628
|
+
_host_index=_host_index
|
|
4629
|
+
)
|
|
4630
|
+
|
|
4631
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
4632
|
+
'200': "ClusterNodeGroupsCreateResponse",
|
|
4633
|
+
'400': "ErrorResponseModel",
|
|
4634
|
+
'401': "ErrorResponseModel",
|
|
4635
|
+
'404': "ErrorResponseModel",
|
|
4636
|
+
'409': "ErrorResponseModel",
|
|
4637
|
+
'500': None,
|
|
4638
|
+
}
|
|
4639
|
+
response_data = await self.api_client.call_api(
|
|
4640
|
+
*_param,
|
|
4641
|
+
_request_timeout=_request_timeout
|
|
4642
|
+
)
|
|
4643
|
+
await response_data.read()
|
|
4644
|
+
return self.api_client.response_deserialize(
|
|
4645
|
+
response_data=response_data,
|
|
4646
|
+
response_types_map=_response_types_map,
|
|
4647
|
+
).data
|
|
4648
|
+
|
|
4649
|
+
|
|
4650
|
+
@validate_call
|
|
4651
|
+
async def update_node_group_with_http_info(
|
|
4652
|
+
self,
|
|
4653
|
+
cluster_id: StrictInt,
|
|
4654
|
+
node_group_id: StrictInt,
|
|
4655
|
+
payload: UpdateClusterNodeGroupPayload,
|
|
4656
|
+
_request_timeout: Union[
|
|
4657
|
+
None,
|
|
4658
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4659
|
+
Tuple[
|
|
4660
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4661
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
4662
|
+
]
|
|
4663
|
+
] = None,
|
|
4664
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
4665
|
+
_content_type: Optional[StrictStr] = None,
|
|
4666
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
4667
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
4668
|
+
) -> ApiResponse[ClusterNodeGroupsCreateResponse]:
|
|
4669
|
+
"""Update a node group in a cluster
|
|
4670
|
+
|
|
4671
|
+
|
|
4672
|
+
:param cluster_id: (required)
|
|
4673
|
+
:type cluster_id: int
|
|
4674
|
+
:param node_group_id: (required)
|
|
4675
|
+
:type node_group_id: int
|
|
4676
|
+
:param payload: (required)
|
|
4677
|
+
:type payload: UpdateClusterNodeGroupPayload
|
|
4678
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
4679
|
+
number provided, it will be total request
|
|
4680
|
+
timeout. It can also be a pair (tuple) of
|
|
4681
|
+
(connection, read) timeouts.
|
|
4682
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
4683
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
4684
|
+
request; this effectively ignores the
|
|
4685
|
+
authentication in the spec for a single request.
|
|
4686
|
+
:type _request_auth: dict, optional
|
|
4687
|
+
:param _content_type: force content-type for the request.
|
|
4688
|
+
:type _content_type: str, Optional
|
|
4689
|
+
:param _headers: set to override the headers for a single
|
|
4690
|
+
request; this effectively ignores the headers
|
|
4691
|
+
in the spec for a single request.
|
|
4692
|
+
:type _headers: dict, optional
|
|
4693
|
+
:param _host_index: set to override the host_index for a single
|
|
4694
|
+
request; this effectively ignores the host_index
|
|
4695
|
+
in the spec for a single request.
|
|
4696
|
+
:type _host_index: int, optional
|
|
4697
|
+
:return: Returns the result object.
|
|
4698
|
+
""" # noqa: E501
|
|
4699
|
+
|
|
4700
|
+
_param = self._update_node_group_serialize(
|
|
4701
|
+
cluster_id=cluster_id,
|
|
4702
|
+
node_group_id=node_group_id,
|
|
4703
|
+
payload=payload,
|
|
4704
|
+
_request_auth=_request_auth,
|
|
4705
|
+
_content_type=_content_type,
|
|
4706
|
+
_headers=_headers,
|
|
4707
|
+
_host_index=_host_index
|
|
4708
|
+
)
|
|
4709
|
+
|
|
4710
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
4711
|
+
'200': "ClusterNodeGroupsCreateResponse",
|
|
4712
|
+
'400': "ErrorResponseModel",
|
|
4713
|
+
'401': "ErrorResponseModel",
|
|
4714
|
+
'404': "ErrorResponseModel",
|
|
4715
|
+
'409': "ErrorResponseModel",
|
|
4716
|
+
'500': None,
|
|
4717
|
+
}
|
|
4718
|
+
response_data = await self.api_client.call_api(
|
|
4719
|
+
*_param,
|
|
4720
|
+
_request_timeout=_request_timeout
|
|
4721
|
+
)
|
|
4722
|
+
await response_data.read()
|
|
4723
|
+
return self.api_client.response_deserialize(
|
|
4724
|
+
response_data=response_data,
|
|
4725
|
+
response_types_map=_response_types_map,
|
|
4726
|
+
)
|
|
4727
|
+
|
|
4728
|
+
|
|
4729
|
+
@validate_call
|
|
4730
|
+
async def update_node_group_without_preload_content(
|
|
4731
|
+
self,
|
|
4732
|
+
cluster_id: StrictInt,
|
|
4733
|
+
node_group_id: StrictInt,
|
|
4734
|
+
payload: UpdateClusterNodeGroupPayload,
|
|
4735
|
+
_request_timeout: Union[
|
|
4736
|
+
None,
|
|
4737
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4738
|
+
Tuple[
|
|
4739
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
4740
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
4741
|
+
]
|
|
4742
|
+
] = None,
|
|
4743
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
4744
|
+
_content_type: Optional[StrictStr] = None,
|
|
4745
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
4746
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
4747
|
+
) -> RESTResponseType:
|
|
4748
|
+
"""Update a node group in a cluster
|
|
4749
|
+
|
|
4750
|
+
|
|
4751
|
+
:param cluster_id: (required)
|
|
4752
|
+
:type cluster_id: int
|
|
4753
|
+
:param node_group_id: (required)
|
|
4754
|
+
:type node_group_id: int
|
|
4755
|
+
:param payload: (required)
|
|
4756
|
+
:type payload: UpdateClusterNodeGroupPayload
|
|
4757
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
4758
|
+
number provided, it will be total request
|
|
4759
|
+
timeout. It can also be a pair (tuple) of
|
|
4760
|
+
(connection, read) timeouts.
|
|
4761
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
4762
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
4763
|
+
request; this effectively ignores the
|
|
4764
|
+
authentication in the spec for a single request.
|
|
4765
|
+
:type _request_auth: dict, optional
|
|
4766
|
+
:param _content_type: force content-type for the request.
|
|
4767
|
+
:type _content_type: str, Optional
|
|
4768
|
+
:param _headers: set to override the headers for a single
|
|
4769
|
+
request; this effectively ignores the headers
|
|
4770
|
+
in the spec for a single request.
|
|
4771
|
+
:type _headers: dict, optional
|
|
4772
|
+
:param _host_index: set to override the host_index for a single
|
|
4773
|
+
request; this effectively ignores the host_index
|
|
4774
|
+
in the spec for a single request.
|
|
4775
|
+
:type _host_index: int, optional
|
|
4776
|
+
:return: Returns the result object.
|
|
4777
|
+
""" # noqa: E501
|
|
4778
|
+
|
|
4779
|
+
_param = self._update_node_group_serialize(
|
|
4780
|
+
cluster_id=cluster_id,
|
|
4781
|
+
node_group_id=node_group_id,
|
|
4782
|
+
payload=payload,
|
|
4783
|
+
_request_auth=_request_auth,
|
|
4784
|
+
_content_type=_content_type,
|
|
4785
|
+
_headers=_headers,
|
|
4786
|
+
_host_index=_host_index
|
|
4787
|
+
)
|
|
4788
|
+
|
|
4789
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
4790
|
+
'200': "ClusterNodeGroupsCreateResponse",
|
|
4791
|
+
'400': "ErrorResponseModel",
|
|
4792
|
+
'401': "ErrorResponseModel",
|
|
4793
|
+
'404': "ErrorResponseModel",
|
|
4794
|
+
'409': "ErrorResponseModel",
|
|
4795
|
+
'500': None,
|
|
4796
|
+
}
|
|
4797
|
+
response_data = await self.api_client.call_api(
|
|
4798
|
+
*_param,
|
|
4799
|
+
_request_timeout=_request_timeout
|
|
4800
|
+
)
|
|
4801
|
+
return response_data.response
|
|
4802
|
+
|
|
4803
|
+
|
|
4804
|
+
def _update_node_group_serialize(
|
|
4805
|
+
self,
|
|
4806
|
+
cluster_id,
|
|
4807
|
+
node_group_id,
|
|
4808
|
+
payload,
|
|
4809
|
+
_request_auth,
|
|
4810
|
+
_content_type,
|
|
4811
|
+
_headers,
|
|
4812
|
+
_host_index,
|
|
4813
|
+
) -> RequestSerialized:
|
|
4814
|
+
|
|
4815
|
+
_host = None
|
|
4816
|
+
|
|
4817
|
+
_collection_formats: Dict[str, str] = {
|
|
4818
|
+
}
|
|
4819
|
+
|
|
4820
|
+
_path_params: Dict[str, str] = {}
|
|
4821
|
+
_query_params: List[Tuple[str, str]] = []
|
|
4822
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
4823
|
+
_form_params: List[Tuple[str, str]] = []
|
|
4824
|
+
_files: Dict[
|
|
4825
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
4826
|
+
] = {}
|
|
4827
|
+
_body_params: Optional[bytes] = None
|
|
4828
|
+
|
|
4829
|
+
# process the path parameters
|
|
4830
|
+
if cluster_id is not None:
|
|
4831
|
+
_path_params['cluster_id'] = cluster_id
|
|
4832
|
+
if node_group_id is not None:
|
|
4833
|
+
_path_params['node_group_id'] = node_group_id
|
|
4834
|
+
# process the query parameters
|
|
4835
|
+
# process the header parameters
|
|
4836
|
+
# process the form parameters
|
|
4837
|
+
# process the body parameter
|
|
4838
|
+
if payload is not None:
|
|
4839
|
+
_body_params = payload
|
|
4840
|
+
|
|
4841
|
+
|
|
4842
|
+
# set the HTTP header `Accept`
|
|
4843
|
+
if 'Accept' not in _header_params:
|
|
4844
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
4845
|
+
[
|
|
4846
|
+
'application/json'
|
|
4847
|
+
]
|
|
4848
|
+
)
|
|
4849
|
+
|
|
4850
|
+
# set the HTTP header `Content-Type`
|
|
4851
|
+
if _content_type:
|
|
4852
|
+
_header_params['Content-Type'] = _content_type
|
|
4853
|
+
else:
|
|
4854
|
+
_default_content_type = (
|
|
4855
|
+
self.api_client.select_header_content_type(
|
|
4856
|
+
[
|
|
4857
|
+
'application/json'
|
|
4858
|
+
]
|
|
4859
|
+
)
|
|
4860
|
+
)
|
|
4861
|
+
if _default_content_type is not None:
|
|
4862
|
+
_header_params['Content-Type'] = _default_content_type
|
|
4863
|
+
|
|
4864
|
+
# authentication setting
|
|
4865
|
+
_auth_settings: List[str] = [
|
|
4866
|
+
'apiKey'
|
|
4867
|
+
]
|
|
4868
|
+
|
|
4869
|
+
return self.api_client.param_serialize(
|
|
4870
|
+
method='PATCH',
|
|
4871
|
+
resource_path='/core/clusters/{cluster_id}/node-groups/{node_group_id}',
|
|
4872
|
+
path_params=_path_params,
|
|
4873
|
+
query_params=_query_params,
|
|
4874
|
+
header_params=_header_params,
|
|
4875
|
+
body=_body_params,
|
|
4876
|
+
post_params=_form_params,
|
|
4877
|
+
files=_files,
|
|
4878
|
+
auth_settings=_auth_settings,
|
|
4879
|
+
collection_formats=_collection_formats,
|
|
4880
|
+
_host=_host,
|
|
4881
|
+
_request_auth=_request_auth
|
|
4882
|
+
)
|
|
4883
|
+
|
|
4884
|
+
|