diff --git a/services/certificates/src/stackit/certificates/__init__.py b/services/certificates/src/stackit/certificates/__init__.py index 413e0873..43feed9a 100644 --- a/services/certificates/src/stackit/certificates/__init__.py +++ b/services/certificates/src/stackit/certificates/__init__.py @@ -7,7 +7,7 @@ This API offers the ability to store TLS certificates, which can be used by load balancing servers in STACKIT. They can be between consumer and load balancing server and/or between load balancing server and endpoint server. - The version of the OpenAPI document: 2beta.0.0 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. @@ -29,7 +29,6 @@ "ApiAttributeError", "ApiException", "CreateCertificatePayload", - "CreateCertificateResponse", "GetCertificateResponse", "GoogleProtobufAny", "ListCertificatesResponse", @@ -54,9 +53,6 @@ from stackit.certificates.models.create_certificate_payload import ( CreateCertificatePayload as CreateCertificatePayload, ) -from stackit.certificates.models.create_certificate_response import ( - CreateCertificateResponse as CreateCertificateResponse, -) from stackit.certificates.models.get_certificate_response import ( GetCertificateResponse as GetCertificateResponse, ) diff --git a/services/certificates/src/stackit/certificates/api/default_api.py b/services/certificates/src/stackit/certificates/api/default_api.py index 64c95bd2..7473fdff 100644 --- a/services/certificates/src/stackit/certificates/api/default_api.py +++ b/services/certificates/src/stackit/certificates/api/default_api.py @@ -5,7 +5,7 @@ This API offers the ability to store TLS certificates, which can be used by load balancing servers in STACKIT. They can be between consumer and load balancing server and/or between load balancing server and endpoint server. - The version of the OpenAPI document: 2beta.0.0 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. @@ -22,9 +22,6 @@ from stackit.certificates.models.create_certificate_payload import ( CreateCertificatePayload, ) -from stackit.certificates.models.create_certificate_response import ( - CreateCertificateResponse, -) from stackit.certificates.models.get_certificate_response import GetCertificateResponse from stackit.certificates.models.list_certificates_response import ( ListCertificatesResponse, @@ -60,7 +57,7 @@ def create_certificate( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> CreateCertificateResponse: + ) -> GetCertificateResponse: """Store a TLS certificate in a project. CreateCertificate will store a TLS certificate in a project. @@ -104,7 +101,7 @@ def create_certificate( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "CreateCertificateResponse", + "200": "GetCertificateResponse", "400": None, "401": "Status", "403": None, @@ -132,7 +129,7 @@ def create_certificate_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[CreateCertificateResponse]: + ) -> ApiResponse[GetCertificateResponse]: """Store a TLS certificate in a project. CreateCertificate will store a TLS certificate in a project. @@ -176,7 +173,7 @@ def create_certificate_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "CreateCertificateResponse", + "200": "GetCertificateResponse", "400": None, "401": "Status", "403": None, @@ -248,7 +245,7 @@ def create_certificate_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "CreateCertificateResponse", + "200": "GetCertificateResponse", "400": None, "401": "Status", "403": None, @@ -308,7 +305,7 @@ def _create_certificate_serialize( return self.api_client.param_serialize( method="POST", - resource_path="/v2beta/projects/{projectId}/regions/{region}/certificates", + resource_path="/v2/projects/{projectId}/regions/{region}/certificates", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -576,7 +573,7 @@ def _delete_certificate_serialize( return self.api_client.param_serialize( method="DELETE", - resource_path="/v2beta/projects/{projectId}/regions/{region}/certificates/{id}", + resource_path="/v2/projects/{projectId}/regions/{region}/certificates/{id}", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -847,7 +844,7 @@ def _get_certificate_serialize( return self.api_client.param_serialize( method="GET", - resource_path="/v2beta/projects/{projectId}/regions/{region}/certificates/{id}", + resource_path="/v2/projects/{projectId}/regions/{region}/certificates/{id}", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -1167,7 +1164,7 @@ def _list_certificates_serialize( return self.api_client.param_serialize( method="GET", - resource_path="/v2beta/projects/{projectId}/regions/{region}/certificates", + resource_path="/v2/projects/{projectId}/regions/{region}/certificates", path_params=_path_params, query_params=_query_params, header_params=_header_params, diff --git a/services/certificates/src/stackit/certificates/api_client.py b/services/certificates/src/stackit/certificates/api_client.py index fb7af4a4..759df534 100644 --- a/services/certificates/src/stackit/certificates/api_client.py +++ b/services/certificates/src/stackit/certificates/api_client.py @@ -5,7 +5,7 @@ This API offers the ability to store TLS certificates, which can be used by load balancing servers in STACKIT. They can be between consumer and load balancing server and/or between load balancing server and endpoint server. - The version of the OpenAPI document: 2beta.0.0 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/certificates/src/stackit/certificates/configuration.py b/services/certificates/src/stackit/certificates/configuration.py index fe6209a0..0f3bb557 100644 --- a/services/certificates/src/stackit/certificates/configuration.py +++ b/services/certificates/src/stackit/certificates/configuration.py @@ -5,7 +5,7 @@ This API offers the ability to store TLS certificates, which can be used by load balancing servers in STACKIT. They can be between consumer and load balancing server and/or between load balancing server and endpoint server. - The version of the OpenAPI document: 2beta.0.0 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/certificates/src/stackit/certificates/exceptions.py b/services/certificates/src/stackit/certificates/exceptions.py index 66a0a51f..244fb084 100644 --- a/services/certificates/src/stackit/certificates/exceptions.py +++ b/services/certificates/src/stackit/certificates/exceptions.py @@ -5,7 +5,7 @@ This API offers the ability to store TLS certificates, which can be used by load balancing servers in STACKIT. They can be between consumer and load balancing server and/or between load balancing server and endpoint server. - The version of the OpenAPI document: 2beta.0.0 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/certificates/src/stackit/certificates/models/__init__.py b/services/certificates/src/stackit/certificates/models/__init__.py index 2b551629..7ee18028 100644 --- a/services/certificates/src/stackit/certificates/models/__init__.py +++ b/services/certificates/src/stackit/certificates/models/__init__.py @@ -6,7 +6,7 @@ This API offers the ability to store TLS certificates, which can be used by load balancing servers in STACKIT. They can be between consumer and load balancing server and/or between load balancing server and endpoint server. - The version of the OpenAPI document: 2beta.0.0 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. @@ -17,9 +17,6 @@ from stackit.certificates.models.create_certificate_payload import ( CreateCertificatePayload, ) -from stackit.certificates.models.create_certificate_response import ( - CreateCertificateResponse, -) from stackit.certificates.models.get_certificate_response import GetCertificateResponse from stackit.certificates.models.google_protobuf_any import GoogleProtobufAny from stackit.certificates.models.list_certificates_response import ( diff --git a/services/certificates/src/stackit/certificates/models/create_certificate_payload.py b/services/certificates/src/stackit/certificates/models/create_certificate_payload.py index 9b820b43..7d78c585 100644 --- a/services/certificates/src/stackit/certificates/models/create_certificate_payload.py +++ b/services/certificates/src/stackit/certificates/models/create_certificate_payload.py @@ -5,7 +5,7 @@ This API offers the ability to store TLS certificates, which can be used by load balancing servers in STACKIT. They can be between consumer and load balancing server and/or between load balancing server and endpoint server. - The version of the OpenAPI document: 2beta.0.0 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/certificates/src/stackit/certificates/models/create_certificate_response.py b/services/certificates/src/stackit/certificates/models/create_certificate_response.py deleted file mode 100644 index 310a1d0b..00000000 --- a/services/certificates/src/stackit/certificates/models/create_certificate_response.py +++ /dev/null @@ -1,108 +0,0 @@ -# coding: utf-8 - -""" - STACKIT Application Load Balancer Certificates API - - This API offers the ability to store TLS certificates, which can be used by load balancing servers in STACKIT. They can be between consumer and load balancing server and/or between load balancing server and endpoint server. - - The version of the OpenAPI document: 2beta.0.0 - Generated by OpenAPI Generator (https://openapi-generator.tech) - - Do not edit the class manually. -""" # noqa: E501 - -from __future__ import annotations - -import json -import pprint -import re # noqa: F401 -from typing import Any, ClassVar, Dict, List, Optional, Set - -from pydantic import BaseModel, ConfigDict, Field, field_validator -from typing_extensions import Annotated, Self - - -class CreateCertificateResponse(BaseModel): - """ - CreateCertificateResponse returns unique resource id - """ # noqa: E501 - - id: Optional[Annotated[str, Field(strict=True)]] = Field(default=None, description="The certificates resource id") - region: Optional[Annotated[str, Field(strict=True)]] = Field(default=None, description="Region") - __properties: ClassVar[List[str]] = ["id", "region"] - - @field_validator("id") - def id_validate_regular_expression(cls, value): - """Validates the regular expression""" - if value is None: - return value - - if not re.match(r"^[0-9a-z](?:(?:[0-9a-z]|-){0,251}[0-9a-z])?$", value): - raise ValueError(r"must validate the regular expression /^[0-9a-z](?:(?:[0-9a-z]|-){0,251}[0-9a-z])?$/") - return value - - @field_validator("region") - def region_validate_regular_expression(cls, value): - """Validates the regular expression""" - if value is None: - return value - - if not re.match(r"^[a-z]{2,4}[0-9]{2}$", value): - raise ValueError(r"must validate the regular expression /^[a-z]{2,4}[0-9]{2}$/") - return value - - 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 CreateCertificateResponse 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. - * OpenAPI `readOnly` fields are excluded. - """ - excluded_fields: Set[str] = set( - [ - "region", - ] - ) - - _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 CreateCertificateResponse 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"), "region": obj.get("region")}) - return _obj diff --git a/services/certificates/src/stackit/certificates/models/get_certificate_response.py b/services/certificates/src/stackit/certificates/models/get_certificate_response.py index f0cf715b..9813e206 100644 --- a/services/certificates/src/stackit/certificates/models/get_certificate_response.py +++ b/services/certificates/src/stackit/certificates/models/get_certificate_response.py @@ -5,7 +5,7 @@ This API offers the ability to store TLS certificates, which can be used by load balancing servers in STACKIT. They can be between consumer and load balancing server and/or between load balancing server and endpoint server. - The version of the OpenAPI document: 2beta.0.0 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/certificates/src/stackit/certificates/models/google_protobuf_any.py b/services/certificates/src/stackit/certificates/models/google_protobuf_any.py index d4bfe87a..faec854f 100644 --- a/services/certificates/src/stackit/certificates/models/google_protobuf_any.py +++ b/services/certificates/src/stackit/certificates/models/google_protobuf_any.py @@ -5,7 +5,7 @@ This API offers the ability to store TLS certificates, which can be used by load balancing servers in STACKIT. They can be between consumer and load balancing server and/or between load balancing server and endpoint server. - The version of the OpenAPI document: 2beta.0.0 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/certificates/src/stackit/certificates/models/list_certificates_response.py b/services/certificates/src/stackit/certificates/models/list_certificates_response.py index 4026909b..e36c660b 100644 --- a/services/certificates/src/stackit/certificates/models/list_certificates_response.py +++ b/services/certificates/src/stackit/certificates/models/list_certificates_response.py @@ -5,7 +5,7 @@ This API offers the ability to store TLS certificates, which can be used by load balancing servers in STACKIT. They can be between consumer and load balancing server and/or between load balancing server and endpoint server. - The version of the OpenAPI document: 2beta.0.0 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/certificates/src/stackit/certificates/models/status.py b/services/certificates/src/stackit/certificates/models/status.py index 73aebec8..bc175f0a 100644 --- a/services/certificates/src/stackit/certificates/models/status.py +++ b/services/certificates/src/stackit/certificates/models/status.py @@ -5,7 +5,7 @@ This API offers the ability to store TLS certificates, which can be used by load balancing servers in STACKIT. They can be between consumer and load balancing server and/or between load balancing server and endpoint server. - The version of the OpenAPI document: 2beta.0.0 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/certificates/src/stackit/certificates/rest.py b/services/certificates/src/stackit/certificates/rest.py index efbce97b..fd01d33c 100644 --- a/services/certificates/src/stackit/certificates/rest.py +++ b/services/certificates/src/stackit/certificates/rest.py @@ -5,7 +5,7 @@ This API offers the ability to store TLS certificates, which can be used by load balancing servers in STACKIT. They can be between consumer and load balancing server and/or between load balancing server and endpoint server. - The version of the OpenAPI document: 2beta.0.0 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually.