Repository: jquant/evo_client_python
Pull request #34: fix api version
Author: login: ricardokazu
Created: 2025-03-21T17:40:57Z | Merged: 2025-03-21T17:45:50Z



Diff:
diff --git a/pyproject.toml b/pyproject.toml
index b83a074..e492f9c 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -1,6 +1,6 @@
 [project]
 name = "evo_client"
-version = "1.0.6"
+version = "1.0.7"
 description = "ABC Evo SDK"
 authors = [
     {email = "support@evo.com"}
diff --git a/src/evo_client/api/member_membership_api.py b/src/evo_client/api/member_membership_api.py
index 43a687a..00b3e14 100644
--- a/src/evo_client/api/member_membership_api.py
+++ b/src/evo_client/api/member_membership_api.py
@@ -15,7 +15,8 @@ class MemberMembershipApi(BaseApi):
 
     def __init__(self, api_client: Optional[ApiClient] = None):
         super().__init__(api_client)
-        self.base_path = "/api/v1/membermembership"
+        self.base_path_v1 = "/api/v1/membermembership"
+        self.base_path_v2 = "/api/v2/membermembership"
 
     @overload
     def cancel_membership(
@@ -33,8 +34,7 @@ def cancel_membership(
         add_fine: bool = False,
         value_fine: Optional[float] = None,
         async_req: Literal[False] = False,
-    ) -> Any:
-        ...
+    ) -> Any: ...
 
     @overload
     def cancel_membership(
@@ -52,8 +52,7 @@ def cancel_membership(
         add_fine: bool = False,
         value_fine: Optional[float] = None,
         async_req: Literal[True] = True,
-    ) -> AsyncResult[Any]:
-        ...
+    ) -> AsyncResult[Any]: ...
 
     def cancel_membership(
         self,
@@ -105,7 +104,7 @@ def cancel_membership(
         }
 
         return self.api_client.call_api(
-            resource_path=f"{self.base_path}/cancellation",
+            resource_path=f"{self.base_path_v1}/cancellation",
             method="POST",
             query_params={k: v for k, v in params.items() if v is not None},
             auth_settings=["Basic"],
@@ -116,14 +115,12 @@ def cancel_membership(
     @overload
     def get_membership(
         self, id_member_membership: int, async_req: Literal[False] = False
-    ) -> MemberMembershipApiViewModel:
-        ...
+    ) -> MemberMembershipApiViewModel: ...
 
     @overload
     def get_membership(
         self, id_member_membership: int, async_req: Literal[True] = True
-    ) -> MemberMembershipApiViewModel:
-        ...
+    ) -> MemberMembershipApiViewModel: ...
 
     def get_membership(
         self, id_member_membership: int, async_req: bool = False
@@ -136,7 +133,7 @@ def get_membership(
             async_req: Execute request asynchronously
         """
         return self.api_client.call_api(
-            resource_path=f"{self.base_path}/{id_member_membership}",
+            resource_path=f"{self.base_path_v1}/{id_member_membership}",
             method="GET",
             response_type=MemberMembershipApiViewModel,
             auth_settings=["Basic"],
@@ -161,8 +158,7 @@ def get_canceled_memberships(
         take: Optional[int] = None,
         skip: Optional[int] = None,
         async_req: Literal[False] = False,
-    ) -> List[ContratosCanceladosResumoApiViewModel]:
-        ...
+    ) -> List[ContratosCanceladosResumoApiViewModel]: ...
 
     @overload
     def get_canceled_memberships(
@@ -181,8 +177,7 @@ def get_canceled_memberships(
         take: Optional[int] = None,
         skip: Optional[int] = None,
         async_req: Literal[True] = True,
-    ) -> List[ContratosCanceladosResumoApiViewModel]:
-        ...
+    ) -> List[ContratosCanceladosResumoApiViewModel]: ...
 
     def get_canceled_memberships(
         self,
@@ -243,7 +238,7 @@ def get_canceled_memberships(
         }
 
         return self.api_client.call_api(
-            resource_path="/api/v2/membermembership",
+            resource_path=f"{self.base_path_v2}",
             method="GET",
             query_params={k: v for k, v in params.items() if v is not None},
             response_type=List[ContratosCanceladosResumoApiViewModel],
diff --git a/src/evo_client/api/membership_api.py b/src/evo_client/api/membership_api.py
index 747bd14..ec737a0 100644
--- a/src/evo_client/api/membership_api.py
+++ b/src/evo_client/api/membership_api.py
@@ -14,24 +14,23 @@ class MembershipApi(BaseApi):
 
     def __init__(self, api_client: Optional[ApiClient] = None):
         super().__init__(api_client)
-        self.base_path = "/api/v1/membership"
+        self.base_path_v1 = "/api/v1/membership"
+        self.base_path_v2 = "/api/v2/membership"
 
     @overload
     def get_categories(
         self, async_req: Literal[False] = False
-    ) -> List[W12UtilsCategoryMembershipViewModel]:
-        ...
+    ) -> List[W12UtilsCategoryMembershipViewModel]: ...
 
     @overload
-    def get_categories(self, async_req: Literal[True] = True) -> AsyncResult[Any]:
-        ...
+    def get_categories(self, async_req: Literal[True] = True) -> AsyncResult[Any]: ...
 
     def get_categories(
         self, async_req: bool = False
     ) -> Union[List[W12UtilsCategoryMembershipViewModel], AsyncResult[Any]]:
         """Get membership categories."""
         return self.api_client.call_api(
-            resource_path=f"{self.base_path}/category",
+            resource_path=f"{self.base_path_v1}/category",
             method="GET",
             response_type=List[W12UtilsCategoryMembershipViewModel],
             auth_settings=["Basic"],
@@ -48,8 +47,7 @@ def get_memberships(
         skip: Optional[int] = None,
         active: Optional[bool] = None,
         async_req: Literal[False] = False,
-    ) -> List[ContratosResumoApiViewModel]:
-        ...
+    ) -> List[ContratosResumoApiViewModel]: ...
 
     @overload
     def get_memberships(
@@ -61,8 +59,7 @@ def get_memberships(
         skip: Optional[int] = None,
         active: Optional[bool] = None,
         async_req: Literal[True] = True,
-    ) -> AsyncResult[Any]:
-        ...
+    ) -> AsyncResult[Any]: ...
 
     def get_memberships(
         self,
@@ -96,7 +93,7 @@ def get_memberships(
         }
 
         return self.api_client.call_api(
-            resource_path=self.base_path,
+            resource_path=self.base_path_v2,
             method="GET",
             query_params={k: v for k, v in params.items() if v is not None},
             response_type=List[ContratosResumoApiViewModel],
diff --git a/src/evo_client/api/sales_api.py b/src/evo_client/api/sales_api.py
index 79329fb..cee4d34 100644
--- a/src/evo_client/api/sales_api.py
+++ b/src/evo_client/api/sales_api.py
@@ -14,19 +14,18 @@ class SalesApi(BaseApi):
 
     def __init__(self, api_client: Optional[ApiClient] = None):
         super().__init__(api_client)
-        self.base_path = "/api/v1/sales"
+        self.base_path_v1 = "/api/v1/sales"
+        self.base_path_v2 = "/api/v2/sales"
 
     @overload
     def get_sale_by_id(
         self, sale_id: int, async_req: Literal[False] = False
-    ) -> SalesViewModel:
-        ...
+    ) -> SalesViewModel: ...
 
     @overload
     def get_sale_by_id(
         self, sale_id: int, async_req: Literal[True] = True
-    ) -> AsyncResult[Any]:
-        ...
+    ) -> AsyncResult[Any]: ...
 
     def get_sale_by_id(
         self, sale_id: int, async_req: bool = False
@@ -36,7 +35,7 @@ def get_sale_by_id(
             raise ValueError("sale_id is required")
 
         return self.api_client.call_api(
-            resource_path=f"{self.base_path}/{sale_id}",
+            resource_path=f"{self.base_path_v1}/{sale_id}",
             method="GET",
             response_type=SalesViewModel,
             auth_settings=["Basic"],
@@ -46,14 +45,12 @@ def get_sale_by_id(
     @overload
     def create_sale(
         self, body: Optional[NewSaleViewModel] = None, async_req: Literal[False] = False
-    ) -> NewSaleResponse:
-        ...
+    ) -> NewSaleResponse: ...
 
     @overload
     def create_sale(
         self, body: Optional[NewSaleViewModel] = None, async_req: Literal[True] = True
-    ) -> AsyncResult[Any]:
-        ...
+    ) -> AsyncResult[Any]: ...
 
     def create_sale(
         self, body: Optional[NewSaleViewModel] = None, async_req: bool = False
@@ -71,7 +68,7 @@ def create_sale(
         - 7: Pix
         """
         return self.api_client.call_api(
-            resource_path=self.base_path,
+            resource_path=self.base_path_v2,
             method="POST",
             body=body.model_dump(exclude_unset=True) if body else None,
             response_type=NewSaleResponse,
@@ -99,8 +96,7 @@ def get_sales(
         show_allow_locker: Optional[bool] = None,
         only_total_pass: Optional[bool] = None,
         async_req: Literal[False] = False,
-    ) -> List[SalesViewModel]:
-        ...
+    ) -> List[SalesViewModel]: ...
 
     @overload
     def get_sales(
@@ -122,8 +118,7 @@ def get_sales(
         show_allow_locker: Optional[bool] = None,
         only_total_pass: Optional[bool] = None,
         async_req: Literal[True] = True,
-    ) -> AsyncResult[Any]:
-        ...
+    ) -> AsyncResult[Any]: ...
 
     def get_sales(
         self,
@@ -186,7 +181,7 @@ def get_sales(
         }
 
         return self.api_client.call_api(
-            resource_path="/api/v2/sales",
+            resource_path=self.base_path_v2,
             method="GET",
             query_params={k: v for k, v in params.items() if v is not None},
             response_type=List[SalesViewModel],
@@ -197,14 +192,12 @@ def get_sales(
     @overload
     def get_sales_items(
         self, branch_id: Optional[int] = None, async_req: Literal[False] = False
-    ) -> List[SalesItemsViewModel]:
-        ...
+    ) -> List[SalesItemsViewModel]: ...
 
     @overload
     def get_sales_items(
         self, branch_id: Optional[int] = None, async_req: Literal[True] = True
-    ) -> AsyncResult[Any]:
-        ...
+    ) -> AsyncResult[Any]: ...
 
     def get_sales_items(
         self, branch_id: Optional[int] = None, async_req: bool = False
@@ -213,7 +206,7 @@ def get_sales_items(
         params = {"idBranch": branch_id} if branch_id else {}
 
         return self.api_client.call_api(
-            resource_path=f"{self.base_path}/sales-items",
+            resource_path=f"{self.base_path_v1}/sales-items",
             method="GET",
             query_params=params,
             response_type=List[SalesItemsViewModel],
@@ -227,8 +220,7 @@ def get_sale_by_session_id(
         session_id: str,
         date: Optional[datetime] = None,
         async_req: Literal[False] = False,
-    ) -> int:
-        ...
+    ) -> int: ...
 
     @overload
     def get_sale_by_session_id(
@@ -236,8 +228,7 @@ def get_sale_by_session_id(
         session_id: str,
         date: Optional[datetime] = None,
         async_req: Literal[True] = True,
-    ) -> AsyncResult[Any]:
-        ...
+    ) -> AsyncResult[Any]: ...
 
     def get_sale_by_session_id(
         self, session_id: str, date: Optional[datetime] = None, async_req: bool = False
@@ -246,7 +237,7 @@ def get_sale_by_session_id(
         params = {"sessionId": session_id, "date": date}
 
         return self.api_client.call_api(
-            resource_path=f"{self.base_path}/by-session-id",
+            resource_path=f"{self.base_path_v1}/by-session-id",
             method="GET",
             query_params={k: v for k, v in params.items() if v is not None},
             response_type=int,
diff --git a/test/api/test_membership_api.py b/test/api/test_membership_api.py
index 26711ea..c28da14 100644
--- a/test/api/test_membership_api.py
+++ b/test/api/test_membership_api.py
@@ -52,7 +52,7 @@ def test_get_memberships_basic(membership_api: MembershipApi, mock_api_client: M
     mock_api_client.assert_called_once()
     args = mock_api_client.call_args[1]
     assert args["method"] == "GET"
-    assert args["resource_path"] == "/api/v1/membership"
+    assert args["resource_path"] == "/api/v2/membership"
 
 
 def test_get_memberships_with_filters(
diff --git a/test/api/test_sales_api.py b/test/api/test_sales_api.py
index 03d6120..4bcebd0 100644
--- a/test/api/test_sales_api.py
+++ b/test/api/test_sales_api.py
@@ -59,7 +59,7 @@ def test_create_sale(sales_api: SalesApi, mock_api_client: Mock):
     mock_api_client.assert_called_once()
     args = mock_api_client.call_args[1]
     assert args["method"] == "POST"
-    assert args["resource_path"] == "/api/v1/sales"
+    assert args["resource_path"] == "/api/v2/sales"
     assert args["body"] == sale_data.model_dump(exclude_unset=True)
 
 


Reviews:
user: login: gemini-code-assist[bot]
body: Hello @ricardokazu, I'm Gemini Code Assist[^1]! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

## Summary of Changes
This pull request addresses an issue with the API versioning in the `evo_client` library. Specifically, it modifies the `MemberMembershipApi`, `MembershipApi`, and `SalesApi` classes to correctly use versioned base paths for API calls. The changes involve introducing `base_path_v1` and `base_path_v2` attributes to store the base paths for API versions 1 and 2, respectively, and updating the `resource_path` parameter in the `call_api` method to use the appropriate versioned base path based on the API endpoint being called. Additionally, some redundant `...` lines were removed from type overload definitions.

### Highlights
* **API Versioning**: The pull request introduces explicit versioning for API endpoints by defining `base_path_v1` and `base_path_v2` attributes.
* **Endpoint Updates**: The `resource_path` in `call_api` calls is updated to use the correct versioned base path.
* **Code Cleanup**: Redundant `...` lines are removed from type overload definitions for cleaner code.

### Changelog
<details>
<summary>Click here to see the changelog</summary>

* **src/evo_client/api/member_membership_api.py**
  * Introduced `base_path_v1` and `base_path_v2` attributes for API versioning.
  * Updated `cancel_membership` endpoint to use `base_path_v1`.
  * Updated `get_membership` endpoint to use `base_path_v1`.
  * Updated `get_canceled_memberships` endpoint to use `base_path_v2`.
  * Removed redundant `...` from type overload definitions.
* **src/evo_client/api/membership_api.py**
  * Introduced `base_path_v1` and `base_path_v2` attributes for API versioning.
  * Updated `get_categories` endpoint to use `base_path_v1`.
  * Updated `get_memberships` endpoint to use `base_path_v2`.
  * Removed redundant `...` from type overload definitions.
* **src/evo_client/api/sales_api.py**
  * Introduced `base_path_v1` and `base_path_v2` attributes for API versioning.
  * Updated `get_sale_by_id` endpoint to use `base_path_v1`.
  * Updated `create_sale` endpoint to use `base_path_v2`.
  * Updated `get_sales` endpoint to use `base_path_v2`.
  * Updated `get_sales_items` endpoint to use `base_path_v1`.
  * Updated `get_sale_by_session_id` endpoint to use `base_path_v1`.
  * Removed redundant `...` from type overload definitions.

</details>


<details>

<summary><b>Using Gemini Code Assist</b></summary>
<br>

The full guide for Gemini Code Assist can be found on our [documentation page](https://developers.google.com/gemini-code-assist/docs/review-github-code), here are some quick tips.

<b>Invoking Gemini</b>

You can request assistance from Gemini at any point in your pull request via creating an issue comment (i.e. comment on the pull request page) using either `/gemini <command>` or `@gemini-code-assist <command>`. Below is a summary of the supported commands.

Feature | Command | Description
--- | --- | ---
Code Review | `/gemini review` | Performs a code review for the current pull request in its current state.
Pull Request Summary | `/gemini summary` | Provides a summary of the current pull request in its current state.
Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in issue comments and review comments.
Help | `/gemini help` | Displays a list of available commands.

<b>Customization</b>

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a `.gemini/` folder in the base of the repository. Detailed instructions can be found [here](https://developers.google.com/gemini-code-assist/docs/customize-gemini-behavior-github).

<b>Limitations & Feedback</b>

Gemini Code Assist is currently in preview and may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with :thumbsup: and :thumbsdown: on @gemini-code-assist comments to provide feedback.

</details>

<b>You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the [Gemini Code Assist IDE Extension](https://cloud.google.com/products/gemini/code-assist).</b>


[^1]: Review the [Privacy Notices](https://policies.google.com/privacy), [Generative AI Prohibited Use Policy](https://policies.google.com/terms/generative-ai/use-policy), [Terms of Service](https://policies.google.com/terms), and learn how to configure Gemini Code Assist in GitHub [here](https://developers.google.com/gemini-code-assist/docs/review-github-code). Gemini can make mistakes, so double check it and [use code with caution](https://support.google.com/legal/answer/13505487).

---

**Trivia time!**

What is the most popular API architectural style?

<details>
<summary><b>Click here for the answer</b></summary>
<br>
REST (Representational State Transfer) is the most popular API architectural style.

</details>

state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-03-21T17:41:07Z
user: login: gemini-code-assist[bot]
body: ## Code Review
The pull request updates the API versions used in several API classes. This involves introducing separate base path variables for different API versions and updating the resource paths in the API calls. The changes seem straightforward and necessary for supporting multiple API versions.

### Summary of Findings
* **Inconsistent API Version Usage**: The code uses both `base_path_v1` and `base_path_v2` in different API calls. Ensure that the correct version is being used for each endpoint to maintain consistency and prevent unexpected behavior.
* **Overload signature documentation**: The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

### Merge Readiness
The pull request seems to address a necessary update to the API versions. However, it's crucial to verify that the correct API version is being used for each endpoint and that the changes are thoroughly tested to prevent any regressions. I am unable to approve this pull request, and recommend that others review and approve this code before merging. Given the `medium` severity comment, I recommend that the author addresses it before merging.
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-03-21T17:41:24Z

Review comments:
diff_hunk: @@ -33,8 +34,7 @@ def cancel_membership(
         add_fine: bool = False,
         value_fine: Optional[float] = None,
         async_req: Literal[False] = False,
-    ) -> Any:
-        ...
+    ) -> Any: ...
path: src/evo_client/api/member_membership_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```suggestion
    ) -> Any:
        ...

```
created_at: 2025-03-21T17:41:22Z
author_association: CONTRIBUTOR
diff_hunk: @@ -52,8 +52,7 @@ def cancel_membership(
         add_fine: bool = False,
         value_fine: Optional[float] = None,
         async_req: Literal[True] = True,
-    ) -> AsyncResult[Any]:
-        ...
+    ) -> AsyncResult[Any]: ...
path: src/evo_client/api/member_membership_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> AsyncResult[Any]:
        ...

```
created_at: 2025-03-21T17:41:22Z
author_association: CONTRIBUTOR
diff_hunk: @@ -116,14 +115,12 @@ def cancel_membership(
     @overload
     def get_membership(
         self, id_member_membership: int, async_req: Literal[False] = False
-    ) -> MemberMembershipApiViewModel:
-        ...
+    ) -> MemberMembershipApiViewModel: ...
path: src/evo_client/api/member_membership_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> MemberMembershipApiViewModel:
        ...

```
created_at: 2025-03-21T17:41:23Z
author_association: CONTRIBUTOR
diff_hunk: @@ -116,14 +115,12 @@ def cancel_membership(
     @overload
     def get_membership(
         self, id_member_membership: int, async_req: Literal[False] = False
-    ) -> MemberMembershipApiViewModel:
-        ...
+    ) -> MemberMembershipApiViewModel: ...
 
     @overload
     def get_membership(
         self, id_member_membership: int, async_req: Literal[True] = True
-    ) -> MemberMembershipApiViewModel:
-        ...
+    ) -> MemberMembershipApiViewModel: ...
path: src/evo_client/api/member_membership_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> MemberMembershipApiViewModel:
        ...

```
created_at: 2025-03-21T17:41:23Z
author_association: CONTRIBUTOR
diff_hunk: @@ -161,8 +158,7 @@ def get_canceled_memberships(
         take: Optional[int] = None,
         skip: Optional[int] = None,
         async_req: Literal[False] = False,
-    ) -> List[ContratosCanceladosResumoApiViewModel]:
-        ...
+    ) -> List[ContratosCanceladosResumoApiViewModel]: ...
path: src/evo_client/api/member_membership_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> List[ContratosCanceladosResumoApiViewModel]:
        ...

```
created_at: 2025-03-21T17:41:23Z
author_association: CONTRIBUTOR
diff_hunk: @@ -181,8 +177,7 @@ def get_canceled_memberships(
         take: Optional[int] = None,
         skip: Optional[int] = None,
         async_req: Literal[True] = True,
-    ) -> List[ContratosCanceladosResumoApiViewModel]:
-        ...
+    ) -> List[ContratosCanceladosResumoApiViewModel]: ...
path: src/evo_client/api/member_membership_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> List[ContratosCanceladosResumoApiViewModel]:
        ...

```
created_at: 2025-03-21T17:41:23Z
author_association: CONTRIBUTOR
diff_hunk: @@ -14,24 +14,23 @@ class MembershipApi(BaseApi):
 
     def __init__(self, api_client: Optional[ApiClient] = None):
         super().__init__(api_client)
-        self.base_path = "/api/v1/membership"
+        self.base_path_v1 = "/api/v1/membership"
+        self.base_path_v2 = "/api/v2/membership"
 
     @overload
     def get_categories(
         self, async_req: Literal[False] = False
-    ) -> List[W12UtilsCategoryMembershipViewModel]:
-        ...
+    ) -> List[W12UtilsCategoryMembershipViewModel]: ...
path: src/evo_client/api/membership_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```suggestion
    ) -> List[W12UtilsCategoryMembershipViewModel]:
        ...

```
created_at: 2025-03-21T17:41:23Z
author_association: CONTRIBUTOR
diff_hunk: @@ -14,24 +14,23 @@ class MembershipApi(BaseApi):
 
     def __init__(self, api_client: Optional[ApiClient] = None):
         super().__init__(api_client)
-        self.base_path = "/api/v1/membership"
+        self.base_path_v1 = "/api/v1/membership"
+        self.base_path_v2 = "/api/v2/membership"
 
     @overload
     def get_categories(
         self, async_req: Literal[False] = False
-    ) -> List[W12UtilsCategoryMembershipViewModel]:
-        ...
+    ) -> List[W12UtilsCategoryMembershipViewModel]: ...
 
     @overload
-    def get_categories(self, async_req: Literal[True] = True) -> AsyncResult[Any]:
-        ...
+    def get_categories(self, async_req: Literal[True] = True) -> AsyncResult[Any]: ...
path: src/evo_client/api/membership_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> AsyncResult[Any]:
        ...

```
created_at: 2025-03-21T17:41:23Z
author_association: CONTRIBUTOR
diff_hunk: @@ -48,8 +47,7 @@ def get_memberships(
         skip: Optional[int] = None,
         active: Optional[bool] = None,
         async_req: Literal[False] = False,
-    ) -> List[ContratosResumoApiViewModel]:
-        ...
+    ) -> List[ContratosResumoApiViewModel]: ...
path: src/evo_client/api/membership_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> List[ContratosResumoApiViewModel]:
        ...

```
created_at: 2025-03-21T17:41:23Z
author_association: CONTRIBUTOR
diff_hunk: @@ -61,8 +59,7 @@ def get_memberships(
         skip: Optional[int] = None,
         active: Optional[bool] = None,
         async_req: Literal[True] = True,
-    ) -> AsyncResult[Any]:
-        ...
+    ) -> AsyncResult[Any]: ...
path: src/evo_client/api/membership_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> AsyncResult[Any]:
        ...

```
created_at: 2025-03-21T17:41:23Z
author_association: CONTRIBUTOR
diff_hunk: @@ -14,19 +14,18 @@ class SalesApi(BaseApi):
 
     def __init__(self, api_client: Optional[ApiClient] = None):
         super().__init__(api_client)
-        self.base_path = "/api/v1/sales"
+        self.base_path_v1 = "/api/v1/sales"
+        self.base_path_v2 = "/api/v2/sales"
 
     @overload
     def get_sale_by_id(
         self, sale_id: int, async_req: Literal[False] = False
-    ) -> SalesViewModel:
-        ...
+    ) -> SalesViewModel: ...
path: src/evo_client/api/sales_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```suggestion
    ) -> SalesViewModel:
        ...

```
created_at: 2025-03-21T17:41:23Z
author_association: CONTRIBUTOR
diff_hunk: @@ -14,19 +14,18 @@ class SalesApi(BaseApi):
 
     def __init__(self, api_client: Optional[ApiClient] = None):
         super().__init__(api_client)
-        self.base_path = "/api/v1/sales"
+        self.base_path_v1 = "/api/v1/sales"
+        self.base_path_v2 = "/api/v2/sales"
 
     @overload
     def get_sale_by_id(
         self, sale_id: int, async_req: Literal[False] = False
-    ) -> SalesViewModel:
-        ...
+    ) -> SalesViewModel: ...
 
     @overload
     def get_sale_by_id(
         self, sale_id: int, async_req: Literal[True] = True
-    ) -> AsyncResult[Any]:
-        ...
+    ) -> AsyncResult[Any]: ...
path: src/evo_client/api/sales_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> AsyncResult[Any]:
        ...

```
created_at: 2025-03-21T17:41:23Z
author_association: CONTRIBUTOR
diff_hunk: @@ -46,14 +45,12 @@ def get_sale_by_id(
     @overload
     def create_sale(
         self, body: Optional[NewSaleViewModel] = None, async_req: Literal[False] = False
-    ) -> NewSaleResponse:
-        ...
+    ) -> NewSaleResponse: ...
path: src/evo_client/api/sales_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> NewSaleResponse:
        ...

```
created_at: 2025-03-21T17:41:24Z
author_association: CONTRIBUTOR
diff_hunk: @@ -46,14 +45,12 @@ def get_sale_by_id(
     @overload
     def create_sale(
         self, body: Optional[NewSaleViewModel] = None, async_req: Literal[False] = False
-    ) -> NewSaleResponse:
-        ...
+    ) -> NewSaleResponse: ...
 
     @overload
     def create_sale(
         self, body: Optional[NewSaleViewModel] = None, async_req: Literal[True] = True
-    ) -> AsyncResult[Any]:
-        ...
+    ) -> AsyncResult[Any]: ...
path: src/evo_client/api/sales_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> AsyncResult[Any]:
        ...

```
created_at: 2025-03-21T17:41:24Z
author_association: CONTRIBUTOR
diff_hunk: @@ -99,8 +96,7 @@ def get_sales(
         show_allow_locker: Optional[bool] = None,
         only_total_pass: Optional[bool] = None,
         async_req: Literal[False] = False,
-    ) -> List[SalesViewModel]:
-        ...
+    ) -> List[SalesViewModel]: ...
path: src/evo_client/api/sales_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> List[SalesViewModel]:
        ...

```
created_at: 2025-03-21T17:41:24Z
author_association: CONTRIBUTOR
diff_hunk: @@ -122,8 +118,7 @@ def get_sales(
         show_allow_locker: Optional[bool] = None,
         only_total_pass: Optional[bool] = None,
         async_req: Literal[True] = True,
-    ) -> AsyncResult[Any]:
-        ...
+    ) -> AsyncResult[Any]: ...
path: src/evo_client/api/sales_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> AsyncResult[Any]:
        ...

```
created_at: 2025-03-21T17:41:24Z
author_association: CONTRIBUTOR
diff_hunk: @@ -197,14 +192,12 @@ def get_sales(
     @overload
     def get_sales_items(
         self, branch_id: Optional[int] = None, async_req: Literal[False] = False
-    ) -> List[SalesItemsViewModel]:
-        ...
+    ) -> List[SalesItemsViewModel]: ...
path: src/evo_client/api/sales_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> List[SalesItemsViewModel]:
        ...

```
created_at: 2025-03-21T17:41:24Z
author_association: CONTRIBUTOR
diff_hunk: @@ -197,14 +192,12 @@ def get_sales(
     @overload
     def get_sales_items(
         self, branch_id: Optional[int] = None, async_req: Literal[False] = False
-    ) -> List[SalesItemsViewModel]:
-        ...
+    ) -> List[SalesItemsViewModel]: ...
 
     @overload
     def get_sales_items(
         self, branch_id: Optional[int] = None, async_req: Literal[True] = True
-    ) -> AsyncResult[Any]:
-        ...
+    ) -> AsyncResult[Any]: ...
path: src/evo_client/api/sales_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> AsyncResult[Any]:
        ...

```
created_at: 2025-03-21T17:41:24Z
author_association: CONTRIBUTOR
diff_hunk: @@ -227,17 +220,15 @@ def get_sale_by_session_id(
         session_id: str,
         date: Optional[datetime] = None,
         async_req: Literal[False] = False,
-    ) -> int:
-        ...
+    ) -> int: ...
path: src/evo_client/api/sales_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> int:
        ...

```
created_at: 2025-03-21T17:41:24Z
author_association: CONTRIBUTOR
diff_hunk: @@ -227,17 +220,15 @@ def get_sale_by_session_id(
         session_id: str,
         date: Optional[datetime] = None,
         async_req: Literal[False] = False,
-    ) -> int:
-        ...
+    ) -> int: ...
 
     @overload
     def get_sale_by_session_id(
         self,
         session_id: str,
         date: Optional[datetime] = None,
         async_req: Literal[True] = True,
-    ) -> AsyncResult[Any]:
-        ...
+    ) -> AsyncResult[Any]: ...
path: src/evo_client/api/sales_api.py
user: login: gemini-code-assist[bot]
body: ![medium](https://img.shields.io/badge/priority-medium-yellow)

The overload signatures are now only defined with `...`. While this is valid, it removes the documentation for each parameter. Consider adding back the documentation for each parameter in the overload signatures.

```python
    ) -> AsyncResult[Any]:
        ...

```
created_at: 2025-03-21T17:41:24Z
author_association: CONTRIBUTOR

PR comments:
user: login: github-actions[bot]
created_at: 2025-03-21T17:42:00Z
body: A **new** [pull request](https://github.com/jquant/evo_client_python/pull/35) has been created to format the Python code from this Pull Request. :art:
Please review the changes and merge the pull request #35 before merging the current pull request. :+1:
author_association: NONE
user: login: github-actions[bot]
created_at: 2025-03-21T17:42:43Z
body: A **new** [pull request](https://github.com/jquant/evo_client_python/pull/35) has been created to format the Python code from this Pull Request. :art:
Please review the changes and merge the pull request #35 before merging the current pull request. :+1:
author_association: NONE
user: login: github-actions[bot]
created_at: 2025-03-21T17:45:31Z
body: A **new** [pull request](https://github.com/jquant/evo_client_python/pull/35) has been created to format the Python code from this Pull Request. :art:
Please review the changes and merge the pull request #35 before merging the current pull request. :+1:
author_association: NONE
user: login: codecov[bot]
created_at: 2025-03-21T17:46:13Z
body: ## [Codecov](https://app.codecov.io/gh/jquant/evo_client_python/pull/34?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=jquant) Report
All modified and coverable lines are covered by tests :white_check_mark:
> Project coverage is 69.50%. Comparing base [(`1b1e325`)](https://app.codecov.io/gh/jquant/evo_client_python/commit/1b1e325430666c11416aa4173a3a9aaf2acb7f8b?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=jquant) to head [(`c20e74a`)](https://app.codecov.io/gh/jquant/evo_client_python/commit/c20e74a16fb3d5ed6721b9a09a4fe73111f3e12a?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=jquant).
> Report is 5 commits behind head on main.

<details><summary>Additional details and impacted files</summary>


```diff
@@            Coverage Diff             @@
##             main      #34      +/-   ##
==========================================
+ Coverage   69.49%   69.50%   +0.01%     
==========================================
  Files         160      160              
  Lines        5812     5815       +3     
==========================================
+ Hits         4039     4042       +3     
  Misses       1773     1773              
```

</details>

[:umbrella: View full report in Codecov by Sentry](https://app.codecov.io/gh/jquant/evo_client_python/pull/34?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=jquant).   
:loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=jquant).

<details><summary> :rocket: New features to boost your workflow: </summary>

- :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
</details>
author_association: NONE