bosa-connectors-binary 0.1.3__cp311-cp311-win_amd64.whl → 0.1.4__cp311-cp311-win_amd64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,46 @@
1
+ from .connector import BosaConnector as BosaConnector
2
+ from .helpers.model_request_generator import create_request_model as create_request_model
3
+ from _typeshed import Incomplete
4
+ from langchain_core.tools import BaseTool
5
+ from pydantic import BaseModel as BaseModel
6
+
7
+ class BosaConnectorToolError(Exception):
8
+ """Base exception for BOSA connector errors."""
9
+
10
+ class BOSAConnectorToolGenerator:
11
+ """Tool Generator for BOSA Connectors.
12
+
13
+ This class generates tools based on OpenAPI schemas for various services.
14
+
15
+ Attributes:
16
+ api_base_url (str): The base URL for the API.
17
+ api_key (str): The API key for authentication.
18
+ info_path (str): The path to the API information endpoint.
19
+ DEFAULT_TIMEOUT (int): Default timeout for API requests.
20
+ app_name (str): The name of the application.
21
+ schema_data (dict): The schema data for the services.
22
+
23
+ Methods:
24
+ generate_tools(): Generates tools for the specified services.
25
+ """
26
+ api_base_url: str
27
+ api_key: str
28
+ INFO_PATH: str
29
+ DEFAULT_TIMEOUT: int
30
+ app_name: str
31
+ schema_data: dict
32
+ EXCLUDED_ENDPOINTS: Incomplete
33
+ def __init__(self, api_base_url: str, api_key: str, app_name: str) -> None:
34
+ """Initialize the tool generator with API base URL, info path, and app name.
35
+
36
+ Args:
37
+ api_base_url (str): The base URL for the API.
38
+ api_key (str): The API key for authentication.
39
+ app_name (str): The name of the application.
40
+ """
41
+ def generate_tools(self) -> list[BaseTool]:
42
+ """Generate tools based on the BOSA API OpenAPI schemas.
43
+
44
+ Returns:
45
+ Dict[str, Type[BaseTool]]: A dictionary of generated tool classes.
46
+ """
Binary file