From bd2c251b6f4e6af391eeaebb60450ce790cc6bb7 Mon Sep 17 00:00:00 2001 From: platform CI Date: Tue, 18 Aug 2026 18:21:31 +0000 Subject: [PATCH] Update clients to latest platform release (4.25.0) --- README.md | 20 +- docs/CreateBlockVolumeRequest.md | 33 - docs/CreateDynamoDeploymentRequest.md | 6 +- docs/CreateFilesystemVolumeRequest.md | 33 + docs/DeleteUserVaultItemRequest.md | 34 + docs/DeploymentComponentType.md | 2 + docs/DeploymentLogEventV4.md | 31 + docs/DeploymentResponse.md | 5 + docs/DynamoServingMode.md | 12 + docs/DynamoWorkerPoolConfig.md | 30 + docs/DynamoWorkerPools.md | 30 + docs/EXTERNALApi.md | 443 ++- docs/GetClusterResponse.md | 1 + docs/GetDeploymentLogV4Response.md | 29 + docs/GetDeploymentPodsResponse.md | 29 + docs/GetDynamoDeploymentResponse.md | 2 + ...onse.md => GetFilesystemVolumeResponse.md} | 19 +- docs/GetVolumeResponse.md | 3 +- docs/PodDetails.md | 4 +- docs/UpdateClusterMetadataRequest.md | 29 + docs/UpsertUserVaultItemRequest.md | 34 + docs/UserVaultItem.md | 2 + docs/VolumeAccessMode.md | 2 - docs/VolumeBackend.md | 2 +- platform_api_python_client/__init__.py | 15 +- .../api/external_api.py | 3057 ++++++++++++----- platform_api_python_client/api_client.py | 2 +- platform_api_python_client/configuration.py | 2 +- platform_api_python_client/models/__init__.py | 13 +- .../create_dynamo_deployment_request.py | 25 +- ...py => create_filesystem_volume_request.py} | 12 +- .../models/create_volume_request.py | 32 +- .../models/delete_user_vault_item_request.py | 108 + .../models/deployment_component_type.py | 2 + .../models/deployment_log_event_v4.py | 91 + .../models/deployment_response.py | 27 +- .../models/dynamo_serving_mode.py | 37 + .../models/dynamo_worker_pool_config.py | 103 + .../models/dynamo_worker_pools.py | 109 + .../models/get_cluster_response.py | 8 +- .../models/get_deployment_log_v4_response.py | 95 + .../models/get_deployment_pods_response.py | 87 + .../models/get_dynamo_deployment_response.py | 16 +- ...e.py => get_filesystem_volume_response.py} | 12 +- .../models/get_volume_response.py | 32 +- .../models/update_cluster_metadata_request.py | 87 + .../models/upsert_user_vault_item_request.py | 103 + .../models/user_vault_item.py | 9 +- .../models/volume_access_mode.py | 1 - .../models/volume_backend.py | 2 +- pyproject.toml | 2 +- setup.py | 2 +- test/test_create_dynamo_deployment_request.py | 3 +- ... test_create_filesystem_volume_request.py} | 26 +- test/test_delete_user_vault_item_request.py | 57 + test/test_deployment_log_event_v4.py | 56 + test/test_deployment_response.py | 8 +- test/test_deployment_status_v3_response.py | 2 +- test/test_dynamo_serving_mode.py | 33 + test/test_dynamo_worker_pool_config.py | 54 + test/test_dynamo_worker_pools.py | 54 + test/test_external_api.py | 35 + test/test_get_cluster_response.py | 3 +- test/test_get_deployment_log_v4_response.py | 62 + test/test_get_deployment_pods_response.py | 56 + test/test_get_dynamo_deployment_response.py | 2 + ...=> test_get_filesystem_volume_response.py} | 30 +- test/test_get_object_volume_response.py | 4 +- test/test_get_volume_response.py | 4 +- test/test_list_get_cluster_response.py | 6 +- test/test_list_user_vault_items_response.py | 2 + test/test_revision_pod_details.py | 2 +- test/test_update_cluster_metadata_request.py | 52 + test/test_upsert_user_vault_item_request.py | 58 + test/test_user_vault_item.py | 2 + test/test_volume_status_response.py | 4 +- 76 files changed, 4565 insertions(+), 976 deletions(-) delete mode 100644 docs/CreateBlockVolumeRequest.md create mode 100644 docs/CreateFilesystemVolumeRequest.md create mode 100644 docs/DeleteUserVaultItemRequest.md create mode 100644 docs/DeploymentLogEventV4.md create mode 100644 docs/DynamoServingMode.md create mode 100644 docs/DynamoWorkerPoolConfig.md create mode 100644 docs/DynamoWorkerPools.md create mode 100644 docs/GetDeploymentLogV4Response.md create mode 100644 docs/GetDeploymentPodsResponse.md rename docs/{GetBlockVolumeResponse.md => GetFilesystemVolumeResponse.md} (54%) create mode 100644 docs/UpdateClusterMetadataRequest.md create mode 100644 docs/UpsertUserVaultItemRequest.md rename platform_api_python_client/models/{create_block_volume_request.py => create_filesystem_volume_request.py} (91%) create mode 100644 platform_api_python_client/models/delete_user_vault_item_request.py create mode 100644 platform_api_python_client/models/deployment_log_event_v4.py create mode 100644 platform_api_python_client/models/dynamo_serving_mode.py create mode 100644 platform_api_python_client/models/dynamo_worker_pool_config.py create mode 100644 platform_api_python_client/models/dynamo_worker_pools.py create mode 100644 platform_api_python_client/models/get_deployment_log_v4_response.py create mode 100644 platform_api_python_client/models/get_deployment_pods_response.py rename platform_api_python_client/models/{get_block_volume_response.py => get_filesystem_volume_response.py} (90%) create mode 100644 platform_api_python_client/models/update_cluster_metadata_request.py create mode 100644 platform_api_python_client/models/upsert_user_vault_item_request.py rename test/{test_create_block_volume_request.py => test_create_filesystem_volume_request.py} (82%) create mode 100644 test/test_delete_user_vault_item_request.py create mode 100644 test/test_deployment_log_event_v4.py create mode 100644 test/test_dynamo_serving_mode.py create mode 100644 test/test_dynamo_worker_pool_config.py create mode 100644 test/test_dynamo_worker_pools.py create mode 100644 test/test_get_deployment_log_v4_response.py create mode 100644 test/test_get_deployment_pods_response.py rename test/{test_get_block_volume_response.py => test_get_filesystem_volume_response.py} (64%) create mode 100644 test/test_update_cluster_metadata_request.py create mode 100644 test/test_upsert_user_vault_item_request.py diff --git a/README.md b/README.md index 5573020..06d5b5e 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ No description provided (generated by Openapi Generator https://github.com/opena This Python package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project: - API version: 0.1.0 -- Package version: 4.23.1 +- Package version: 4.25.0 - Generator version: 7.9.0 - Build package: org.openapitools.codegen.languages.PythonClientCodegen @@ -109,6 +109,7 @@ Class | Method | HTTP request | Description *EXTERNALApi* | [**delete_cluster_clusters_cluster_id_delete**](docs/EXTERNALApi.md#delete_cluster_clusters_cluster_id_delete) | **DELETE** /clusters/{cluster_id} | Delete Cluster *EXTERNALApi* | [**delete_hardware_instance_hardware_instances_hardware_instance_id_delete**](docs/EXTERNALApi.md#delete_hardware_instance_hardware_instances_hardware_instance_id_delete) | **DELETE** /hardware-instances/{hardware_instance_id} | Delete Hardware Instance *EXTERNALApi* | [**delete_service_account_service_accounts_workos_id_delete**](docs/EXTERNALApi.md#delete_service_account_service_accounts_workos_id_delete) | **DELETE** /service-accounts/{workos_id} | Delete Service Account +*EXTERNALApi* | [**delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete**](docs/EXTERNALApi.md#delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete) | **DELETE** /user_vault/{secret_id} | Delete User Vault Item By Id Endpoint *EXTERNALApi* | [**delete_user_vault_item_endpoint_user_vault_delete**](docs/EXTERNALApi.md#delete_user_vault_item_endpoint_user_vault_delete) | **DELETE** /user_vault | Delete User Vault Item Endpoint *EXTERNALApi* | [**delete_volume_endpoint_volumes_volume_id_delete**](docs/EXTERNALApi.md#delete_volume_endpoint_volumes_volume_id_delete) | **DELETE** /volumes/{volume_id} | Delete Volume Endpoint *EXTERNALApi* | [**generate_service_account_secret_service_accounts_workos_id_secrets_post**](docs/EXTERNALApi.md#generate_service_account_secret_service_accounts_workos_id_secrets_post) | **POST** /service-accounts/{workos_id}/secrets | Generate Service Account Secret @@ -122,6 +123,8 @@ Class | Method | HTTP request | Description *EXTERNALApi* | [**get_cserve_v3_deployment_deployments_cserve_v3_deployment_id_get**](docs/EXTERNALApi.md#get_cserve_v3_deployment_deployments_cserve_v3_deployment_id_get) | **GET** /deployments/cserve_v3/{deployment_id} | Get Cserve V3 Deployment *EXTERNALApi* | [**get_deployment_logs_deployments_logs_deployment_id_get**](docs/EXTERNALApi.md#get_deployment_logs_deployments_logs_deployment_id_get) | **GET** /deployments/logs/{deployment_id} | Get Deployment Logs *EXTERNALApi* | [**get_deployment_logs_v3_deployments_logs_v3_deployment_id_revision_number_get**](docs/EXTERNALApi.md#get_deployment_logs_v3_deployments_logs_v3_deployment_id_revision_number_get) | **GET** /deployments/logs_v3/{deployment_id}/{revision_number} | Get Deployment Logs V3 +*EXTERNALApi* | [**get_deployment_logs_v4_logs_deployment_id_revision_number_get**](docs/EXTERNALApi.md#get_deployment_logs_v4_logs_deployment_id_revision_number_get) | **GET** /logs/{deployment_id}/{revision_number} | Get Deployment Logs V4 +*EXTERNALApi* | [**get_deployment_pods_deployments_pods_deployment_id_revision_number_get**](docs/EXTERNALApi.md#get_deployment_pods_deployments_pods_deployment_id_revision_number_get) | **GET** /deployments/pods/{deployment_id}/{revision_number} | Get Deployment Pods *EXTERNALApi* | [**get_deployment_revision_deployments_revisions_deployment_id_revision_number_get**](docs/EXTERNALApi.md#get_deployment_revision_deployments_revisions_deployment_id_revision_number_get) | **GET** /deployments/revisions/{deployment_id}/{revision_number} | Get Deployment Revision *EXTERNALApi* | [**get_deployment_revisions_deployments_revisions_deployment_id_get**](docs/EXTERNALApi.md#get_deployment_revisions_deployments_revisions_deployment_id_get) | **GET** /deployments/revisions/{deployment_id} | Get Deployment Revisions *EXTERNALApi* | [**get_deployment_status_deployments_status_deployment_id_get**](docs/EXTERNALApi.md#get_deployment_status_deployments_status_deployment_id_get) | **GET** /deployments/status/{deployment_id} | Get Deployment Status @@ -135,6 +138,7 @@ Class | Method | HTTP request | Description *EXTERNALApi* | [**get_prebuilt_images_prebuilt_images_get**](docs/EXTERNALApi.md#get_prebuilt_images_prebuilt_images_get) | **GET** /prebuilt-images | Get Prebuilt Images *EXTERNALApi* | [**get_usage_daily_bills_get**](docs/EXTERNALApi.md#get_usage_daily_bills_get) | **GET** /daily_bills | Get Usage *EXTERNALApi* | [**get_usage_deployments_usage_deployment_id_get**](docs/EXTERNALApi.md#get_usage_deployments_usage_deployment_id_get) | **GET** /deployments/usage/{deployment_id} | Get Usage +*EXTERNALApi* | [**get_user_vault_item_by_id_endpoint_user_vault_secret_id_get**](docs/EXTERNALApi.md#get_user_vault_item_by_id_endpoint_user_vault_secret_id_get) | **GET** /user_vault/{secret_id} | Get User Vault Item By Id Endpoint *EXTERNALApi* | [**get_volume_endpoint_volumes_volume_id_get**](docs/EXTERNALApi.md#get_volume_endpoint_volumes_volume_id_get) | **GET** /volumes/{volume_id} | Get Volume Endpoint *EXTERNALApi* | [**get_volume_status_endpoint_volumes_status_volume_id_get**](docs/EXTERNALApi.md#get_volume_status_endpoint_volumes_status_volume_id_get) | **GET** /volumes/status/{volume_id} | Get Volume Status Endpoint *EXTERNALApi* | [**invite_user_organizations_invite_post**](docs/EXTERNALApi.md#invite_user_organizations_invite_post) | **POST** /organizations/invite | Invite User @@ -143,6 +147,7 @@ Class | Method | HTTP request | Description *EXTERNALApi* | [**rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put**](docs/EXTERNALApi.md#rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put) | **PUT** /deployments/revisions/{deployment_id}/{revision_number} | Rollout Existing Revision *EXTERNALApi* | [**setup_stripe_customer_payments_setup_post**](docs/EXTERNALApi.md#setup_stripe_customer_payments_setup_post) | **POST** /payments/setup | Setup Stripe Customer *EXTERNALApi* | [**update_cluster_clusters_cluster_id_put**](docs/EXTERNALApi.md#update_cluster_clusters_cluster_id_put) | **PUT** /clusters/{cluster_id} | Update Cluster +*EXTERNALApi* | [**update_cluster_metadata_clusters_cluster_id_metadata_put**](docs/EXTERNALApi.md#update_cluster_metadata_clusters_cluster_id_metadata_put) | **PUT** /clusters/{cluster_id}/metadata | Update Cluster Metadata *EXTERNALApi* | [**update_compute_deployment_deployments_compute_put**](docs/EXTERNALApi.md#update_compute_deployment_deployments_compute_put) | **PUT** /deployments/compute | Update Compute Deployment *EXTERNALApi* | [**update_cserve_v2_deployment_deployments_cserve_v2_put**](docs/EXTERNALApi.md#update_cserve_v2_deployment_deployments_cserve_v2_put) | **PUT** /deployments/cserve_v2 | Update Cserve V2 Deployment *EXTERNALApi* | [**update_cserve_v3_deployment_deployments_cserve_v3_put**](docs/EXTERNALApi.md#update_cserve_v3_deployment_deployments_cserve_v3_put) | **PUT** /deployments/cserve_v3 | Update Cserve V3 Deployment @@ -171,7 +176,6 @@ Class | Method | HTTP request | Description - [ClusterRegistrationRequest](docs/ClusterRegistrationRequest.md) - [ClusterRegistrationResponse](docs/ClusterRegistrationResponse.md) - [ConfigFileMount](docs/ConfigFileMount.md) - - [CreateBlockVolumeRequest](docs/CreateBlockVolumeRequest.md) - [CreateCServeV2DeploymentResponse](docs/CreateCServeV2DeploymentResponse.md) - [CreateCServeV3DeploymentRequest](docs/CreateCServeV3DeploymentRequest.md) - [CreateCServeV3DeploymentResponse](docs/CreateCServeV3DeploymentResponse.md) @@ -179,6 +183,7 @@ Class | Method | HTTP request | Description - [CreateComputeDeploymentResponse](docs/CreateComputeDeploymentResponse.md) - [CreateDynamoDeploymentRequest](docs/CreateDynamoDeploymentRequest.md) - [CreateDynamoDeploymentResponse](docs/CreateDynamoDeploymentResponse.md) + - [CreateFilesystemVolumeRequest](docs/CreateFilesystemVolumeRequest.md) - [CreateHardwareInstanceRequest](docs/CreateHardwareInstanceRequest.md) - [CreateInferenceDeploymentResponse](docs/CreateInferenceDeploymentResponse.md) - [CreateInferenceV3DeploymentRequest](docs/CreateInferenceV3DeploymentRequest.md) @@ -192,7 +197,9 @@ Class | Method | HTTP request | Description - [CreateVolumeRequest](docs/CreateVolumeRequest.md) - [CreditsResponse](docs/CreditsResponse.md) - [DailyBillResponse](docs/DailyBillResponse.md) + - [DeleteUserVaultItemRequest](docs/DeleteUserVaultItemRequest.md) - [DeploymentComponentType](docs/DeploymentComponentType.md) + - [DeploymentLogEventV4](docs/DeploymentLogEventV4.md) - [DeploymentResponse](docs/DeploymentResponse.md) - [DeploymentStatus](docs/DeploymentStatus.md) - [DeploymentStatusRequest](docs/DeploymentStatusRequest.md) @@ -201,20 +208,25 @@ Class | Method | HTTP request | Description - [DeploymentType](docs/DeploymentType.md) - [DeploymentUsage](docs/DeploymentUsage.md) - [DeploymentUsageValue](docs/DeploymentUsageValue.md) + - [DynamoServingMode](docs/DynamoServingMode.md) + - [DynamoWorkerPoolConfig](docs/DynamoWorkerPoolConfig.md) + - [DynamoWorkerPools](docs/DynamoWorkerPools.md) - [ExternalDns](docs/ExternalDns.md) - [FinalStack](docs/FinalStack.md) - [FluentBit](docs/FluentBit.md) - [GenerateServiceAccountSecretResponse](docs/GenerateServiceAccountSecretResponse.md) - - [GetBlockVolumeResponse](docs/GetBlockVolumeResponse.md) - [GetCServeV2DeploymentResponse](docs/GetCServeV2DeploymentResponse.md) - [GetCServeV3DeploymentResponse](docs/GetCServeV3DeploymentResponse.md) - [GetClusterResponse](docs/GetClusterResponse.md) - [GetComputeDeploymentResponse](docs/GetComputeDeploymentResponse.md) - [GetDeploymentLogResponse](docs/GetDeploymentLogResponse.md) + - [GetDeploymentLogV4Response](docs/GetDeploymentLogV4Response.md) + - [GetDeploymentPodsResponse](docs/GetDeploymentPodsResponse.md) - [GetDeploymentResponse](docs/GetDeploymentResponse.md) - [GetDeploymentRevisionResponse](docs/GetDeploymentRevisionResponse.md) - [GetDeploymentUsageResponse](docs/GetDeploymentUsageResponse.md) - [GetDynamoDeploymentResponse](docs/GetDynamoDeploymentResponse.md) + - [GetFilesystemVolumeResponse](docs/GetFilesystemVolumeResponse.md) - [GetInferenceDeploymentResponse](docs/GetInferenceDeploymentResponse.md) - [GetInferenceV3DeploymentResponse](docs/GetInferenceV3DeploymentResponse.md) - [GetJobDeploymentResponse](docs/GetJobDeploymentResponse.md) @@ -263,9 +275,11 @@ Class | Method | HTTP request | Description - [Spire](docs/Spire.md) - [SpireCrds](docs/SpireCrds.md) - [TeleportKubeAgent](docs/TeleportKubeAgent.md) + - [UpdateClusterMetadataRequest](docs/UpdateClusterMetadataRequest.md) - [UpdateDeploymentResponse](docs/UpdateDeploymentResponse.md) - [UpdateDeploymentStatusV3Request](docs/UpdateDeploymentStatusV3Request.md) - [UpdateServiceAccountRequest](docs/UpdateServiceAccountRequest.md) + - [UpsertUserVaultItemRequest](docs/UpsertUserVaultItemRequest.md) - [UserVaultItem](docs/UserVaultItem.md) - [UserVaultType](docs/UserVaultType.md) - [ValidationError](docs/ValidationError.md) diff --git a/docs/CreateBlockVolumeRequest.md b/docs/CreateBlockVolumeRequest.md deleted file mode 100644 index ec56648..0000000 --- a/docs/CreateBlockVolumeRequest.md +++ /dev/null @@ -1,33 +0,0 @@ -# CreateBlockVolumeRequest - - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **str** | | -**cluster_id** | **int** | | -**backend** | **str** | | -**size_gb** | **int** | | [optional] [default to 100] -**storage_class** | **str** | | [optional] - -## Example - -```python -from platform_api_python_client.models.create_block_volume_request import CreateBlockVolumeRequest - -# TODO update the JSON string below -json = "{}" -# create an instance of CreateBlockVolumeRequest from a JSON string -create_block_volume_request_instance = CreateBlockVolumeRequest.from_json(json) -# print the JSON string representation of the object -print(CreateBlockVolumeRequest.to_json()) - -# convert the object into a dict -create_block_volume_request_dict = create_block_volume_request_instance.to_dict() -# create an instance of CreateBlockVolumeRequest from a dict -create_block_volume_request_from_dict = CreateBlockVolumeRequest.from_dict(create_block_volume_request_dict) -``` -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/docs/CreateDynamoDeploymentRequest.md b/docs/CreateDynamoDeploymentRequest.md index 75812d6..04ea991 100644 --- a/docs/CreateDynamoDeploymentRequest.md +++ b/docs/CreateDynamoDeploymentRequest.md @@ -1,6 +1,6 @@ # CreateDynamoDeploymentRequest -Create a NVIDIA Dynamo (DynamoGraphDeployment) inference deployment. Aggregated + KV-router pattern with a vLLM backend. The Frontend pod enables KV-aware routing across worker replicas. +Create a Dynamo deployment. Aggregated mode requires ``hardware_instance_id``; disaggregated mode requires fixed-size ``worker_pools``. ## Properties @@ -10,9 +10,11 @@ Name | Type | Description | Notes **max_unavailable** | **int** | | [optional] **name** | **str** | | **cluster_id** | **int** | | -**hardware_instance_id** | **int** | | +**hardware_instance_id** | **int** | | [optional] **user_annotations** | **Dict[str, str]** | | [optional] **chart_revision** | **str** | | [optional] +**serving_mode** | [**DynamoServingMode**](DynamoServingMode.md) | | [optional] +**worker_pools** | [**DynamoWorkerPools**](DynamoWorkerPools.md) | | [optional] **model** | **str** | | **served_model_name** | **str** | | [optional] **min_replicas** | **int** | | [optional] [default to 1] diff --git a/docs/CreateFilesystemVolumeRequest.md b/docs/CreateFilesystemVolumeRequest.md new file mode 100644 index 0000000..cd1a37f --- /dev/null +++ b/docs/CreateFilesystemVolumeRequest.md @@ -0,0 +1,33 @@ +# CreateFilesystemVolumeRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **str** | | +**cluster_id** | **int** | | +**backend** | **str** | | +**size_gb** | **int** | | [optional] [default to 100] +**storage_class** | **str** | | [optional] + +## Example + +```python +from platform_api_python_client.models.create_filesystem_volume_request import CreateFilesystemVolumeRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of CreateFilesystemVolumeRequest from a JSON string +create_filesystem_volume_request_instance = CreateFilesystemVolumeRequest.from_json(json) +# print the JSON string representation of the object +print(CreateFilesystemVolumeRequest.to_json()) + +# convert the object into a dict +create_filesystem_volume_request_dict = create_filesystem_volume_request_instance.to_dict() +# create an instance of CreateFilesystemVolumeRequest from a dict +create_filesystem_volume_request_from_dict = CreateFilesystemVolumeRequest.from_dict(create_filesystem_volume_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeleteUserVaultItemRequest.md b/docs/DeleteUserVaultItemRequest.md new file mode 100644 index 0000000..eff7869 --- /dev/null +++ b/docs/DeleteUserVaultItemRequest.md @@ -0,0 +1,34 @@ +# DeleteUserVaultItemRequest + +Body for the legacy delete, deliberately permissive. Kept separate from UserVaultItem so that model can require `id`. Here `id` stays optional because resolving by (type, key, visibility) is the only way to delete a row for which the client was never handed an id, and `value` is accepted and ignored because old clients send back a whole vault item. + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **int** | | [optional] +**type** | [**UserVaultType**](UserVaultType.md) | | +**key** | **str** | | +**value** | **str** | | [optional] +**visibility** | [**VaultScope**](VaultScope.md) | | [optional] + +## Example + +```python +from platform_api_python_client.models.delete_user_vault_item_request import DeleteUserVaultItemRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of DeleteUserVaultItemRequest from a JSON string +delete_user_vault_item_request_instance = DeleteUserVaultItemRequest.from_json(json) +# print the JSON string representation of the object +print(DeleteUserVaultItemRequest.to_json()) + +# convert the object into a dict +delete_user_vault_item_request_dict = delete_user_vault_item_request_instance.to_dict() +# create an instance of DeleteUserVaultItemRequest from a dict +delete_user_vault_item_request_from_dict = DeleteUserVaultItemRequest.from_dict(delete_user_vault_item_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeploymentComponentType.md b/docs/DeploymentComponentType.md index 15238c5..69cc990 100644 --- a/docs/DeploymentComponentType.md +++ b/docs/DeploymentComponentType.md @@ -18,3 +18,5 @@ * `EPP` (value: `'epp'`) [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeploymentLogEventV4.md b/docs/DeploymentLogEventV4.md new file mode 100644 index 0000000..d5b0556 --- /dev/null +++ b/docs/DeploymentLogEventV4.md @@ -0,0 +1,31 @@ +# DeploymentLogEventV4 + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **str** | Stable event identity: '<nanosecond timestamp>-<content hash>'. Deduplication key for the re-deliveries of fetch_newer pages; its nanosecond prefix orders events (sorted insert for late arrivals, never append). | +**timestamp** | **int** | Event timestamp in epoch milliseconds. | +**message** | **str** | Raw log line as emitted by the container. | + +## Example + +```python +from platform_api_python_client.models.deployment_log_event_v4 import DeploymentLogEventV4 + +# TODO update the JSON string below +json = "{}" +# create an instance of DeploymentLogEventV4 from a JSON string +deployment_log_event_v4_instance = DeploymentLogEventV4.from_json(json) +# print the JSON string representation of the object +print(DeploymentLogEventV4.to_json()) + +# convert the object into a dict +deployment_log_event_v4_dict = deployment_log_event_v4_instance.to_dict() +# create an instance of DeploymentLogEventV4 from a dict +deployment_log_event_v4_from_dict = DeploymentLogEventV4.from_dict(deployment_log_event_v4_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DeploymentResponse.md b/docs/DeploymentResponse.md index 09248b3..88ead0f 100644 --- a/docs/DeploymentResponse.md +++ b/docs/DeploymentResponse.md @@ -17,6 +17,8 @@ Name | Type | Description | Notes **hardware_instance_id** | **int** | | **revision_number** | **int** | | **user_annotations** | **Dict[str, str]** | | [optional] +**serving_mode** | [**DynamoServingMode**](DynamoServingMode.md) | | [optional] +**worker_pools** | [**DynamoWorkerPools**](DynamoWorkerPools.md) | | [optional] **model** | **str** | | **served_model_name** | **str** | | [optional] **min_replicas** | **int** | | @@ -42,6 +44,9 @@ Name | Type | Description | Notes **image_pull_secret_credentials** | [**ImagePullSecretCredentials**](ImagePullSecretCredentials.md) | | [optional] **config_file** | [**ConfigFileMount**](ConfigFileMount.md) | | [optional] **metrics** | [**MetricsConfig**](MetricsConfig.md) | | [optional] +**exposed_port** | **int** | | +**ssh_public_key** | **str** | | [optional] +**ssh_password** | **str** | | [optional] ## Example diff --git a/docs/DynamoServingMode.md b/docs/DynamoServingMode.md new file mode 100644 index 0000000..064d520 --- /dev/null +++ b/docs/DynamoServingMode.md @@ -0,0 +1,12 @@ +# DynamoServingMode + + +## Enum + +* `AGGREGATED` (value: `'aggregated'`) + +* `DISAGGREGATED` (value: `'disaggregated'`) + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DynamoWorkerPoolConfig.md b/docs/DynamoWorkerPoolConfig.md new file mode 100644 index 0000000..b53786f --- /dev/null +++ b/docs/DynamoWorkerPoolConfig.md @@ -0,0 +1,30 @@ +# DynamoWorkerPoolConfig + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**hardware_instance_id** | **int** | | +**replicas** | **int** | | + +## Example + +```python +from platform_api_python_client.models.dynamo_worker_pool_config import DynamoWorkerPoolConfig + +# TODO update the JSON string below +json = "{}" +# create an instance of DynamoWorkerPoolConfig from a JSON string +dynamo_worker_pool_config_instance = DynamoWorkerPoolConfig.from_json(json) +# print the JSON string representation of the object +print(DynamoWorkerPoolConfig.to_json()) + +# convert the object into a dict +dynamo_worker_pool_config_dict = dynamo_worker_pool_config_instance.to_dict() +# create an instance of DynamoWorkerPoolConfig from a dict +dynamo_worker_pool_config_from_dict = DynamoWorkerPoolConfig.from_dict(dynamo_worker_pool_config_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/DynamoWorkerPools.md b/docs/DynamoWorkerPools.md new file mode 100644 index 0000000..4bda08d --- /dev/null +++ b/docs/DynamoWorkerPools.md @@ -0,0 +1,30 @@ +# DynamoWorkerPools + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**prefill** | [**DynamoWorkerPoolConfig**](DynamoWorkerPoolConfig.md) | | +**decode** | [**DynamoWorkerPoolConfig**](DynamoWorkerPoolConfig.md) | | + +## Example + +```python +from platform_api_python_client.models.dynamo_worker_pools import DynamoWorkerPools + +# TODO update the JSON string below +json = "{}" +# create an instance of DynamoWorkerPools from a JSON string +dynamo_worker_pools_instance = DynamoWorkerPools.from_json(json) +# print the JSON string representation of the object +print(DynamoWorkerPools.to_json()) + +# convert the object into a dict +dynamo_worker_pools_dict = dynamo_worker_pools_instance.to_dict() +# create an instance of DynamoWorkerPools from a dict +dynamo_worker_pools_from_dict = DynamoWorkerPools.from_dict(dynamo_worker_pools_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/EXTERNALApi.md b/docs/EXTERNALApi.md index f73f3ef..cbd63ed 100644 --- a/docs/EXTERNALApi.md +++ b/docs/EXTERNALApi.md @@ -19,6 +19,7 @@ Method | HTTP request | Description [**delete_cluster_clusters_cluster_id_delete**](EXTERNALApi.md#delete_cluster_clusters_cluster_id_delete) | **DELETE** /clusters/{cluster_id} | Delete Cluster [**delete_hardware_instance_hardware_instances_hardware_instance_id_delete**](EXTERNALApi.md#delete_hardware_instance_hardware_instances_hardware_instance_id_delete) | **DELETE** /hardware-instances/{hardware_instance_id} | Delete Hardware Instance [**delete_service_account_service_accounts_workos_id_delete**](EXTERNALApi.md#delete_service_account_service_accounts_workos_id_delete) | **DELETE** /service-accounts/{workos_id} | Delete Service Account +[**delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete**](EXTERNALApi.md#delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete) | **DELETE** /user_vault/{secret_id} | Delete User Vault Item By Id Endpoint [**delete_user_vault_item_endpoint_user_vault_delete**](EXTERNALApi.md#delete_user_vault_item_endpoint_user_vault_delete) | **DELETE** /user_vault | Delete User Vault Item Endpoint [**delete_volume_endpoint_volumes_volume_id_delete**](EXTERNALApi.md#delete_volume_endpoint_volumes_volume_id_delete) | **DELETE** /volumes/{volume_id} | Delete Volume Endpoint [**generate_service_account_secret_service_accounts_workos_id_secrets_post**](EXTERNALApi.md#generate_service_account_secret_service_accounts_workos_id_secrets_post) | **POST** /service-accounts/{workos_id}/secrets | Generate Service Account Secret @@ -32,6 +33,8 @@ Method | HTTP request | Description [**get_cserve_v3_deployment_deployments_cserve_v3_deployment_id_get**](EXTERNALApi.md#get_cserve_v3_deployment_deployments_cserve_v3_deployment_id_get) | **GET** /deployments/cserve_v3/{deployment_id} | Get Cserve V3 Deployment [**get_deployment_logs_deployments_logs_deployment_id_get**](EXTERNALApi.md#get_deployment_logs_deployments_logs_deployment_id_get) | **GET** /deployments/logs/{deployment_id} | Get Deployment Logs [**get_deployment_logs_v3_deployments_logs_v3_deployment_id_revision_number_get**](EXTERNALApi.md#get_deployment_logs_v3_deployments_logs_v3_deployment_id_revision_number_get) | **GET** /deployments/logs_v3/{deployment_id}/{revision_number} | Get Deployment Logs V3 +[**get_deployment_logs_v4_logs_deployment_id_revision_number_get**](EXTERNALApi.md#get_deployment_logs_v4_logs_deployment_id_revision_number_get) | **GET** /logs/{deployment_id}/{revision_number} | Get Deployment Logs V4 +[**get_deployment_pods_deployments_pods_deployment_id_revision_number_get**](EXTERNALApi.md#get_deployment_pods_deployments_pods_deployment_id_revision_number_get) | **GET** /deployments/pods/{deployment_id}/{revision_number} | Get Deployment Pods [**get_deployment_revision_deployments_revisions_deployment_id_revision_number_get**](EXTERNALApi.md#get_deployment_revision_deployments_revisions_deployment_id_revision_number_get) | **GET** /deployments/revisions/{deployment_id}/{revision_number} | Get Deployment Revision [**get_deployment_revisions_deployments_revisions_deployment_id_get**](EXTERNALApi.md#get_deployment_revisions_deployments_revisions_deployment_id_get) | **GET** /deployments/revisions/{deployment_id} | Get Deployment Revisions [**get_deployment_status_deployments_status_deployment_id_get**](EXTERNALApi.md#get_deployment_status_deployments_status_deployment_id_get) | **GET** /deployments/status/{deployment_id} | Get Deployment Status @@ -45,6 +48,7 @@ Method | HTTP request | Description [**get_prebuilt_images_prebuilt_images_get**](EXTERNALApi.md#get_prebuilt_images_prebuilt_images_get) | **GET** /prebuilt-images | Get Prebuilt Images [**get_usage_daily_bills_get**](EXTERNALApi.md#get_usage_daily_bills_get) | **GET** /daily_bills | Get Usage [**get_usage_deployments_usage_deployment_id_get**](EXTERNALApi.md#get_usage_deployments_usage_deployment_id_get) | **GET** /deployments/usage/{deployment_id} | Get Usage +[**get_user_vault_item_by_id_endpoint_user_vault_secret_id_get**](EXTERNALApi.md#get_user_vault_item_by_id_endpoint_user_vault_secret_id_get) | **GET** /user_vault/{secret_id} | Get User Vault Item By Id Endpoint [**get_volume_endpoint_volumes_volume_id_get**](EXTERNALApi.md#get_volume_endpoint_volumes_volume_id_get) | **GET** /volumes/{volume_id} | Get Volume Endpoint [**get_volume_status_endpoint_volumes_status_volume_id_get**](EXTERNALApi.md#get_volume_status_endpoint_volumes_status_volume_id_get) | **GET** /volumes/status/{volume_id} | Get Volume Status Endpoint [**invite_user_organizations_invite_post**](EXTERNALApi.md#invite_user_organizations_invite_post) | **POST** /organizations/invite | Invite User @@ -53,6 +57,7 @@ Method | HTTP request | Description [**rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put**](EXTERNALApi.md#rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put) | **PUT** /deployments/revisions/{deployment_id}/{revision_number} | Rollout Existing Revision [**setup_stripe_customer_payments_setup_post**](EXTERNALApi.md#setup_stripe_customer_payments_setup_post) | **POST** /payments/setup | Setup Stripe Customer [**update_cluster_clusters_cluster_id_put**](EXTERNALApi.md#update_cluster_clusters_cluster_id_put) | **PUT** /clusters/{cluster_id} | Update Cluster +[**update_cluster_metadata_clusters_cluster_id_metadata_put**](EXTERNALApi.md#update_cluster_metadata_clusters_cluster_id_metadata_put) | **PUT** /clusters/{cluster_id}/metadata | Update Cluster Metadata [**update_compute_deployment_deployments_compute_put**](EXTERNALApi.md#update_compute_deployment_deployments_compute_put) | **PUT** /deployments/compute | Update Compute Deployment [**update_cserve_v2_deployment_deployments_cserve_v2_put**](EXTERNALApi.md#update_cserve_v2_deployment_deployments_cserve_v2_put) | **PUT** /deployments/cserve_v2 | Update Cserve V2 Deployment [**update_cserve_v3_deployment_deployments_cserve_v3_put**](EXTERNALApi.md#update_cserve_v3_deployment_deployments_cserve_v3_put) | **PUT** /deployments/cserve_v3 | Update Cserve V3 Deployment @@ -896,7 +901,7 @@ Name | Type | Description | Notes Create Volume Endpoint -Create a volume. Only the block backend is provisioned; object lands in CCL-147. +Create a volume. Only the filesystem backend is provisioned; object lands in CCL-147. ### Example @@ -1195,12 +1200,90 @@ void (empty response body) [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +# **delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete** +> object delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete(secret_id) + +Delete User Vault Item By Id Endpoint + +Delete a vault item by ID. TODO(vault-migration): reject the delete when a selected deployment revision references the secret. Revision-reference tracking lands in a follow-up migration, so nothing is checked yet. + +### Example + +* Bearer Authentication (HTTPBearer): + +```python +import platform_api_python_client +from platform_api_python_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = platform_api_python_client.Configuration( + host = "http://localhost" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: HTTPBearer +configuration = platform_api_python_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with platform_api_python_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = platform_api_python_client.EXTERNALApi(api_client) + secret_id = 56 # int | + + try: + # Delete User Vault Item By Id Endpoint + api_response = api_instance.delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete(secret_id) + print("The response of EXTERNALApi->delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EXTERNALApi->delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **secret_id** | **int**| | + +### Return type + +**object** + +### Authorization + +[HTTPBearer](../README.md#HTTPBearer) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + # **delete_user_vault_item_endpoint_user_vault_delete** -> object delete_user_vault_item_endpoint_user_vault_delete(user_vault_item) +> object delete_user_vault_item_endpoint_user_vault_delete(delete_user_vault_item_request) Delete User Vault Item Endpoint -Delete an item of a specific type for the user. +Compatibility shim for the legacy type/key/visibility delete body. ### Example @@ -1208,7 +1291,7 @@ Delete an item of a specific type for the user. ```python import platform_api_python_client -from platform_api_python_client.models.user_vault_item import UserVaultItem +from platform_api_python_client.models.delete_user_vault_item_request import DeleteUserVaultItemRequest from platform_api_python_client.rest import ApiException from pprint import pprint @@ -1232,11 +1315,11 @@ configuration = platform_api_python_client.Configuration( with platform_api_python_client.ApiClient(configuration) as api_client: # Create an instance of the API class api_instance = platform_api_python_client.EXTERNALApi(api_client) - user_vault_item = platform_api_python_client.UserVaultItem() # UserVaultItem | + delete_user_vault_item_request = platform_api_python_client.DeleteUserVaultItemRequest() # DeleteUserVaultItemRequest | try: # Delete User Vault Item Endpoint - api_response = api_instance.delete_user_vault_item_endpoint_user_vault_delete(user_vault_item) + api_response = api_instance.delete_user_vault_item_endpoint_user_vault_delete(delete_user_vault_item_request) print("The response of EXTERNALApi->delete_user_vault_item_endpoint_user_vault_delete:\n") pprint(api_response) except Exception as e: @@ -1250,7 +1333,7 @@ with platform_api_python_client.ApiClient(configuration) as api_client: Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **user_vault_item** | [**UserVaultItem**](UserVaultItem.md)| | + **delete_user_vault_item_request** | [**DeleteUserVaultItemRequest**](DeleteUserVaultItemRequest.md)| | ### Return type @@ -1434,7 +1517,7 @@ Name | Type | Description | Notes Get All User Vault Items Endpoint -Retrieve all items the user has access to (both USER and ORG scoped). +List metadata for every item the user can read, without any secret values. Values are deliberately omitted so browsing the vault never bulk-exposes secrets. Callers that need one value fetch it from the by-id endpoint below. ### Example @@ -2215,6 +2298,176 @@ Name | Type | Description | Notes [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +# **get_deployment_logs_v4_logs_deployment_id_revision_number_get** +> GetDeploymentLogV4Response get_deployment_logs_v4_logs_deployment_id_revision_number_get(deployment_id, revision_number, pod, fetch_newer=fetch_newer, timestamp=timestamp, max_lines=max_lines) + +Get Deployment Logs V4 + +Retrieve one page of a single pod's logs from Loki, oldest line first. - `pod`: which pod's logs to read; pick a name reported by `/deployments/pods/{deployment_id}/{revision_number}` — a pod unknown to the log store simply yields empty pages. - `fetch_newer`: direction. `false` (default) pages toward older logs, starting from the newest page; `true` fetches newer logs (for follow-polling). - `timestamp`: epoch-millisecond boundary (the events' `timestamp` unit), exclusive in both directions: `fetch_newer=false` returns lines strictly older than that millisecond, `fetch_newer=true` lines strictly newer. Without it both directions scan the whole log window: `fetch_newer=false` starts at the tail (the newest page), `fetch_newer=true` at the head (the oldest page) — to follow live logs, take the tail page first and pass its newest `timestamp`. There is no server-issued page token — mint the boundary from the events themselves (pages never split a millisecond, so a delivered boundary millisecond is always complete): pass the oldest event's `timestamp` to keep paging older, and the newest event `timestamp` seen on any page — history pages included — to fetch newer. An empty `fetch_newer=false` page means history is exhausted; an empty `fetch_newer=true` page means nothing new yet — poll again with the same `timestamp`. - `fetch_newer=true` with a `timestamp` also re-delivers the ~15 seconds at and before it on every poll (late-arriving lines land there), so callers must deduplicate by event `id`; re-delivered lines do not count toward `max_lines`. A span holding more than the log store's 5000-entry query ceiling re-delivers only its newest 5000 lines (the excess is dropped and logged server-side). - `max_lines`: cap on new lines per page — default 100, at most 5000 (the log store's per-query ceiling); a page may exceed it when many lines share one millisecond (such a group is never split across pages, unless it exceeds that same 5000-entry ceiling — the excess is then dropped and logged server-side) or through the re-delivered span. + +### Example + +* Bearer Authentication (HTTPBearer): + +```python +import platform_api_python_client +from platform_api_python_client.models.get_deployment_log_v4_response import GetDeploymentLogV4Response +from platform_api_python_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = platform_api_python_client.Configuration( + host = "http://localhost" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: HTTPBearer +configuration = platform_api_python_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with platform_api_python_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = platform_api_python_client.EXTERNALApi(api_client) + deployment_id = 56 # int | + revision_number = 56 # int | + pod = 'pod_example' # str | + fetch_newer = False # bool | (optional) (default to False) + timestamp = 56 # int | (optional) + max_lines = 100 # int | (optional) (default to 100) + + try: + # Get Deployment Logs V4 + api_response = api_instance.get_deployment_logs_v4_logs_deployment_id_revision_number_get(deployment_id, revision_number, pod, fetch_newer=fetch_newer, timestamp=timestamp, max_lines=max_lines) + print("The response of EXTERNALApi->get_deployment_logs_v4_logs_deployment_id_revision_number_get:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EXTERNALApi->get_deployment_logs_v4_logs_deployment_id_revision_number_get: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **deployment_id** | **int**| | + **revision_number** | **int**| | + **pod** | **str**| | + **fetch_newer** | **bool**| | [optional] [default to False] + **timestamp** | **int**| | [optional] + **max_lines** | **int**| | [optional] [default to 100] + +### Return type + +[**GetDeploymentLogV4Response**](GetDeploymentLogV4Response.md) + +### Authorization + +[HTTPBearer](../README.md#HTTPBearer) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **get_deployment_pods_deployments_pods_deployment_id_revision_number_get** +> GetDeploymentPodsResponse get_deployment_pods_deployments_pods_deployment_id_revision_number_get(deployment_id, revision_number) + +Get Deployment Pods + +List the pod names recorded for this revision, recently terminated pods included; the history is bounded to a retention window, so the list can differ from the live pods in status_v3. + +### Example + +* Bearer Authentication (HTTPBearer): + +```python +import platform_api_python_client +from platform_api_python_client.models.get_deployment_pods_response import GetDeploymentPodsResponse +from platform_api_python_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = platform_api_python_client.Configuration( + host = "http://localhost" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: HTTPBearer +configuration = platform_api_python_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with platform_api_python_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = platform_api_python_client.EXTERNALApi(api_client) + deployment_id = 56 # int | + revision_number = 56 # int | + + try: + # Get Deployment Pods + api_response = api_instance.get_deployment_pods_deployments_pods_deployment_id_revision_number_get(deployment_id, revision_number) + print("The response of EXTERNALApi->get_deployment_pods_deployments_pods_deployment_id_revision_number_get:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EXTERNALApi->get_deployment_pods_deployments_pods_deployment_id_revision_number_get: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **deployment_id** | **int**| | + **revision_number** | **int**| | + +### Return type + +[**GetDeploymentPodsResponse**](GetDeploymentPodsResponse.md) + +### Authorization + +[HTTPBearer](../README.md#HTTPBearer) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + # **get_deployment_revision_deployments_revisions_deployment_id_revision_number_get** > GetDeploymentRevisionResponse get_deployment_revision_deployments_revisions_deployment_id_revision_number_get(deployment_id, revision_number) @@ -3241,6 +3494,85 @@ Name | Type | Description | Notes [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +# **get_user_vault_item_by_id_endpoint_user_vault_secret_id_get** +> UserVaultItem get_user_vault_item_by_id_endpoint_user_vault_secret_id_get(secret_id) + +Get User Vault Item By Id Endpoint + +Resolve a single secret's value. This is the only endpoint that returns a vault value, so it is the single place where read access to secret material is authorized and auditable. + +### Example + +* Bearer Authentication (HTTPBearer): + +```python +import platform_api_python_client +from platform_api_python_client.models.user_vault_item import UserVaultItem +from platform_api_python_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = platform_api_python_client.Configuration( + host = "http://localhost" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: HTTPBearer +configuration = platform_api_python_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with platform_api_python_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = platform_api_python_client.EXTERNALApi(api_client) + secret_id = 56 # int | + + try: + # Get User Vault Item By Id Endpoint + api_response = api_instance.get_user_vault_item_by_id_endpoint_user_vault_secret_id_get(secret_id) + print("The response of EXTERNALApi->get_user_vault_item_by_id_endpoint_user_vault_secret_id_get:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EXTERNALApi->get_user_vault_item_by_id_endpoint_user_vault_secret_id_get: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **secret_id** | **int**| | + +### Return type + +[**UserVaultItem**](UserVaultItem.md) + +### Authorization + +[HTTPBearer](../README.md#HTTPBearer) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + # **get_volume_endpoint_volumes_volume_id_get** > GetVolumeResponse get_volume_endpoint_volumes_volume_id_get(volume_id) @@ -3861,6 +4193,88 @@ Name | Type | Description | Notes [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) +# **update_cluster_metadata_clusters_cluster_id_metadata_put** +> GetClusterResponse update_cluster_metadata_clusters_cluster_id_metadata_put(cluster_id, update_cluster_metadata_request) + +Update Cluster Metadata + +Update DB metadata for an org-owned cluster. Does not drive infra stack updates. Global clusters (parent_id IS NULL) are not mutable here. + +### Example + +* Bearer Authentication (HTTPBearer): + +```python +import platform_api_python_client +from platform_api_python_client.models.get_cluster_response import GetClusterResponse +from platform_api_python_client.models.update_cluster_metadata_request import UpdateClusterMetadataRequest +from platform_api_python_client.rest import ApiException +from pprint import pprint + +# Defining the host is optional and defaults to http://localhost +# See configuration.py for a list of all supported configuration parameters. +configuration = platform_api_python_client.Configuration( + host = "http://localhost" +) + +# The client must configure the authentication and authorization parameters +# in accordance with the API server security policy. +# Examples for each auth method are provided below, use the example that +# satisfies your auth use case. + +# Configure Bearer authorization: HTTPBearer +configuration = platform_api_python_client.Configuration( + access_token = os.environ["BEARER_TOKEN"] +) + +# Enter a context with an instance of the API client +with platform_api_python_client.ApiClient(configuration) as api_client: + # Create an instance of the API class + api_instance = platform_api_python_client.EXTERNALApi(api_client) + cluster_id = 56 # int | + update_cluster_metadata_request = platform_api_python_client.UpdateClusterMetadataRequest() # UpdateClusterMetadataRequest | + + try: + # Update Cluster Metadata + api_response = api_instance.update_cluster_metadata_clusters_cluster_id_metadata_put(cluster_id, update_cluster_metadata_request) + print("The response of EXTERNALApi->update_cluster_metadata_clusters_cluster_id_metadata_put:\n") + pprint(api_response) + except Exception as e: + print("Exception when calling EXTERNALApi->update_cluster_metadata_clusters_cluster_id_metadata_put: %s\n" % e) +``` + + + +### Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **cluster_id** | **int**| | + **update_cluster_metadata_request** | [**UpdateClusterMetadataRequest**](UpdateClusterMetadataRequest.md)| | + +### Return type + +[**GetClusterResponse**](GetClusterResponse.md) + +### Authorization + +[HTTPBearer](../README.md#HTTPBearer) + +### HTTP request headers + + - **Content-Type**: application/json + - **Accept**: application/json + +### HTTP response details + +| Status code | Description | Response headers | +|-------------|-------------|------------------| +**200** | Successful Response | - | +**422** | Validation Error | - | + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + # **update_compute_deployment_deployments_compute_put** > UpdateDeploymentResponse update_compute_deployment_deployments_compute_put(deployment_id, create_compute_deployment_request) @@ -4546,11 +4960,11 @@ Name | Type | Description | Notes [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) # **update_user_vault_item_endpoint_user_vault_put** -> object update_user_vault_item_endpoint_user_vault_put(user_vault_item) +> UserVaultItem update_user_vault_item_endpoint_user_vault_put(upsert_user_vault_item_request) Update User Vault Item Endpoint -Update or add an item of a specific type for the user. +Create or update a vault item, writing its value to both SSM and PostgreSQL. The key and value rules are declared on UpsertUserVaultItemRequest, so a malformed write is rejected with a 422 before this handler runs. ### Example @@ -4558,6 +4972,7 @@ Update or add an item of a specific type for the user. ```python import platform_api_python_client +from platform_api_python_client.models.upsert_user_vault_item_request import UpsertUserVaultItemRequest from platform_api_python_client.models.user_vault_item import UserVaultItem from platform_api_python_client.rest import ApiException from pprint import pprint @@ -4582,11 +4997,11 @@ configuration = platform_api_python_client.Configuration( with platform_api_python_client.ApiClient(configuration) as api_client: # Create an instance of the API class api_instance = platform_api_python_client.EXTERNALApi(api_client) - user_vault_item = platform_api_python_client.UserVaultItem() # UserVaultItem | + upsert_user_vault_item_request = platform_api_python_client.UpsertUserVaultItemRequest() # UpsertUserVaultItemRequest | try: # Update User Vault Item Endpoint - api_response = api_instance.update_user_vault_item_endpoint_user_vault_put(user_vault_item) + api_response = api_instance.update_user_vault_item_endpoint_user_vault_put(upsert_user_vault_item_request) print("The response of EXTERNALApi->update_user_vault_item_endpoint_user_vault_put:\n") pprint(api_response) except Exception as e: @@ -4600,11 +5015,11 @@ with platform_api_python_client.ApiClient(configuration) as api_client: Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - **user_vault_item** | [**UserVaultItem**](UserVaultItem.md)| | + **upsert_user_vault_item_request** | [**UpsertUserVaultItemRequest**](UpsertUserVaultItemRequest.md)| | ### Return type -**object** +[**UserVaultItem**](UserVaultItem.md) ### Authorization diff --git a/docs/GetClusterResponse.md b/docs/GetClusterResponse.md index 5cae237..6a0a563 100644 --- a/docs/GetClusterResponse.md +++ b/docs/GetClusterResponse.md @@ -9,6 +9,7 @@ Name | Type | Description | Notes **cluster_name** | **str** | | **display_name** | **str** | | **region** | **str** | | [optional] +**deployment_creation_disabled** | **bool** | | [optional] [default to False] ## Example diff --git a/docs/GetDeploymentLogV4Response.md b/docs/GetDeploymentLogV4Response.md new file mode 100644 index 0000000..1949096 --- /dev/null +++ b/docs/GetDeploymentLogV4Response.md @@ -0,0 +1,29 @@ +# GetDeploymentLogV4Response + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**events** | [**List[DeploymentLogEventV4]**](DeploymentLogEventV4.md) | Log events, oldest first. Page boundaries are minted client-side from the events' timestamp field (see the endpoint description): an empty fetch_newer=false page means history is exhausted; an empty fetch_newer=true page means nothing new yet. | + +## Example + +```python +from platform_api_python_client.models.get_deployment_log_v4_response import GetDeploymentLogV4Response + +# TODO update the JSON string below +json = "{}" +# create an instance of GetDeploymentLogV4Response from a JSON string +get_deployment_log_v4_response_instance = GetDeploymentLogV4Response.from_json(json) +# print the JSON string representation of the object +print(GetDeploymentLogV4Response.to_json()) + +# convert the object into a dict +get_deployment_log_v4_response_dict = get_deployment_log_v4_response_instance.to_dict() +# create an instance of GetDeploymentLogV4Response from a dict +get_deployment_log_v4_response_from_dict = GetDeploymentLogV4Response.from_dict(get_deployment_log_v4_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GetDeploymentPodsResponse.md b/docs/GetDeploymentPodsResponse.md new file mode 100644 index 0000000..0b27f39 --- /dev/null +++ b/docs/GetDeploymentPodsResponse.md @@ -0,0 +1,29 @@ +# GetDeploymentPodsResponse + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pods** | **List[str]** | | + +## Example + +```python +from platform_api_python_client.models.get_deployment_pods_response import GetDeploymentPodsResponse + +# TODO update the JSON string below +json = "{}" +# create an instance of GetDeploymentPodsResponse from a JSON string +get_deployment_pods_response_instance = GetDeploymentPodsResponse.from_json(json) +# print the JSON string representation of the object +print(GetDeploymentPodsResponse.to_json()) + +# convert the object into a dict +get_deployment_pods_response_dict = get_deployment_pods_response_instance.to_dict() +# create an instance of GetDeploymentPodsResponse from a dict +get_deployment_pods_response_from_dict = GetDeploymentPodsResponse.from_dict(get_deployment_pods_response_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/GetDynamoDeploymentResponse.md b/docs/GetDynamoDeploymentResponse.md index cdde16e..243c969 100644 --- a/docs/GetDynamoDeploymentResponse.md +++ b/docs/GetDynamoDeploymentResponse.md @@ -17,6 +17,8 @@ Name | Type | Description | Notes **hardware_instance_id** | **int** | | **revision_number** | **int** | | **user_annotations** | **Dict[str, str]** | | [optional] +**serving_mode** | [**DynamoServingMode**](DynamoServingMode.md) | | [optional] +**worker_pools** | [**DynamoWorkerPools**](DynamoWorkerPools.md) | | [optional] **model** | **str** | | **served_model_name** | **str** | | [optional] **min_replicas** | **int** | | diff --git a/docs/GetBlockVolumeResponse.md b/docs/GetFilesystemVolumeResponse.md similarity index 54% rename from docs/GetBlockVolumeResponse.md rename to docs/GetFilesystemVolumeResponse.md index 0a54087..bc3d6c5 100644 --- a/docs/GetBlockVolumeResponse.md +++ b/docs/GetFilesystemVolumeResponse.md @@ -1,4 +1,4 @@ -# GetBlockVolumeResponse +# GetFilesystemVolumeResponse ## Properties @@ -14,24 +14,25 @@ Name | Type | Description | Notes **pvc_name** | **str** | | **created_at** | **datetime** | | **size_gb** | **int** | | -**storage_class** | **str** | | +**storage_class** | **str** | | ## Example ```python -from platform_api_python_client.models.get_block_volume_response import GetBlockVolumeResponse +from platform_api_python_client.models.get_filesystem_volume_response import GetFilesystemVolumeResponse # TODO update the JSON string below json = "{}" -# create an instance of GetBlockVolumeResponse from a JSON string -get_block_volume_response_instance = GetBlockVolumeResponse.from_json(json) +# create an instance of GetFilesystemVolumeResponse from a JSON string +get_filesystem_volume_response_instance = GetFilesystemVolumeResponse.from_json(json) # print the JSON string representation of the object -print(GetBlockVolumeResponse.to_json()) +print(GetFilesystemVolumeResponse.to_json()) # convert the object into a dict -get_block_volume_response_dict = get_block_volume_response_instance.to_dict() -# create an instance of GetBlockVolumeResponse from a dict -get_block_volume_response_from_dict = GetBlockVolumeResponse.from_dict(get_block_volume_response_dict) +get_filesystem_volume_response_dict = get_filesystem_volume_response_instance.to_dict() +# create an instance of GetFilesystemVolumeResponse from a dict +get_filesystem_volume_response_from_dict = GetFilesystemVolumeResponse.from_dict(get_filesystem_volume_response_dict) ``` [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/docs/GetVolumeResponse.md b/docs/GetVolumeResponse.md index 4fef1ee..d0ae281 100644 --- a/docs/GetVolumeResponse.md +++ b/docs/GetVolumeResponse.md @@ -14,7 +14,7 @@ Name | Type | Description | Notes **pvc_name** | **str** | | **created_at** | **datetime** | | **size_gb** | **int** | | -**storage_class** | **str** | | +**storage_class** | **str** | | **provider** | [**ObjectStorageProvider**](ObjectStorageProvider.md) | | **bucket** | **str** | | **region** | **str** | | @@ -42,3 +42,4 @@ get_volume_response_from_dict = GetVolumeResponse.from_dict(get_volume_response_ ``` [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + diff --git a/docs/PodDetails.md b/docs/PodDetails.md index c5884d4..4dc8f3a 100644 --- a/docs/PodDetails.md +++ b/docs/PodDetails.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **name** | **str** | | [optional] **revision_number** | **int** | | [optional] -**component_type** | [**DeploymentComponentType**](DeploymentComponentType.md) | | [optional] +**component_type** | [**DeploymentComponentType**](DeploymentComponentType.md) | | [optional] **status** | [**PodStatus**](PodStatus.md) | | **error_message** | **str** | | [optional] @@ -29,3 +29,5 @@ pod_details_dict = pod_details_instance.to_dict() pod_details_from_dict = PodDetails.from_dict(pod_details_dict) ``` [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UpdateClusterMetadataRequest.md b/docs/UpdateClusterMetadataRequest.md new file mode 100644 index 0000000..7f04687 --- /dev/null +++ b/docs/UpdateClusterMetadataRequest.md @@ -0,0 +1,29 @@ +# UpdateClusterMetadataRequest + + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**deployment_creation_disabled** | **bool** | | + +## Example + +```python +from platform_api_python_client.models.update_cluster_metadata_request import UpdateClusterMetadataRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UpdateClusterMetadataRequest from a JSON string +update_cluster_metadata_request_instance = UpdateClusterMetadataRequest.from_json(json) +# print the JSON string representation of the object +print(UpdateClusterMetadataRequest.to_json()) + +# convert the object into a dict +update_cluster_metadata_request_dict = update_cluster_metadata_request_instance.to_dict() +# create an instance of UpdateClusterMetadataRequest from a dict +update_cluster_metadata_request_from_dict = UpdateClusterMetadataRequest.from_dict(update_cluster_metadata_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UpsertUserVaultItemRequest.md b/docs/UpsertUserVaultItemRequest.md new file mode 100644 index 0000000..d9ae8e7 --- /dev/null +++ b/docs/UpsertUserVaultItemRequest.md @@ -0,0 +1,34 @@ +# UpsertUserVaultItemRequest + +Write model for PUT /user_vault, where the key and value rules are enforced. + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **int** | | [optional] +**type** | [**UserVaultType**](UserVaultType.md) | | +**key** | **str** | | +**value** | **str** | | +**visibility** | [**VaultScope**](VaultScope.md) | | [optional] + +## Example + +```python +from platform_api_python_client.models.upsert_user_vault_item_request import UpsertUserVaultItemRequest + +# TODO update the JSON string below +json = "{}" +# create an instance of UpsertUserVaultItemRequest from a JSON string +upsert_user_vault_item_request_instance = UpsertUserVaultItemRequest.from_json(json) +# print the JSON string representation of the object +print(UpsertUserVaultItemRequest.to_json()) + +# convert the object into a dict +upsert_user_vault_item_request_dict = upsert_user_vault_item_request_instance.to_dict() +# create an instance of UpsertUserVaultItemRequest from a dict +upsert_user_vault_item_request_from_dict = UpsertUserVaultItemRequest.from_dict(upsert_user_vault_item_request_dict) +``` +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/UserVaultItem.md b/docs/UserVaultItem.md index 0506a43..63292d8 100644 --- a/docs/UserVaultItem.md +++ b/docs/UserVaultItem.md @@ -1,10 +1,12 @@ # UserVaultItem +Response model for vault reads and writes. Every row has a primary key, so `id` is always present and clients can always address a secret by it. `key` stays an unconstrained str and `value` stays optional so secrets stored before the SSM migration remain listable and readable: enforcing the write rules here would turn one such row into a 500 for the whole listing. Write validation lives in UpsertUserVaultItemRequest. ## Properties Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- +**id** | **int** | | **type** | [**UserVaultType**](UserVaultType.md) | | **key** | **str** | | **value** | **str** | | [optional] diff --git a/docs/VolumeAccessMode.md b/docs/VolumeAccessMode.md index 48ac1f5..27fe5d3 100644 --- a/docs/VolumeAccessMode.md +++ b/docs/VolumeAccessMode.md @@ -3,8 +3,6 @@ ## Enum -* `READWRITEONCE` (value: `'ReadWriteOnce'`) - * `READWRITEMANY` (value: `'ReadWriteMany'`) [[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) diff --git a/docs/VolumeBackend.md b/docs/VolumeBackend.md index bd4ff5e..370828f 100644 --- a/docs/VolumeBackend.md +++ b/docs/VolumeBackend.md @@ -3,7 +3,7 @@ ## Enum -* `BLOCK` (value: `'block'`) +* `FILESYSTEM` (value: `'filesystem'`) * `OBJECT` (value: `'object'`) diff --git a/platform_api_python_client/__init__.py b/platform_api_python_client/__init__.py index 416547b..996c84a 100644 --- a/platform_api_python_client/__init__.py +++ b/platform_api_python_client/__init__.py @@ -14,7 +14,7 @@ """ # noqa: E501 -__version__ = "4.23.1" +__version__ = "4.25.0" # import apis into sdk package from platform_api_python_client.api.external_api import EXTERNALApi @@ -45,7 +45,6 @@ from platform_api_python_client.models.cluster_registration_request import ClusterRegistrationRequest from platform_api_python_client.models.cluster_registration_response import ClusterRegistrationResponse from platform_api_python_client.models.config_file_mount import ConfigFileMount -from platform_api_python_client.models.create_block_volume_request import CreateBlockVolumeRequest from platform_api_python_client.models.create_c_serve_v2_deployment_response import CreateCServeV2DeploymentResponse from platform_api_python_client.models.create_c_serve_v3_deployment_request import CreateCServeV3DeploymentRequest from platform_api_python_client.models.create_c_serve_v3_deployment_response import CreateCServeV3DeploymentResponse @@ -53,6 +52,7 @@ from platform_api_python_client.models.create_compute_deployment_response import CreateComputeDeploymentResponse from platform_api_python_client.models.create_dynamo_deployment_request import CreateDynamoDeploymentRequest from platform_api_python_client.models.create_dynamo_deployment_response import CreateDynamoDeploymentResponse +from platform_api_python_client.models.create_filesystem_volume_request import CreateFilesystemVolumeRequest from platform_api_python_client.models.create_hardware_instance_request import CreateHardwareInstanceRequest from platform_api_python_client.models.create_inference_deployment_response import CreateInferenceDeploymentResponse from platform_api_python_client.models.create_inference_v3_deployment_request import CreateInferenceV3DeploymentRequest @@ -66,7 +66,9 @@ from platform_api_python_client.models.create_volume_request import CreateVolumeRequest from platform_api_python_client.models.credits_response import CreditsResponse from platform_api_python_client.models.daily_bill_response import DailyBillResponse +from platform_api_python_client.models.delete_user_vault_item_request import DeleteUserVaultItemRequest from platform_api_python_client.models.deployment_component_type import DeploymentComponentType +from platform_api_python_client.models.deployment_log_event_v4 import DeploymentLogEventV4 from platform_api_python_client.models.deployment_response import DeploymentResponse from platform_api_python_client.models.deployment_status import DeploymentStatus from platform_api_python_client.models.deployment_status_request import DeploymentStatusRequest @@ -75,20 +77,25 @@ from platform_api_python_client.models.deployment_type import DeploymentType from platform_api_python_client.models.deployment_usage import DeploymentUsage from platform_api_python_client.models.deployment_usage_value import DeploymentUsageValue +from platform_api_python_client.models.dynamo_serving_mode import DynamoServingMode +from platform_api_python_client.models.dynamo_worker_pool_config import DynamoWorkerPoolConfig +from platform_api_python_client.models.dynamo_worker_pools import DynamoWorkerPools from platform_api_python_client.models.external_dns import ExternalDns from platform_api_python_client.models.final_stack import FinalStack from platform_api_python_client.models.fluent_bit import FluentBit from platform_api_python_client.models.generate_service_account_secret_response import GenerateServiceAccountSecretResponse -from platform_api_python_client.models.get_block_volume_response import GetBlockVolumeResponse from platform_api_python_client.models.get_c_serve_v2_deployment_response import GetCServeV2DeploymentResponse from platform_api_python_client.models.get_c_serve_v3_deployment_response import GetCServeV3DeploymentResponse from platform_api_python_client.models.get_cluster_response import GetClusterResponse from platform_api_python_client.models.get_compute_deployment_response import GetComputeDeploymentResponse from platform_api_python_client.models.get_deployment_log_response import GetDeploymentLogResponse +from platform_api_python_client.models.get_deployment_log_v4_response import GetDeploymentLogV4Response +from platform_api_python_client.models.get_deployment_pods_response import GetDeploymentPodsResponse from platform_api_python_client.models.get_deployment_response import GetDeploymentResponse from platform_api_python_client.models.get_deployment_revision_response import GetDeploymentRevisionResponse from platform_api_python_client.models.get_deployment_usage_response import GetDeploymentUsageResponse from platform_api_python_client.models.get_dynamo_deployment_response import GetDynamoDeploymentResponse +from platform_api_python_client.models.get_filesystem_volume_response import GetFilesystemVolumeResponse from platform_api_python_client.models.get_inference_deployment_response import GetInferenceDeploymentResponse from platform_api_python_client.models.get_inference_v3_deployment_response import GetInferenceV3DeploymentResponse from platform_api_python_client.models.get_job_deployment_response import GetJobDeploymentResponse @@ -137,9 +144,11 @@ from platform_api_python_client.models.spire import Spire from platform_api_python_client.models.spire_crds import SpireCrds from platform_api_python_client.models.teleport_kube_agent import TeleportKubeAgent +from platform_api_python_client.models.update_cluster_metadata_request import UpdateClusterMetadataRequest from platform_api_python_client.models.update_deployment_response import UpdateDeploymentResponse from platform_api_python_client.models.update_deployment_status_v3_request import UpdateDeploymentStatusV3Request from platform_api_python_client.models.update_service_account_request import UpdateServiceAccountRequest +from platform_api_python_client.models.upsert_user_vault_item_request import UpsertUserVaultItemRequest from platform_api_python_client.models.user_vault_item import UserVaultItem from platform_api_python_client.models.user_vault_type import UserVaultType from platform_api_python_client.models.validation_error import ValidationError diff --git a/platform_api_python_client/api/external_api.py b/platform_api_python_client/api/external_api.py index 8ea1ec7..0ccba88 100644 --- a/platform_api_python_client/api/external_api.py +++ b/platform_api_python_client/api/external_api.py @@ -17,7 +17,7 @@ from typing_extensions import Annotated from datetime import date -from pydantic import Field, StrictBool, StrictInt, StrictStr +from pydantic import Field, StrictBool, StrictInt, StrictStr, field_validator from typing import Any, Optional from typing_extensions import Annotated from platform_api_python_client.models.cluster_config import ClusterConfig @@ -41,6 +41,7 @@ from platform_api_python_client.models.create_service_account_response import CreateServiceAccountResponse from platform_api_python_client.models.create_volume_request import CreateVolumeRequest from platform_api_python_client.models.credits_response import CreditsResponse +from platform_api_python_client.models.delete_user_vault_item_request import DeleteUserVaultItemRequest from platform_api_python_client.models.deployment_status_request import DeploymentStatusRequest from platform_api_python_client.models.deployment_status_response import DeploymentStatusResponse from platform_api_python_client.models.deployment_status_v3_response import DeploymentStatusV3Response @@ -48,8 +49,11 @@ from platform_api_python_client.models.generate_service_account_secret_response import GenerateServiceAccountSecretResponse from platform_api_python_client.models.get_c_serve_v2_deployment_response import GetCServeV2DeploymentResponse from platform_api_python_client.models.get_c_serve_v3_deployment_response import GetCServeV3DeploymentResponse +from platform_api_python_client.models.get_cluster_response import GetClusterResponse from platform_api_python_client.models.get_compute_deployment_response import GetComputeDeploymentResponse from platform_api_python_client.models.get_deployment_log_response import GetDeploymentLogResponse +from platform_api_python_client.models.get_deployment_log_v4_response import GetDeploymentLogV4Response +from platform_api_python_client.models.get_deployment_pods_response import GetDeploymentPodsResponse from platform_api_python_client.models.get_deployment_revision_response import GetDeploymentRevisionResponse from platform_api_python_client.models.get_deployment_usage_response import GetDeploymentUsageResponse from platform_api_python_client.models.get_dynamo_deployment_response import GetDynamoDeploymentResponse @@ -73,9 +77,11 @@ from platform_api_python_client.models.metric import Metric from platform_api_python_client.models.rollout_strategy_params import RolloutStrategyParams from platform_api_python_client.models.service_account_response import ServiceAccountResponse +from platform_api_python_client.models.update_cluster_metadata_request import UpdateClusterMetadataRequest from platform_api_python_client.models.update_deployment_response import UpdateDeploymentResponse from platform_api_python_client.models.update_deployment_status_v3_request import UpdateDeploymentStatusV3Request from platform_api_python_client.models.update_service_account_request import UpdateServiceAccountRequest +from platform_api_python_client.models.upsert_user_vault_item_request import UpsertUserVaultItemRequest from platform_api_python_client.models.user_vault_item import UserVaultItem from platform_api_python_client.models.user_vault_type import UserVaultType from platform_api_python_client.models.volume_status_response import VolumeStatusResponse @@ -3073,7 +3079,7 @@ def create_volume_endpoint_volumes_post( ) -> GetVolumeResponse: """Create Volume Endpoint - Create a volume. Only the block backend is provisioned; object lands in CCL-147. + Create a volume. Only the filesystem backend is provisioned; object lands in CCL-147. :param create_volume_request: (required) :type create_volume_request: CreateVolumeRequest @@ -3141,7 +3147,7 @@ def create_volume_endpoint_volumes_post_with_http_info( ) -> ApiResponse[GetVolumeResponse]: """Create Volume Endpoint - Create a volume. Only the block backend is provisioned; object lands in CCL-147. + Create a volume. Only the filesystem backend is provisioned; object lands in CCL-147. :param create_volume_request: (required) :type create_volume_request: CreateVolumeRequest @@ -3209,7 +3215,7 @@ def create_volume_endpoint_volumes_post_without_preload_content( ) -> RESTResponseType: """Create Volume Endpoint - Create a volume. Only the block backend is provisioned; object lands in CCL-147. + Create a volume. Only the filesystem backend is provisioned; object lands in CCL-147. :param create_volume_request: (required) :type create_volume_request: CreateVolumeRequest @@ -4114,10 +4120,274 @@ def _delete_service_account_service_accounts_workos_id_delete_serialize( + @validate_call + def delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete( + self, + secret_id: Annotated[int, Field(strict=True, ge=1)], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> object: + """Delete User Vault Item By Id Endpoint + + Delete a vault item by ID. TODO(vault-migration): reject the delete when a selected deployment revision references the secret. Revision-reference tracking lands in a follow-up migration, so nothing is checked yet. + + :param secret_id: (required) + :type secret_id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete_serialize( + secret_id=secret_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "object", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete_with_http_info( + self, + secret_id: Annotated[int, Field(strict=True, ge=1)], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[object]: + """Delete User Vault Item By Id Endpoint + + Delete a vault item by ID. TODO(vault-migration): reject the delete when a selected deployment revision references the secret. Revision-reference tracking lands in a follow-up migration, so nothing is checked yet. + + :param secret_id: (required) + :type secret_id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete_serialize( + secret_id=secret_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "object", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete_without_preload_content( + self, + secret_id: Annotated[int, Field(strict=True, ge=1)], + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """Delete User Vault Item By Id Endpoint + + Delete a vault item by ID. TODO(vault-migration): reject the delete when a selected deployment revision references the secret. Revision-reference tracking lands in a follow-up migration, so nothing is checked yet. + + :param secret_id: (required) + :type secret_id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete_serialize( + secret_id=secret_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "object", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete_serialize( + self, + secret_id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if secret_id is not None: + _path_params['secret_id'] = secret_id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'HTTPBearer' + ] + + return self.api_client.param_serialize( + method='DELETE', + resource_path='/user_vault/{secret_id}', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + @validate_call def delete_user_vault_item_endpoint_user_vault_delete( self, - user_vault_item: UserVaultItem, + delete_user_vault_item_request: DeleteUserVaultItemRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -4131,12 +4401,12 @@ def delete_user_vault_item_endpoint_user_vault_delete( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> object: - """Delete User Vault Item Endpoint + """(Deprecated) Delete User Vault Item Endpoint - Delete an item of a specific type for the user. + Compatibility shim for the legacy type/key/visibility delete body. - :param user_vault_item: (required) - :type user_vault_item: UserVaultItem + :param delete_user_vault_item_request: (required) + :type delete_user_vault_item_request: DeleteUserVaultItemRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -4158,9 +4428,10 @@ def delete_user_vault_item_endpoint_user_vault_delete( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 + warnings.warn("DELETE /user_vault is deprecated.", DeprecationWarning) _param = self._delete_user_vault_item_endpoint_user_vault_delete_serialize( - user_vault_item=user_vault_item, + delete_user_vault_item_request=delete_user_vault_item_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -4185,7 +4456,7 @@ def delete_user_vault_item_endpoint_user_vault_delete( @validate_call def delete_user_vault_item_endpoint_user_vault_delete_with_http_info( self, - user_vault_item: UserVaultItem, + delete_user_vault_item_request: DeleteUserVaultItemRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -4199,12 +4470,12 @@ def delete_user_vault_item_endpoint_user_vault_delete_with_http_info( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> ApiResponse[object]: - """Delete User Vault Item Endpoint + """(Deprecated) Delete User Vault Item Endpoint - Delete an item of a specific type for the user. + Compatibility shim for the legacy type/key/visibility delete body. - :param user_vault_item: (required) - :type user_vault_item: UserVaultItem + :param delete_user_vault_item_request: (required) + :type delete_user_vault_item_request: DeleteUserVaultItemRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -4226,9 +4497,10 @@ def delete_user_vault_item_endpoint_user_vault_delete_with_http_info( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 + warnings.warn("DELETE /user_vault is deprecated.", DeprecationWarning) _param = self._delete_user_vault_item_endpoint_user_vault_delete_serialize( - user_vault_item=user_vault_item, + delete_user_vault_item_request=delete_user_vault_item_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -4253,7 +4525,7 @@ def delete_user_vault_item_endpoint_user_vault_delete_with_http_info( @validate_call def delete_user_vault_item_endpoint_user_vault_delete_without_preload_content( self, - user_vault_item: UserVaultItem, + delete_user_vault_item_request: DeleteUserVaultItemRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -4267,12 +4539,12 @@ def delete_user_vault_item_endpoint_user_vault_delete_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Delete User Vault Item Endpoint + """(Deprecated) Delete User Vault Item Endpoint - Delete an item of a specific type for the user. + Compatibility shim for the legacy type/key/visibility delete body. - :param user_vault_item: (required) - :type user_vault_item: UserVaultItem + :param delete_user_vault_item_request: (required) + :type delete_user_vault_item_request: DeleteUserVaultItemRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -4294,9 +4566,10 @@ def delete_user_vault_item_endpoint_user_vault_delete_without_preload_content( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 + warnings.warn("DELETE /user_vault is deprecated.", DeprecationWarning) _param = self._delete_user_vault_item_endpoint_user_vault_delete_serialize( - user_vault_item=user_vault_item, + delete_user_vault_item_request=delete_user_vault_item_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -4316,7 +4589,7 @@ def delete_user_vault_item_endpoint_user_vault_delete_without_preload_content( def _delete_user_vault_item_endpoint_user_vault_delete_serialize( self, - user_vault_item, + delete_user_vault_item_request, _request_auth, _content_type, _headers, @@ -4342,8 +4615,8 @@ def _delete_user_vault_item_endpoint_user_vault_delete_serialize( # process the header parameters # process the form parameters # process the body parameter - if user_vault_item is not None: - _body_params = user_vault_item + if delete_user_vault_item_request is not None: + _body_params = delete_user_vault_item_request # set the HTTP header `Accept` @@ -4936,7 +5209,7 @@ def get_all_user_vault_items_endpoint_user_vault_get( ) -> ListUserVaultItemsResponse: """Get All User Vault Items Endpoint - Retrieve all items the user has access to (both USER and ORG scoped). + List metadata for every item the user can read, without any secret values. Values are deliberately omitted so browsing the vault never bulk-exposes secrets. Callers that need one value fetch it from the by-id endpoint below. :param type: :type type: UserVaultType @@ -5008,7 +5281,7 @@ def get_all_user_vault_items_endpoint_user_vault_get_with_http_info( ) -> ApiResponse[ListUserVaultItemsResponse]: """Get All User Vault Items Endpoint - Retrieve all items the user has access to (both USER and ORG scoped). + List metadata for every item the user can read, without any secret values. Values are deliberately omitted so browsing the vault never bulk-exposes secrets. Callers that need one value fetch it from the by-id endpoint below. :param type: :type type: UserVaultType @@ -5080,7 +5353,7 @@ def get_all_user_vault_items_endpoint_user_vault_get_without_preload_content( ) -> RESTResponseType: """Get All User Vault Items Endpoint - Retrieve all items the user has access to (both USER and ORG scoped). + List metadata for every item the user can read, without any secret values. Values are deliberately omitted so browsing the vault never bulk-exposes secrets. Callers that need one value fetch it from the by-id endpoint below. :param type: :type type: UserVaultType @@ -5965,7 +6238,7 @@ def get_credits_credits_get( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> CreditsResponse: - """Get Credits + """(Deprecated) Get Credits :param _request_timeout: timeout setting for this request. If one @@ -5989,6 +6262,7 @@ def get_credits_credits_get( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 + warnings.warn("GET /credits is deprecated.", DeprecationWarning) _param = self._get_credits_credits_get_serialize( _request_auth=_request_auth, @@ -6027,7 +6301,7 @@ def get_credits_credits_get_with_http_info( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> ApiResponse[CreditsResponse]: - """Get Credits + """(Deprecated) Get Credits :param _request_timeout: timeout setting for this request. If one @@ -6051,6 +6325,7 @@ def get_credits_credits_get_with_http_info( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 + warnings.warn("GET /credits is deprecated.", DeprecationWarning) _param = self._get_credits_credits_get_serialize( _request_auth=_request_auth, @@ -6089,7 +6364,7 @@ def get_credits_credits_get_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Credits + """(Deprecated) Get Credits :param _request_timeout: timeout setting for this request. If one @@ -6113,6 +6388,7 @@ def get_credits_credits_get_without_preload_content( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 + warnings.warn("GET /credits is deprecated.", DeprecationWarning) _param = self._get_credits_credits_get_serialize( _request_auth=_request_auth, @@ -7702,10 +7978,14 @@ def _get_deployment_logs_v3_deployments_logs_v3_deployment_id_revision_number_ge @validate_call - def get_deployment_revision_deployments_revisions_deployment_id_revision_number_get( + def get_deployment_logs_v4_logs_deployment_id_revision_number_get( self, deployment_id: StrictInt, revision_number: StrictInt, + pod: Annotated[str, Field(strict=True, max_length=253)], + fetch_newer: Optional[StrictBool] = None, + timestamp: Optional[Annotated[int, Field(le=9223372036853, strict=True, ge=0)]] = None, + max_lines: Optional[Annotated[int, Field(le=5000, strict=True, ge=1)]] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -7718,15 +7998,23 @@ def get_deployment_revision_deployments_revisions_deployment_id_revision_number_ _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> GetDeploymentRevisionResponse: - """Get Deployment Revision + ) -> GetDeploymentLogV4Response: + """Get Deployment Logs V4 - Get a specific revision for a deployment. + Retrieve one page of a single pod's logs from Loki, oldest line first. - `pod`: which pod's logs to read; pick a name reported by `/deployments/pods/{deployment_id}/{revision_number}` — a pod unknown to the log store simply yields empty pages. - `fetch_newer`: direction. `false` (default) pages toward older logs, starting from the newest page; `true` fetches newer logs (for follow-polling). - `timestamp`: epoch-millisecond boundary (the events' `timestamp` unit), exclusive in both directions: `fetch_newer=false` returns lines strictly older than that millisecond, `fetch_newer=true` lines strictly newer. Without it both directions scan the whole log window: `fetch_newer=false` starts at the tail (the newest page), `fetch_newer=true` at the head (the oldest page) — to follow live logs, take the tail page first and pass its newest `timestamp`. There is no server-issued page token — mint the boundary from the events themselves (pages never split a millisecond, so a delivered boundary millisecond is always complete): pass the oldest event's `timestamp` to keep paging older, and the newest event `timestamp` seen on any page — history pages included — to fetch newer. An empty `fetch_newer=false` page means history is exhausted; an empty `fetch_newer=true` page means nothing new yet — poll again with the same `timestamp`. - `fetch_newer=true` with a `timestamp` also re-delivers the ~15 seconds at and before it on every poll (late-arriving lines land there), so callers must deduplicate by event `id`; re-delivered lines do not count toward `max_lines`. A span holding more than the log store's 5000-entry query ceiling re-delivers only its newest 5000 lines (the excess is dropped and logged server-side). - `max_lines`: cap on new lines per page — default 100, at most 5000 (the log store's per-query ceiling); a page may exceed it when many lines share one millisecond (such a group is never split across pages, unless it exceeds that same 5000-entry ceiling — the excess is then dropped and logged server-side) or through the re-delivered span. :param deployment_id: (required) :type deployment_id: int :param revision_number: (required) :type revision_number: int + :param pod: (required) + :type pod: str + :param fetch_newer: + :type fetch_newer: bool + :param timestamp: + :type timestamp: int + :param max_lines: + :type max_lines: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -7749,9 +8037,13 @@ def get_deployment_revision_deployments_revisions_deployment_id_revision_number_ :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployment_revision_deployments_revisions_deployment_id_revision_number_get_serialize( + _param = self._get_deployment_logs_v4_logs_deployment_id_revision_number_get_serialize( deployment_id=deployment_id, revision_number=revision_number, + pod=pod, + fetch_newer=fetch_newer, + timestamp=timestamp, + max_lines=max_lines, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -7759,7 +8051,7 @@ def get_deployment_revision_deployments_revisions_deployment_id_revision_number_ ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetDeploymentRevisionResponse", + '200': "GetDeploymentLogV4Response", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -7774,10 +8066,14 @@ def get_deployment_revision_deployments_revisions_deployment_id_revision_number_ @validate_call - def get_deployment_revision_deployments_revisions_deployment_id_revision_number_get_with_http_info( + def get_deployment_logs_v4_logs_deployment_id_revision_number_get_with_http_info( self, deployment_id: StrictInt, revision_number: StrictInt, + pod: Annotated[str, Field(strict=True, max_length=253)], + fetch_newer: Optional[StrictBool] = None, + timestamp: Optional[Annotated[int, Field(le=9223372036853, strict=True, ge=0)]] = None, + max_lines: Optional[Annotated[int, Field(le=5000, strict=True, ge=1)]] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -7790,15 +8086,23 @@ def get_deployment_revision_deployments_revisions_deployment_id_revision_number_ _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[GetDeploymentRevisionResponse]: - """Get Deployment Revision + ) -> ApiResponse[GetDeploymentLogV4Response]: + """Get Deployment Logs V4 - Get a specific revision for a deployment. + Retrieve one page of a single pod's logs from Loki, oldest line first. - `pod`: which pod's logs to read; pick a name reported by `/deployments/pods/{deployment_id}/{revision_number}` — a pod unknown to the log store simply yields empty pages. - `fetch_newer`: direction. `false` (default) pages toward older logs, starting from the newest page; `true` fetches newer logs (for follow-polling). - `timestamp`: epoch-millisecond boundary (the events' `timestamp` unit), exclusive in both directions: `fetch_newer=false` returns lines strictly older than that millisecond, `fetch_newer=true` lines strictly newer. Without it both directions scan the whole log window: `fetch_newer=false` starts at the tail (the newest page), `fetch_newer=true` at the head (the oldest page) — to follow live logs, take the tail page first and pass its newest `timestamp`. There is no server-issued page token — mint the boundary from the events themselves (pages never split a millisecond, so a delivered boundary millisecond is always complete): pass the oldest event's `timestamp` to keep paging older, and the newest event `timestamp` seen on any page — history pages included — to fetch newer. An empty `fetch_newer=false` page means history is exhausted; an empty `fetch_newer=true` page means nothing new yet — poll again with the same `timestamp`. - `fetch_newer=true` with a `timestamp` also re-delivers the ~15 seconds at and before it on every poll (late-arriving lines land there), so callers must deduplicate by event `id`; re-delivered lines do not count toward `max_lines`. A span holding more than the log store's 5000-entry query ceiling re-delivers only its newest 5000 lines (the excess is dropped and logged server-side). - `max_lines`: cap on new lines per page — default 100, at most 5000 (the log store's per-query ceiling); a page may exceed it when many lines share one millisecond (such a group is never split across pages, unless it exceeds that same 5000-entry ceiling — the excess is then dropped and logged server-side) or through the re-delivered span. :param deployment_id: (required) :type deployment_id: int :param revision_number: (required) :type revision_number: int + :param pod: (required) + :type pod: str + :param fetch_newer: + :type fetch_newer: bool + :param timestamp: + :type timestamp: int + :param max_lines: + :type max_lines: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -7821,9 +8125,13 @@ def get_deployment_revision_deployments_revisions_deployment_id_revision_number_ :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployment_revision_deployments_revisions_deployment_id_revision_number_get_serialize( + _param = self._get_deployment_logs_v4_logs_deployment_id_revision_number_get_serialize( deployment_id=deployment_id, revision_number=revision_number, + pod=pod, + fetch_newer=fetch_newer, + timestamp=timestamp, + max_lines=max_lines, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -7831,7 +8139,7 @@ def get_deployment_revision_deployments_revisions_deployment_id_revision_number_ ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetDeploymentRevisionResponse", + '200': "GetDeploymentLogV4Response", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -7846,10 +8154,14 @@ def get_deployment_revision_deployments_revisions_deployment_id_revision_number_ @validate_call - def get_deployment_revision_deployments_revisions_deployment_id_revision_number_get_without_preload_content( + def get_deployment_logs_v4_logs_deployment_id_revision_number_get_without_preload_content( self, deployment_id: StrictInt, revision_number: StrictInt, + pod: Annotated[str, Field(strict=True, max_length=253)], + fetch_newer: Optional[StrictBool] = None, + timestamp: Optional[Annotated[int, Field(le=9223372036853, strict=True, ge=0)]] = None, + max_lines: Optional[Annotated[int, Field(le=5000, strict=True, ge=1)]] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -7863,14 +8175,22 @@ def get_deployment_revision_deployments_revisions_deployment_id_revision_number_ _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Deployment Revision + """Get Deployment Logs V4 - Get a specific revision for a deployment. + Retrieve one page of a single pod's logs from Loki, oldest line first. - `pod`: which pod's logs to read; pick a name reported by `/deployments/pods/{deployment_id}/{revision_number}` — a pod unknown to the log store simply yields empty pages. - `fetch_newer`: direction. `false` (default) pages toward older logs, starting from the newest page; `true` fetches newer logs (for follow-polling). - `timestamp`: epoch-millisecond boundary (the events' `timestamp` unit), exclusive in both directions: `fetch_newer=false` returns lines strictly older than that millisecond, `fetch_newer=true` lines strictly newer. Without it both directions scan the whole log window: `fetch_newer=false` starts at the tail (the newest page), `fetch_newer=true` at the head (the oldest page) — to follow live logs, take the tail page first and pass its newest `timestamp`. There is no server-issued page token — mint the boundary from the events themselves (pages never split a millisecond, so a delivered boundary millisecond is always complete): pass the oldest event's `timestamp` to keep paging older, and the newest event `timestamp` seen on any page — history pages included — to fetch newer. An empty `fetch_newer=false` page means history is exhausted; an empty `fetch_newer=true` page means nothing new yet — poll again with the same `timestamp`. - `fetch_newer=true` with a `timestamp` also re-delivers the ~15 seconds at and before it on every poll (late-arriving lines land there), so callers must deduplicate by event `id`; re-delivered lines do not count toward `max_lines`. A span holding more than the log store's 5000-entry query ceiling re-delivers only its newest 5000 lines (the excess is dropped and logged server-side). - `max_lines`: cap on new lines per page — default 100, at most 5000 (the log store's per-query ceiling); a page may exceed it when many lines share one millisecond (such a group is never split across pages, unless it exceeds that same 5000-entry ceiling — the excess is then dropped and logged server-side) or through the re-delivered span. :param deployment_id: (required) :type deployment_id: int :param revision_number: (required) :type revision_number: int + :param pod: (required) + :type pod: str + :param fetch_newer: + :type fetch_newer: bool + :param timestamp: + :type timestamp: int + :param max_lines: + :type max_lines: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -7893,9 +8213,13 @@ def get_deployment_revision_deployments_revisions_deployment_id_revision_number_ :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployment_revision_deployments_revisions_deployment_id_revision_number_get_serialize( + _param = self._get_deployment_logs_v4_logs_deployment_id_revision_number_get_serialize( deployment_id=deployment_id, revision_number=revision_number, + pod=pod, + fetch_newer=fetch_newer, + timestamp=timestamp, + max_lines=max_lines, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -7903,7 +8227,7 @@ def get_deployment_revision_deployments_revisions_deployment_id_revision_number_ ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetDeploymentRevisionResponse", + '200': "GetDeploymentLogV4Response", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -7913,10 +8237,14 @@ def get_deployment_revision_deployments_revisions_deployment_id_revision_number_ return response_data.response - def _get_deployment_revision_deployments_revisions_deployment_id_revision_number_get_serialize( + def _get_deployment_logs_v4_logs_deployment_id_revision_number_get_serialize( self, deployment_id, revision_number, + pod, + fetch_newer, + timestamp, + max_lines, _request_auth, _content_type, _headers, @@ -7943,9 +8271,25 @@ def _get_deployment_revision_deployments_revisions_deployment_id_revision_number if revision_number is not None: _path_params['revision_number'] = revision_number # process the query parameters - # process the header parameters - # process the form parameters - # process the body parameter + if pod is not None: + + _query_params.append(('pod', pod)) + + if fetch_newer is not None: + + _query_params.append(('fetch_newer', fetch_newer)) + + if timestamp is not None: + + _query_params.append(('timestamp', timestamp)) + + if max_lines is not None: + + _query_params.append(('max_lines', max_lines)) + + # process the header parameters + # process the form parameters + # process the body parameter # set the HTTP header `Accept` @@ -7964,7 +8308,7 @@ def _get_deployment_revision_deployments_revisions_deployment_id_revision_number return self.api_client.param_serialize( method='GET', - resource_path='/deployments/revisions/{deployment_id}/{revision_number}', + resource_path='/logs/{deployment_id}/{revision_number}', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -7981,9 +8325,10 @@ def _get_deployment_revision_deployments_revisions_deployment_id_revision_number @validate_call - def get_deployment_revisions_deployments_revisions_deployment_id_get( + def get_deployment_pods_deployments_pods_deployment_id_revision_number_get( self, deployment_id: StrictInt, + revision_number: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -7996,13 +8341,15 @@ def get_deployment_revisions_deployments_revisions_deployment_id_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ListDeploymentRevisionsResponse: - """Get Deployment Revisions + ) -> GetDeploymentPodsResponse: + """Get Deployment Pods - List all revisions for a deployment. + List the pod names recorded for this revision, recently terminated pods included; the history is bounded to a retention window, so the list can differ from the live pods in status_v3. :param deployment_id: (required) :type deployment_id: int + :param revision_number: (required) + :type revision_number: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -8025,8 +8372,9 @@ def get_deployment_revisions_deployments_revisions_deployment_id_get( :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployment_revisions_deployments_revisions_deployment_id_get_serialize( + _param = self._get_deployment_pods_deployments_pods_deployment_id_revision_number_get_serialize( deployment_id=deployment_id, + revision_number=revision_number, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -8034,7 +8382,7 @@ def get_deployment_revisions_deployments_revisions_deployment_id_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListDeploymentRevisionsResponse", + '200': "GetDeploymentPodsResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -8049,9 +8397,10 @@ def get_deployment_revisions_deployments_revisions_deployment_id_get( @validate_call - def get_deployment_revisions_deployments_revisions_deployment_id_get_with_http_info( + def get_deployment_pods_deployments_pods_deployment_id_revision_number_get_with_http_info( self, deployment_id: StrictInt, + revision_number: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -8064,13 +8413,15 @@ def get_deployment_revisions_deployments_revisions_deployment_id_get_with_http_i _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[ListDeploymentRevisionsResponse]: - """Get Deployment Revisions + ) -> ApiResponse[GetDeploymentPodsResponse]: + """Get Deployment Pods - List all revisions for a deployment. + List the pod names recorded for this revision, recently terminated pods included; the history is bounded to a retention window, so the list can differ from the live pods in status_v3. :param deployment_id: (required) :type deployment_id: int + :param revision_number: (required) + :type revision_number: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -8093,8 +8444,9 @@ def get_deployment_revisions_deployments_revisions_deployment_id_get_with_http_i :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployment_revisions_deployments_revisions_deployment_id_get_serialize( + _param = self._get_deployment_pods_deployments_pods_deployment_id_revision_number_get_serialize( deployment_id=deployment_id, + revision_number=revision_number, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -8102,7 +8454,7 @@ def get_deployment_revisions_deployments_revisions_deployment_id_get_with_http_i ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListDeploymentRevisionsResponse", + '200': "GetDeploymentPodsResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -8117,9 +8469,10 @@ def get_deployment_revisions_deployments_revisions_deployment_id_get_with_http_i @validate_call - def get_deployment_revisions_deployments_revisions_deployment_id_get_without_preload_content( + def get_deployment_pods_deployments_pods_deployment_id_revision_number_get_without_preload_content( self, deployment_id: StrictInt, + revision_number: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -8133,12 +8486,14 @@ def get_deployment_revisions_deployments_revisions_deployment_id_get_without_pre _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Deployment Revisions + """Get Deployment Pods - List all revisions for a deployment. + List the pod names recorded for this revision, recently terminated pods included; the history is bounded to a retention window, so the list can differ from the live pods in status_v3. :param deployment_id: (required) :type deployment_id: int + :param revision_number: (required) + :type revision_number: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -8161,8 +8516,9 @@ def get_deployment_revisions_deployments_revisions_deployment_id_get_without_pre :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployment_revisions_deployments_revisions_deployment_id_get_serialize( + _param = self._get_deployment_pods_deployments_pods_deployment_id_revision_number_get_serialize( deployment_id=deployment_id, + revision_number=revision_number, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -8170,7 +8526,7 @@ def get_deployment_revisions_deployments_revisions_deployment_id_get_without_pre ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListDeploymentRevisionsResponse", + '200': "GetDeploymentPodsResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -8180,9 +8536,10 @@ def get_deployment_revisions_deployments_revisions_deployment_id_get_without_pre return response_data.response - def _get_deployment_revisions_deployments_revisions_deployment_id_get_serialize( + def _get_deployment_pods_deployments_pods_deployment_id_revision_number_get_serialize( self, deployment_id, + revision_number, _request_auth, _content_type, _headers, @@ -8206,6 +8563,8 @@ def _get_deployment_revisions_deployments_revisions_deployment_id_get_serialize( # process the path parameters if deployment_id is not None: _path_params['deployment_id'] = deployment_id + if revision_number is not None: + _path_params['revision_number'] = revision_number # process the query parameters # process the header parameters # process the form parameters @@ -8228,7 +8587,7 @@ def _get_deployment_revisions_deployments_revisions_deployment_id_get_serialize( return self.api_client.param_serialize( method='GET', - resource_path='/deployments/revisions/{deployment_id}', + resource_path='/deployments/pods/{deployment_id}/{revision_number}', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -8245,9 +8604,10 @@ def _get_deployment_revisions_deployments_revisions_deployment_id_get_serialize( @validate_call - def get_deployment_status_deployments_status_deployment_id_get( + def get_deployment_revision_deployments_revisions_deployment_id_revision_number_get( self, deployment_id: StrictInt, + revision_number: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -8260,12 +8620,15 @@ def get_deployment_status_deployments_status_deployment_id_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> DeploymentStatusResponse: - """Get Deployment Status + ) -> GetDeploymentRevisionResponse: + """Get Deployment Revision + Get a specific revision for a deployment. :param deployment_id: (required) :type deployment_id: int + :param revision_number: (required) + :type revision_number: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -8288,8 +8651,9 @@ def get_deployment_status_deployments_status_deployment_id_get( :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployment_status_deployments_status_deployment_id_get_serialize( + _param = self._get_deployment_revision_deployments_revisions_deployment_id_revision_number_get_serialize( deployment_id=deployment_id, + revision_number=revision_number, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -8297,7 +8661,7 @@ def get_deployment_status_deployments_status_deployment_id_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "DeploymentStatusResponse", + '200': "GetDeploymentRevisionResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -8312,9 +8676,10 @@ def get_deployment_status_deployments_status_deployment_id_get( @validate_call - def get_deployment_status_deployments_status_deployment_id_get_with_http_info( + def get_deployment_revision_deployments_revisions_deployment_id_revision_number_get_with_http_info( self, deployment_id: StrictInt, + revision_number: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -8327,12 +8692,15 @@ def get_deployment_status_deployments_status_deployment_id_get_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[DeploymentStatusResponse]: - """Get Deployment Status + ) -> ApiResponse[GetDeploymentRevisionResponse]: + """Get Deployment Revision + Get a specific revision for a deployment. :param deployment_id: (required) :type deployment_id: int + :param revision_number: (required) + :type revision_number: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -8355,8 +8723,9 @@ def get_deployment_status_deployments_status_deployment_id_get_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployment_status_deployments_status_deployment_id_get_serialize( + _param = self._get_deployment_revision_deployments_revisions_deployment_id_revision_number_get_serialize( deployment_id=deployment_id, + revision_number=revision_number, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -8364,7 +8733,7 @@ def get_deployment_status_deployments_status_deployment_id_get_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "DeploymentStatusResponse", + '200': "GetDeploymentRevisionResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -8379,9 +8748,10 @@ def get_deployment_status_deployments_status_deployment_id_get_with_http_info( @validate_call - def get_deployment_status_deployments_status_deployment_id_get_without_preload_content( + def get_deployment_revision_deployments_revisions_deployment_id_revision_number_get_without_preload_content( self, deployment_id: StrictInt, + revision_number: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -8395,11 +8765,14 @@ def get_deployment_status_deployments_status_deployment_id_get_without_preload_c _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Deployment Status + """Get Deployment Revision + Get a specific revision for a deployment. :param deployment_id: (required) :type deployment_id: int + :param revision_number: (required) + :type revision_number: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -8422,8 +8795,9 @@ def get_deployment_status_deployments_status_deployment_id_get_without_preload_c :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployment_status_deployments_status_deployment_id_get_serialize( + _param = self._get_deployment_revision_deployments_revisions_deployment_id_revision_number_get_serialize( deployment_id=deployment_id, + revision_number=revision_number, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -8431,7 +8805,7 @@ def get_deployment_status_deployments_status_deployment_id_get_without_preload_c ) _response_types_map: Dict[str, Optional[str]] = { - '200': "DeploymentStatusResponse", + '200': "GetDeploymentRevisionResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -8441,9 +8815,10 @@ def get_deployment_status_deployments_status_deployment_id_get_without_preload_c return response_data.response - def _get_deployment_status_deployments_status_deployment_id_get_serialize( + def _get_deployment_revision_deployments_revisions_deployment_id_revision_number_get_serialize( self, deployment_id, + revision_number, _request_auth, _content_type, _headers, @@ -8467,6 +8842,8 @@ def _get_deployment_status_deployments_status_deployment_id_get_serialize( # process the path parameters if deployment_id is not None: _path_params['deployment_id'] = deployment_id + if revision_number is not None: + _path_params['revision_number'] = revision_number # process the query parameters # process the header parameters # process the form parameters @@ -8489,7 +8866,7 @@ def _get_deployment_status_deployments_status_deployment_id_get_serialize( return self.api_client.param_serialize( method='GET', - resource_path='/deployments/status/{deployment_id}', + resource_path='/deployments/revisions/{deployment_id}/{revision_number}', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -8506,7 +8883,7 @@ def _get_deployment_status_deployments_status_deployment_id_get_serialize( @validate_call - def get_deployment_status_v3_deployments_status_v3_deployment_id_get( + def get_deployment_revisions_deployments_revisions_deployment_id_get( self, deployment_id: StrictInt, _request_timeout: Union[ @@ -8521,9 +8898,10 @@ def get_deployment_status_v3_deployments_status_v3_deployment_id_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> DeploymentStatusV3Response: - """Get Deployment Status V3 + ) -> ListDeploymentRevisionsResponse: + """Get Deployment Revisions + List all revisions for a deployment. :param deployment_id: (required) :type deployment_id: int @@ -8549,7 +8927,7 @@ def get_deployment_status_v3_deployments_status_v3_deployment_id_get( :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployment_status_v3_deployments_status_v3_deployment_id_get_serialize( + _param = self._get_deployment_revisions_deployments_revisions_deployment_id_get_serialize( deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, @@ -8558,7 +8936,7 @@ def get_deployment_status_v3_deployments_status_v3_deployment_id_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "DeploymentStatusV3Response", + '200': "ListDeploymentRevisionsResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -8573,7 +8951,7 @@ def get_deployment_status_v3_deployments_status_v3_deployment_id_get( @validate_call - def get_deployment_status_v3_deployments_status_v3_deployment_id_get_with_http_info( + def get_deployment_revisions_deployments_revisions_deployment_id_get_with_http_info( self, deployment_id: StrictInt, _request_timeout: Union[ @@ -8588,9 +8966,10 @@ def get_deployment_status_v3_deployments_status_v3_deployment_id_get_with_http_i _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[DeploymentStatusV3Response]: - """Get Deployment Status V3 + ) -> ApiResponse[ListDeploymentRevisionsResponse]: + """Get Deployment Revisions + List all revisions for a deployment. :param deployment_id: (required) :type deployment_id: int @@ -8616,7 +8995,7 @@ def get_deployment_status_v3_deployments_status_v3_deployment_id_get_with_http_i :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployment_status_v3_deployments_status_v3_deployment_id_get_serialize( + _param = self._get_deployment_revisions_deployments_revisions_deployment_id_get_serialize( deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, @@ -8625,7 +9004,7 @@ def get_deployment_status_v3_deployments_status_v3_deployment_id_get_with_http_i ) _response_types_map: Dict[str, Optional[str]] = { - '200': "DeploymentStatusV3Response", + '200': "ListDeploymentRevisionsResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -8640,7 +9019,7 @@ def get_deployment_status_v3_deployments_status_v3_deployment_id_get_with_http_i @validate_call - def get_deployment_status_v3_deployments_status_v3_deployment_id_get_without_preload_content( + def get_deployment_revisions_deployments_revisions_deployment_id_get_without_preload_content( self, deployment_id: StrictInt, _request_timeout: Union[ @@ -8656,8 +9035,9 @@ def get_deployment_status_v3_deployments_status_v3_deployment_id_get_without_pre _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Deployment Status V3 + """Get Deployment Revisions + List all revisions for a deployment. :param deployment_id: (required) :type deployment_id: int @@ -8683,7 +9063,7 @@ def get_deployment_status_v3_deployments_status_v3_deployment_id_get_without_pre :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployment_status_v3_deployments_status_v3_deployment_id_get_serialize( + _param = self._get_deployment_revisions_deployments_revisions_deployment_id_get_serialize( deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, @@ -8692,7 +9072,7 @@ def get_deployment_status_v3_deployments_status_v3_deployment_id_get_without_pre ) _response_types_map: Dict[str, Optional[str]] = { - '200': "DeploymentStatusV3Response", + '200': "ListDeploymentRevisionsResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -8702,7 +9082,7 @@ def get_deployment_status_v3_deployments_status_v3_deployment_id_get_without_pre return response_data.response - def _get_deployment_status_v3_deployments_status_v3_deployment_id_get_serialize( + def _get_deployment_revisions_deployments_revisions_deployment_id_get_serialize( self, deployment_id, _request_auth, @@ -8750,7 +9130,7 @@ def _get_deployment_status_v3_deployments_status_v3_deployment_id_get_serialize( return self.api_client.param_serialize( method='GET', - resource_path='/deployments/status_v3/{deployment_id}', + resource_path='/deployments/revisions/{deployment_id}', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -8767,12 +9147,9 @@ def _get_deployment_status_v3_deployments_status_v3_deployment_id_get_serialize( @validate_call - def get_deployments_deployments_get( + def get_deployment_status_deployments_status_deployment_id_get( self, - offset: Optional[Annotated[int, Field(strict=True, ge=0)]] = None, - limit: Optional[Annotated[int, Field(strict=True, ge=0)]] = None, - type: Optional[DeploymentType] = None, - search_query: Optional[StrictStr] = None, + deployment_id: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -8785,18 +9162,12 @@ def get_deployments_deployments_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ListGetDeploymentResponse: - """Get Deployments + ) -> DeploymentStatusResponse: + """Get Deployment Status - :param offset: - :type offset: int - :param limit: - :type limit: int - :param type: - :type type: DeploymentType - :param search_query: - :type search_query: str + :param deployment_id: (required) + :type deployment_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -8819,11 +9190,8 @@ def get_deployments_deployments_get( :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployments_deployments_get_serialize( - offset=offset, - limit=limit, - type=type, - search_query=search_query, + _param = self._get_deployment_status_deployments_status_deployment_id_get_serialize( + deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -8831,7 +9199,7 @@ def get_deployments_deployments_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListGetDeploymentResponse", + '200': "DeploymentStatusResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -8846,12 +9214,9 @@ def get_deployments_deployments_get( @validate_call - def get_deployments_deployments_get_with_http_info( + def get_deployment_status_deployments_status_deployment_id_get_with_http_info( self, - offset: Optional[Annotated[int, Field(strict=True, ge=0)]] = None, - limit: Optional[Annotated[int, Field(strict=True, ge=0)]] = None, - type: Optional[DeploymentType] = None, - search_query: Optional[StrictStr] = None, + deployment_id: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -8864,18 +9229,12 @@ def get_deployments_deployments_get_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[ListGetDeploymentResponse]: - """Get Deployments + ) -> ApiResponse[DeploymentStatusResponse]: + """Get Deployment Status - :param offset: - :type offset: int - :param limit: - :type limit: int - :param type: - :type type: DeploymentType - :param search_query: - :type search_query: str + :param deployment_id: (required) + :type deployment_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -8898,11 +9257,8 @@ def get_deployments_deployments_get_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployments_deployments_get_serialize( - offset=offset, - limit=limit, - type=type, - search_query=search_query, + _param = self._get_deployment_status_deployments_status_deployment_id_get_serialize( + deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -8910,7 +9266,7 @@ def get_deployments_deployments_get_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListGetDeploymentResponse", + '200': "DeploymentStatusResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -8925,12 +9281,9 @@ def get_deployments_deployments_get_with_http_info( @validate_call - def get_deployments_deployments_get_without_preload_content( + def get_deployment_status_deployments_status_deployment_id_get_without_preload_content( self, - offset: Optional[Annotated[int, Field(strict=True, ge=0)]] = None, - limit: Optional[Annotated[int, Field(strict=True, ge=0)]] = None, - type: Optional[DeploymentType] = None, - search_query: Optional[StrictStr] = None, + deployment_id: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -8944,17 +9297,11 @@ def get_deployments_deployments_get_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Deployments + """Get Deployment Status - :param offset: - :type offset: int - :param limit: - :type limit: int - :param type: - :type type: DeploymentType - :param search_query: - :type search_query: str + :param deployment_id: (required) + :type deployment_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -8977,11 +9324,8 @@ def get_deployments_deployments_get_without_preload_content( :return: Returns the result object. """ # noqa: E501 - _param = self._get_deployments_deployments_get_serialize( - offset=offset, - limit=limit, - type=type, - search_query=search_query, + _param = self._get_deployment_status_deployments_status_deployment_id_get_serialize( + deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -8989,7 +9333,7 @@ def get_deployments_deployments_get_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListGetDeploymentResponse", + '200': "DeploymentStatusResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -8999,12 +9343,9 @@ def get_deployments_deployments_get_without_preload_content( return response_data.response - def _get_deployments_deployments_get_serialize( + def _get_deployment_status_deployments_status_deployment_id_get_serialize( self, - offset, - limit, - type, - search_query, + deployment_id, _request_auth, _content_type, _headers, @@ -9026,23 +9367,9 @@ def _get_deployments_deployments_get_serialize( _body_params: Optional[bytes] = None # process the path parameters + if deployment_id is not None: + _path_params['deployment_id'] = deployment_id # process the query parameters - if offset is not None: - - _query_params.append(('offset', offset)) - - if limit is not None: - - _query_params.append(('limit', limit)) - - if type is not None: - - _query_params.append(('type', type.value)) - - if search_query is not None: - - _query_params.append(('search_query', search_query)) - # process the header parameters # process the form parameters # process the body parameter @@ -9064,7 +9391,7 @@ def _get_deployments_deployments_get_serialize( return self.api_client.param_serialize( method='GET', - resource_path='/deployments', + resource_path='/deployments/status/{deployment_id}', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -9081,7 +9408,7 @@ def _get_deployments_deployments_get_serialize( @validate_call - def get_dynamo_deployment_deployments_dynamo_deployment_id_get( + def get_deployment_status_v3_deployments_status_v3_deployment_id_get( self, deployment_id: StrictInt, _request_timeout: Union[ @@ -9096,8 +9423,8 @@ def get_dynamo_deployment_deployments_dynamo_deployment_id_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> GetDynamoDeploymentResponse: - """Get Dynamo Deployment + ) -> DeploymentStatusV3Response: + """Get Deployment Status V3 :param deployment_id: (required) @@ -9124,7 +9451,7 @@ def get_dynamo_deployment_deployments_dynamo_deployment_id_get( :return: Returns the result object. """ # noqa: E501 - _param = self._get_dynamo_deployment_deployments_dynamo_deployment_id_get_serialize( + _param = self._get_deployment_status_v3_deployments_status_v3_deployment_id_get_serialize( deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, @@ -9133,7 +9460,7 @@ def get_dynamo_deployment_deployments_dynamo_deployment_id_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetDynamoDeploymentResponse", + '200': "DeploymentStatusV3Response", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -9148,7 +9475,7 @@ def get_dynamo_deployment_deployments_dynamo_deployment_id_get( @validate_call - def get_dynamo_deployment_deployments_dynamo_deployment_id_get_with_http_info( + def get_deployment_status_v3_deployments_status_v3_deployment_id_get_with_http_info( self, deployment_id: StrictInt, _request_timeout: Union[ @@ -9163,8 +9490,8 @@ def get_dynamo_deployment_deployments_dynamo_deployment_id_get_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[GetDynamoDeploymentResponse]: - """Get Dynamo Deployment + ) -> ApiResponse[DeploymentStatusV3Response]: + """Get Deployment Status V3 :param deployment_id: (required) @@ -9191,7 +9518,7 @@ def get_dynamo_deployment_deployments_dynamo_deployment_id_get_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._get_dynamo_deployment_deployments_dynamo_deployment_id_get_serialize( + _param = self._get_deployment_status_v3_deployments_status_v3_deployment_id_get_serialize( deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, @@ -9200,7 +9527,7 @@ def get_dynamo_deployment_deployments_dynamo_deployment_id_get_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetDynamoDeploymentResponse", + '200': "DeploymentStatusV3Response", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -9215,7 +9542,7 @@ def get_dynamo_deployment_deployments_dynamo_deployment_id_get_with_http_info( @validate_call - def get_dynamo_deployment_deployments_dynamo_deployment_id_get_without_preload_content( + def get_deployment_status_v3_deployments_status_v3_deployment_id_get_without_preload_content( self, deployment_id: StrictInt, _request_timeout: Union[ @@ -9231,7 +9558,7 @@ def get_dynamo_deployment_deployments_dynamo_deployment_id_get_without_preload_c _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Dynamo Deployment + """Get Deployment Status V3 :param deployment_id: (required) @@ -9258,7 +9585,7 @@ def get_dynamo_deployment_deployments_dynamo_deployment_id_get_without_preload_c :return: Returns the result object. """ # noqa: E501 - _param = self._get_dynamo_deployment_deployments_dynamo_deployment_id_get_serialize( + _param = self._get_deployment_status_v3_deployments_status_v3_deployment_id_get_serialize( deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, @@ -9267,7 +9594,7 @@ def get_dynamo_deployment_deployments_dynamo_deployment_id_get_without_preload_c ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetDynamoDeploymentResponse", + '200': "DeploymentStatusV3Response", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -9277,7 +9604,7 @@ def get_dynamo_deployment_deployments_dynamo_deployment_id_get_without_preload_c return response_data.response - def _get_dynamo_deployment_deployments_dynamo_deployment_id_get_serialize( + def _get_deployment_status_v3_deployments_status_v3_deployment_id_get_serialize( self, deployment_id, _request_auth, @@ -9325,7 +9652,7 @@ def _get_dynamo_deployment_deployments_dynamo_deployment_id_get_serialize( return self.api_client.param_serialize( method='GET', - resource_path='/deployments/dynamo/{deployment_id}', + resource_path='/deployments/status_v3/{deployment_id}', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -9342,9 +9669,12 @@ def _get_dynamo_deployment_deployments_dynamo_deployment_id_get_serialize( @validate_call - def get_hardware_instances_hardware_instances_get( + def get_deployments_deployments_get( self, - cluster_id: Optional[StrictInt] = None, + offset: Optional[Annotated[int, Field(strict=True, ge=0)]] = None, + limit: Optional[Annotated[int, Field(strict=True, ge=0)]] = None, + type: Optional[DeploymentType] = None, + search_query: Optional[StrictStr] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -9357,12 +9687,18 @@ def get_hardware_instances_hardware_instances_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ListHardwareInstanceResponse: - """Get Hardware Instances + ) -> ListGetDeploymentResponse: + """Get Deployments - :param cluster_id: - :type cluster_id: int + :param offset: + :type offset: int + :param limit: + :type limit: int + :param type: + :type type: DeploymentType + :param search_query: + :type search_query: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -9385,8 +9721,11 @@ def get_hardware_instances_hardware_instances_get( :return: Returns the result object. """ # noqa: E501 - _param = self._get_hardware_instances_hardware_instances_get_serialize( - cluster_id=cluster_id, + _param = self._get_deployments_deployments_get_serialize( + offset=offset, + limit=limit, + type=type, + search_query=search_query, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -9394,7 +9733,7 @@ def get_hardware_instances_hardware_instances_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListHardwareInstanceResponse", + '200': "ListGetDeploymentResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -9409,9 +9748,12 @@ def get_hardware_instances_hardware_instances_get( @validate_call - def get_hardware_instances_hardware_instances_get_with_http_info( + def get_deployments_deployments_get_with_http_info( self, - cluster_id: Optional[StrictInt] = None, + offset: Optional[Annotated[int, Field(strict=True, ge=0)]] = None, + limit: Optional[Annotated[int, Field(strict=True, ge=0)]] = None, + type: Optional[DeploymentType] = None, + search_query: Optional[StrictStr] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -9424,12 +9766,18 @@ def get_hardware_instances_hardware_instances_get_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[ListHardwareInstanceResponse]: - """Get Hardware Instances + ) -> ApiResponse[ListGetDeploymentResponse]: + """Get Deployments - :param cluster_id: - :type cluster_id: int + :param offset: + :type offset: int + :param limit: + :type limit: int + :param type: + :type type: DeploymentType + :param search_query: + :type search_query: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -9452,8 +9800,11 @@ def get_hardware_instances_hardware_instances_get_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._get_hardware_instances_hardware_instances_get_serialize( - cluster_id=cluster_id, + _param = self._get_deployments_deployments_get_serialize( + offset=offset, + limit=limit, + type=type, + search_query=search_query, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -9461,7 +9812,7 @@ def get_hardware_instances_hardware_instances_get_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListHardwareInstanceResponse", + '200': "ListGetDeploymentResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -9476,9 +9827,12 @@ def get_hardware_instances_hardware_instances_get_with_http_info( @validate_call - def get_hardware_instances_hardware_instances_get_without_preload_content( + def get_deployments_deployments_get_without_preload_content( self, - cluster_id: Optional[StrictInt] = None, + offset: Optional[Annotated[int, Field(strict=True, ge=0)]] = None, + limit: Optional[Annotated[int, Field(strict=True, ge=0)]] = None, + type: Optional[DeploymentType] = None, + search_query: Optional[StrictStr] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -9492,11 +9846,17 @@ def get_hardware_instances_hardware_instances_get_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Hardware Instances + """Get Deployments - :param cluster_id: - :type cluster_id: int + :param offset: + :type offset: int + :param limit: + :type limit: int + :param type: + :type type: DeploymentType + :param search_query: + :type search_query: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -9519,8 +9879,11 @@ def get_hardware_instances_hardware_instances_get_without_preload_content( :return: Returns the result object. """ # noqa: E501 - _param = self._get_hardware_instances_hardware_instances_get_serialize( - cluster_id=cluster_id, + _param = self._get_deployments_deployments_get_serialize( + offset=offset, + limit=limit, + type=type, + search_query=search_query, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -9528,7 +9891,7 @@ def get_hardware_instances_hardware_instances_get_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListHardwareInstanceResponse", + '200': "ListGetDeploymentResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -9538,9 +9901,12 @@ def get_hardware_instances_hardware_instances_get_without_preload_content( return response_data.response - def _get_hardware_instances_hardware_instances_get_serialize( + def _get_deployments_deployments_get_serialize( self, - cluster_id, + offset, + limit, + type, + search_query, _request_auth, _content_type, _headers, @@ -9563,9 +9929,21 @@ def _get_hardware_instances_hardware_instances_get_serialize( # process the path parameters # process the query parameters - if cluster_id is not None: + if offset is not None: - _query_params.append(('cluster_id', cluster_id)) + _query_params.append(('offset', offset)) + + if limit is not None: + + _query_params.append(('limit', limit)) + + if type is not None: + + _query_params.append(('type', type.value)) + + if search_query is not None: + + _query_params.append(('search_query', search_query)) # process the header parameters # process the form parameters @@ -9588,7 +9966,7 @@ def _get_hardware_instances_hardware_instances_get_serialize( return self.api_client.param_serialize( method='GET', - resource_path='/hardware-instances', + resource_path='/deployments', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -9605,7 +9983,7 @@ def _get_hardware_instances_hardware_instances_get_serialize( @validate_call - def get_inference_deployment_deployments_inference_deployment_id_get( + def get_dynamo_deployment_deployments_dynamo_deployment_id_get( self, deployment_id: StrictInt, _request_timeout: Union[ @@ -9620,8 +9998,8 @@ def get_inference_deployment_deployments_inference_deployment_id_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> GetInferenceDeploymentResponse: - """Get Inference Deployment + ) -> GetDynamoDeploymentResponse: + """Get Dynamo Deployment :param deployment_id: (required) @@ -9648,7 +10026,7 @@ def get_inference_deployment_deployments_inference_deployment_id_get( :return: Returns the result object. """ # noqa: E501 - _param = self._get_inference_deployment_deployments_inference_deployment_id_get_serialize( + _param = self._get_dynamo_deployment_deployments_dynamo_deployment_id_get_serialize( deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, @@ -9657,7 +10035,7 @@ def get_inference_deployment_deployments_inference_deployment_id_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetInferenceDeploymentResponse", + '200': "GetDynamoDeploymentResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -9672,7 +10050,7 @@ def get_inference_deployment_deployments_inference_deployment_id_get( @validate_call - def get_inference_deployment_deployments_inference_deployment_id_get_with_http_info( + def get_dynamo_deployment_deployments_dynamo_deployment_id_get_with_http_info( self, deployment_id: StrictInt, _request_timeout: Union[ @@ -9687,8 +10065,8 @@ def get_inference_deployment_deployments_inference_deployment_id_get_with_http_i _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[GetInferenceDeploymentResponse]: - """Get Inference Deployment + ) -> ApiResponse[GetDynamoDeploymentResponse]: + """Get Dynamo Deployment :param deployment_id: (required) @@ -9715,7 +10093,7 @@ def get_inference_deployment_deployments_inference_deployment_id_get_with_http_i :return: Returns the result object. """ # noqa: E501 - _param = self._get_inference_deployment_deployments_inference_deployment_id_get_serialize( + _param = self._get_dynamo_deployment_deployments_dynamo_deployment_id_get_serialize( deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, @@ -9724,7 +10102,7 @@ def get_inference_deployment_deployments_inference_deployment_id_get_with_http_i ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetInferenceDeploymentResponse", + '200': "GetDynamoDeploymentResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -9739,7 +10117,7 @@ def get_inference_deployment_deployments_inference_deployment_id_get_with_http_i @validate_call - def get_inference_deployment_deployments_inference_deployment_id_get_without_preload_content( + def get_dynamo_deployment_deployments_dynamo_deployment_id_get_without_preload_content( self, deployment_id: StrictInt, _request_timeout: Union[ @@ -9755,7 +10133,7 @@ def get_inference_deployment_deployments_inference_deployment_id_get_without_pre _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Inference Deployment + """Get Dynamo Deployment :param deployment_id: (required) @@ -9782,7 +10160,7 @@ def get_inference_deployment_deployments_inference_deployment_id_get_without_pre :return: Returns the result object. """ # noqa: E501 - _param = self._get_inference_deployment_deployments_inference_deployment_id_get_serialize( + _param = self._get_dynamo_deployment_deployments_dynamo_deployment_id_get_serialize( deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, @@ -9791,7 +10169,7 @@ def get_inference_deployment_deployments_inference_deployment_id_get_without_pre ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetInferenceDeploymentResponse", + '200': "GetDynamoDeploymentResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -9801,7 +10179,7 @@ def get_inference_deployment_deployments_inference_deployment_id_get_without_pre return response_data.response - def _get_inference_deployment_deployments_inference_deployment_id_get_serialize( + def _get_dynamo_deployment_deployments_dynamo_deployment_id_get_serialize( self, deployment_id, _request_auth, @@ -9849,7 +10227,7 @@ def _get_inference_deployment_deployments_inference_deployment_id_get_serialize( return self.api_client.param_serialize( method='GET', - resource_path='/deployments/inference/{deployment_id}', + resource_path='/deployments/dynamo/{deployment_id}', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -9866,9 +10244,9 @@ def _get_inference_deployment_deployments_inference_deployment_id_get_serialize( @validate_call - def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get( + def get_hardware_instances_hardware_instances_get( self, - deployment_id: StrictInt, + cluster_id: Optional[StrictInt] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -9881,12 +10259,12 @@ def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> GetInferenceV3DeploymentResponse: - """Get Inference V3 Deployment + ) -> ListHardwareInstanceResponse: + """Get Hardware Instances - :param deployment_id: (required) - :type deployment_id: int + :param cluster_id: + :type cluster_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -9909,8 +10287,8 @@ def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get( :return: Returns the result object. """ # noqa: E501 - _param = self._get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_serialize( - deployment_id=deployment_id, + _param = self._get_hardware_instances_hardware_instances_get_serialize( + cluster_id=cluster_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -9918,7 +10296,7 @@ def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetInferenceV3DeploymentResponse", + '200': "ListHardwareInstanceResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -9933,9 +10311,9 @@ def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get( @validate_call - def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_with_http_info( + def get_hardware_instances_hardware_instances_get_with_http_info( self, - deployment_id: StrictInt, + cluster_id: Optional[StrictInt] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -9948,12 +10326,12 @@ def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_with_ _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[GetInferenceV3DeploymentResponse]: - """Get Inference V3 Deployment + ) -> ApiResponse[ListHardwareInstanceResponse]: + """Get Hardware Instances - :param deployment_id: (required) - :type deployment_id: int + :param cluster_id: + :type cluster_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -9976,8 +10354,8 @@ def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_with_ :return: Returns the result object. """ # noqa: E501 - _param = self._get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_serialize( - deployment_id=deployment_id, + _param = self._get_hardware_instances_hardware_instances_get_serialize( + cluster_id=cluster_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -9985,7 +10363,7 @@ def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_with_ ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetInferenceV3DeploymentResponse", + '200': "ListHardwareInstanceResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -10000,9 +10378,9 @@ def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_with_ @validate_call - def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_without_preload_content( + def get_hardware_instances_hardware_instances_get_without_preload_content( self, - deployment_id: StrictInt, + cluster_id: Optional[StrictInt] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -10016,11 +10394,11 @@ def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_witho _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Inference V3 Deployment + """Get Hardware Instances - :param deployment_id: (required) - :type deployment_id: int + :param cluster_id: + :type cluster_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -10043,8 +10421,8 @@ def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_witho :return: Returns the result object. """ # noqa: E501 - _param = self._get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_serialize( - deployment_id=deployment_id, + _param = self._get_hardware_instances_hardware_instances_get_serialize( + cluster_id=cluster_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -10052,7 +10430,7 @@ def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_witho ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetInferenceV3DeploymentResponse", + '200': "ListHardwareInstanceResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -10062,9 +10440,9 @@ def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_witho return response_data.response - def _get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_serialize( + def _get_hardware_instances_hardware_instances_get_serialize( self, - deployment_id, + cluster_id, _request_auth, _content_type, _headers, @@ -10086,9 +10464,11 @@ def _get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_seri _body_params: Optional[bytes] = None # process the path parameters - if deployment_id is not None: - _path_params['deployment_id'] = deployment_id # process the query parameters + if cluster_id is not None: + + _query_params.append(('cluster_id', cluster_id)) + # process the header parameters # process the form parameters # process the body parameter @@ -10110,7 +10490,7 @@ def _get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_seri return self.api_client.param_serialize( method='GET', - resource_path='/deployments/inference_v3/{deployment_id}', + resource_path='/hardware-instances', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -10127,7 +10507,7 @@ def _get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_seri @validate_call - def get_job_deployment_deployments_job_deployment_id_get( + def get_inference_deployment_deployments_inference_deployment_id_get( self, deployment_id: StrictInt, _request_timeout: Union[ @@ -10142,8 +10522,8 @@ def get_job_deployment_deployments_job_deployment_id_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> GetJobDeploymentResponse: - """Get Job Deployment + ) -> GetInferenceDeploymentResponse: + """Get Inference Deployment :param deployment_id: (required) @@ -10170,7 +10550,7 @@ def get_job_deployment_deployments_job_deployment_id_get( :return: Returns the result object. """ # noqa: E501 - _param = self._get_job_deployment_deployments_job_deployment_id_get_serialize( + _param = self._get_inference_deployment_deployments_inference_deployment_id_get_serialize( deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, @@ -10179,7 +10559,7 @@ def get_job_deployment_deployments_job_deployment_id_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetJobDeploymentResponse", + '200': "GetInferenceDeploymentResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -10194,7 +10574,7 @@ def get_job_deployment_deployments_job_deployment_id_get( @validate_call - def get_job_deployment_deployments_job_deployment_id_get_with_http_info( + def get_inference_deployment_deployments_inference_deployment_id_get_with_http_info( self, deployment_id: StrictInt, _request_timeout: Union[ @@ -10209,8 +10589,8 @@ def get_job_deployment_deployments_job_deployment_id_get_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[GetJobDeploymentResponse]: - """Get Job Deployment + ) -> ApiResponse[GetInferenceDeploymentResponse]: + """Get Inference Deployment :param deployment_id: (required) @@ -10237,7 +10617,7 @@ def get_job_deployment_deployments_job_deployment_id_get_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._get_job_deployment_deployments_job_deployment_id_get_serialize( + _param = self._get_inference_deployment_deployments_inference_deployment_id_get_serialize( deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, @@ -10246,7 +10626,7 @@ def get_job_deployment_deployments_job_deployment_id_get_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetJobDeploymentResponse", + '200': "GetInferenceDeploymentResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -10261,7 +10641,7 @@ def get_job_deployment_deployments_job_deployment_id_get_with_http_info( @validate_call - def get_job_deployment_deployments_job_deployment_id_get_without_preload_content( + def get_inference_deployment_deployments_inference_deployment_id_get_without_preload_content( self, deployment_id: StrictInt, _request_timeout: Union[ @@ -10277,7 +10657,7 @@ def get_job_deployment_deployments_job_deployment_id_get_without_preload_content _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Job Deployment + """Get Inference Deployment :param deployment_id: (required) @@ -10304,7 +10684,7 @@ def get_job_deployment_deployments_job_deployment_id_get_without_preload_content :return: Returns the result object. """ # noqa: E501 - _param = self._get_job_deployment_deployments_job_deployment_id_get_serialize( + _param = self._get_inference_deployment_deployments_inference_deployment_id_get_serialize( deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, @@ -10313,7 +10693,7 @@ def get_job_deployment_deployments_job_deployment_id_get_without_preload_content ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetJobDeploymentResponse", + '200': "GetInferenceDeploymentResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -10323,7 +10703,7 @@ def get_job_deployment_deployments_job_deployment_id_get_without_preload_content return response_data.response - def _get_job_deployment_deployments_job_deployment_id_get_serialize( + def _get_inference_deployment_deployments_inference_deployment_id_get_serialize( self, deployment_id, _request_auth, @@ -10371,7 +10751,7 @@ def _get_job_deployment_deployments_job_deployment_id_get_serialize( return self.api_client.param_serialize( method='GET', - resource_path='/deployments/job/{deployment_id}', + resource_path='/deployments/inference/{deployment_id}', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -10388,9 +10768,9 @@ def _get_job_deployment_deployments_job_deployment_id_get_serialize( @validate_call - def get_prebuilt_images_prebuilt_images_get( + def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get( self, - type: Optional[DeploymentType] = None, + deployment_id: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -10403,12 +10783,12 @@ def get_prebuilt_images_prebuilt_images_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ListPrebuiltImageResponse: - """Get Prebuilt Images + ) -> GetInferenceV3DeploymentResponse: + """Get Inference V3 Deployment - :param type: - :type type: DeploymentType + :param deployment_id: (required) + :type deployment_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -10431,8 +10811,8 @@ def get_prebuilt_images_prebuilt_images_get( :return: Returns the result object. """ # noqa: E501 - _param = self._get_prebuilt_images_prebuilt_images_get_serialize( - type=type, + _param = self._get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_serialize( + deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -10440,7 +10820,7 @@ def get_prebuilt_images_prebuilt_images_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListPrebuiltImageResponse", + '200': "GetInferenceV3DeploymentResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -10455,9 +10835,9 @@ def get_prebuilt_images_prebuilt_images_get( @validate_call - def get_prebuilt_images_prebuilt_images_get_with_http_info( + def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_with_http_info( self, - type: Optional[DeploymentType] = None, + deployment_id: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -10470,12 +10850,12 @@ def get_prebuilt_images_prebuilt_images_get_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[ListPrebuiltImageResponse]: - """Get Prebuilt Images + ) -> ApiResponse[GetInferenceV3DeploymentResponse]: + """Get Inference V3 Deployment - :param type: - :type type: DeploymentType + :param deployment_id: (required) + :type deployment_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -10498,8 +10878,8 @@ def get_prebuilt_images_prebuilt_images_get_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._get_prebuilt_images_prebuilt_images_get_serialize( - type=type, + _param = self._get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_serialize( + deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -10507,7 +10887,7 @@ def get_prebuilt_images_prebuilt_images_get_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListPrebuiltImageResponse", + '200': "GetInferenceV3DeploymentResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -10522,9 +10902,9 @@ def get_prebuilt_images_prebuilt_images_get_with_http_info( @validate_call - def get_prebuilt_images_prebuilt_images_get_without_preload_content( + def get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_without_preload_content( self, - type: Optional[DeploymentType] = None, + deployment_id: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -10538,11 +10918,11 @@ def get_prebuilt_images_prebuilt_images_get_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Prebuilt Images + """Get Inference V3 Deployment - :param type: - :type type: DeploymentType + :param deployment_id: (required) + :type deployment_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -10565,8 +10945,8 @@ def get_prebuilt_images_prebuilt_images_get_without_preload_content( :return: Returns the result object. """ # noqa: E501 - _param = self._get_prebuilt_images_prebuilt_images_get_serialize( - type=type, + _param = self._get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_serialize( + deployment_id=deployment_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -10574,7 +10954,7 @@ def get_prebuilt_images_prebuilt_images_get_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListPrebuiltImageResponse", + '200': "GetInferenceV3DeploymentResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -10584,9 +10964,9 @@ def get_prebuilt_images_prebuilt_images_get_without_preload_content( return response_data.response - def _get_prebuilt_images_prebuilt_images_get_serialize( + def _get_inference_v3_deployment_deployments_inference_v3_deployment_id_get_serialize( self, - type, + deployment_id, _request_auth, _content_type, _headers, @@ -10608,10 +10988,1162 @@ def _get_prebuilt_images_prebuilt_images_get_serialize( _body_params: Optional[bytes] = None # process the path parameters + if deployment_id is not None: + _path_params['deployment_id'] = deployment_id # process the query parameters - if type is not None: + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'HTTPBearer' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/deployments/inference_v3/{deployment_id}', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def get_job_deployment_deployments_job_deployment_id_get( + self, + deployment_id: StrictInt, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GetJobDeploymentResponse: + """Get Job Deployment + + + :param deployment_id: (required) + :type deployment_id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_job_deployment_deployments_job_deployment_id_get_serialize( + deployment_id=deployment_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GetJobDeploymentResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def get_job_deployment_deployments_job_deployment_id_get_with_http_info( + self, + deployment_id: StrictInt, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GetJobDeploymentResponse]: + """Get Job Deployment + + + :param deployment_id: (required) + :type deployment_id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_job_deployment_deployments_job_deployment_id_get_serialize( + deployment_id=deployment_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GetJobDeploymentResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def get_job_deployment_deployments_job_deployment_id_get_without_preload_content( + self, + deployment_id: StrictInt, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """Get Job Deployment + + + :param deployment_id: (required) + :type deployment_id: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_job_deployment_deployments_job_deployment_id_get_serialize( + deployment_id=deployment_id, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GetJobDeploymentResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _get_job_deployment_deployments_job_deployment_id_get_serialize( + self, + deployment_id, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if deployment_id is not None: + _path_params['deployment_id'] = deployment_id + # process the query parameters + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'HTTPBearer' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/deployments/job/{deployment_id}', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def get_prebuilt_images_prebuilt_images_get( + self, + type: Optional[DeploymentType] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ListPrebuiltImageResponse: + """Get Prebuilt Images + + + :param type: + :type type: DeploymentType + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_prebuilt_images_prebuilt_images_get_serialize( + type=type, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ListPrebuiltImageResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def get_prebuilt_images_prebuilt_images_get_with_http_info( + self, + type: Optional[DeploymentType] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ListPrebuiltImageResponse]: + """Get Prebuilt Images + + + :param type: + :type type: DeploymentType + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_prebuilt_images_prebuilt_images_get_serialize( + type=type, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ListPrebuiltImageResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def get_prebuilt_images_prebuilt_images_get_without_preload_content( + self, + type: Optional[DeploymentType] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """Get Prebuilt Images + + + :param type: + :type type: DeploymentType + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_prebuilt_images_prebuilt_images_get_serialize( + type=type, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ListPrebuiltImageResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _get_prebuilt_images_prebuilt_images_get_serialize( + self, + type, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if type is not None: + + _query_params.append(('type', type.value)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'HTTPBearer' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/prebuilt-images', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def get_usage_daily_bills_get( + self, + start_date: date, + end_date: date, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ListDailyBillResponse: + """(Deprecated) Get Usage + + + :param start_date: (required) + :type start_date: date + :param end_date: (required) + :type end_date: date + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + warnings.warn("GET /daily_bills is deprecated.", DeprecationWarning) + + _param = self._get_usage_daily_bills_get_serialize( + start_date=start_date, + end_date=end_date, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ListDailyBillResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def get_usage_daily_bills_get_with_http_info( + self, + start_date: date, + end_date: date, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[ListDailyBillResponse]: + """(Deprecated) Get Usage + + + :param start_date: (required) + :type start_date: date + :param end_date: (required) + :type end_date: date + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + warnings.warn("GET /daily_bills is deprecated.", DeprecationWarning) + + _param = self._get_usage_daily_bills_get_serialize( + start_date=start_date, + end_date=end_date, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ListDailyBillResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def get_usage_daily_bills_get_without_preload_content( + self, + start_date: date, + end_date: date, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """(Deprecated) Get Usage + + + :param start_date: (required) + :type start_date: date + :param end_date: (required) + :type end_date: date + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + warnings.warn("GET /daily_bills is deprecated.", DeprecationWarning) + + _param = self._get_usage_daily_bills_get_serialize( + start_date=start_date, + end_date=end_date, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "ListDailyBillResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _get_usage_daily_bills_get_serialize( + self, + start_date, + end_date, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + # process the query parameters + if start_date is not None: + if isinstance(start_date, date): + _query_params.append( + ( + 'start_date', + start_date.strftime( + self.api_client.configuration.date_format + ) + ) + ) + else: + _query_params.append(('start_date', start_date)) + + if end_date is not None: + if isinstance(end_date, date): + _query_params.append( + ( + 'end_date', + end_date.strftime( + self.api_client.configuration.date_format + ) + ) + ) + else: + _query_params.append(('end_date', end_date)) + + # process the header parameters + # process the form parameters + # process the body parameter + + + # set the HTTP header `Accept` + if 'Accept' not in _header_params: + _header_params['Accept'] = self.api_client.select_header_accept( + [ + 'application/json' + ] + ) + + + # authentication setting + _auth_settings: List[str] = [ + 'HTTPBearer' + ] + + return self.api_client.param_serialize( + method='GET', + resource_path='/daily_bills', + path_params=_path_params, + query_params=_query_params, + header_params=_header_params, + body=_body_params, + post_params=_form_params, + files=_files, + auth_settings=_auth_settings, + collection_formats=_collection_formats, + _host=_host, + _request_auth=_request_auth + ) + + + + + @validate_call + def get_usage_deployments_usage_deployment_id_get( + self, + deployment_id: StrictInt, + metric: Metric, + start_time_in_seconds: StrictInt, + end_time_in_seconds: StrictInt, + step: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> GetDeploymentUsageResponse: + """Get Usage + + + :param deployment_id: (required) + :type deployment_id: int + :param metric: (required) + :type metric: Metric + :param start_time_in_seconds: (required) + :type start_time_in_seconds: int + :param end_time_in_seconds: (required) + :type end_time_in_seconds: int + :param step: + :type step: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_usage_deployments_usage_deployment_id_get_serialize( + deployment_id=deployment_id, + metric=metric, + start_time_in_seconds=start_time_in_seconds, + end_time_in_seconds=end_time_in_seconds, + step=step, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GetDeploymentUsageResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ).data + + + @validate_call + def get_usage_deployments_usage_deployment_id_get_with_http_info( + self, + deployment_id: StrictInt, + metric: Metric, + start_time_in_seconds: StrictInt, + end_time_in_seconds: StrictInt, + step: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> ApiResponse[GetDeploymentUsageResponse]: + """Get Usage + + + :param deployment_id: (required) + :type deployment_id: int + :param metric: (required) + :type metric: Metric + :param start_time_in_seconds: (required) + :type start_time_in_seconds: int + :param end_time_in_seconds: (required) + :type end_time_in_seconds: int + :param step: + :type step: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_usage_deployments_usage_deployment_id_get_serialize( + deployment_id=deployment_id, + metric=metric, + start_time_in_seconds=start_time_in_seconds, + end_time_in_seconds=end_time_in_seconds, + step=step, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GetDeploymentUsageResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + response_data.read() + return self.api_client.response_deserialize( + response_data=response_data, + response_types_map=_response_types_map, + ) + + + @validate_call + def get_usage_deployments_usage_deployment_id_get_without_preload_content( + self, + deployment_id: StrictInt, + metric: Metric, + start_time_in_seconds: StrictInt, + end_time_in_seconds: StrictInt, + step: Optional[StrictInt] = None, + _request_timeout: Union[ + None, + Annotated[StrictFloat, Field(gt=0)], + Tuple[ + Annotated[StrictFloat, Field(gt=0)], + Annotated[StrictFloat, Field(gt=0)] + ] + ] = None, + _request_auth: Optional[Dict[StrictStr, Any]] = None, + _content_type: Optional[StrictStr] = None, + _headers: Optional[Dict[StrictStr, Any]] = None, + _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, + ) -> RESTResponseType: + """Get Usage + + + :param deployment_id: (required) + :type deployment_id: int + :param metric: (required) + :type metric: Metric + :param start_time_in_seconds: (required) + :type start_time_in_seconds: int + :param end_time_in_seconds: (required) + :type end_time_in_seconds: int + :param step: + :type step: int + :param _request_timeout: timeout setting for this request. If one + number provided, it will be total request + timeout. It can also be a pair (tuple) of + (connection, read) timeouts. + :type _request_timeout: int, tuple(int, int), optional + :param _request_auth: set to override the auth_settings for an a single + request; this effectively ignores the + authentication in the spec for a single request. + :type _request_auth: dict, optional + :param _content_type: force content-type for the request. + :type _content_type: str, Optional + :param _headers: set to override the headers for a single + request; this effectively ignores the headers + in the spec for a single request. + :type _headers: dict, optional + :param _host_index: set to override the host_index for a single + request; this effectively ignores the host_index + in the spec for a single request. + :type _host_index: int, optional + :return: Returns the result object. + """ # noqa: E501 + + _param = self._get_usage_deployments_usage_deployment_id_get_serialize( + deployment_id=deployment_id, + metric=metric, + start_time_in_seconds=start_time_in_seconds, + end_time_in_seconds=end_time_in_seconds, + step=step, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index + ) + + _response_types_map: Dict[str, Optional[str]] = { + '200': "GetDeploymentUsageResponse", + '422': "HTTPValidationError", + } + response_data = self.api_client.call_api( + *_param, + _request_timeout=_request_timeout + ) + return response_data.response + + + def _get_usage_deployments_usage_deployment_id_get_serialize( + self, + deployment_id, + metric, + start_time_in_seconds, + end_time_in_seconds, + step, + _request_auth, + _content_type, + _headers, + _host_index, + ) -> RequestSerialized: + + _host = None + + _collection_formats: Dict[str, str] = { + } + + _path_params: Dict[str, str] = {} + _query_params: List[Tuple[str, str]] = [] + _header_params: Dict[str, Optional[str]] = _headers or {} + _form_params: List[Tuple[str, str]] = [] + _files: Dict[ + str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]] + ] = {} + _body_params: Optional[bytes] = None + + # process the path parameters + if deployment_id is not None: + _path_params['deployment_id'] = deployment_id + # process the query parameters + if metric is not None: + + _query_params.append(('metric', metric.value)) + + if start_time_in_seconds is not None: + + _query_params.append(('start_time_in_seconds', start_time_in_seconds)) - _query_params.append(('type', type.value)) + if end_time_in_seconds is not None: + + _query_params.append(('end_time_in_seconds', end_time_in_seconds)) + + if step is not None: + + _query_params.append(('step', step)) # process the header parameters # process the form parameters @@ -10634,7 +12166,7 @@ def _get_prebuilt_images_prebuilt_images_get_serialize( return self.api_client.param_serialize( method='GET', - resource_path='/prebuilt-images', + resource_path='/deployments/usage/{deployment_id}', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -10651,10 +12183,9 @@ def _get_prebuilt_images_prebuilt_images_get_serialize( @validate_call - def get_usage_daily_bills_get( + def get_user_vault_item_by_id_endpoint_user_vault_secret_id_get( self, - start_date: date, - end_date: date, + secret_id: Annotated[int, Field(strict=True, ge=1)], _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -10667,14 +12198,13 @@ def get_usage_daily_bills_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ListDailyBillResponse: - """Get Usage + ) -> UserVaultItem: + """Get User Vault Item By Id Endpoint + Resolve a single secret's value. This is the only endpoint that returns a vault value, so it is the single place where read access to secret material is authorized and auditable. - :param start_date: (required) - :type start_date: date - :param end_date: (required) - :type end_date: date + :param secret_id: (required) + :type secret_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -10697,9 +12227,8 @@ def get_usage_daily_bills_get( :return: Returns the result object. """ # noqa: E501 - _param = self._get_usage_daily_bills_get_serialize( - start_date=start_date, - end_date=end_date, + _param = self._get_user_vault_item_by_id_endpoint_user_vault_secret_id_get_serialize( + secret_id=secret_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -10707,7 +12236,7 @@ def get_usage_daily_bills_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListDailyBillResponse", + '200': "UserVaultItem", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -10722,10 +12251,9 @@ def get_usage_daily_bills_get( @validate_call - def get_usage_daily_bills_get_with_http_info( + def get_user_vault_item_by_id_endpoint_user_vault_secret_id_get_with_http_info( self, - start_date: date, - end_date: date, + secret_id: Annotated[int, Field(strict=True, ge=1)], _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -10738,14 +12266,13 @@ def get_usage_daily_bills_get_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[ListDailyBillResponse]: - """Get Usage + ) -> ApiResponse[UserVaultItem]: + """Get User Vault Item By Id Endpoint + Resolve a single secret's value. This is the only endpoint that returns a vault value, so it is the single place where read access to secret material is authorized and auditable. - :param start_date: (required) - :type start_date: date - :param end_date: (required) - :type end_date: date + :param secret_id: (required) + :type secret_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -10768,9 +12295,8 @@ def get_usage_daily_bills_get_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._get_usage_daily_bills_get_serialize( - start_date=start_date, - end_date=end_date, + _param = self._get_user_vault_item_by_id_endpoint_user_vault_secret_id_get_serialize( + secret_id=secret_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -10778,7 +12304,7 @@ def get_usage_daily_bills_get_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListDailyBillResponse", + '200': "UserVaultItem", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -10793,10 +12319,9 @@ def get_usage_daily_bills_get_with_http_info( @validate_call - def get_usage_daily_bills_get_without_preload_content( + def get_user_vault_item_by_id_endpoint_user_vault_secret_id_get_without_preload_content( self, - start_date: date, - end_date: date, + secret_id: Annotated[int, Field(strict=True, ge=1)], _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -10810,13 +12335,12 @@ def get_usage_daily_bills_get_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Usage + """Get User Vault Item By Id Endpoint + Resolve a single secret's value. This is the only endpoint that returns a vault value, so it is the single place where read access to secret material is authorized and auditable. - :param start_date: (required) - :type start_date: date - :param end_date: (required) - :type end_date: date + :param secret_id: (required) + :type secret_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -10839,9 +12363,8 @@ def get_usage_daily_bills_get_without_preload_content( :return: Returns the result object. """ # noqa: E501 - _param = self._get_usage_daily_bills_get_serialize( - start_date=start_date, - end_date=end_date, + _param = self._get_user_vault_item_by_id_endpoint_user_vault_secret_id_get_serialize( + secret_id=secret_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -10849,7 +12372,7 @@ def get_usage_daily_bills_get_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListDailyBillResponse", + '200': "UserVaultItem", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -10859,10 +12382,9 @@ def get_usage_daily_bills_get_without_preload_content( return response_data.response - def _get_usage_daily_bills_get_serialize( + def _get_user_vault_item_by_id_endpoint_user_vault_secret_id_get_serialize( self, - start_date, - end_date, + secret_id, _request_auth, _content_type, _headers, @@ -10884,33 +12406,9 @@ def _get_usage_daily_bills_get_serialize( _body_params: Optional[bytes] = None # process the path parameters + if secret_id is not None: + _path_params['secret_id'] = secret_id # process the query parameters - if start_date is not None: - if isinstance(start_date, date): - _query_params.append( - ( - 'start_date', - start_date.strftime( - self.api_client.configuration.date_format - ) - ) - ) - else: - _query_params.append(('start_date', start_date)) - - if end_date is not None: - if isinstance(end_date, date): - _query_params.append( - ( - 'end_date', - end_date.strftime( - self.api_client.configuration.date_format - ) - ) - ) - else: - _query_params.append(('end_date', end_date)) - # process the header parameters # process the form parameters # process the body parameter @@ -10932,7 +12430,7 @@ def _get_usage_daily_bills_get_serialize( return self.api_client.param_serialize( method='GET', - resource_path='/daily_bills', + resource_path='/user_vault/{secret_id}', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -10949,13 +12447,9 @@ def _get_usage_daily_bills_get_serialize( @validate_call - def get_usage_deployments_usage_deployment_id_get( + def get_volume_endpoint_volumes_volume_id_get( self, - deployment_id: StrictInt, - metric: Metric, - start_time_in_seconds: StrictInt, - end_time_in_seconds: StrictInt, - step: Optional[StrictInt] = None, + volume_id: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -10968,20 +12462,13 @@ def get_usage_deployments_usage_deployment_id_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> GetDeploymentUsageResponse: - """Get Usage + ) -> GetVolumeResponse: + """Get Volume Endpoint + Retrieve a single volume by id. - :param deployment_id: (required) - :type deployment_id: int - :param metric: (required) - :type metric: Metric - :param start_time_in_seconds: (required) - :type start_time_in_seconds: int - :param end_time_in_seconds: (required) - :type end_time_in_seconds: int - :param step: - :type step: int + :param volume_id: (required) + :type volume_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -11004,12 +12491,8 @@ def get_usage_deployments_usage_deployment_id_get( :return: Returns the result object. """ # noqa: E501 - _param = self._get_usage_deployments_usage_deployment_id_get_serialize( - deployment_id=deployment_id, - metric=metric, - start_time_in_seconds=start_time_in_seconds, - end_time_in_seconds=end_time_in_seconds, - step=step, + _param = self._get_volume_endpoint_volumes_volume_id_get_serialize( + volume_id=volume_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -11017,7 +12500,7 @@ def get_usage_deployments_usage_deployment_id_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetDeploymentUsageResponse", + '200': "GetVolumeResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -11032,13 +12515,9 @@ def get_usage_deployments_usage_deployment_id_get( @validate_call - def get_usage_deployments_usage_deployment_id_get_with_http_info( + def get_volume_endpoint_volumes_volume_id_get_with_http_info( self, - deployment_id: StrictInt, - metric: Metric, - start_time_in_seconds: StrictInt, - end_time_in_seconds: StrictInt, - step: Optional[StrictInt] = None, + volume_id: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -11051,20 +12530,13 @@ def get_usage_deployments_usage_deployment_id_get_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[GetDeploymentUsageResponse]: - """Get Usage + ) -> ApiResponse[GetVolumeResponse]: + """Get Volume Endpoint + Retrieve a single volume by id. - :param deployment_id: (required) - :type deployment_id: int - :param metric: (required) - :type metric: Metric - :param start_time_in_seconds: (required) - :type start_time_in_seconds: int - :param end_time_in_seconds: (required) - :type end_time_in_seconds: int - :param step: - :type step: int + :param volume_id: (required) + :type volume_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -11087,12 +12559,8 @@ def get_usage_deployments_usage_deployment_id_get_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._get_usage_deployments_usage_deployment_id_get_serialize( - deployment_id=deployment_id, - metric=metric, - start_time_in_seconds=start_time_in_seconds, - end_time_in_seconds=end_time_in_seconds, - step=step, + _param = self._get_volume_endpoint_volumes_volume_id_get_serialize( + volume_id=volume_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -11100,7 +12568,7 @@ def get_usage_deployments_usage_deployment_id_get_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetDeploymentUsageResponse", + '200': "GetVolumeResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -11115,13 +12583,9 @@ def get_usage_deployments_usage_deployment_id_get_with_http_info( @validate_call - def get_usage_deployments_usage_deployment_id_get_without_preload_content( + def get_volume_endpoint_volumes_volume_id_get_without_preload_content( self, - deployment_id: StrictInt, - metric: Metric, - start_time_in_seconds: StrictInt, - end_time_in_seconds: StrictInt, - step: Optional[StrictInt] = None, + volume_id: StrictInt, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -11135,19 +12599,12 @@ def get_usage_deployments_usage_deployment_id_get_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Usage + """Get Volume Endpoint + Retrieve a single volume by id. - :param deployment_id: (required) - :type deployment_id: int - :param metric: (required) - :type metric: Metric - :param start_time_in_seconds: (required) - :type start_time_in_seconds: int - :param end_time_in_seconds: (required) - :type end_time_in_seconds: int - :param step: - :type step: int + :param volume_id: (required) + :type volume_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -11170,12 +12627,8 @@ def get_usage_deployments_usage_deployment_id_get_without_preload_content( :return: Returns the result object. """ # noqa: E501 - _param = self._get_usage_deployments_usage_deployment_id_get_serialize( - deployment_id=deployment_id, - metric=metric, - start_time_in_seconds=start_time_in_seconds, - end_time_in_seconds=end_time_in_seconds, - step=step, + _param = self._get_volume_endpoint_volumes_volume_id_get_serialize( + volume_id=volume_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -11183,7 +12636,7 @@ def get_usage_deployments_usage_deployment_id_get_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetDeploymentUsageResponse", + '200': "GetVolumeResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -11193,13 +12646,9 @@ def get_usage_deployments_usage_deployment_id_get_without_preload_content( return response_data.response - def _get_usage_deployments_usage_deployment_id_get_serialize( + def _get_volume_endpoint_volumes_volume_id_get_serialize( self, - deployment_id, - metric, - start_time_in_seconds, - end_time_in_seconds, - step, + volume_id, _request_auth, _content_type, _headers, @@ -11221,25 +12670,9 @@ def _get_usage_deployments_usage_deployment_id_get_serialize( _body_params: Optional[bytes] = None # process the path parameters - if deployment_id is not None: - _path_params['deployment_id'] = deployment_id + if volume_id is not None: + _path_params['volume_id'] = volume_id # process the query parameters - if metric is not None: - - _query_params.append(('metric', metric.value)) - - if start_time_in_seconds is not None: - - _query_params.append(('start_time_in_seconds', start_time_in_seconds)) - - if end_time_in_seconds is not None: - - _query_params.append(('end_time_in_seconds', end_time_in_seconds)) - - if step is not None: - - _query_params.append(('step', step)) - # process the header parameters # process the form parameters # process the body parameter @@ -11261,7 +12694,7 @@ def _get_usage_deployments_usage_deployment_id_get_serialize( return self.api_client.param_serialize( method='GET', - resource_path='/deployments/usage/{deployment_id}', + resource_path='/volumes/{volume_id}', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -11278,7 +12711,7 @@ def _get_usage_deployments_usage_deployment_id_get_serialize( @validate_call - def get_volume_endpoint_volumes_volume_id_get( + def get_volume_status_endpoint_volumes_status_volume_id_get( self, volume_id: StrictInt, _request_timeout: Union[ @@ -11293,10 +12726,10 @@ def get_volume_endpoint_volumes_volume_id_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> GetVolumeResponse: - """Get Volume Endpoint + ) -> VolumeStatusResponse: + """Get Volume Status Endpoint - Retrieve a single volume by id. + Live volume status: status is the stored intent, service_status is computed from the volume app's health and PVC phase. :param volume_id: (required) :type volume_id: int @@ -11322,7 +12755,7 @@ def get_volume_endpoint_volumes_volume_id_get( :return: Returns the result object. """ # noqa: E501 - _param = self._get_volume_endpoint_volumes_volume_id_get_serialize( + _param = self._get_volume_status_endpoint_volumes_status_volume_id_get_serialize( volume_id=volume_id, _request_auth=_request_auth, _content_type=_content_type, @@ -11331,7 +12764,7 @@ def get_volume_endpoint_volumes_volume_id_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetVolumeResponse", + '200': "VolumeStatusResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -11346,7 +12779,7 @@ def get_volume_endpoint_volumes_volume_id_get( @validate_call - def get_volume_endpoint_volumes_volume_id_get_with_http_info( + def get_volume_status_endpoint_volumes_status_volume_id_get_with_http_info( self, volume_id: StrictInt, _request_timeout: Union[ @@ -11361,10 +12794,10 @@ def get_volume_endpoint_volumes_volume_id_get_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[GetVolumeResponse]: - """Get Volume Endpoint + ) -> ApiResponse[VolumeStatusResponse]: + """Get Volume Status Endpoint - Retrieve a single volume by id. + Live volume status: status is the stored intent, service_status is computed from the volume app's health and PVC phase. :param volume_id: (required) :type volume_id: int @@ -11390,7 +12823,7 @@ def get_volume_endpoint_volumes_volume_id_get_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._get_volume_endpoint_volumes_volume_id_get_serialize( + _param = self._get_volume_status_endpoint_volumes_status_volume_id_get_serialize( volume_id=volume_id, _request_auth=_request_auth, _content_type=_content_type, @@ -11399,7 +12832,7 @@ def get_volume_endpoint_volumes_volume_id_get_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetVolumeResponse", + '200': "VolumeStatusResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -11414,7 +12847,7 @@ def get_volume_endpoint_volumes_volume_id_get_with_http_info( @validate_call - def get_volume_endpoint_volumes_volume_id_get_without_preload_content( + def get_volume_status_endpoint_volumes_status_volume_id_get_without_preload_content( self, volume_id: StrictInt, _request_timeout: Union[ @@ -11430,9 +12863,9 @@ def get_volume_endpoint_volumes_volume_id_get_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Volume Endpoint + """Get Volume Status Endpoint - Retrieve a single volume by id. + Live volume status: status is the stored intent, service_status is computed from the volume app's health and PVC phase. :param volume_id: (required) :type volume_id: int @@ -11458,7 +12891,7 @@ def get_volume_endpoint_volumes_volume_id_get_without_preload_content( :return: Returns the result object. """ # noqa: E501 - _param = self._get_volume_endpoint_volumes_volume_id_get_serialize( + _param = self._get_volume_status_endpoint_volumes_status_volume_id_get_serialize( volume_id=volume_id, _request_auth=_request_auth, _content_type=_content_type, @@ -11467,7 +12900,7 @@ def get_volume_endpoint_volumes_volume_id_get_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "GetVolumeResponse", + '200': "VolumeStatusResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -11477,7 +12910,7 @@ def get_volume_endpoint_volumes_volume_id_get_without_preload_content( return response_data.response - def _get_volume_endpoint_volumes_volume_id_get_serialize( + def _get_volume_status_endpoint_volumes_status_volume_id_get_serialize( self, volume_id, _request_auth, @@ -11525,7 +12958,7 @@ def _get_volume_endpoint_volumes_volume_id_get_serialize( return self.api_client.param_serialize( method='GET', - resource_path='/volumes/{volume_id}', + resource_path='/volumes/status/{volume_id}', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -11542,9 +12975,9 @@ def _get_volume_endpoint_volumes_volume_id_get_serialize( @validate_call - def get_volume_status_endpoint_volumes_status_volume_id_get( + def invite_user_organizations_invite_post( self, - volume_id: StrictInt, + invite_user_request: InviteUserRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -11557,13 +12990,12 @@ def get_volume_status_endpoint_volumes_status_volume_id_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> VolumeStatusResponse: - """Get Volume Status Endpoint + ) -> object: + """Invite User - Live volume status: status is the stored intent, service_status is computed from the volume app's health and PVC phase. - :param volume_id: (required) - :type volume_id: int + :param invite_user_request: (required) + :type invite_user_request: InviteUserRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -11586,8 +13018,8 @@ def get_volume_status_endpoint_volumes_status_volume_id_get( :return: Returns the result object. """ # noqa: E501 - _param = self._get_volume_status_endpoint_volumes_status_volume_id_get_serialize( - volume_id=volume_id, + _param = self._invite_user_organizations_invite_post_serialize( + invite_user_request=invite_user_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -11595,7 +13027,7 @@ def get_volume_status_endpoint_volumes_status_volume_id_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "VolumeStatusResponse", + '200': "object", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -11610,9 +13042,9 @@ def get_volume_status_endpoint_volumes_status_volume_id_get( @validate_call - def get_volume_status_endpoint_volumes_status_volume_id_get_with_http_info( + def invite_user_organizations_invite_post_with_http_info( self, - volume_id: StrictInt, + invite_user_request: InviteUserRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -11625,13 +13057,12 @@ def get_volume_status_endpoint_volumes_status_volume_id_get_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[VolumeStatusResponse]: - """Get Volume Status Endpoint + ) -> ApiResponse[object]: + """Invite User - Live volume status: status is the stored intent, service_status is computed from the volume app's health and PVC phase. - :param volume_id: (required) - :type volume_id: int + :param invite_user_request: (required) + :type invite_user_request: InviteUserRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -11654,8 +13085,8 @@ def get_volume_status_endpoint_volumes_status_volume_id_get_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._get_volume_status_endpoint_volumes_status_volume_id_get_serialize( - volume_id=volume_id, + _param = self._invite_user_organizations_invite_post_serialize( + invite_user_request=invite_user_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -11663,7 +13094,7 @@ def get_volume_status_endpoint_volumes_status_volume_id_get_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "VolumeStatusResponse", + '200': "object", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -11678,9 +13109,9 @@ def get_volume_status_endpoint_volumes_status_volume_id_get_with_http_info( @validate_call - def get_volume_status_endpoint_volumes_status_volume_id_get_without_preload_content( + def invite_user_organizations_invite_post_without_preload_content( self, - volume_id: StrictInt, + invite_user_request: InviteUserRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -11694,12 +13125,11 @@ def get_volume_status_endpoint_volumes_status_volume_id_get_without_preload_cont _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get Volume Status Endpoint + """Invite User - Live volume status: status is the stored intent, service_status is computed from the volume app's health and PVC phase. - :param volume_id: (required) - :type volume_id: int + :param invite_user_request: (required) + :type invite_user_request: InviteUserRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -11722,8 +13152,8 @@ def get_volume_status_endpoint_volumes_status_volume_id_get_without_preload_cont :return: Returns the result object. """ # noqa: E501 - _param = self._get_volume_status_endpoint_volumes_status_volume_id_get_serialize( - volume_id=volume_id, + _param = self._invite_user_organizations_invite_post_serialize( + invite_user_request=invite_user_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -11731,7 +13161,7 @@ def get_volume_status_endpoint_volumes_status_volume_id_get_without_preload_cont ) _response_types_map: Dict[str, Optional[str]] = { - '200': "VolumeStatusResponse", + '200': "object", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -11741,9 +13171,9 @@ def get_volume_status_endpoint_volumes_status_volume_id_get_without_preload_cont return response_data.response - def _get_volume_status_endpoint_volumes_status_volume_id_get_serialize( + def _invite_user_organizations_invite_post_serialize( self, - volume_id, + invite_user_request, _request_auth, _content_type, _headers, @@ -11765,12 +13195,12 @@ def _get_volume_status_endpoint_volumes_status_volume_id_get_serialize( _body_params: Optional[bytes] = None # process the path parameters - if volume_id is not None: - _path_params['volume_id'] = volume_id # process the query parameters # process the header parameters # process the form parameters # process the body parameter + if invite_user_request is not None: + _body_params = invite_user_request # set the HTTP header `Accept` @@ -11781,6 +13211,19 @@ def _get_volume_status_endpoint_volumes_status_volume_id_get_serialize( ] ) + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type # authentication setting _auth_settings: List[str] = [ @@ -11788,8 +13231,8 @@ def _get_volume_status_endpoint_volumes_status_volume_id_get_serialize( ] return self.api_client.param_serialize( - method='GET', - resource_path='/volumes/status/{volume_id}', + method='POST', + resource_path='/organizations/invite', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -11806,9 +13249,9 @@ def _get_volume_status_endpoint_volumes_status_volume_id_get_serialize( @validate_call - def invite_user_organizations_invite_post( + def list_cluster_capacity_capacity_get( self, - invite_user_request: InviteUserRequest, + cluster_id: Optional[StrictInt] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -11821,12 +13264,13 @@ def invite_user_organizations_invite_post( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> object: - """Invite User + ) -> ListClusterCapacityResponse: + """List Cluster Capacity + Return GPU capacity breakdown for accessible clusters. When *cluster_id* is supplied only that cluster is included (if accessible). Clusters whose Prometheus data is unavailable are omitted from the results rather than failing the entire request. - :param invite_user_request: (required) - :type invite_user_request: InviteUserRequest + :param cluster_id: + :type cluster_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -11849,8 +13293,8 @@ def invite_user_organizations_invite_post( :return: Returns the result object. """ # noqa: E501 - _param = self._invite_user_organizations_invite_post_serialize( - invite_user_request=invite_user_request, + _param = self._list_cluster_capacity_capacity_get_serialize( + cluster_id=cluster_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -11858,7 +13302,7 @@ def invite_user_organizations_invite_post( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "object", + '200': "ListClusterCapacityResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -11873,9 +13317,9 @@ def invite_user_organizations_invite_post( @validate_call - def invite_user_organizations_invite_post_with_http_info( + def list_cluster_capacity_capacity_get_with_http_info( self, - invite_user_request: InviteUserRequest, + cluster_id: Optional[StrictInt] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -11888,12 +13332,13 @@ def invite_user_organizations_invite_post_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[object]: - """Invite User + ) -> ApiResponse[ListClusterCapacityResponse]: + """List Cluster Capacity + Return GPU capacity breakdown for accessible clusters. When *cluster_id* is supplied only that cluster is included (if accessible). Clusters whose Prometheus data is unavailable are omitted from the results rather than failing the entire request. - :param invite_user_request: (required) - :type invite_user_request: InviteUserRequest + :param cluster_id: + :type cluster_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -11916,8 +13361,8 @@ def invite_user_organizations_invite_post_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._invite_user_organizations_invite_post_serialize( - invite_user_request=invite_user_request, + _param = self._list_cluster_capacity_capacity_get_serialize( + cluster_id=cluster_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -11925,7 +13370,7 @@ def invite_user_organizations_invite_post_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "object", + '200': "ListClusterCapacityResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -11940,9 +13385,9 @@ def invite_user_organizations_invite_post_with_http_info( @validate_call - def invite_user_organizations_invite_post_without_preload_content( + def list_cluster_capacity_capacity_get_without_preload_content( self, - invite_user_request: InviteUserRequest, + cluster_id: Optional[StrictInt] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -11956,11 +13401,12 @@ def invite_user_organizations_invite_post_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Invite User + """List Cluster Capacity + Return GPU capacity breakdown for accessible clusters. When *cluster_id* is supplied only that cluster is included (if accessible). Clusters whose Prometheus data is unavailable are omitted from the results rather than failing the entire request. - :param invite_user_request: (required) - :type invite_user_request: InviteUserRequest + :param cluster_id: + :type cluster_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -11983,8 +13429,8 @@ def invite_user_organizations_invite_post_without_preload_content( :return: Returns the result object. """ # noqa: E501 - _param = self._invite_user_organizations_invite_post_serialize( - invite_user_request=invite_user_request, + _param = self._list_cluster_capacity_capacity_get_serialize( + cluster_id=cluster_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -11992,7 +13438,7 @@ def invite_user_organizations_invite_post_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "object", + '200': "ListClusterCapacityResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -12002,9 +13448,9 @@ def invite_user_organizations_invite_post_without_preload_content( return response_data.response - def _invite_user_organizations_invite_post_serialize( + def _list_cluster_capacity_capacity_get_serialize( self, - invite_user_request, + cluster_id, _request_auth, _content_type, _headers, @@ -12027,11 +13473,13 @@ def _invite_user_organizations_invite_post_serialize( # process the path parameters # process the query parameters + if cluster_id is not None: + + _query_params.append(('cluster_id', cluster_id)) + # process the header parameters # process the form parameters # process the body parameter - if invite_user_request is not None: - _body_params = invite_user_request # set the HTTP header `Accept` @@ -12042,19 +13490,6 @@ def _invite_user_organizations_invite_post_serialize( ] ) - # set the HTTP header `Content-Type` - if _content_type: - _header_params['Content-Type'] = _content_type - else: - _default_content_type = ( - self.api_client.select_header_content_type( - [ - 'application/json' - ] - ) - ) - if _default_content_type is not None: - _header_params['Content-Type'] = _default_content_type # authentication setting _auth_settings: List[str] = [ @@ -12062,8 +13497,8 @@ def _invite_user_organizations_invite_post_serialize( ] return self.api_client.param_serialize( - method='POST', - resource_path='/organizations/invite', + method='GET', + resource_path='/capacity', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -12080,9 +13515,8 @@ def _invite_user_organizations_invite_post_serialize( @validate_call - def list_cluster_capacity_capacity_get( + def list_service_accounts_service_accounts_get( self, - cluster_id: Optional[StrictInt] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -12095,13 +13529,10 @@ def list_cluster_capacity_capacity_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ListClusterCapacityResponse: - """List Cluster Capacity + ) -> ListServiceAccountsResponse: + """List Service Accounts - Return GPU capacity breakdown for accessible clusters. When *cluster_id* is supplied only that cluster is included (if accessible). Clusters whose Prometheus data is unavailable are omitted from the results rather than failing the entire request. - :param cluster_id: - :type cluster_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -12124,8 +13555,7 @@ def list_cluster_capacity_capacity_get( :return: Returns the result object. """ # noqa: E501 - _param = self._list_cluster_capacity_capacity_get_serialize( - cluster_id=cluster_id, + _param = self._list_service_accounts_service_accounts_get_serialize( _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -12133,8 +13563,7 @@ def list_cluster_capacity_capacity_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListClusterCapacityResponse", - '422': "HTTPValidationError", + '200': "ListServiceAccountsResponse", } response_data = self.api_client.call_api( *_param, @@ -12148,9 +13577,8 @@ def list_cluster_capacity_capacity_get( @validate_call - def list_cluster_capacity_capacity_get_with_http_info( + def list_service_accounts_service_accounts_get_with_http_info( self, - cluster_id: Optional[StrictInt] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -12163,13 +13591,10 @@ def list_cluster_capacity_capacity_get_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[ListClusterCapacityResponse]: - """List Cluster Capacity + ) -> ApiResponse[ListServiceAccountsResponse]: + """List Service Accounts - Return GPU capacity breakdown for accessible clusters. When *cluster_id* is supplied only that cluster is included (if accessible). Clusters whose Prometheus data is unavailable are omitted from the results rather than failing the entire request. - :param cluster_id: - :type cluster_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -12192,8 +13617,7 @@ def list_cluster_capacity_capacity_get_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._list_cluster_capacity_capacity_get_serialize( - cluster_id=cluster_id, + _param = self._list_service_accounts_service_accounts_get_serialize( _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -12201,8 +13625,7 @@ def list_cluster_capacity_capacity_get_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListClusterCapacityResponse", - '422': "HTTPValidationError", + '200': "ListServiceAccountsResponse", } response_data = self.api_client.call_api( *_param, @@ -12216,9 +13639,8 @@ def list_cluster_capacity_capacity_get_with_http_info( @validate_call - def list_cluster_capacity_capacity_get_without_preload_content( + def list_service_accounts_service_accounts_get_without_preload_content( self, - cluster_id: Optional[StrictInt] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -12232,12 +13654,9 @@ def list_cluster_capacity_capacity_get_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """List Cluster Capacity + """List Service Accounts - Return GPU capacity breakdown for accessible clusters. When *cluster_id* is supplied only that cluster is included (if accessible). Clusters whose Prometheus data is unavailable are omitted from the results rather than failing the entire request. - :param cluster_id: - :type cluster_id: int :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -12260,8 +13679,7 @@ def list_cluster_capacity_capacity_get_without_preload_content( :return: Returns the result object. """ # noqa: E501 - _param = self._list_cluster_capacity_capacity_get_serialize( - cluster_id=cluster_id, + _param = self._list_service_accounts_service_accounts_get_serialize( _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -12269,8 +13687,7 @@ def list_cluster_capacity_capacity_get_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListClusterCapacityResponse", - '422': "HTTPValidationError", + '200': "ListServiceAccountsResponse", } response_data = self.api_client.call_api( *_param, @@ -12279,9 +13696,8 @@ def list_cluster_capacity_capacity_get_without_preload_content( return response_data.response - def _list_cluster_capacity_capacity_get_serialize( + def _list_service_accounts_service_accounts_get_serialize( self, - cluster_id, _request_auth, _content_type, _headers, @@ -12304,10 +13720,6 @@ def _list_cluster_capacity_capacity_get_serialize( # process the path parameters # process the query parameters - if cluster_id is not None: - - _query_params.append(('cluster_id', cluster_id)) - # process the header parameters # process the form parameters # process the body parameter @@ -12329,7 +13741,7 @@ def _list_cluster_capacity_capacity_get_serialize( return self.api_client.param_serialize( method='GET', - resource_path='/capacity', + resource_path='/service-accounts', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -12346,8 +13758,11 @@ def _list_cluster_capacity_capacity_get_serialize( @validate_call - def list_service_accounts_service_accounts_get( + def rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put( self, + deployment_id: StrictInt, + revision_number: StrictInt, + rollout_strategy_params: Optional[RolloutStrategyParams] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -12360,10 +13775,17 @@ def list_service_accounts_service_accounts_get( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ListServiceAccountsResponse: - """List Service Accounts + ) -> UpdateDeploymentResponse: + """Rollout Existing Revision + Change the selected revision for a deployment and apply the changes. + :param deployment_id: (required) + :type deployment_id: int + :param revision_number: (required) + :type revision_number: int + :param rollout_strategy_params: + :type rollout_strategy_params: RolloutStrategyParams :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -12386,7 +13808,10 @@ def list_service_accounts_service_accounts_get( :return: Returns the result object. """ # noqa: E501 - _param = self._list_service_accounts_service_accounts_get_serialize( + _param = self._rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put_serialize( + deployment_id=deployment_id, + revision_number=revision_number, + rollout_strategy_params=rollout_strategy_params, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -12394,7 +13819,8 @@ def list_service_accounts_service_accounts_get( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListServiceAccountsResponse", + '200': "UpdateDeploymentResponse", + '422': "HTTPValidationError", } response_data = self.api_client.call_api( *_param, @@ -12408,8 +13834,11 @@ def list_service_accounts_service_accounts_get( @validate_call - def list_service_accounts_service_accounts_get_with_http_info( + def rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put_with_http_info( self, + deployment_id: StrictInt, + revision_number: StrictInt, + rollout_strategy_params: Optional[RolloutStrategyParams] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -12422,10 +13851,17 @@ def list_service_accounts_service_accounts_get_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[ListServiceAccountsResponse]: - """List Service Accounts + ) -> ApiResponse[UpdateDeploymentResponse]: + """Rollout Existing Revision + Change the selected revision for a deployment and apply the changes. + :param deployment_id: (required) + :type deployment_id: int + :param revision_number: (required) + :type revision_number: int + :param rollout_strategy_params: + :type rollout_strategy_params: RolloutStrategyParams :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -12448,7 +13884,10 @@ def list_service_accounts_service_accounts_get_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._list_service_accounts_service_accounts_get_serialize( + _param = self._rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put_serialize( + deployment_id=deployment_id, + revision_number=revision_number, + rollout_strategy_params=rollout_strategy_params, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -12456,7 +13895,8 @@ def list_service_accounts_service_accounts_get_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListServiceAccountsResponse", + '200': "UpdateDeploymentResponse", + '422': "HTTPValidationError", } response_data = self.api_client.call_api( *_param, @@ -12470,8 +13910,11 @@ def list_service_accounts_service_accounts_get_with_http_info( @validate_call - def list_service_accounts_service_accounts_get_without_preload_content( + def rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put_without_preload_content( self, + deployment_id: StrictInt, + revision_number: StrictInt, + rollout_strategy_params: Optional[RolloutStrategyParams] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -12485,9 +13928,16 @@ def list_service_accounts_service_accounts_get_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """List Service Accounts + """Rollout Existing Revision + Change the selected revision for a deployment and apply the changes. + :param deployment_id: (required) + :type deployment_id: int + :param revision_number: (required) + :type revision_number: int + :param rollout_strategy_params: + :type rollout_strategy_params: RolloutStrategyParams :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -12510,7 +13960,10 @@ def list_service_accounts_service_accounts_get_without_preload_content( :return: Returns the result object. """ # noqa: E501 - _param = self._list_service_accounts_service_accounts_get_serialize( + _param = self._rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put_serialize( + deployment_id=deployment_id, + revision_number=revision_number, + rollout_strategy_params=rollout_strategy_params, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -12518,7 +13971,8 @@ def list_service_accounts_service_accounts_get_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "ListServiceAccountsResponse", + '200': "UpdateDeploymentResponse", + '422': "HTTPValidationError", } response_data = self.api_client.call_api( *_param, @@ -12527,8 +13981,11 @@ def list_service_accounts_service_accounts_get_without_preload_content( return response_data.response - def _list_service_accounts_service_accounts_get_serialize( + def _rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put_serialize( self, + deployment_id, + revision_number, + rollout_strategy_params, _request_auth, _content_type, _headers, @@ -12550,10 +14007,16 @@ def _list_service_accounts_service_accounts_get_serialize( _body_params: Optional[bytes] = None # process the path parameters + if deployment_id is not None: + _path_params['deployment_id'] = deployment_id + if revision_number is not None: + _path_params['revision_number'] = revision_number # process the query parameters # process the header parameters # process the form parameters # process the body parameter + if rollout_strategy_params is not None: + _body_params = rollout_strategy_params # set the HTTP header `Accept` @@ -12564,6 +14027,19 @@ def _list_service_accounts_service_accounts_get_serialize( ] ) + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type # authentication setting _auth_settings: List[str] = [ @@ -12571,8 +14047,8 @@ def _list_service_accounts_service_accounts_get_serialize( ] return self.api_client.param_serialize( - method='GET', - resource_path='/service-accounts', + method='PUT', + resource_path='/deployments/revisions/{deployment_id}/{revision_number}', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -12589,11 +14065,8 @@ def _list_service_accounts_service_accounts_get_serialize( @validate_call - def rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put( + def setup_stripe_customer_payments_setup_post( self, - deployment_id: StrictInt, - revision_number: StrictInt, - rollout_strategy_params: Optional[RolloutStrategyParams] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -12606,17 +14079,10 @@ def rollout_existing_revision_deployments_revisions_deployment_id_revision_numbe _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> UpdateDeploymentResponse: - """Rollout Existing Revision + ) -> object: + """Setup Stripe Customer - Change the selected revision for a deployment and apply the changes. - :param deployment_id: (required) - :type deployment_id: int - :param revision_number: (required) - :type revision_number: int - :param rollout_strategy_params: - :type rollout_strategy_params: RolloutStrategyParams :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -12639,10 +14105,7 @@ def rollout_existing_revision_deployments_revisions_deployment_id_revision_numbe :return: Returns the result object. """ # noqa: E501 - _param = self._rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put_serialize( - deployment_id=deployment_id, - revision_number=revision_number, - rollout_strategy_params=rollout_strategy_params, + _param = self._setup_stripe_customer_payments_setup_post_serialize( _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -12650,8 +14113,7 @@ def rollout_existing_revision_deployments_revisions_deployment_id_revision_numbe ) _response_types_map: Dict[str, Optional[str]] = { - '200': "UpdateDeploymentResponse", - '422': "HTTPValidationError", + '200': "object", } response_data = self.api_client.call_api( *_param, @@ -12665,11 +14127,8 @@ def rollout_existing_revision_deployments_revisions_deployment_id_revision_numbe @validate_call - def rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put_with_http_info( + def setup_stripe_customer_payments_setup_post_with_http_info( self, - deployment_id: StrictInt, - revision_number: StrictInt, - rollout_strategy_params: Optional[RolloutStrategyParams] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -12682,17 +14141,10 @@ def rollout_existing_revision_deployments_revisions_deployment_id_revision_numbe _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[UpdateDeploymentResponse]: - """Rollout Existing Revision + ) -> ApiResponse[object]: + """Setup Stripe Customer - Change the selected revision for a deployment and apply the changes. - :param deployment_id: (required) - :type deployment_id: int - :param revision_number: (required) - :type revision_number: int - :param rollout_strategy_params: - :type rollout_strategy_params: RolloutStrategyParams :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -12715,10 +14167,7 @@ def rollout_existing_revision_deployments_revisions_deployment_id_revision_numbe :return: Returns the result object. """ # noqa: E501 - _param = self._rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put_serialize( - deployment_id=deployment_id, - revision_number=revision_number, - rollout_strategy_params=rollout_strategy_params, + _param = self._setup_stripe_customer_payments_setup_post_serialize( _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -12726,8 +14175,7 @@ def rollout_existing_revision_deployments_revisions_deployment_id_revision_numbe ) _response_types_map: Dict[str, Optional[str]] = { - '200': "UpdateDeploymentResponse", - '422': "HTTPValidationError", + '200': "object", } response_data = self.api_client.call_api( *_param, @@ -12741,11 +14189,8 @@ def rollout_existing_revision_deployments_revisions_deployment_id_revision_numbe @validate_call - def rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put_without_preload_content( + def setup_stripe_customer_payments_setup_post_without_preload_content( self, - deployment_id: StrictInt, - revision_number: StrictInt, - rollout_strategy_params: Optional[RolloutStrategyParams] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -12759,16 +14204,9 @@ def rollout_existing_revision_deployments_revisions_deployment_id_revision_numbe _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Rollout Existing Revision + """Setup Stripe Customer - Change the selected revision for a deployment and apply the changes. - :param deployment_id: (required) - :type deployment_id: int - :param revision_number: (required) - :type revision_number: int - :param rollout_strategy_params: - :type rollout_strategy_params: RolloutStrategyParams :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -12791,10 +14229,7 @@ def rollout_existing_revision_deployments_revisions_deployment_id_revision_numbe :return: Returns the result object. """ # noqa: E501 - _param = self._rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put_serialize( - deployment_id=deployment_id, - revision_number=revision_number, - rollout_strategy_params=rollout_strategy_params, + _param = self._setup_stripe_customer_payments_setup_post_serialize( _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -12802,8 +14237,7 @@ def rollout_existing_revision_deployments_revisions_deployment_id_revision_numbe ) _response_types_map: Dict[str, Optional[str]] = { - '200': "UpdateDeploymentResponse", - '422': "HTTPValidationError", + '200': "object", } response_data = self.api_client.call_api( *_param, @@ -12812,11 +14246,8 @@ def rollout_existing_revision_deployments_revisions_deployment_id_revision_numbe return response_data.response - def _rollout_existing_revision_deployments_revisions_deployment_id_revision_number_put_serialize( + def _setup_stripe_customer_payments_setup_post_serialize( self, - deployment_id, - revision_number, - rollout_strategy_params, _request_auth, _content_type, _headers, @@ -12838,16 +14269,10 @@ def _rollout_existing_revision_deployments_revisions_deployment_id_revision_numb _body_params: Optional[bytes] = None # process the path parameters - if deployment_id is not None: - _path_params['deployment_id'] = deployment_id - if revision_number is not None: - _path_params['revision_number'] = revision_number # process the query parameters # process the header parameters # process the form parameters # process the body parameter - if rollout_strategy_params is not None: - _body_params = rollout_strategy_params # set the HTTP header `Accept` @@ -12858,19 +14283,6 @@ def _rollout_existing_revision_deployments_revisions_deployment_id_revision_numb ] ) - # set the HTTP header `Content-Type` - if _content_type: - _header_params['Content-Type'] = _content_type - else: - _default_content_type = ( - self.api_client.select_header_content_type( - [ - 'application/json' - ] - ) - ) - if _default_content_type is not None: - _header_params['Content-Type'] = _default_content_type # authentication setting _auth_settings: List[str] = [ @@ -12878,8 +14290,8 @@ def _rollout_existing_revision_deployments_revisions_deployment_id_revision_numb ] return self.api_client.param_serialize( - method='PUT', - resource_path='/deployments/revisions/{deployment_id}/{revision_number}', + method='POST', + resource_path='/payments/setup', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -12896,8 +14308,10 @@ def _rollout_existing_revision_deployments_revisions_deployment_id_revision_numb @validate_call - def setup_stripe_customer_payments_setup_post( + def update_cluster_clusters_cluster_id_put( self, + cluster_id: StrictInt, + cluster_config: ClusterConfig, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -12911,9 +14325,13 @@ def setup_stripe_customer_payments_setup_post( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> object: - """Setup Stripe Customer + """Update Cluster + :param cluster_id: (required) + :type cluster_id: int + :param cluster_config: (required) + :type cluster_config: ClusterConfig :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -12936,7 +14354,9 @@ def setup_stripe_customer_payments_setup_post( :return: Returns the result object. """ # noqa: E501 - _param = self._setup_stripe_customer_payments_setup_post_serialize( + _param = self._update_cluster_clusters_cluster_id_put_serialize( + cluster_id=cluster_id, + cluster_config=cluster_config, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -12945,6 +14365,7 @@ def setup_stripe_customer_payments_setup_post( _response_types_map: Dict[str, Optional[str]] = { '200': "object", + '422': "HTTPValidationError", } response_data = self.api_client.call_api( *_param, @@ -12958,8 +14379,10 @@ def setup_stripe_customer_payments_setup_post( @validate_call - def setup_stripe_customer_payments_setup_post_with_http_info( + def update_cluster_clusters_cluster_id_put_with_http_info( self, + cluster_id: StrictInt, + cluster_config: ClusterConfig, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -12973,9 +14396,13 @@ def setup_stripe_customer_payments_setup_post_with_http_info( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> ApiResponse[object]: - """Setup Stripe Customer + """Update Cluster + :param cluster_id: (required) + :type cluster_id: int + :param cluster_config: (required) + :type cluster_config: ClusterConfig :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -12998,7 +14425,9 @@ def setup_stripe_customer_payments_setup_post_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._setup_stripe_customer_payments_setup_post_serialize( + _param = self._update_cluster_clusters_cluster_id_put_serialize( + cluster_id=cluster_id, + cluster_config=cluster_config, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -13007,6 +14436,7 @@ def setup_stripe_customer_payments_setup_post_with_http_info( _response_types_map: Dict[str, Optional[str]] = { '200': "object", + '422': "HTTPValidationError", } response_data = self.api_client.call_api( *_param, @@ -13020,8 +14450,10 @@ def setup_stripe_customer_payments_setup_post_with_http_info( @validate_call - def setup_stripe_customer_payments_setup_post_without_preload_content( + def update_cluster_clusters_cluster_id_put_without_preload_content( self, + cluster_id: StrictInt, + cluster_config: ClusterConfig, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -13035,9 +14467,13 @@ def setup_stripe_customer_payments_setup_post_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Setup Stripe Customer + """Update Cluster + :param cluster_id: (required) + :type cluster_id: int + :param cluster_config: (required) + :type cluster_config: ClusterConfig :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -13060,7 +14496,9 @@ def setup_stripe_customer_payments_setup_post_without_preload_content( :return: Returns the result object. """ # noqa: E501 - _param = self._setup_stripe_customer_payments_setup_post_serialize( + _param = self._update_cluster_clusters_cluster_id_put_serialize( + cluster_id=cluster_id, + cluster_config=cluster_config, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -13069,6 +14507,7 @@ def setup_stripe_customer_payments_setup_post_without_preload_content( _response_types_map: Dict[str, Optional[str]] = { '200': "object", + '422': "HTTPValidationError", } response_data = self.api_client.call_api( *_param, @@ -13077,8 +14516,10 @@ def setup_stripe_customer_payments_setup_post_without_preload_content( return response_data.response - def _setup_stripe_customer_payments_setup_post_serialize( + def _update_cluster_clusters_cluster_id_put_serialize( self, + cluster_id, + cluster_config, _request_auth, _content_type, _headers, @@ -13100,10 +14541,14 @@ def _setup_stripe_customer_payments_setup_post_serialize( _body_params: Optional[bytes] = None # process the path parameters + if cluster_id is not None: + _path_params['cluster_id'] = cluster_id # process the query parameters # process the header parameters # process the form parameters # process the body parameter + if cluster_config is not None: + _body_params = cluster_config # set the HTTP header `Accept` @@ -13114,6 +14559,19 @@ def _setup_stripe_customer_payments_setup_post_serialize( ] ) + # set the HTTP header `Content-Type` + if _content_type: + _header_params['Content-Type'] = _content_type + else: + _default_content_type = ( + self.api_client.select_header_content_type( + [ + 'application/json' + ] + ) + ) + if _default_content_type is not None: + _header_params['Content-Type'] = _default_content_type # authentication setting _auth_settings: List[str] = [ @@ -13121,8 +14579,8 @@ def _setup_stripe_customer_payments_setup_post_serialize( ] return self.api_client.param_serialize( - method='POST', - resource_path='/payments/setup', + method='PUT', + resource_path='/clusters/{cluster_id}', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -13139,10 +14597,10 @@ def _setup_stripe_customer_payments_setup_post_serialize( @validate_call - def update_cluster_clusters_cluster_id_put( + def update_cluster_metadata_clusters_cluster_id_metadata_put( self, cluster_id: StrictInt, - cluster_config: ClusterConfig, + update_cluster_metadata_request: UpdateClusterMetadataRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -13155,14 +14613,15 @@ def update_cluster_clusters_cluster_id_put( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> object: - """Update Cluster + ) -> GetClusterResponse: + """Update Cluster Metadata + Update DB metadata for an org-owned cluster. Does not drive infra stack updates. Global clusters (parent_id IS NULL) are not mutable here. :param cluster_id: (required) :type cluster_id: int - :param cluster_config: (required) - :type cluster_config: ClusterConfig + :param update_cluster_metadata_request: (required) + :type update_cluster_metadata_request: UpdateClusterMetadataRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -13185,9 +14644,9 @@ def update_cluster_clusters_cluster_id_put( :return: Returns the result object. """ # noqa: E501 - _param = self._update_cluster_clusters_cluster_id_put_serialize( + _param = self._update_cluster_metadata_clusters_cluster_id_metadata_put_serialize( cluster_id=cluster_id, - cluster_config=cluster_config, + update_cluster_metadata_request=update_cluster_metadata_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -13195,7 +14654,7 @@ def update_cluster_clusters_cluster_id_put( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "object", + '200': "GetClusterResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -13210,10 +14669,10 @@ def update_cluster_clusters_cluster_id_put( @validate_call - def update_cluster_clusters_cluster_id_put_with_http_info( + def update_cluster_metadata_clusters_cluster_id_metadata_put_with_http_info( self, cluster_id: StrictInt, - cluster_config: ClusterConfig, + update_cluster_metadata_request: UpdateClusterMetadataRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -13226,14 +14685,15 @@ def update_cluster_clusters_cluster_id_put_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[object]: - """Update Cluster + ) -> ApiResponse[GetClusterResponse]: + """Update Cluster Metadata + Update DB metadata for an org-owned cluster. Does not drive infra stack updates. Global clusters (parent_id IS NULL) are not mutable here. :param cluster_id: (required) :type cluster_id: int - :param cluster_config: (required) - :type cluster_config: ClusterConfig + :param update_cluster_metadata_request: (required) + :type update_cluster_metadata_request: UpdateClusterMetadataRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -13256,9 +14716,9 @@ def update_cluster_clusters_cluster_id_put_with_http_info( :return: Returns the result object. """ # noqa: E501 - _param = self._update_cluster_clusters_cluster_id_put_serialize( + _param = self._update_cluster_metadata_clusters_cluster_id_metadata_put_serialize( cluster_id=cluster_id, - cluster_config=cluster_config, + update_cluster_metadata_request=update_cluster_metadata_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -13266,7 +14726,7 @@ def update_cluster_clusters_cluster_id_put_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "object", + '200': "GetClusterResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -13281,10 +14741,10 @@ def update_cluster_clusters_cluster_id_put_with_http_info( @validate_call - def update_cluster_clusters_cluster_id_put_without_preload_content( + def update_cluster_metadata_clusters_cluster_id_metadata_put_without_preload_content( self, cluster_id: StrictInt, - cluster_config: ClusterConfig, + update_cluster_metadata_request: UpdateClusterMetadataRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -13298,13 +14758,14 @@ def update_cluster_clusters_cluster_id_put_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Update Cluster + """Update Cluster Metadata + Update DB metadata for an org-owned cluster. Does not drive infra stack updates. Global clusters (parent_id IS NULL) are not mutable here. :param cluster_id: (required) :type cluster_id: int - :param cluster_config: (required) - :type cluster_config: ClusterConfig + :param update_cluster_metadata_request: (required) + :type update_cluster_metadata_request: UpdateClusterMetadataRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -13327,9 +14788,9 @@ def update_cluster_clusters_cluster_id_put_without_preload_content( :return: Returns the result object. """ # noqa: E501 - _param = self._update_cluster_clusters_cluster_id_put_serialize( + _param = self._update_cluster_metadata_clusters_cluster_id_metadata_put_serialize( cluster_id=cluster_id, - cluster_config=cluster_config, + update_cluster_metadata_request=update_cluster_metadata_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -13337,7 +14798,7 @@ def update_cluster_clusters_cluster_id_put_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "object", + '200': "GetClusterResponse", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -13347,10 +14808,10 @@ def update_cluster_clusters_cluster_id_put_without_preload_content( return response_data.response - def _update_cluster_clusters_cluster_id_put_serialize( + def _update_cluster_metadata_clusters_cluster_id_metadata_put_serialize( self, cluster_id, - cluster_config, + update_cluster_metadata_request, _request_auth, _content_type, _headers, @@ -13378,8 +14839,8 @@ def _update_cluster_clusters_cluster_id_put_serialize( # process the header parameters # process the form parameters # process the body parameter - if cluster_config is not None: - _body_params = cluster_config + if update_cluster_metadata_request is not None: + _body_params = update_cluster_metadata_request # set the HTTP header `Accept` @@ -13411,7 +14872,7 @@ def _update_cluster_clusters_cluster_id_put_serialize( return self.api_client.param_serialize( method='PUT', - resource_path='/clusters/{cluster_id}', + resource_path='/clusters/{cluster_id}/metadata', path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -15951,7 +17412,7 @@ def _update_service_account_service_accounts_workos_id_put_serialize( @validate_call def update_user_vault_item_endpoint_user_vault_put( self, - user_vault_item: UserVaultItem, + upsert_user_vault_item_request: UpsertUserVaultItemRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -15964,13 +17425,13 @@ def update_user_vault_item_endpoint_user_vault_put( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> object: + ) -> UserVaultItem: """Update User Vault Item Endpoint - Update or add an item of a specific type for the user. + Create or update a vault item, writing its value to both SSM and PostgreSQL. The key and value rules are declared on UpsertUserVaultItemRequest, so a malformed write is rejected with a 422 before this handler runs. - :param user_vault_item: (required) - :type user_vault_item: UserVaultItem + :param upsert_user_vault_item_request: (required) + :type upsert_user_vault_item_request: UpsertUserVaultItemRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -15994,7 +17455,7 @@ def update_user_vault_item_endpoint_user_vault_put( """ # noqa: E501 _param = self._update_user_vault_item_endpoint_user_vault_put_serialize( - user_vault_item=user_vault_item, + upsert_user_vault_item_request=upsert_user_vault_item_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -16002,7 +17463,7 @@ def update_user_vault_item_endpoint_user_vault_put( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "object", + '200': "UserVaultItem", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -16019,7 +17480,7 @@ def update_user_vault_item_endpoint_user_vault_put( @validate_call def update_user_vault_item_endpoint_user_vault_put_with_http_info( self, - user_vault_item: UserVaultItem, + upsert_user_vault_item_request: UpsertUserVaultItemRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -16032,13 +17493,13 @@ def update_user_vault_item_endpoint_user_vault_put_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[object]: + ) -> ApiResponse[UserVaultItem]: """Update User Vault Item Endpoint - Update or add an item of a specific type for the user. + Create or update a vault item, writing its value to both SSM and PostgreSQL. The key and value rules are declared on UpsertUserVaultItemRequest, so a malformed write is rejected with a 422 before this handler runs. - :param user_vault_item: (required) - :type user_vault_item: UserVaultItem + :param upsert_user_vault_item_request: (required) + :type upsert_user_vault_item_request: UpsertUserVaultItemRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -16062,7 +17523,7 @@ def update_user_vault_item_endpoint_user_vault_put_with_http_info( """ # noqa: E501 _param = self._update_user_vault_item_endpoint_user_vault_put_serialize( - user_vault_item=user_vault_item, + upsert_user_vault_item_request=upsert_user_vault_item_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -16070,7 +17531,7 @@ def update_user_vault_item_endpoint_user_vault_put_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "object", + '200': "UserVaultItem", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -16087,7 +17548,7 @@ def update_user_vault_item_endpoint_user_vault_put_with_http_info( @validate_call def update_user_vault_item_endpoint_user_vault_put_without_preload_content( self, - user_vault_item: UserVaultItem, + upsert_user_vault_item_request: UpsertUserVaultItemRequest, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -16103,10 +17564,10 @@ def update_user_vault_item_endpoint_user_vault_put_without_preload_content( ) -> RESTResponseType: """Update User Vault Item Endpoint - Update or add an item of a specific type for the user. + Create or update a vault item, writing its value to both SSM and PostgreSQL. The key and value rules are declared on UpsertUserVaultItemRequest, so a malformed write is rejected with a 422 before this handler runs. - :param user_vault_item: (required) - :type user_vault_item: UserVaultItem + :param upsert_user_vault_item_request: (required) + :type upsert_user_vault_item_request: UpsertUserVaultItemRequest :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -16130,7 +17591,7 @@ def update_user_vault_item_endpoint_user_vault_put_without_preload_content( """ # noqa: E501 _param = self._update_user_vault_item_endpoint_user_vault_put_serialize( - user_vault_item=user_vault_item, + upsert_user_vault_item_request=upsert_user_vault_item_request, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -16138,7 +17599,7 @@ def update_user_vault_item_endpoint_user_vault_put_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - '200': "object", + '200': "UserVaultItem", '422': "HTTPValidationError", } response_data = self.api_client.call_api( @@ -16150,7 +17611,7 @@ def update_user_vault_item_endpoint_user_vault_put_without_preload_content( def _update_user_vault_item_endpoint_user_vault_put_serialize( self, - user_vault_item, + upsert_user_vault_item_request, _request_auth, _content_type, _headers, @@ -16176,8 +17637,8 @@ def _update_user_vault_item_endpoint_user_vault_put_serialize( # process the header parameters # process the form parameters # process the body parameter - if user_vault_item is not None: - _body_params = user_vault_item + if upsert_user_vault_item_request is not None: + _body_params = upsert_user_vault_item_request # set the HTTP header `Accept` diff --git a/platform_api_python_client/api_client.py b/platform_api_python_client/api_client.py index 3d882c0..0cd9af5 100644 --- a/platform_api_python_client/api_client.py +++ b/platform_api_python_client/api_client.py @@ -90,7 +90,7 @@ def __init__( self.default_headers[header_name] = header_value self.cookie = cookie # Set default User-Agent. - self.user_agent = 'OpenAPI-Generator/4.23.1/python' + self.user_agent = 'OpenAPI-Generator/4.25.0/python' self.client_side_validation = configuration.client_side_validation def __enter__(self): diff --git a/platform_api_python_client/configuration.py b/platform_api_python_client/configuration.py index ce69e3e..c9287f5 100644 --- a/platform_api_python_client/configuration.py +++ b/platform_api_python_client/configuration.py @@ -392,7 +392,7 @@ def to_debug_report(self): "OS: {env}\n"\ "Python Version: {pyversion}\n"\ "Version of the API: 0.1.0\n"\ - "SDK Package Version: 4.23.1".\ + "SDK Package Version: 4.25.0".\ format(env=sys.platform, pyversion=sys.version) def get_host_settings(self): diff --git a/platform_api_python_client/models/__init__.py b/platform_api_python_client/models/__init__.py index d7bd6fe..0d0c253 100644 --- a/platform_api_python_client/models/__init__.py +++ b/platform_api_python_client/models/__init__.py @@ -28,7 +28,6 @@ from platform_api_python_client.models.cluster_registration_request import ClusterRegistrationRequest from platform_api_python_client.models.cluster_registration_response import ClusterRegistrationResponse from platform_api_python_client.models.config_file_mount import ConfigFileMount -from platform_api_python_client.models.create_block_volume_request import CreateBlockVolumeRequest from platform_api_python_client.models.create_c_serve_v2_deployment_response import CreateCServeV2DeploymentResponse from platform_api_python_client.models.create_c_serve_v3_deployment_request import CreateCServeV3DeploymentRequest from platform_api_python_client.models.create_c_serve_v3_deployment_response import CreateCServeV3DeploymentResponse @@ -36,6 +35,7 @@ from platform_api_python_client.models.create_compute_deployment_response import CreateComputeDeploymentResponse from platform_api_python_client.models.create_dynamo_deployment_request import CreateDynamoDeploymentRequest from platform_api_python_client.models.create_dynamo_deployment_response import CreateDynamoDeploymentResponse +from platform_api_python_client.models.create_filesystem_volume_request import CreateFilesystemVolumeRequest from platform_api_python_client.models.create_hardware_instance_request import CreateHardwareInstanceRequest from platform_api_python_client.models.create_inference_deployment_response import CreateInferenceDeploymentResponse from platform_api_python_client.models.create_inference_v3_deployment_request import CreateInferenceV3DeploymentRequest @@ -49,7 +49,9 @@ from platform_api_python_client.models.create_volume_request import CreateVolumeRequest from platform_api_python_client.models.credits_response import CreditsResponse from platform_api_python_client.models.daily_bill_response import DailyBillResponse +from platform_api_python_client.models.delete_user_vault_item_request import DeleteUserVaultItemRequest from platform_api_python_client.models.deployment_component_type import DeploymentComponentType +from platform_api_python_client.models.deployment_log_event_v4 import DeploymentLogEventV4 from platform_api_python_client.models.deployment_response import DeploymentResponse from platform_api_python_client.models.deployment_status import DeploymentStatus from platform_api_python_client.models.deployment_status_request import DeploymentStatusRequest @@ -58,20 +60,25 @@ from platform_api_python_client.models.deployment_type import DeploymentType from platform_api_python_client.models.deployment_usage import DeploymentUsage from platform_api_python_client.models.deployment_usage_value import DeploymentUsageValue +from platform_api_python_client.models.dynamo_serving_mode import DynamoServingMode +from platform_api_python_client.models.dynamo_worker_pool_config import DynamoWorkerPoolConfig +from platform_api_python_client.models.dynamo_worker_pools import DynamoWorkerPools from platform_api_python_client.models.external_dns import ExternalDns from platform_api_python_client.models.final_stack import FinalStack from platform_api_python_client.models.fluent_bit import FluentBit from platform_api_python_client.models.generate_service_account_secret_response import GenerateServiceAccountSecretResponse -from platform_api_python_client.models.get_block_volume_response import GetBlockVolumeResponse from platform_api_python_client.models.get_c_serve_v2_deployment_response import GetCServeV2DeploymentResponse from platform_api_python_client.models.get_c_serve_v3_deployment_response import GetCServeV3DeploymentResponse from platform_api_python_client.models.get_cluster_response import GetClusterResponse from platform_api_python_client.models.get_compute_deployment_response import GetComputeDeploymentResponse from platform_api_python_client.models.get_deployment_log_response import GetDeploymentLogResponse +from platform_api_python_client.models.get_deployment_log_v4_response import GetDeploymentLogV4Response +from platform_api_python_client.models.get_deployment_pods_response import GetDeploymentPodsResponse from platform_api_python_client.models.get_deployment_response import GetDeploymentResponse from platform_api_python_client.models.get_deployment_revision_response import GetDeploymentRevisionResponse from platform_api_python_client.models.get_deployment_usage_response import GetDeploymentUsageResponse from platform_api_python_client.models.get_dynamo_deployment_response import GetDynamoDeploymentResponse +from platform_api_python_client.models.get_filesystem_volume_response import GetFilesystemVolumeResponse from platform_api_python_client.models.get_inference_deployment_response import GetInferenceDeploymentResponse from platform_api_python_client.models.get_inference_v3_deployment_response import GetInferenceV3DeploymentResponse from platform_api_python_client.models.get_job_deployment_response import GetJobDeploymentResponse @@ -120,9 +127,11 @@ from platform_api_python_client.models.spire import Spire from platform_api_python_client.models.spire_crds import SpireCrds from platform_api_python_client.models.teleport_kube_agent import TeleportKubeAgent +from platform_api_python_client.models.update_cluster_metadata_request import UpdateClusterMetadataRequest from platform_api_python_client.models.update_deployment_response import UpdateDeploymentResponse from platform_api_python_client.models.update_deployment_status_v3_request import UpdateDeploymentStatusV3Request from platform_api_python_client.models.update_service_account_request import UpdateServiceAccountRequest +from platform_api_python_client.models.upsert_user_vault_item_request import UpsertUserVaultItemRequest from platform_api_python_client.models.user_vault_item import UserVaultItem from platform_api_python_client.models.user_vault_type import UserVaultType from platform_api_python_client.models.validation_error import ValidationError diff --git a/platform_api_python_client/models/create_dynamo_deployment_request.py b/platform_api_python_client/models/create_dynamo_deployment_request.py index 6a30ed2..eda0fca 100644 --- a/platform_api_python_client/models/create_dynamo_deployment_request.py +++ b/platform_api_python_client/models/create_dynamo_deployment_request.py @@ -21,20 +21,24 @@ from typing import Any, ClassVar, Dict, List, Optional from typing_extensions import Annotated from platform_api_python_client.models.backend_protocol import BackendProtocol +from platform_api_python_client.models.dynamo_serving_mode import DynamoServingMode +from platform_api_python_client.models.dynamo_worker_pools import DynamoWorkerPools from typing import Optional, Set from typing_extensions import Self class CreateDynamoDeploymentRequest(BaseModel): """ - Create a NVIDIA Dynamo (DynamoGraphDeployment) inference deployment. Aggregated + KV-router pattern with a vLLM backend. The Frontend pod enables KV-aware routing across worker replicas. + Create a Dynamo deployment. Aggregated mode requires ``hardware_instance_id``; disaggregated mode requires fixed-size ``worker_pools``. """ # noqa: E501 max_surge: Optional[StrictInt] = None max_unavailable: Optional[StrictInt] = None name: Annotated[str, Field(min_length=1, strict=True, max_length=20)] cluster_id: StrictInt - hardware_instance_id: StrictInt + hardware_instance_id: Optional[StrictInt] = None user_annotations: Optional[Dict[str, StrictStr]] = None chart_revision: Optional[StrictStr] = None + serving_mode: Optional[DynamoServingMode] = None + worker_pools: Optional[DynamoWorkerPools] = None model: StrictStr served_model_name: Optional[StrictStr] = None min_replicas: Optional[StrictInt] = 1 @@ -49,7 +53,7 @@ class CreateDynamoDeploymentRequest(BaseModel): enable_logging: Optional[StrictBool] = True enable_node_model_cache: Optional[StrictBool] = False backend_protocol: Optional[BackendProtocol] = None - __properties: ClassVar[List[str]] = ["max_surge", "max_unavailable", "name", "cluster_id", "hardware_instance_id", "user_annotations", "chart_revision", "model", "served_model_name", "min_replicas", "max_replicas", "concurrency", "cooldown_period", "extra_args", "hf_token", "env_vars", "endpoint_bearer_token", "endpoint_certificate_authority", "enable_logging", "enable_node_model_cache", "backend_protocol"] + __properties: ClassVar[List[str]] = ["max_surge", "max_unavailable", "name", "cluster_id", "hardware_instance_id", "user_annotations", "chart_revision", "serving_mode", "worker_pools", "model", "served_model_name", "min_replicas", "max_replicas", "concurrency", "cooldown_period", "extra_args", "hf_token", "env_vars", "endpoint_bearer_token", "endpoint_certificate_authority", "enable_logging", "enable_node_model_cache", "backend_protocol"] @field_validator('name') def name_validate_regular_expression(cls, value): @@ -97,6 +101,9 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) + # override the default output from pydantic by calling `to_dict()` of worker_pools + if self.worker_pools: + _dict['worker_pools'] = self.worker_pools.to_dict() # set to None if max_surge (nullable) is None # and model_fields_set contains the field if self.max_surge is None and "max_surge" in self.model_fields_set: @@ -107,11 +114,21 @@ def to_dict(self) -> Dict[str, Any]: if self.max_unavailable is None and "max_unavailable" in self.model_fields_set: _dict['max_unavailable'] = None + # set to None if hardware_instance_id (nullable) is None + # and model_fields_set contains the field + if self.hardware_instance_id is None and "hardware_instance_id" in self.model_fields_set: + _dict['hardware_instance_id'] = None + # set to None if user_annotations (nullable) is None # and model_fields_set contains the field if self.user_annotations is None and "user_annotations" in self.model_fields_set: _dict['user_annotations'] = None + # set to None if worker_pools (nullable) is None + # and model_fields_set contains the field + if self.worker_pools is None and "worker_pools" in self.model_fields_set: + _dict['worker_pools'] = None + # set to None if served_model_name (nullable) is None # and model_fields_set contains the field if self.served_model_name is None and "served_model_name" in self.model_fields_set: @@ -166,6 +183,8 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "hardware_instance_id": obj.get("hardware_instance_id"), "user_annotations": obj.get("user_annotations"), "chart_revision": obj.get("chart_revision"), + "serving_mode": obj.get("serving_mode"), + "worker_pools": DynamoWorkerPools.from_dict(obj["worker_pools"]) if obj.get("worker_pools") is not None else None, "model": obj.get("model"), "served_model_name": obj.get("served_model_name"), "min_replicas": obj.get("min_replicas") if obj.get("min_replicas") is not None else 1, diff --git a/platform_api_python_client/models/create_block_volume_request.py b/platform_api_python_client/models/create_filesystem_volume_request.py similarity index 91% rename from platform_api_python_client/models/create_block_volume_request.py rename to platform_api_python_client/models/create_filesystem_volume_request.py index 6e277c1..6bae519 100644 --- a/platform_api_python_client/models/create_block_volume_request.py +++ b/platform_api_python_client/models/create_filesystem_volume_request.py @@ -23,9 +23,9 @@ from typing import Optional, Set from typing_extensions import Self -class CreateBlockVolumeRequest(BaseModel): +class CreateFilesystemVolumeRequest(BaseModel): """ - CreateBlockVolumeRequest + CreateFilesystemVolumeRequest """ # noqa: E501 name: Annotated[str, Field(min_length=1, strict=True, max_length=20)] cluster_id: StrictInt @@ -44,8 +44,8 @@ def name_validate_regular_expression(cls, value): @field_validator('backend') def backend_validate_enum(cls, value): """Validates the enum""" - if value not in set(['block']): - raise ValueError("must be one of enum values ('block')") + if value not in set(['filesystem']): + raise ValueError("must be one of enum values ('filesystem')") return value @field_validator('storage_class') @@ -76,7 +76,7 @@ def to_json(self) -> str: @classmethod def from_json(cls, json_str: str) -> Optional[Self]: - """Create an instance of CreateBlockVolumeRequest from a JSON string""" + """Create an instance of CreateFilesystemVolumeRequest from a JSON string""" return cls.from_dict(json.loads(json_str)) def to_dict(self) -> Dict[str, Any]: @@ -106,7 +106,7 @@ def to_dict(self) -> Dict[str, Any]: @classmethod def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: - """Create an instance of CreateBlockVolumeRequest from a dict""" + """Create an instance of CreateFilesystemVolumeRequest from a dict""" if obj is None: return None diff --git a/platform_api_python_client/models/create_volume_request.py b/platform_api_python_client/models/create_volume_request.py index fb1deea..be6d948 100644 --- a/platform_api_python_client/models/create_volume_request.py +++ b/platform_api_python_client/models/create_volume_request.py @@ -17,24 +17,24 @@ import pprint from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator from typing import Any, List, Optional -from platform_api_python_client.models.create_block_volume_request import CreateBlockVolumeRequest +from platform_api_python_client.models.create_filesystem_volume_request import CreateFilesystemVolumeRequest from platform_api_python_client.models.create_object_volume_request import CreateObjectVolumeRequest from pydantic import StrictStr, Field from typing import Union, List, Set, Optional, Dict from typing_extensions import Literal, Self -CREATEVOLUMEREQUEST_ONE_OF_SCHEMAS = ["CreateBlockVolumeRequest", "CreateObjectVolumeRequest"] +CREATEVOLUMEREQUEST_ONE_OF_SCHEMAS = ["CreateFilesystemVolumeRequest", "CreateObjectVolumeRequest"] class CreateVolumeRequest(BaseModel): """ CreateVolumeRequest """ - # data type: CreateBlockVolumeRequest - oneof_schema_1_validator: Optional[CreateBlockVolumeRequest] = None + # data type: CreateFilesystemVolumeRequest + oneof_schema_1_validator: Optional[CreateFilesystemVolumeRequest] = None # data type: CreateObjectVolumeRequest oneof_schema_2_validator: Optional[CreateObjectVolumeRequest] = None - actual_instance: Optional[Union[CreateBlockVolumeRequest, CreateObjectVolumeRequest]] = None - one_of_schemas: Set[str] = { "CreateBlockVolumeRequest", "CreateObjectVolumeRequest" } + actual_instance: Optional[Union[CreateFilesystemVolumeRequest, CreateObjectVolumeRequest]] = None + one_of_schemas: Set[str] = { "CreateFilesystemVolumeRequest", "CreateObjectVolumeRequest" } model_config = ConfigDict( validate_assignment=True, @@ -60,9 +60,9 @@ def actual_instance_must_validate_oneof(cls, v): instance = CreateVolumeRequest.model_construct() error_messages = [] match = 0 - # validate data type: CreateBlockVolumeRequest - if not isinstance(v, CreateBlockVolumeRequest): - error_messages.append(f"Error! Input type `{type(v)}` is not `CreateBlockVolumeRequest`") + # validate data type: CreateFilesystemVolumeRequest + if not isinstance(v, CreateFilesystemVolumeRequest): + error_messages.append(f"Error! Input type `{type(v)}` is not `CreateFilesystemVolumeRequest`") else: match += 1 # validate data type: CreateObjectVolumeRequest @@ -72,10 +72,10 @@ def actual_instance_must_validate_oneof(cls, v): match += 1 if match > 1: # more than 1 match - raise ValueError("Multiple matches found when setting `actual_instance` in CreateVolumeRequest with oneOf schemas: CreateBlockVolumeRequest, CreateObjectVolumeRequest. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when setting `actual_instance` in CreateVolumeRequest with oneOf schemas: CreateFilesystemVolumeRequest, CreateObjectVolumeRequest. Details: " + ", ".join(error_messages)) elif match == 0: # no match - raise ValueError("No match found when setting `actual_instance` in CreateVolumeRequest with oneOf schemas: CreateBlockVolumeRequest, CreateObjectVolumeRequest. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when setting `actual_instance` in CreateVolumeRequest with oneOf schemas: CreateFilesystemVolumeRequest, CreateObjectVolumeRequest. Details: " + ", ".join(error_messages)) else: return v @@ -90,9 +90,9 @@ def from_json(cls, json_str: str) -> Self: error_messages = [] match = 0 - # deserialize data into CreateBlockVolumeRequest + # deserialize data into CreateFilesystemVolumeRequest try: - instance.actual_instance = CreateBlockVolumeRequest.from_json(json_str) + instance.actual_instance = CreateFilesystemVolumeRequest.from_json(json_str) match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) @@ -105,10 +105,10 @@ def from_json(cls, json_str: str) -> Self: if match > 1: # more than 1 match - raise ValueError("Multiple matches found when deserializing the JSON string into CreateVolumeRequest with oneOf schemas: CreateBlockVolumeRequest, CreateObjectVolumeRequest. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when deserializing the JSON string into CreateVolumeRequest with oneOf schemas: CreateFilesystemVolumeRequest, CreateObjectVolumeRequest. Details: " + ", ".join(error_messages)) elif match == 0: # no match - raise ValueError("No match found when deserializing the JSON string into CreateVolumeRequest with oneOf schemas: CreateBlockVolumeRequest, CreateObjectVolumeRequest. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when deserializing the JSON string into CreateVolumeRequest with oneOf schemas: CreateFilesystemVolumeRequest, CreateObjectVolumeRequest. Details: " + ", ".join(error_messages)) else: return instance @@ -122,7 +122,7 @@ def to_json(self) -> str: else: return json.dumps(self.actual_instance) - def to_dict(self) -> Optional[Union[Dict[str, Any], CreateBlockVolumeRequest, CreateObjectVolumeRequest]]: + def to_dict(self) -> Optional[Union[Dict[str, Any], CreateFilesystemVolumeRequest, CreateObjectVolumeRequest]]: """Returns the dict representation of the actual instance""" if self.actual_instance is None: return None diff --git a/platform_api_python_client/models/delete_user_vault_item_request.py b/platform_api_python_client/models/delete_user_vault_item_request.py new file mode 100644 index 0000000..38316d2 --- /dev/null +++ b/platform_api_python_client/models/delete_user_vault_item_request.py @@ -0,0 +1,108 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictStr +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from platform_api_python_client.models.user_vault_type import UserVaultType +from platform_api_python_client.models.vault_scope import VaultScope +from typing import Optional, Set +from typing_extensions import Self + +class DeleteUserVaultItemRequest(BaseModel): + """ + Body for the legacy delete, deliberately permissive. Kept separate from UserVaultItem so that model can require `id`. Here `id` stays optional because resolving by (type, key, visibility) is the only way to delete a row for which the client was never handed an id, and `value` is accepted and ignored because old clients send back a whole vault item. + """ # noqa: E501 + id: Optional[Annotated[int, Field(strict=True, ge=1)]] = None + type: UserVaultType + key: StrictStr + value: Optional[StrictStr] = None + visibility: Optional[VaultScope] = None + __properties: ClassVar[List[str]] = ["id", "type", "key", "value", "visibility"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeleteUserVaultItemRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if id (nullable) is None + # and model_fields_set contains the field + if self.id is None and "id" in self.model_fields_set: + _dict['id'] = None + + # set to None if value (nullable) is None + # and model_fields_set contains the field + if self.value is None and "value" in self.model_fields_set: + _dict['value'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeleteUserVaultItemRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "type": obj.get("type"), + "key": obj.get("key"), + "value": obj.get("value"), + "visibility": obj.get("visibility") + }) + return _obj + + diff --git a/platform_api_python_client/models/deployment_component_type.py b/platform_api_python_client/models/deployment_component_type.py index b2509e8..656f581 100644 --- a/platform_api_python_client/models/deployment_component_type.py +++ b/platform_api_python_client/models/deployment_component_type.py @@ -38,3 +38,5 @@ class DeploymentComponentType(str, Enum): def from_json(cls, json_str: str) -> Self: """Create an instance of DeploymentComponentType from a JSON string""" return cls(json.loads(json_str)) + + diff --git a/platform_api_python_client/models/deployment_log_event_v4.py b/platform_api_python_client/models/deployment_log_event_v4.py new file mode 100644 index 0000000..913dd20 --- /dev/null +++ b/platform_api_python_client/models/deployment_log_event_v4.py @@ -0,0 +1,91 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self + +class DeploymentLogEventV4(BaseModel): + """ + DeploymentLogEventV4 + """ # noqa: E501 + id: StrictStr = Field(description="Stable event identity: '-'. Deduplication key for the re-deliveries of fetch_newer pages; its nanosecond prefix orders events (sorted insert for late arrivals, never append).") + timestamp: StrictInt = Field(description="Event timestamp in epoch milliseconds.") + message: StrictStr = Field(description="Raw log line as emitted by the container.") + __properties: ClassVar[List[str]] = ["id", "timestamp", "message"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DeploymentLogEventV4 from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DeploymentLogEventV4 from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "timestamp": obj.get("timestamp"), + "message": obj.get("message") + }) + return _obj + + diff --git a/platform_api_python_client/models/deployment_response.py b/platform_api_python_client/models/deployment_response.py index e33543d..5b91901 100644 --- a/platform_api_python_client/models/deployment_response.py +++ b/platform_api_python_client/models/deployment_response.py @@ -20,13 +20,14 @@ from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator from typing import Optional from platform_api_python_client.models.get_c_serve_v3_deployment_response import GetCServeV3DeploymentResponse +from platform_api_python_client.models.get_compute_deployment_response import GetComputeDeploymentResponse from platform_api_python_client.models.get_dynamo_deployment_response import GetDynamoDeploymentResponse from platform_api_python_client.models.get_inference_v3_deployment_response import GetInferenceV3DeploymentResponse from typing import Union, Any, List, Set, TYPE_CHECKING, Optional, Dict from typing_extensions import Literal, Self from pydantic import Field -DEPLOYMENTRESPONSE_ANY_OF_SCHEMAS = ["GetCServeV3DeploymentResponse", "GetDynamoDeploymentResponse", "GetInferenceV3DeploymentResponse"] +DEPLOYMENTRESPONSE_ANY_OF_SCHEMAS = ["GetCServeV3DeploymentResponse", "GetComputeDeploymentResponse", "GetDynamoDeploymentResponse", "GetInferenceV3DeploymentResponse"] class DeploymentResponse(BaseModel): """ @@ -39,11 +40,13 @@ class DeploymentResponse(BaseModel): anyof_schema_2_validator: Optional[GetCServeV3DeploymentResponse] = None # data type: GetInferenceV3DeploymentResponse anyof_schema_3_validator: Optional[GetInferenceV3DeploymentResponse] = None + # data type: GetComputeDeploymentResponse + anyof_schema_4_validator: Optional[GetComputeDeploymentResponse] = None if TYPE_CHECKING: - actual_instance: Optional[Union[GetCServeV3DeploymentResponse, GetDynamoDeploymentResponse, GetInferenceV3DeploymentResponse]] = None + actual_instance: Optional[Union[GetCServeV3DeploymentResponse, GetComputeDeploymentResponse, GetDynamoDeploymentResponse, GetInferenceV3DeploymentResponse]] = None else: actual_instance: Any = None - any_of_schemas: Set[str] = { "GetCServeV3DeploymentResponse", "GetDynamoDeploymentResponse", "GetInferenceV3DeploymentResponse" } + any_of_schemas: Set[str] = { "GetCServeV3DeploymentResponse", "GetComputeDeploymentResponse", "GetDynamoDeploymentResponse", "GetInferenceV3DeploymentResponse" } model_config = { "validate_assignment": True, @@ -82,9 +85,15 @@ def actual_instance_must_validate_anyof(cls, v): else: return v + # validate data type: GetComputeDeploymentResponse + if not isinstance(v, GetComputeDeploymentResponse): + error_messages.append(f"Error! Input type `{type(v)}` is not `GetComputeDeploymentResponse`") + else: + return v + if error_messages: # no match - raise ValueError("No match found when setting the actual_instance in DeploymentResponse with anyOf schemas: GetCServeV3DeploymentResponse, GetDynamoDeploymentResponse, GetInferenceV3DeploymentResponse. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when setting the actual_instance in DeploymentResponse with anyOf schemas: GetCServeV3DeploymentResponse, GetComputeDeploymentResponse, GetDynamoDeploymentResponse, GetInferenceV3DeploymentResponse. Details: " + ", ".join(error_messages)) else: return v @@ -115,10 +124,16 @@ def from_json(cls, json_str: str) -> Self: return instance except (ValidationError, ValueError) as e: error_messages.append(str(e)) + # anyof_schema_4_validator: Optional[GetComputeDeploymentResponse] = None + try: + instance.actual_instance = GetComputeDeploymentResponse.from_json(json_str) + return instance + except (ValidationError, ValueError) as e: + error_messages.append(str(e)) if error_messages: # no match - raise ValueError("No match found when deserializing the JSON string into DeploymentResponse with anyOf schemas: GetCServeV3DeploymentResponse, GetDynamoDeploymentResponse, GetInferenceV3DeploymentResponse. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when deserializing the JSON string into DeploymentResponse with anyOf schemas: GetCServeV3DeploymentResponse, GetComputeDeploymentResponse, GetDynamoDeploymentResponse, GetInferenceV3DeploymentResponse. Details: " + ", ".join(error_messages)) else: return instance @@ -132,7 +147,7 @@ def to_json(self) -> str: else: return json.dumps(self.actual_instance) - def to_dict(self) -> Optional[Union[Dict[str, Any], GetCServeV3DeploymentResponse, GetDynamoDeploymentResponse, GetInferenceV3DeploymentResponse]]: + def to_dict(self) -> Optional[Union[Dict[str, Any], GetCServeV3DeploymentResponse, GetComputeDeploymentResponse, GetDynamoDeploymentResponse, GetInferenceV3DeploymentResponse]]: """Returns the dict representation of the actual instance""" if self.actual_instance is None: return None diff --git a/platform_api_python_client/models/dynamo_serving_mode.py b/platform_api_python_client/models/dynamo_serving_mode.py new file mode 100644 index 0000000..86550ba --- /dev/null +++ b/platform_api_python_client/models/dynamo_serving_mode.py @@ -0,0 +1,37 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import json +from enum import Enum +from typing_extensions import Self + + +class DynamoServingMode(str, Enum): + """ + DynamoServingMode + """ + + """ + allowed enum values + """ + AGGREGATED = 'aggregated' + DISAGGREGATED = 'disaggregated' + + @classmethod + def from_json(cls, json_str: str) -> Self: + """Create an instance of DynamoServingMode from a JSON string""" + return cls(json.loads(json_str)) + + diff --git a/platform_api_python_client/models/dynamo_worker_pool_config.py b/platform_api_python_client/models/dynamo_worker_pool_config.py new file mode 100644 index 0000000..c2c9126 --- /dev/null +++ b/platform_api_python_client/models/dynamo_worker_pool_config.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field, StrictInt +from typing import Any, ClassVar, Dict, List +from typing_extensions import Annotated +from typing import Optional, Set +from typing_extensions import Self + +class DynamoWorkerPoolConfig(BaseModel): + """ + DynamoWorkerPoolConfig + """ # noqa: E501 + hardware_instance_id: StrictInt + replicas: Annotated[int, Field(strict=True, ge=1)] + additional_properties: Dict[str, Any] = {} + __properties: ClassVar[List[str]] = ["hardware_instance_id", "replicas"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DynamoWorkerPoolConfig from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * Fields in `self.additional_properties` are added to the output dict. + """ + excluded_fields: Set[str] = set([ + "additional_properties", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # puts key-value pairs in additional_properties in the top level + if self.additional_properties is not None: + for _key, _value in self.additional_properties.items(): + _dict[_key] = _value + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DynamoWorkerPoolConfig from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "hardware_instance_id": obj.get("hardware_instance_id"), + "replicas": obj.get("replicas") + }) + # store additional fields in additional_properties + for _key in obj.keys(): + if _key not in cls.__properties: + _obj.additional_properties[_key] = obj.get(_key) + + return _obj + + diff --git a/platform_api_python_client/models/dynamo_worker_pools.py b/platform_api_python_client/models/dynamo_worker_pools.py new file mode 100644 index 0000000..49c97ed --- /dev/null +++ b/platform_api_python_client/models/dynamo_worker_pools.py @@ -0,0 +1,109 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict +from typing import Any, ClassVar, Dict, List +from platform_api_python_client.models.dynamo_worker_pool_config import DynamoWorkerPoolConfig +from typing import Optional, Set +from typing_extensions import Self + +class DynamoWorkerPools(BaseModel): + """ + DynamoWorkerPools + """ # noqa: E501 + prefill: DynamoWorkerPoolConfig + decode: DynamoWorkerPoolConfig + additional_properties: Dict[str, Any] = {} + __properties: ClassVar[List[str]] = ["prefill", "decode"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of DynamoWorkerPools from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + * Fields in `self.additional_properties` are added to the output dict. + """ + excluded_fields: Set[str] = set([ + "additional_properties", + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of prefill + if self.prefill: + _dict['prefill'] = self.prefill.to_dict() + # override the default output from pydantic by calling `to_dict()` of decode + if self.decode: + _dict['decode'] = self.decode.to_dict() + # puts key-value pairs in additional_properties in the top level + if self.additional_properties is not None: + for _key, _value in self.additional_properties.items(): + _dict[_key] = _value + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of DynamoWorkerPools from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "prefill": DynamoWorkerPoolConfig.from_dict(obj["prefill"]) if obj.get("prefill") is not None else None, + "decode": DynamoWorkerPoolConfig.from_dict(obj["decode"]) if obj.get("decode") is not None else None + }) + # store additional fields in additional_properties + for _key in obj.keys(): + if _key not in cls.__properties: + _obj.additional_properties[_key] = obj.get(_key) + + return _obj + + diff --git a/platform_api_python_client/models/get_cluster_response.py b/platform_api_python_client/models/get_cluster_response.py index 3dfa3ea..7c11cc4 100644 --- a/platform_api_python_client/models/get_cluster_response.py +++ b/platform_api_python_client/models/get_cluster_response.py @@ -17,7 +17,7 @@ import re # noqa: F401 import json -from pydantic import BaseModel, ConfigDict, StrictInt, StrictStr +from pydantic import BaseModel, ConfigDict, StrictBool, StrictInt, StrictStr from typing import Any, ClassVar, Dict, List, Optional from typing import Optional, Set from typing_extensions import Self @@ -30,7 +30,8 @@ class GetClusterResponse(BaseModel): cluster_name: StrictStr display_name: StrictStr region: Optional[StrictStr] = None - __properties: ClassVar[List[str]] = ["id", "cluster_name", "display_name", "region"] + deployment_creation_disabled: Optional[StrictBool] = False + __properties: ClassVar[List[str]] = ["id", "cluster_name", "display_name", "region", "deployment_creation_disabled"] model_config = ConfigDict( populate_by_name=True, @@ -91,7 +92,8 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "id": obj.get("id"), "cluster_name": obj.get("cluster_name"), "display_name": obj.get("display_name"), - "region": obj.get("region") + "region": obj.get("region"), + "deployment_creation_disabled": obj.get("deployment_creation_disabled") if obj.get("deployment_creation_disabled") is not None else False }) return _obj diff --git a/platform_api_python_client/models/get_deployment_log_v4_response.py b/platform_api_python_client/models/get_deployment_log_v4_response.py new file mode 100644 index 0000000..5f284e8 --- /dev/null +++ b/platform_api_python_client/models/get_deployment_log_v4_response.py @@ -0,0 +1,95 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List +from platform_api_python_client.models.deployment_log_event_v4 import DeploymentLogEventV4 +from typing import Optional, Set +from typing_extensions import Self + +class GetDeploymentLogV4Response(BaseModel): + """ + GetDeploymentLogV4Response + """ # noqa: E501 + events: List[DeploymentLogEventV4] = Field(description="Log events, oldest first. Page boundaries are minted client-side from the events' timestamp field (see the endpoint description): an empty fetch_newer=false page means history is exhausted; an empty fetch_newer=true page means nothing new yet.") + __properties: ClassVar[List[str]] = ["events"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GetDeploymentLogV4Response from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # override the default output from pydantic by calling `to_dict()` of each item in events (list) + _items = [] + if self.events: + for _item_events in self.events: + if _item_events: + _items.append(_item_events.to_dict()) + _dict['events'] = _items + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GetDeploymentLogV4Response from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "events": [DeploymentLogEventV4.from_dict(_item) for _item in obj["events"]] if obj.get("events") is not None else None + }) + return _obj + + diff --git a/platform_api_python_client/models/get_deployment_pods_response.py b/platform_api_python_client/models/get_deployment_pods_response.py new file mode 100644 index 0000000..2d0ce50 --- /dev/null +++ b/platform_api_python_client/models/get_deployment_pods_response.py @@ -0,0 +1,87 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictStr +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self + +class GetDeploymentPodsResponse(BaseModel): + """ + GetDeploymentPodsResponse + """ # noqa: E501 + pods: List[StrictStr] + __properties: ClassVar[List[str]] = ["pods"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of GetDeploymentPodsResponse from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of GetDeploymentPodsResponse from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "pods": obj.get("pods") + }) + return _obj + + diff --git a/platform_api_python_client/models/get_dynamo_deployment_response.py b/platform_api_python_client/models/get_dynamo_deployment_response.py index ad1eb8e..e8c7117 100644 --- a/platform_api_python_client/models/get_dynamo_deployment_response.py +++ b/platform_api_python_client/models/get_dynamo_deployment_response.py @@ -23,6 +23,8 @@ from platform_api_python_client.models.backend_protocol import BackendProtocol from platform_api_python_client.models.deployment_status import DeploymentStatus from platform_api_python_client.models.deployment_type import DeploymentType +from platform_api_python_client.models.dynamo_serving_mode import DynamoServingMode +from platform_api_python_client.models.dynamo_worker_pools import DynamoWorkerPools from typing import Optional, Set from typing_extensions import Self @@ -42,6 +44,8 @@ class GetDynamoDeploymentResponse(BaseModel): hardware_instance_id: StrictInt revision_number: StrictInt user_annotations: Optional[Dict[str, StrictStr]] = None + serving_mode: Optional[DynamoServingMode] = None + worker_pools: Optional[DynamoWorkerPools] = None model: StrictStr served_model_name: Optional[StrictStr] = None min_replicas: StrictInt @@ -55,7 +59,7 @@ class GetDynamoDeploymentResponse(BaseModel): enable_logging: Optional[StrictBool] = True enable_node_model_cache: Optional[StrictBool] = False backend_protocol: Optional[BackendProtocol] = None - __properties: ClassVar[List[str]] = ["creator_email", "cluster_id", "id", "name", "endpoint_url", "image_url", "type", "status", "created_at", "hardware_instance_id", "revision_number", "user_annotations", "model", "served_model_name", "min_replicas", "max_replicas", "concurrency", "cooldown_period", "extra_args", "env_vars", "endpoint_certificate_authority", "endpoint_bearer_token", "enable_logging", "enable_node_model_cache", "backend_protocol"] + __properties: ClassVar[List[str]] = ["creator_email", "cluster_id", "id", "name", "endpoint_url", "image_url", "type", "status", "created_at", "hardware_instance_id", "revision_number", "user_annotations", "serving_mode", "worker_pools", "model", "served_model_name", "min_replicas", "max_replicas", "concurrency", "cooldown_period", "extra_args", "env_vars", "endpoint_certificate_authority", "endpoint_bearer_token", "enable_logging", "enable_node_model_cache", "backend_protocol"] model_config = ConfigDict( populate_by_name=True, @@ -96,6 +100,9 @@ def to_dict(self) -> Dict[str, Any]: exclude=excluded_fields, exclude_none=True, ) + # override the default output from pydantic by calling `to_dict()` of worker_pools + if self.worker_pools: + _dict['worker_pools'] = self.worker_pools.to_dict() # set to None if image_url (nullable) is None # and model_fields_set contains the field if self.image_url is None and "image_url" in self.model_fields_set: @@ -106,6 +113,11 @@ def to_dict(self) -> Dict[str, Any]: if self.user_annotations is None and "user_annotations" in self.model_fields_set: _dict['user_annotations'] = None + # set to None if worker_pools (nullable) is None + # and model_fields_set contains the field + if self.worker_pools is None and "worker_pools" in self.model_fields_set: + _dict['worker_pools'] = None + # set to None if served_model_name (nullable) is None # and model_fields_set contains the field if self.served_model_name is None and "served_model_name" in self.model_fields_set: @@ -160,6 +172,8 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "hardware_instance_id": obj.get("hardware_instance_id"), "revision_number": obj.get("revision_number"), "user_annotations": obj.get("user_annotations"), + "serving_mode": obj.get("serving_mode"), + "worker_pools": DynamoWorkerPools.from_dict(obj["worker_pools"]) if obj.get("worker_pools") is not None else None, "model": obj.get("model"), "served_model_name": obj.get("served_model_name"), "min_replicas": obj.get("min_replicas"), diff --git a/platform_api_python_client/models/get_block_volume_response.py b/platform_api_python_client/models/get_filesystem_volume_response.py similarity index 90% rename from platform_api_python_client/models/get_block_volume_response.py rename to platform_api_python_client/models/get_filesystem_volume_response.py index 0afab61..15d4e63 100644 --- a/platform_api_python_client/models/get_block_volume_response.py +++ b/platform_api_python_client/models/get_filesystem_volume_response.py @@ -25,9 +25,9 @@ from typing import Optional, Set from typing_extensions import Self -class GetBlockVolumeResponse(BaseModel): +class GetFilesystemVolumeResponse(BaseModel): """ - GetBlockVolumeResponse + GetFilesystemVolumeResponse """ # noqa: E501 id: StrictInt name: StrictStr @@ -44,8 +44,8 @@ class GetBlockVolumeResponse(BaseModel): @field_validator('backend') def backend_validate_enum(cls, value): """Validates the enum""" - if value not in set(['block']): - raise ValueError("must be one of enum values ('block')") + if value not in set(['filesystem']): + raise ValueError("must be one of enum values ('filesystem')") return value model_config = ConfigDict( @@ -66,7 +66,7 @@ def to_json(self) -> str: @classmethod def from_json(cls, json_str: str) -> Optional[Self]: - """Create an instance of GetBlockVolumeResponse from a JSON string""" + """Create an instance of GetFilesystemVolumeResponse from a JSON string""" return cls.from_dict(json.loads(json_str)) def to_dict(self) -> Dict[str, Any]: @@ -91,7 +91,7 @@ def to_dict(self) -> Dict[str, Any]: @classmethod def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: - """Create an instance of GetBlockVolumeResponse from a dict""" + """Create an instance of GetFilesystemVolumeResponse from a dict""" if obj is None: return None diff --git a/platform_api_python_client/models/get_volume_response.py b/platform_api_python_client/models/get_volume_response.py index 8f2ff04..7e55499 100644 --- a/platform_api_python_client/models/get_volume_response.py +++ b/platform_api_python_client/models/get_volume_response.py @@ -17,24 +17,24 @@ import pprint from pydantic import BaseModel, ConfigDict, Field, StrictStr, ValidationError, field_validator from typing import Any, List, Optional -from platform_api_python_client.models.get_block_volume_response import GetBlockVolumeResponse +from platform_api_python_client.models.get_filesystem_volume_response import GetFilesystemVolumeResponse from platform_api_python_client.models.get_object_volume_response import GetObjectVolumeResponse from pydantic import StrictStr, Field from typing import Union, List, Set, Optional, Dict from typing_extensions import Literal, Self -GETVOLUMERESPONSE_ONE_OF_SCHEMAS = ["GetBlockVolumeResponse", "GetObjectVolumeResponse"] +GETVOLUMERESPONSE_ONE_OF_SCHEMAS = ["GetFilesystemVolumeResponse", "GetObjectVolumeResponse"] class GetVolumeResponse(BaseModel): """ GetVolumeResponse """ - # data type: GetBlockVolumeResponse - oneof_schema_1_validator: Optional[GetBlockVolumeResponse] = None + # data type: GetFilesystemVolumeResponse + oneof_schema_1_validator: Optional[GetFilesystemVolumeResponse] = None # data type: GetObjectVolumeResponse oneof_schema_2_validator: Optional[GetObjectVolumeResponse] = None - actual_instance: Optional[Union[GetBlockVolumeResponse, GetObjectVolumeResponse]] = None - one_of_schemas: Set[str] = { "GetBlockVolumeResponse", "GetObjectVolumeResponse" } + actual_instance: Optional[Union[GetFilesystemVolumeResponse, GetObjectVolumeResponse]] = None + one_of_schemas: Set[str] = { "GetFilesystemVolumeResponse", "GetObjectVolumeResponse" } model_config = ConfigDict( validate_assignment=True, @@ -60,9 +60,9 @@ def actual_instance_must_validate_oneof(cls, v): instance = GetVolumeResponse.model_construct() error_messages = [] match = 0 - # validate data type: GetBlockVolumeResponse - if not isinstance(v, GetBlockVolumeResponse): - error_messages.append(f"Error! Input type `{type(v)}` is not `GetBlockVolumeResponse`") + # validate data type: GetFilesystemVolumeResponse + if not isinstance(v, GetFilesystemVolumeResponse): + error_messages.append(f"Error! Input type `{type(v)}` is not `GetFilesystemVolumeResponse`") else: match += 1 # validate data type: GetObjectVolumeResponse @@ -72,10 +72,10 @@ def actual_instance_must_validate_oneof(cls, v): match += 1 if match > 1: # more than 1 match - raise ValueError("Multiple matches found when setting `actual_instance` in GetVolumeResponse with oneOf schemas: GetBlockVolumeResponse, GetObjectVolumeResponse. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when setting `actual_instance` in GetVolumeResponse with oneOf schemas: GetFilesystemVolumeResponse, GetObjectVolumeResponse. Details: " + ", ".join(error_messages)) elif match == 0: # no match - raise ValueError("No match found when setting `actual_instance` in GetVolumeResponse with oneOf schemas: GetBlockVolumeResponse, GetObjectVolumeResponse. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when setting `actual_instance` in GetVolumeResponse with oneOf schemas: GetFilesystemVolumeResponse, GetObjectVolumeResponse. Details: " + ", ".join(error_messages)) else: return v @@ -90,9 +90,9 @@ def from_json(cls, json_str: str) -> Self: error_messages = [] match = 0 - # deserialize data into GetBlockVolumeResponse + # deserialize data into GetFilesystemVolumeResponse try: - instance.actual_instance = GetBlockVolumeResponse.from_json(json_str) + instance.actual_instance = GetFilesystemVolumeResponse.from_json(json_str) match += 1 except (ValidationError, ValueError) as e: error_messages.append(str(e)) @@ -105,10 +105,10 @@ def from_json(cls, json_str: str) -> Self: if match > 1: # more than 1 match - raise ValueError("Multiple matches found when deserializing the JSON string into GetVolumeResponse with oneOf schemas: GetBlockVolumeResponse, GetObjectVolumeResponse. Details: " + ", ".join(error_messages)) + raise ValueError("Multiple matches found when deserializing the JSON string into GetVolumeResponse with oneOf schemas: GetFilesystemVolumeResponse, GetObjectVolumeResponse. Details: " + ", ".join(error_messages)) elif match == 0: # no match - raise ValueError("No match found when deserializing the JSON string into GetVolumeResponse with oneOf schemas: GetBlockVolumeResponse, GetObjectVolumeResponse. Details: " + ", ".join(error_messages)) + raise ValueError("No match found when deserializing the JSON string into GetVolumeResponse with oneOf schemas: GetFilesystemVolumeResponse, GetObjectVolumeResponse. Details: " + ", ".join(error_messages)) else: return instance @@ -122,7 +122,7 @@ def to_json(self) -> str: else: return json.dumps(self.actual_instance) - def to_dict(self) -> Optional[Union[Dict[str, Any], GetBlockVolumeResponse, GetObjectVolumeResponse]]: + def to_dict(self) -> Optional[Union[Dict[str, Any], GetFilesystemVolumeResponse, GetObjectVolumeResponse]]: """Returns the dict representation of the actual instance""" if self.actual_instance is None: return None diff --git a/platform_api_python_client/models/update_cluster_metadata_request.py b/platform_api_python_client/models/update_cluster_metadata_request.py new file mode 100644 index 0000000..8ce216d --- /dev/null +++ b/platform_api_python_client/models/update_cluster_metadata_request.py @@ -0,0 +1,87 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, StrictBool +from typing import Any, ClassVar, Dict, List +from typing import Optional, Set +from typing_extensions import Self + +class UpdateClusterMetadataRequest(BaseModel): + """ + UpdateClusterMetadataRequest + """ # noqa: E501 + deployment_creation_disabled: StrictBool + __properties: ClassVar[List[str]] = ["deployment_creation_disabled"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UpdateClusterMetadataRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UpdateClusterMetadataRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "deployment_creation_disabled": obj.get("deployment_creation_disabled") + }) + return _obj + + diff --git a/platform_api_python_client/models/upsert_user_vault_item_request.py b/platform_api_python_client/models/upsert_user_vault_item_request.py new file mode 100644 index 0000000..7d2705b --- /dev/null +++ b/platform_api_python_client/models/upsert_user_vault_item_request.py @@ -0,0 +1,103 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +from __future__ import annotations +import pprint +import re # noqa: F401 +import json + +from pydantic import BaseModel, ConfigDict, Field +from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated +from platform_api_python_client.models.user_vault_type import UserVaultType +from platform_api_python_client.models.vault_scope import VaultScope +from typing import Optional, Set +from typing_extensions import Self + +class UpsertUserVaultItemRequest(BaseModel): + """ + Write model for PUT /user_vault, where the key and value rules are enforced. + """ # noqa: E501 + id: Optional[Annotated[int, Field(strict=True, ge=1)]] = None + type: UserVaultType + key: Annotated[str, Field(min_length=1, strict=True, max_length=512)] + value: Annotated[str, Field(min_length=1, strict=True, max_length=4096)] + visibility: Optional[VaultScope] = None + __properties: ClassVar[List[str]] = ["id", "type", "key", "value", "visibility"] + + model_config = ConfigDict( + populate_by_name=True, + validate_assignment=True, + protected_namespaces=(), + ) + + + def to_str(self) -> str: + """Returns the string representation of the model using alias""" + return pprint.pformat(self.model_dump(by_alias=True)) + + def to_json(self) -> str: + """Returns the JSON representation of the model using alias""" + # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead + return json.dumps(self.to_dict()) + + @classmethod + def from_json(cls, json_str: str) -> Optional[Self]: + """Create an instance of UpsertUserVaultItemRequest from a JSON string""" + return cls.from_dict(json.loads(json_str)) + + def to_dict(self) -> Dict[str, Any]: + """Return the dictionary representation of the model using alias. + + This has the following differences from calling pydantic's + `self.model_dump(by_alias=True)`: + + * `None` is only added to the output dict for nullable fields that + were set at model initialization. Other fields with value `None` + are ignored. + """ + excluded_fields: Set[str] = set([ + ]) + + _dict = self.model_dump( + by_alias=True, + exclude=excluded_fields, + exclude_none=True, + ) + # set to None if id (nullable) is None + # and model_fields_set contains the field + if self.id is None and "id" in self.model_fields_set: + _dict['id'] = None + + return _dict + + @classmethod + def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: + """Create an instance of UpsertUserVaultItemRequest from a dict""" + if obj is None: + return None + + if not isinstance(obj, dict): + return cls.model_validate(obj) + + _obj = cls.model_validate({ + "id": obj.get("id"), + "type": obj.get("type"), + "key": obj.get("key"), + "value": obj.get("value"), + "visibility": obj.get("visibility") + }) + return _obj + + diff --git a/platform_api_python_client/models/user_vault_item.py b/platform_api_python_client/models/user_vault_item.py index cc9c7ce..5c8e874 100644 --- a/platform_api_python_client/models/user_vault_item.py +++ b/platform_api_python_client/models/user_vault_item.py @@ -17,8 +17,9 @@ import re # noqa: F401 import json -from pydantic import BaseModel, ConfigDict, StrictStr +from pydantic import BaseModel, ConfigDict, Field, StrictStr from typing import Any, ClassVar, Dict, List, Optional +from typing_extensions import Annotated from platform_api_python_client.models.user_vault_type import UserVaultType from platform_api_python_client.models.vault_scope import VaultScope from typing import Optional, Set @@ -26,13 +27,14 @@ class UserVaultItem(BaseModel): """ - UserVaultItem + Response model for vault reads and writes. Every row has a primary key, so `id` is always present and clients can always address a secret by it. `key` stays an unconstrained str and `value` stays optional so secrets stored before the SSM migration remain listable and readable: enforcing the write rules here would turn one such row into a 500 for the whole listing. Write validation lives in UpsertUserVaultItemRequest. """ # noqa: E501 + id: Annotated[int, Field(strict=True, ge=1)] type: UserVaultType key: StrictStr value: Optional[StrictStr] = None visibility: Optional[VaultScope] = None - __properties: ClassVar[List[str]] = ["type", "key", "value", "visibility"] + __properties: ClassVar[List[str]] = ["id", "type", "key", "value", "visibility"] model_config = ConfigDict( populate_by_name=True, @@ -90,6 +92,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: return cls.model_validate(obj) _obj = cls.model_validate({ + "id": obj.get("id"), "type": obj.get("type"), "key": obj.get("key"), "value": obj.get("value"), diff --git a/platform_api_python_client/models/volume_access_mode.py b/platform_api_python_client/models/volume_access_mode.py index 156a6d9..31d16fd 100644 --- a/platform_api_python_client/models/volume_access_mode.py +++ b/platform_api_python_client/models/volume_access_mode.py @@ -26,7 +26,6 @@ class VolumeAccessMode(str, Enum): """ allowed enum values """ - READWRITEONCE = 'ReadWriteOnce' READWRITEMANY = 'ReadWriteMany' @classmethod diff --git a/platform_api_python_client/models/volume_backend.py b/platform_api_python_client/models/volume_backend.py index 1f319ce..cd4aef7 100644 --- a/platform_api_python_client/models/volume_backend.py +++ b/platform_api_python_client/models/volume_backend.py @@ -26,7 +26,7 @@ class VolumeBackend(str, Enum): """ allowed enum values """ - BLOCK = 'block' + FILESYSTEM = 'filesystem' OBJECT = 'object' @classmethod diff --git a/pyproject.toml b/pyproject.toml index 0a33d68..5562839 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "platform_api_python_client" -version = "4.23.1" +version = "4.25.0" description = "Platform External API" authors = ["OpenAPI Generator Community "] license = "NoLicense" diff --git a/setup.py b/setup.py index 9e254ed..d7ca34c 100644 --- a/setup.py +++ b/setup.py @@ -21,7 +21,7 @@ # prerequisite: setuptools # http://pypi.python.org/pypi/setuptools NAME = "platform-api-python-client" -VERSION = "4.23.1" +VERSION = "4.25.0" PYTHON_REQUIRES = ">= 3.8" REQUIRES = [ "urllib3 >= 1.25.3, < 3.0.0", diff --git a/test/test_create_dynamo_deployment_request.py b/test/test_create_dynamo_deployment_request.py index 8546f9a..15b0a95 100644 --- a/test/test_create_dynamo_deployment_request.py +++ b/test/test_create_dynamo_deployment_request.py @@ -44,6 +44,8 @@ def make_instance(self, include_optional) -> CreateDynamoDeploymentRequest: 'key' : '' }, chart_revision = '', + serving_mode = 'aggregated', + worker_pools = { }, model = '', served_model_name = '', min_replicas = 56, @@ -65,7 +67,6 @@ def make_instance(self, include_optional) -> CreateDynamoDeploymentRequest: return CreateDynamoDeploymentRequest( name = 'ar1c2v7s6djuy1zmetozkhdomha1b0', cluster_id = 56, - hardware_instance_id = 56, model = '', ) """ diff --git a/test/test_create_block_volume_request.py b/test/test_create_filesystem_volume_request.py similarity index 82% rename from test/test_create_block_volume_request.py rename to test/test_create_filesystem_volume_request.py index 156337c..d6f1def 100644 --- a/test/test_create_block_volume_request.py +++ b/test/test_create_filesystem_volume_request.py @@ -14,10 +14,10 @@ import unittest -from platform_api_python_client.models.create_block_volume_request import CreateBlockVolumeRequest +from platform_api_python_client.models.create_filesystem_volume_request import CreateFilesystemVolumeRequest -class TestCreateBlockVolumeRequest(unittest.TestCase): - """CreateBlockVolumeRequest unit test stubs""" +class TestCreateFilesystemVolumeRequest(unittest.TestCase): + """CreateFilesystemVolumeRequest unit test stubs""" def setUp(self): pass @@ -25,32 +25,32 @@ def setUp(self): def tearDown(self): pass - def make_instance(self, include_optional) -> CreateBlockVolumeRequest: - """Test CreateBlockVolumeRequest + def make_instance(self, include_optional) -> CreateFilesystemVolumeRequest: + """Test CreateFilesystemVolumeRequest include_optional is a boolean, when False only required params are included, when True both required and optional params are included """ - # uncomment below to create an instance of `CreateBlockVolumeRequest` + # uncomment below to create an instance of `CreateFilesystemVolumeRequest` """ - model = CreateBlockVolumeRequest() + model = CreateFilesystemVolumeRequest() if include_optional: - return CreateBlockVolumeRequest( + return CreateFilesystemVolumeRequest( name = 'ar1c2v7s6djuy1zmetozkhdomha1b0', cluster_id = 56, - backend = 'block', + backend = 'filesystem', size_gb = 1.0, storage_class = 'w1c2v7s6djuy1zmetozkhdomha1bae37b8ocvx8o53ow2eg7p6qw9qklp6l4y010fogx.mjvnh6nzn2yp6d7tmo7zxedi-pkbmhcbu-4d4ncp9sp-gpju7f9r1ly-n2jyba-zuswj171d3kxld4uyykb66fgvcwlw.s.p6div96l1hmssf5by0949ps5we2h1m5s.4.7ftu50o3hq25-ctix-xt8fyuzw85-6ya.ezgfzdm4groy.ccn4nxdzyngfr2bsdqi-90qr77qnqf26kpzuf5a652r9yc8wgc.uoko8ht4bjsb-86ca0gq8ejs584qp107f5qv9ze3gk7q64-5mecujmelufynb1wtb8v2n1x9-y9o36a.uqixpalso4ehay1yebs1kiembt-homr2.864bew-vpjuuty7-xv4qjygg3hwqd-5gynywalvhvvesyveyxp35spjahpsiagrj0jehh3a3x8z9axqtswj383252z.d6d4ifob3rgi7j1fao-vb9l55lz.bsk1mqype9zx3n6q-u55t879v1lf.1.k.isf-swgdlh.0.m4u5aoqakjc4xlcmbpoy4ndizk4s3cdhxttexawd8mnl6e4uzxalowdqy9rokd32ct-w5p-yt-emwrzfi.lulqkw0osnqktff9fp6xbt97440w4wt3xjayovyb7flljlnosgtrofp.o.j.p5-2p577rg1fwny6cq1e2d3p5aa62rscqk6cxzeqcrvjnbqd52lumjr3qda19c-7skjef4ovphp57sme4j.v.ex0xp4ft9xd1-4zvmus0m5p.v0h-jlvu47xor814uas43gvg7px7mohsvz1n3b561az73nipt-so37iphbtnhmw48ibn.m.bk41trymo7d0ea3vl3k8vn3ygn2a7ps3-pdkhjjxrdr3lz6urrzqtzh9wngf-95dvz5km9h9e5j8vg6kx1nnqzi442akggqdhy6.i.gupb4cz72xp4qgqp5jsd55qux2vq83uq1j9iy-qb4bt8kb625gpncppm1zw5yrhj.5q6soeyc3hzdpj1thb.b.b5xq79rwp3km1p11ikuwgghy12wdp5xrrsyrsnl7yjolek10nb0oh.h.x.2h707s1vjswprq6au.xucdr85u0erh5dfg2hvs9u7vn0y8ci0w5cs0m66nvcce2fr52dkbd9-7klkniu5cpn6qugmep5e6p9gx9creyetm.2sgithzei3bx4-4ox6m2aiffxmcwza92oxtwxs76a.s.z.im-3mvtf47ak-ld.a.2elgcf13ovinqusgnnclaaotmbqdseafe1dkj6zg4q-zexx0zm-n.j3-w17r6rxur1pbea75jjl8lv5xitcozp.c.h.61bftab5cre-v.9.v.s.fyenvbtf508c5c3k.mghqe7lyva958ar2bzuf2507k602lnujv0ps2icyh27nxstaqbg38m0hpe.g.bg8n69rdva8j104ap-cf1p9yc1ijk9np17sjmh2tukz4atwz0044pdhk9pk1eft1nod0p9-vepbljhwtpf-qd2ysm1.3tiane3jk-09bf0q3dbgqocrp16dzj0xk-uyej17sd81mbgu820re53g21e779vy6.z.rm8pn0xdthfd9cqpo9sslxeml661r0eol4jypf6mdna86sfgz92k.y-52xiufg9mfli1bjvsy947g3cz7wufbd001uiwvuaxblt37i0ah0z6f6qhqwar1c3r14v-vt3pd5kbrrs94okiob2jznknec6ky.3.d.dgp-oapce410llsnx-m--ufb725icarr8pijimdu9gxv3p7744x7btxc9-zq66zjny7rvcbdfcl-7ksv-awu1ddn3dlag.1cg4obm9r3waeqrdsk53.1.q.k.w.gz5qwr2rjf1o2625v873inyqekdlul-2yu96dhuposmz433w4216crklr6.5ifmkesrrzj9hbtdyamuoxl0l1gb0vgsms5ou3nfhhnvvfktn2uyclzyqvy90vz11a6oipnv4tno7.z.t.u4pfk1y-f41a9ekyw5sfqgxxg2436imo6t94jmeph0msaf6p04q5p6z75n97ibih9ynp9w52m2.7bh985by7-jms7z9rzl84e9iub-3gwwq4fe81bi2bmela-4-ti6-mqq-em0m73ls976osz80kxxj.x.jxe4zxgit8guso2bynf9xkxywffvyznse5yovoes9zqhgf9wk74po4qj1hri4b.06kv2f-9nff.ejas130ndgnxp85h0saokre-wcp8nl4iio.g.z8c-0hnu2tn0fal1tsn8phrmhzoys2l25i7fgxqn8.w.w.z0' ) else: - return CreateBlockVolumeRequest( + return CreateFilesystemVolumeRequest( name = 'ar1c2v7s6djuy1zmetozkhdomha1b0', cluster_id = 56, - backend = 'block', + backend = 'filesystem', ) """ - def testCreateBlockVolumeRequest(self): - """Test CreateBlockVolumeRequest""" + def testCreateFilesystemVolumeRequest(self): + """Test CreateFilesystemVolumeRequest""" # inst_req_only = self.make_instance(include_optional=False) # inst_req_and_optional = self.make_instance(include_optional=True) diff --git a/test/test_delete_user_vault_item_request.py b/test/test_delete_user_vault_item_request.py new file mode 100644 index 0000000..21901e6 --- /dev/null +++ b/test/test_delete_user_vault_item_request.py @@ -0,0 +1,57 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from platform_api_python_client.models.delete_user_vault_item_request import DeleteUserVaultItemRequest + +class TestDeleteUserVaultItemRequest(unittest.TestCase): + """DeleteUserVaultItemRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeleteUserVaultItemRequest: + """Test DeleteUserVaultItemRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeleteUserVaultItemRequest` + """ + model = DeleteUserVaultItemRequest() + if include_optional: + return DeleteUserVaultItemRequest( + id = 1.0, + type = 'env_vars', + key = '', + value = '', + visibility = 'USER' + ) + else: + return DeleteUserVaultItemRequest( + type = 'env_vars', + key = '', + ) + """ + + def testDeleteUserVaultItemRequest(self): + """Test DeleteUserVaultItemRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_deployment_log_event_v4.py b/test/test_deployment_log_event_v4.py new file mode 100644 index 0000000..c9a6cca --- /dev/null +++ b/test/test_deployment_log_event_v4.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from platform_api_python_client.models.deployment_log_event_v4 import DeploymentLogEventV4 + +class TestDeploymentLogEventV4(unittest.TestCase): + """DeploymentLogEventV4 unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DeploymentLogEventV4: + """Test DeploymentLogEventV4 + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DeploymentLogEventV4` + """ + model = DeploymentLogEventV4() + if include_optional: + return DeploymentLogEventV4( + id = '', + timestamp = 56, + message = '' + ) + else: + return DeploymentLogEventV4( + id = '', + timestamp = 56, + message = '', + ) + """ + + def testDeploymentLogEventV4(self): + """Test DeploymentLogEventV4""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_deployment_response.py b/test/test_deployment_response.py index b001865..94b9c8d 100644 --- a/test/test_deployment_response.py +++ b/test/test_deployment_response.py @@ -49,6 +49,8 @@ def make_instance(self, include_optional) -> DeploymentResponse: user_annotations = { 'key' : '' }, + serving_mode = 'aggregated', + worker_pools = { }, model = '', served_model_name = '', min_replicas = 56, @@ -86,7 +88,10 @@ def make_instance(self, include_optional) -> DeploymentResponse: content = '0', ), metrics = platform_api_python_client.models.metrics_config.MetricsConfig( port = 1.0, - path = '/W(,j>6>eow3jCO&}nl`:&~', ) + path = '/W(,j>6>eow3jCO&}nl`:&~', ), + exposed_port = 56, + ssh_public_key = '', + ssh_password = '' ) else: return DeploymentResponse( @@ -105,6 +110,7 @@ def make_instance(self, include_optional) -> DeploymentResponse: max_replicas = 56, recipe = { }, container_port = 56, + exposed_port = 56, ) """ diff --git a/test/test_deployment_status_v3_response.py b/test/test_deployment_status_v3_response.py index e9d22e9..b707f0b 100644 --- a/test/test_deployment_status_v3_response.py +++ b/test/test_deployment_status_v3_response.py @@ -48,7 +48,7 @@ def make_instance(self, include_optional) -> DeploymentStatusV3Response: platform_api_python_client.models.pod_details.PodDetails( name = '', revision_number = 56, - component_type = 'user-container', + component_type = 'user-container', status = 'ScalingUp', error_message = '', ) ], diff --git a/test/test_dynamo_serving_mode.py b/test/test_dynamo_serving_mode.py new file mode 100644 index 0000000..8aeffb6 --- /dev/null +++ b/test/test_dynamo_serving_mode.py @@ -0,0 +1,33 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from platform_api_python_client.models.dynamo_serving_mode import DynamoServingMode + +class TestDynamoServingMode(unittest.TestCase): + """DynamoServingMode unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def testDynamoServingMode(self): + """Test DynamoServingMode""" + # inst = DynamoServingMode() + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_dynamo_worker_pool_config.py b/test/test_dynamo_worker_pool_config.py new file mode 100644 index 0000000..0bddb63 --- /dev/null +++ b/test/test_dynamo_worker_pool_config.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from platform_api_python_client.models.dynamo_worker_pool_config import DynamoWorkerPoolConfig + +class TestDynamoWorkerPoolConfig(unittest.TestCase): + """DynamoWorkerPoolConfig unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DynamoWorkerPoolConfig: + """Test DynamoWorkerPoolConfig + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DynamoWorkerPoolConfig` + """ + model = DynamoWorkerPoolConfig() + if include_optional: + return DynamoWorkerPoolConfig( + hardware_instance_id = 56, + replicas = 1.0 + ) + else: + return DynamoWorkerPoolConfig( + hardware_instance_id = 56, + replicas = 1.0, + ) + """ + + def testDynamoWorkerPoolConfig(self): + """Test DynamoWorkerPoolConfig""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_dynamo_worker_pools.py b/test/test_dynamo_worker_pools.py new file mode 100644 index 0000000..b45bc79 --- /dev/null +++ b/test/test_dynamo_worker_pools.py @@ -0,0 +1,54 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from platform_api_python_client.models.dynamo_worker_pools import DynamoWorkerPools + +class TestDynamoWorkerPools(unittest.TestCase): + """DynamoWorkerPools unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> DynamoWorkerPools: + """Test DynamoWorkerPools + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `DynamoWorkerPools` + """ + model = DynamoWorkerPools() + if include_optional: + return DynamoWorkerPools( + prefill = { }, + decode = { } + ) + else: + return DynamoWorkerPools( + prefill = { }, + decode = { }, + ) + """ + + def testDynamoWorkerPools(self): + """Test DynamoWorkerPools""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_external_api.py b/test/test_external_api.py index f8d2a0f..d88780d 100644 --- a/test/test_external_api.py +++ b/test/test_external_api.py @@ -131,6 +131,13 @@ def test_delete_service_account_service_accounts_workos_id_delete(self) -> None: """ pass + def test_delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete(self) -> None: + """Test case for delete_user_vault_item_by_id_endpoint_user_vault_secret_id_delete + + Delete User Vault Item By Id Endpoint + """ + pass + def test_delete_user_vault_item_endpoint_user_vault_delete(self) -> None: """Test case for delete_user_vault_item_endpoint_user_vault_delete @@ -222,6 +229,20 @@ def test_get_deployment_logs_v3_deployments_logs_v3_deployment_id_revision_numbe """ pass + def test_get_deployment_logs_v4_logs_deployment_id_revision_number_get(self) -> None: + """Test case for get_deployment_logs_v4_logs_deployment_id_revision_number_get + + Get Deployment Logs V4 + """ + pass + + def test_get_deployment_pods_deployments_pods_deployment_id_revision_number_get(self) -> None: + """Test case for get_deployment_pods_deployments_pods_deployment_id_revision_number_get + + Get Deployment Pods + """ + pass + def test_get_deployment_revision_deployments_revisions_deployment_id_revision_number_get(self) -> None: """Test case for get_deployment_revision_deployments_revisions_deployment_id_revision_number_get @@ -313,6 +334,13 @@ def test_get_usage_deployments_usage_deployment_id_get(self) -> None: """ pass + def test_get_user_vault_item_by_id_endpoint_user_vault_secret_id_get(self) -> None: + """Test case for get_user_vault_item_by_id_endpoint_user_vault_secret_id_get + + Get User Vault Item By Id Endpoint + """ + pass + def test_get_volume_endpoint_volumes_volume_id_get(self) -> None: """Test case for get_volume_endpoint_volumes_volume_id_get @@ -369,6 +397,13 @@ def test_update_cluster_clusters_cluster_id_put(self) -> None: """ pass + def test_update_cluster_metadata_clusters_cluster_id_metadata_put(self) -> None: + """Test case for update_cluster_metadata_clusters_cluster_id_metadata_put + + Update Cluster Metadata + """ + pass + def test_update_compute_deployment_deployments_compute_put(self) -> None: """Test case for update_compute_deployment_deployments_compute_put diff --git a/test/test_get_cluster_response.py b/test/test_get_cluster_response.py index c41976e..f3a33cb 100644 --- a/test/test_get_cluster_response.py +++ b/test/test_get_cluster_response.py @@ -38,7 +38,8 @@ def make_instance(self, include_optional) -> GetClusterResponse: id = 56, cluster_name = '', display_name = '', - region = '' + region = '', + deployment_creation_disabled = True ) else: return GetClusterResponse( diff --git a/test/test_get_deployment_log_v4_response.py b/test/test_get_deployment_log_v4_response.py new file mode 100644 index 0000000..dd0015d --- /dev/null +++ b/test/test_get_deployment_log_v4_response.py @@ -0,0 +1,62 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from platform_api_python_client.models.get_deployment_log_v4_response import GetDeploymentLogV4Response + +class TestGetDeploymentLogV4Response(unittest.TestCase): + """GetDeploymentLogV4Response unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GetDeploymentLogV4Response: + """Test GetDeploymentLogV4Response + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GetDeploymentLogV4Response` + """ + model = GetDeploymentLogV4Response() + if include_optional: + return GetDeploymentLogV4Response( + events = [ + platform_api_python_client.models.deployment_log_event_v4.DeploymentLogEventV4( + id = '', + timestamp = 56, + message = '', ) + ] + ) + else: + return GetDeploymentLogV4Response( + events = [ + platform_api_python_client.models.deployment_log_event_v4.DeploymentLogEventV4( + id = '', + timestamp = 56, + message = '', ) + ], + ) + """ + + def testGetDeploymentLogV4Response(self): + """Test GetDeploymentLogV4Response""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_get_deployment_pods_response.py b/test/test_get_deployment_pods_response.py new file mode 100644 index 0000000..8858fe8 --- /dev/null +++ b/test/test_get_deployment_pods_response.py @@ -0,0 +1,56 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from platform_api_python_client.models.get_deployment_pods_response import GetDeploymentPodsResponse + +class TestGetDeploymentPodsResponse(unittest.TestCase): + """GetDeploymentPodsResponse unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> GetDeploymentPodsResponse: + """Test GetDeploymentPodsResponse + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `GetDeploymentPodsResponse` + """ + model = GetDeploymentPodsResponse() + if include_optional: + return GetDeploymentPodsResponse( + pods = [ + '' + ] + ) + else: + return GetDeploymentPodsResponse( + pods = [ + '' + ], + ) + """ + + def testGetDeploymentPodsResponse(self): + """Test GetDeploymentPodsResponse""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_get_dynamo_deployment_response.py b/test/test_get_dynamo_deployment_response.py index b56be37..4b3592a 100644 --- a/test/test_get_dynamo_deployment_response.py +++ b/test/test_get_dynamo_deployment_response.py @@ -49,6 +49,8 @@ def make_instance(self, include_optional) -> GetDynamoDeploymentResponse: user_annotations = { 'key' : '' }, + serving_mode = 'aggregated', + worker_pools = { }, model = '', served_model_name = '', min_replicas = 56, diff --git a/test/test_get_block_volume_response.py b/test/test_get_filesystem_volume_response.py similarity index 64% rename from test/test_get_block_volume_response.py rename to test/test_get_filesystem_volume_response.py index 9351ecf..231d418 100644 --- a/test/test_get_block_volume_response.py +++ b/test/test_get_filesystem_volume_response.py @@ -14,10 +14,10 @@ import unittest -from platform_api_python_client.models.get_block_volume_response import GetBlockVolumeResponse +from platform_api_python_client.models.get_filesystem_volume_response import GetFilesystemVolumeResponse -class TestGetBlockVolumeResponse(unittest.TestCase): - """GetBlockVolumeResponse unit test stubs""" +class TestGetFilesystemVolumeResponse(unittest.TestCase): + """GetFilesystemVolumeResponse unit test stubs""" def setUp(self): pass @@ -25,21 +25,21 @@ def setUp(self): def tearDown(self): pass - def make_instance(self, include_optional) -> GetBlockVolumeResponse: - """Test GetBlockVolumeResponse + def make_instance(self, include_optional) -> GetFilesystemVolumeResponse: + """Test GetFilesystemVolumeResponse include_optional is a boolean, when False only required params are included, when True both required and optional params are included """ - # uncomment below to create an instance of `GetBlockVolumeResponse` + # uncomment below to create an instance of `GetFilesystemVolumeResponse` """ - model = GetBlockVolumeResponse() + model = GetFilesystemVolumeResponse() if include_optional: - return GetBlockVolumeResponse( + return GetFilesystemVolumeResponse( id = 56, name = '', cluster_id = 56, - backend = 'block', - access_mode = 'ReadWriteOnce', + backend = 'filesystem', + access_mode = 'ReadWriteMany', status = 'active', pvc_name = '', created_at = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), @@ -47,12 +47,12 @@ def make_instance(self, include_optional) -> GetBlockVolumeResponse: storage_class = '' ) else: - return GetBlockVolumeResponse( + return GetFilesystemVolumeResponse( id = 56, name = '', cluster_id = 56, - backend = 'block', - access_mode = 'ReadWriteOnce', + backend = 'filesystem', + access_mode = 'ReadWriteMany', status = 'active', pvc_name = '', created_at = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), @@ -61,8 +61,8 @@ def make_instance(self, include_optional) -> GetBlockVolumeResponse: ) """ - def testGetBlockVolumeResponse(self): - """Test GetBlockVolumeResponse""" + def testGetFilesystemVolumeResponse(self): + """Test GetFilesystemVolumeResponse""" # inst_req_only = self.make_instance(include_optional=False) # inst_req_and_optional = self.make_instance(include_optional=True) diff --git a/test/test_get_object_volume_response.py b/test/test_get_object_volume_response.py index e2d5f99..f3bb868 100644 --- a/test/test_get_object_volume_response.py +++ b/test/test_get_object_volume_response.py @@ -39,7 +39,7 @@ def make_instance(self, include_optional) -> GetObjectVolumeResponse: name = '', cluster_id = 56, backend = 'object', - access_mode = 'ReadWriteOnce', + access_mode = 'ReadWriteMany', status = 'active', pvc_name = '', created_at = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), @@ -61,7 +61,7 @@ def make_instance(self, include_optional) -> GetObjectVolumeResponse: name = '', cluster_id = 56, backend = 'object', - access_mode = 'ReadWriteOnce', + access_mode = 'ReadWriteMany', status = 'active', pvc_name = '', created_at = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), diff --git a/test/test_get_volume_response.py b/test/test_get_volume_response.py index 962f58f..c5c8d74 100644 --- a/test/test_get_volume_response.py +++ b/test/test_get_volume_response.py @@ -39,7 +39,7 @@ def make_instance(self, include_optional) -> GetVolumeResponse: name = '', cluster_id = 56, backend = 'object', - access_mode = 'ReadWriteOnce', + access_mode = 'ReadWriteMany', status = 'active', pvc_name = '', created_at = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), @@ -63,7 +63,7 @@ def make_instance(self, include_optional) -> GetVolumeResponse: name = '', cluster_id = 56, backend = 'object', - access_mode = 'ReadWriteOnce', + access_mode = 'ReadWriteMany', status = 'active', pvc_name = '', created_at = datetime.datetime.strptime('2013-10-20 19:20:30.00', '%Y-%m-%d %H:%M:%S.%f'), diff --git a/test/test_list_get_cluster_response.py b/test/test_list_get_cluster_response.py index 814ec46..e22d089 100644 --- a/test/test_list_get_cluster_response.py +++ b/test/test_list_get_cluster_response.py @@ -40,7 +40,8 @@ def make_instance(self, include_optional) -> ListGetClusterResponse: id = 56, cluster_name = '', display_name = '', - region = '', ) + region = '', + deployment_creation_disabled = True, ) ] ) else: @@ -50,7 +51,8 @@ def make_instance(self, include_optional) -> ListGetClusterResponse: id = 56, cluster_name = '', display_name = '', - region = '', ) + region = '', + deployment_creation_disabled = True, ) ], ) """ diff --git a/test/test_list_user_vault_items_response.py b/test/test_list_user_vault_items_response.py index e73c607..8df8343 100644 --- a/test/test_list_user_vault_items_response.py +++ b/test/test_list_user_vault_items_response.py @@ -37,6 +37,7 @@ def make_instance(self, include_optional) -> ListUserVaultItemsResponse: return ListUserVaultItemsResponse( results = [ platform_api_python_client.models.user_vault_item.UserVaultItem( + id = 1.0, type = 'env_vars', key = '', value = '', @@ -47,6 +48,7 @@ def make_instance(self, include_optional) -> ListUserVaultItemsResponse: return ListUserVaultItemsResponse( results = [ platform_api_python_client.models.user_vault_item.UserVaultItem( + id = 1.0, type = 'env_vars', key = '', value = '', diff --git a/test/test_revision_pod_details.py b/test/test_revision_pod_details.py index 6827031..c984708 100644 --- a/test/test_revision_pod_details.py +++ b/test/test_revision_pod_details.py @@ -41,7 +41,7 @@ def make_instance(self, include_optional) -> RevisionPodDetails: platform_api_python_client.models.pod_details.PodDetails( name = '', revision_number = 56, - component_type = 'user-container', + component_type = 'user-container', status = 'ScalingUp', error_message = '', ) ], diff --git a/test/test_update_cluster_metadata_request.py b/test/test_update_cluster_metadata_request.py new file mode 100644 index 0000000..f2553fe --- /dev/null +++ b/test/test_update_cluster_metadata_request.py @@ -0,0 +1,52 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from platform_api_python_client.models.update_cluster_metadata_request import UpdateClusterMetadataRequest + +class TestUpdateClusterMetadataRequest(unittest.TestCase): + """UpdateClusterMetadataRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UpdateClusterMetadataRequest: + """Test UpdateClusterMetadataRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UpdateClusterMetadataRequest` + """ + model = UpdateClusterMetadataRequest() + if include_optional: + return UpdateClusterMetadataRequest( + deployment_creation_disabled = True + ) + else: + return UpdateClusterMetadataRequest( + deployment_creation_disabled = True, + ) + """ + + def testUpdateClusterMetadataRequest(self): + """Test UpdateClusterMetadataRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_upsert_user_vault_item_request.py b/test/test_upsert_user_vault_item_request.py new file mode 100644 index 0000000..60af758 --- /dev/null +++ b/test/test_upsert_user_vault_item_request.py @@ -0,0 +1,58 @@ +# coding: utf-8 + +""" + Platform External API + + No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + + The version of the OpenAPI document: 0.1.0 + Generated by OpenAPI Generator (https://openapi-generator.tech) + + Do not edit the class manually. +""" # noqa: E501 + + +import unittest + +from platform_api_python_client.models.upsert_user_vault_item_request import UpsertUserVaultItemRequest + +class TestUpsertUserVaultItemRequest(unittest.TestCase): + """UpsertUserVaultItemRequest unit test stubs""" + + def setUp(self): + pass + + def tearDown(self): + pass + + def make_instance(self, include_optional) -> UpsertUserVaultItemRequest: + """Test UpsertUserVaultItemRequest + include_optional is a boolean, when False only required + params are included, when True both required and + optional params are included """ + # uncomment below to create an instance of `UpsertUserVaultItemRequest` + """ + model = UpsertUserVaultItemRequest() + if include_optional: + return UpsertUserVaultItemRequest( + id = 1.0, + type = 'env_vars', + key = '0', + value = '0', + visibility = 'USER' + ) + else: + return UpsertUserVaultItemRequest( + type = 'env_vars', + key = '0', + value = '0', + ) + """ + + def testUpsertUserVaultItemRequest(self): + """Test UpsertUserVaultItemRequest""" + # inst_req_only = self.make_instance(include_optional=False) + # inst_req_and_optional = self.make_instance(include_optional=True) + +if __name__ == '__main__': + unittest.main() diff --git a/test/test_user_vault_item.py b/test/test_user_vault_item.py index 5c6cc0f..d5d55bc 100644 --- a/test/test_user_vault_item.py +++ b/test/test_user_vault_item.py @@ -35,6 +35,7 @@ def make_instance(self, include_optional) -> UserVaultItem: model = UserVaultItem() if include_optional: return UserVaultItem( + id = 1.0, type = 'env_vars', key = '', value = '', @@ -42,6 +43,7 @@ def make_instance(self, include_optional) -> UserVaultItem: ) else: return UserVaultItem( + id = 1.0, type = 'env_vars', key = '', ) diff --git a/test/test_volume_status_response.py b/test/test_volume_status_response.py index 5189953..b01457f 100644 --- a/test/test_volume_status_response.py +++ b/test/test_volume_status_response.py @@ -36,7 +36,7 @@ def make_instance(self, include_optional) -> VolumeStatusResponse: if include_optional: return VolumeStatusResponse( id = 56, - backend = 'block', + backend = 'filesystem', status = 'active', service_status = 'Healthy', error_message = '' @@ -44,7 +44,7 @@ def make_instance(self, include_optional) -> VolumeStatusResponse: else: return VolumeStatusResponse( id = 56, - backend = 'block', + backend = 'filesystem', status = 'active', ) """