From 61e84c1228d6da340eff4cd63d01838c817465b8 Mon Sep 17 00:00:00 2001 From: ckoegel Date: Mon, 27 Oct 2025 15:52:19 -0400 Subject: [PATCH] SWI-8319 Deprecate TN Lookup V1 --- bandwidth.yml | 2 ++ bandwidth/api/phone_number_lookup_api.py | 18 ++++++++++++------ 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/bandwidth.yml b/bandwidth.yml index 3cc990a7..bf2c9ab0 100644 --- a/bandwidth.yml +++ b/bandwidth.yml @@ -1330,6 +1330,7 @@ paths: servers: *ref_2 /accounts/{accountId}/tnlookup: post: + deprecated: true summary: Create Lookup description: Create a Phone Number Lookup Request. operationId: createLookup @@ -1359,6 +1360,7 @@ paths: description: Production /accounts/{accountId}/tnlookup/{requestId}: get: + deprecated: true summary: Get Lookup Request Status description: Get an existing Phone Number Lookup Request. operationId: getLookupStatus diff --git a/bandwidth/api/phone_number_lookup_api.py b/bandwidth/api/phone_number_lookup_api.py index 3a7a4336..6c5dc0a1 100644 --- a/bandwidth/api/phone_number_lookup_api.py +++ b/bandwidth/api/phone_number_lookup_api.py @@ -59,7 +59,7 @@ def create_lookup( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=1)] = 0, ) -> CreateLookupResponse: - """Create Lookup + """(Deprecated) Create Lookup Create a Phone Number Lookup Request. @@ -88,6 +88,7 @@ def create_lookup( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 + warnings.warn("POST /accounts/{accountId}/tnlookup is deprecated.", DeprecationWarning) _param = self._create_lookup_serialize( account_id=account_id, @@ -136,7 +137,7 @@ def create_lookup_with_http_info( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=1)] = 0, ) -> ApiResponse[CreateLookupResponse]: - """Create Lookup + """(Deprecated) Create Lookup Create a Phone Number Lookup Request. @@ -165,6 +166,7 @@ def create_lookup_with_http_info( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 + warnings.warn("POST /accounts/{accountId}/tnlookup is deprecated.", DeprecationWarning) _param = self._create_lookup_serialize( account_id=account_id, @@ -213,7 +215,7 @@ def create_lookup_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=1)] = 0, ) -> RESTResponseType: - """Create Lookup + """(Deprecated) Create Lookup Create a Phone Number Lookup Request. @@ -242,6 +244,7 @@ def create_lookup_without_preload_content( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 + warnings.warn("POST /accounts/{accountId}/tnlookup is deprecated.", DeprecationWarning) _param = self._create_lookup_serialize( account_id=account_id, @@ -369,7 +372,7 @@ def get_lookup_status( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=1)] = 0, ) -> LookupStatus: - """Get Lookup Request Status + """(Deprecated) Get Lookup Request Status Get an existing Phone Number Lookup Request. @@ -398,6 +401,7 @@ def get_lookup_status( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 + warnings.warn("GET /accounts/{accountId}/tnlookup/{requestId} is deprecated.", DeprecationWarning) _param = self._get_lookup_status_serialize( account_id=account_id, @@ -446,7 +450,7 @@ def get_lookup_status_with_http_info( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=1)] = 0, ) -> ApiResponse[LookupStatus]: - """Get Lookup Request Status + """(Deprecated) Get Lookup Request Status Get an existing Phone Number Lookup Request. @@ -475,6 +479,7 @@ def get_lookup_status_with_http_info( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 + warnings.warn("GET /accounts/{accountId}/tnlookup/{requestId} is deprecated.", DeprecationWarning) _param = self._get_lookup_status_serialize( account_id=account_id, @@ -523,7 +528,7 @@ def get_lookup_status_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=1)] = 0, ) -> RESTResponseType: - """Get Lookup Request Status + """(Deprecated) Get Lookup Request Status Get an existing Phone Number Lookup Request. @@ -552,6 +557,7 @@ def get_lookup_status_without_preload_content( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 + warnings.warn("GET /accounts/{accountId}/tnlookup/{requestId} is deprecated.", DeprecationWarning) _param = self._get_lookup_status_serialize( account_id=account_id,