airia 0.1.26__py3-none-any.whl → 0.1.28__py3-none-any.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,153 @@
1
+ from typing import Any, Dict, List, Optional, Union
2
+ from urllib.parse import urljoin
3
+
4
+ from ...types._api_version import ApiVersion
5
+ from .._request_handler import AsyncRequestHandler, RequestHandler
6
+
7
+
8
+ class BaseTools:
9
+ def __init__(self, request_handler: Union[RequestHandler, AsyncRequestHandler]):
10
+ self._request_handler = request_handler
11
+
12
+ def _pre_create_tool(
13
+ self,
14
+ name: str,
15
+ description: str,
16
+ api_endpoint: str,
17
+ method_type: str,
18
+ purpose: str,
19
+ body_type: str,
20
+ category: str,
21
+ provider: str,
22
+ tool_type: str,
23
+ body: str,
24
+ headers: List[Dict[str, str]],
25
+ parameters: List[Dict[str, Any]],
26
+ request_timeout: int,
27
+ route_through_acc: bool,
28
+ should_redirect: bool,
29
+ tool_credentials: Dict[str, Any],
30
+ acc_group: Optional[str] = None,
31
+ documentation: Optional[str] = None,
32
+ project_id: Optional[str] = None,
33
+ tags: Optional[List[str]] = None,
34
+ tool_metadata: Optional[List[Dict[str, Any]]] = None,
35
+ correlation_id: Optional[str] = None,
36
+ api_version: str = ApiVersion.V1.value,
37
+ ):
38
+ """
39
+ Prepare request data for creating a new tool.
40
+
41
+ This internal method constructs the URL and payload for tool creation
42
+ requests, including all tool configuration and metadata.
43
+
44
+ Args:
45
+ name: Name of the tool
46
+ description: Brief description of what the tool does
47
+ api_endpoint: Web API endpoint where the tool sends its requests
48
+ method_type: HTTP method type (Get, Post, Put, Delete)
49
+ purpose: When and why to use this tool
50
+ body_type: Type of the request body (Json, XFormUrlEncoded, None)
51
+ category: Category of the tool (Action, Airia, Mcp)
52
+ provider: Provider of the tool
53
+ tool_type: Type of the tool (Custom, Calculator, MCP, etc.)
54
+ body: Body of the request that the tool sends to the API
55
+ headers: List of headers required when making the API request
56
+ parameters: Collection of parameters required by the tool
57
+ request_timeout: Request timeout in seconds for tool execution
58
+ route_through_acc: Flag indicating whether the tool should route through the ACC
59
+ should_redirect: Flag indicating whether the tool should redirect with authorization header
60
+ tool_credentials: Tool credentials
61
+ acc_group: Optional ACC specific group name
62
+ documentation: Optional documentation for the tool
63
+ project_id: Optional unique identifier of the project to which the tool is associated
64
+ tags: Optional list of tags for the tool
65
+ tool_metadata: Optional user provided metadata for the tool definition
66
+ correlation_id: Optional correlation ID for tracing
67
+ api_version: API version to use for the request
68
+
69
+ Returns:
70
+ RequestData: Prepared request data for the tool creation endpoint
71
+
72
+ Raises:
73
+ ValueError: If an invalid API version is provided
74
+ """
75
+ if api_version not in ApiVersion.as_list():
76
+ raise ValueError(
77
+ f"Invalid API version: {api_version}. Valid versions are: {', '.join(ApiVersion.as_list())}"
78
+ )
79
+ url = urljoin(self._request_handler.base_url, f"{api_version}/Tools")
80
+
81
+ payload: Dict[str, Any] = {
82
+ "name": name,
83
+ "description": description,
84
+ "apiEndpoint": api_endpoint,
85
+ "methodType": method_type,
86
+ "purpose": purpose,
87
+ "bodyType": body_type,
88
+ "category": category,
89
+ "provider": provider,
90
+ "toolType": tool_type,
91
+ "body": body,
92
+ "headers": headers,
93
+ "parameters": parameters,
94
+ "requestTimeout": request_timeout,
95
+ "routeThroughACC": route_through_acc,
96
+ "shouldRedirect": should_redirect,
97
+ "toolCredentials": tool_credentials,
98
+ }
99
+
100
+ # Add optional fields only if they are provided
101
+ if acc_group is not None:
102
+ payload["accGroup"] = acc_group
103
+ if documentation is not None:
104
+ payload["documentation"] = documentation
105
+ if project_id is not None:
106
+ payload["projectId"] = project_id
107
+ if tags is not None:
108
+ payload["tags"] = tags
109
+ if tool_metadata is not None:
110
+ payload["toolMetadata"] = tool_metadata
111
+
112
+ request_data = self._request_handler.prepare_request(
113
+ url=url, payload=payload, correlation_id=correlation_id
114
+ )
115
+
116
+ return request_data
117
+
118
+ def _pre_delete_tool(
119
+ self,
120
+ tool_id: str,
121
+ correlation_id: Optional[str] = None,
122
+ api_version: str = ApiVersion.V1.value,
123
+ ):
124
+ """
125
+ Prepare request data for deleting a tool by ID.
126
+
127
+ This internal method constructs the URL for tool deletion
128
+ requests using the provided tool identifier.
129
+
130
+ Args:
131
+ tool_id: ID of the tool to delete
132
+ correlation_id: Optional correlation ID for tracing
133
+ api_version: API version to use for the request
134
+
135
+ Returns:
136
+ RequestData: Prepared request data for the tool deletion endpoint
137
+
138
+ Raises:
139
+ ValueError: If an invalid API version is provided
140
+ """
141
+ if api_version not in ApiVersion.as_list():
142
+ raise ValueError(
143
+ f"Invalid API version: {api_version}. Valid versions are: {', '.join(ApiVersion.as_list())}"
144
+ )
145
+ url = urljoin(
146
+ self._request_handler.base_url,
147
+ f"{api_version}/Tools/{tool_id}",
148
+ )
149
+ request_data = self._request_handler.prepare_request(
150
+ url, correlation_id=correlation_id
151
+ )
152
+
153
+ return request_data
@@ -0,0 +1,245 @@
1
+ from typing import Any, Dict, List, Optional, Literal
2
+
3
+ from ...types._api_version import ApiVersion
4
+ from ...types.api.tools import CreateToolResponse
5
+ from .._request_handler import RequestHandler
6
+ from .base_tools import BaseTools
7
+
8
+
9
+ class Tools(BaseTools):
10
+ def __init__(self, request_handler: RequestHandler):
11
+ super().__init__(request_handler)
12
+
13
+ def create_tool(
14
+ self,
15
+ name: str,
16
+ description: str,
17
+ purpose: str,
18
+ api_endpoint: str,
19
+ method_type: str,
20
+ body: str,
21
+ tool_credentials: Dict[str, Any],
22
+ headers: List[Dict[str, str]] = [],
23
+ parameters: List[Dict[str, Any]] = [],
24
+ request_timeout: int = 100,
25
+ body_type: Literal["Json", "XFormUrlEncoded", "None"] = "Json",
26
+ category: Literal["Action", "Airia", "Mcp"] = "Airia",
27
+ tool_type: str = "Custom",
28
+ provider: str = "Custom",
29
+ route_through_acc: bool = False,
30
+ should_redirect: bool = True,
31
+ acc_group: Optional[str] = None,
32
+ documentation: Optional[str] = None,
33
+ project_id: Optional[str] = None,
34
+ tags: Optional[List[str]] = None,
35
+ tool_metadata: Optional[List[Dict[str, Any]]] = None,
36
+ correlation_id: Optional[str] = None,
37
+ ) -> CreateToolResponse:
38
+ """
39
+ Create a new tool in the Airia platform.
40
+
41
+ Args:
42
+ name (str): Name of the tool.
43
+ description (str): Brief description of what the tool does.
44
+ Example: "Use this tool to get the current weather in a given location."
45
+ purpose (str): When and why to use this tool.
46
+ Example: "When a user asks about the weather, including current conditions,
47
+ forecasts, or specific weather events."
48
+ api_endpoint (str): Web API endpoint where the tool sends its requests to
49
+ perform its task.
50
+ method_type (str): HTTP method type. Valid values: "Get", "Post", "Put", "Delete".
51
+ body_type (str): Type of the request body. Valid values: "Json", "XFormUrlEncoded", "None".
52
+ category (str): Category of the tool. Valid values: "Action", "Airia", "Mcp".
53
+ provider (str): Provider of the tool.
54
+ tool_type (str): Type of the tool. Valid values: "Custom", "Calculator", "MCP",
55
+ "LoadMemory", "StoreMemory", etc.
56
+ body (str): Body of the request that the tool sends to the API.
57
+ headers (list[dict]): List of headers required when making the API request.
58
+ Each header should be a dictionary with "key" and "value" fields.
59
+ Example: [{"key": "Content-Type", "value": "application/json"}]
60
+ parameters (list[dict]): Collection of parameters required by the tool
61
+ to execute its function.
62
+ request_timeout (int): Request timeout in seconds for tool execution.
63
+ route_through_acc (bool): Flag indicating whether the tool should route
64
+ through the ACC.
65
+ should_redirect (bool): Flag indicating whether the tool should redirect
66
+ with authorization header attached.
67
+ tool_credentials (dict): Tool credentials model.
68
+ acc_group (str, optional): ACC specific group name. If provided, the tool will
69
+ route through this ACC group.
70
+ documentation (str, optional): Documentation for the tool.
71
+ project_id (str, optional): Unique identifier of the project to which the tool
72
+ is associated.
73
+ tags (list[str], optional): List of tags for the tool.
74
+ tool_metadata (list[dict], optional): User provided metadata for the tool definition.
75
+ correlation_id (str, optional): A unique identifier for request tracing
76
+ and logging. If not provided, one will be automatically generated.
77
+
78
+ Returns:
79
+ CreateToolResponse: A response object containing the created tool details
80
+ including its ID, creation timestamp, configuration, credentials,
81
+ parameters, and all provided metadata.
82
+
83
+ Raises:
84
+ AiriaAPIError: If the API request fails, including cases where:
85
+ - Invalid parameters are provided (400)
86
+ - Authentication fails (401)
87
+ - Access is forbidden (403)
88
+ - Server errors (5xx)
89
+
90
+ Example:
91
+ ```python
92
+ from airia import AiriaClient
93
+
94
+ client = AiriaClient(api_key="your_api_key")
95
+
96
+ # Create a weather tool with all required parameters
97
+ tool = client.tools.create_tool(
98
+ name="get_weather",
99
+ description="Use this tool to get the current weather in a given location.",
100
+ api_endpoint="https://api.weather.com/v1/current",
101
+ method_type="Get",
102
+ purpose="When a user asks about the weather, including current conditions.",
103
+ body_type="None",
104
+ category="Action",
105
+ provider="WeatherAPI",
106
+ tool_type="Custom",
107
+ body="",
108
+ headers=[],
109
+ parameters=[],
110
+ request_timeout=100,
111
+ route_through_acc=False,
112
+ should_redirect=False,
113
+ tool_credentials={}
114
+ )
115
+ print(f"Created tool: {tool.id}")
116
+
117
+ # Create an email tool with headers and optional parameters
118
+ tool = client.tools.create_tool(
119
+ name="send_email",
120
+ description="Send an email to a recipient.",
121
+ api_endpoint="https://api.email-service.com/v1/send",
122
+ method_type="Post",
123
+ purpose="When a user wants to send an email message.",
124
+ body_type="Json",
125
+ category="Action",
126
+ provider="EmailService",
127
+ tool_type="Custom",
128
+ body='{"to": "{{recipient}}", "subject": "{{subject}}", "body": "{{message}}"}',
129
+ headers=[
130
+ {"key": "Content-Type", "value": "application/json"},
131
+ {"key": "Authorization", "value": "Bearer {{api_key}}"}
132
+ ],
133
+ parameters=[
134
+ {"name": "recipient", "type": "string", "required": True},
135
+ {"name": "subject", "type": "string", "required": True},
136
+ {"name": "message", "type": "string", "required": True}
137
+ ],
138
+ request_timeout=120,
139
+ route_through_acc=False,
140
+ should_redirect=False,
141
+ tool_credentials={},
142
+ documentation="This tool sends emails using the Email Service API.",
143
+ tags=["email", "communication"]
144
+ )
145
+ print(f"Created email tool: {tool.id}")
146
+ ```
147
+
148
+ Note:
149
+ - Required parameters: name, description, api_endpoint, method_type, purpose,
150
+ body_type, category, provider, tool_type, body, headers, parameters,
151
+ request_timeout, route_through_acc, should_redirect, and tool_credentials.
152
+ - Optional parameters: acc_group, documentation, project_id, tags, and tool_metadata.
153
+ - The method_type must be one of: "Get", "Post", "Put", "Delete"
154
+ - The body_type must be one of: "Json", "XFormUrlEncoded", "None"
155
+ - The category must be one of: "Action", "Airia", "Mcp"
156
+ - The tool_type must be one of: "Custom", "Calculator", "MCP", "LoadMemory",
157
+ "StoreMemory", etc.
158
+ """
159
+ request_data = self._pre_create_tool(
160
+ name=name,
161
+ description=description,
162
+ api_endpoint=api_endpoint,
163
+ method_type=method_type,
164
+ purpose=purpose,
165
+ body_type=body_type,
166
+ category=category,
167
+ provider=provider,
168
+ tool_type=tool_type,
169
+ body=body,
170
+ headers=headers,
171
+ parameters=parameters,
172
+ request_timeout=request_timeout,
173
+ route_through_acc=route_through_acc,
174
+ should_redirect=should_redirect,
175
+ tool_credentials=tool_credentials,
176
+ acc_group=acc_group,
177
+ documentation=documentation,
178
+ project_id=project_id,
179
+ tags=tags,
180
+ tool_metadata=tool_metadata,
181
+ correlation_id=correlation_id,
182
+ api_version=ApiVersion.V1.value,
183
+ )
184
+ resp = self._request_handler.make_request("POST", request_data)
185
+
186
+ return CreateToolResponse(**resp)
187
+
188
+ def delete_tool(
189
+ self,
190
+ tool_id: str,
191
+ correlation_id: Optional[str] = None,
192
+ ) -> None:
193
+ """
194
+ Delete a tool by its ID.
195
+
196
+ This method permanently removes a tool from the Airia platform.
197
+ This action cannot be undone.
198
+
199
+ Args:
200
+ tool_id (str): The unique identifier of the tool to delete.
201
+ correlation_id (str, optional): A unique identifier for request tracing
202
+ and logging. If not provided, one will be automatically generated.
203
+
204
+ Returns:
205
+ None: This method returns nothing upon successful deletion.
206
+
207
+ Raises:
208
+ AiriaAPIError: If the API request fails, including cases where:
209
+ - The tool_id doesn't exist (404)
210
+ - Authentication fails (401)
211
+ - Access is forbidden (403)
212
+ - Server errors (5xx)
213
+
214
+ Example:
215
+ ```python
216
+ from airia import AiriaClient
217
+
218
+ client = AiriaClient(api_key="your_api_key")
219
+
220
+ # Delete a tool
221
+ client.tools.delete_tool(tool_id="tool_123")
222
+ print("Tool deleted successfully")
223
+
224
+ # Handle deletion errors
225
+ from airia.exceptions import AiriaAPIError
226
+
227
+ try:
228
+ client.tools.delete_tool(tool_id="nonexistent_id")
229
+ except AiriaAPIError as e:
230
+ if e.status_code == 404:
231
+ print("Tool not found")
232
+ else:
233
+ print(f"Error deleting tool: {e.message}")
234
+ ```
235
+
236
+ Note:
237
+ This operation is permanent and cannot be undone. Make sure you have
238
+ the correct tool_id before calling this method.
239
+ """
240
+ request_data = self._pre_delete_tool(
241
+ tool_id=tool_id,
242
+ correlation_id=correlation_id,
243
+ api_version=ApiVersion.V1.value,
244
+ )
245
+ self._request_handler.make_request("DELETE", request_data, return_json=False)
@@ -1,3 +1,4 @@
1
1
  from . import attachments as attachments
2
2
  from . import models as models
3
3
  from . import pipeline_import as pipeline_import
4
+ from . import tools as tools
@@ -0,0 +1,7 @@
1
+ from ._tools import CreateToolResponse, ToolHeader, ToolParameter
2
+
3
+ __all__ = [
4
+ "CreateToolResponse",
5
+ "ToolHeader",
6
+ "ToolParameter",
7
+ ]
@@ -0,0 +1,245 @@
1
+ """
2
+ Pydantic models for tool management API responses.
3
+
4
+ This module defines data structures for tool operations including
5
+ creation and configuration within the Airia platform.
6
+ """
7
+
8
+ from typing import Optional, List
9
+ from datetime import datetime
10
+
11
+ from pydantic import BaseModel, Field
12
+
13
+
14
+ class ToolHeader(BaseModel):
15
+ """Key-value pair header for a tool definition.
16
+
17
+ Attributes:
18
+ key: The key of the header
19
+ value: The value of the header
20
+ """
21
+
22
+ key: str
23
+ value: str
24
+
25
+
26
+ class ToolParameter(BaseModel):
27
+ """Parameter definition for a tool.
28
+
29
+ Attributes:
30
+ name: Name of the parameter
31
+ type: Type of the parameter
32
+ description: Description of what the parameter does
33
+ default: Default value for the parameter
34
+ valid_options: List of valid options for the parameter
35
+ array_item_type: Type of items if this parameter is an array
36
+ parameters: Nested parameters for complex types
37
+ requirement: Whether the parameter is required or optional
38
+ """
39
+
40
+ name: str
41
+ type: str
42
+ description: str
43
+ default: Optional[str] = None
44
+ valid_options: Optional[List[str]] = Field(None, alias="validOptions")
45
+ array_item_type: Optional[str] = Field(None, alias="arrayItemType")
46
+ parameters: Optional[List["ToolParameter"]] = None
47
+ requirement: str
48
+
49
+
50
+ class ToolCredentialSettings(BaseModel):
51
+ """Settings for tool credentials.
52
+
53
+ Attributes:
54
+ available_credential_types: List of available credential types
55
+ default_value: Default credential value
56
+ platform_supported_oauth_types: List of OAuth types supported by the platform
57
+ """
58
+
59
+ available_credential_types: List[str] = Field(alias="availableCredentialTypes")
60
+ default_value: Optional[str] = Field(None, alias="defaultValue")
61
+ platform_supported_oauth_types: List[str] = Field(
62
+ alias="platformSupportedOAuthTypes"
63
+ )
64
+
65
+
66
+ class CredentialEntry(BaseModel):
67
+ """Represents a deserialized object for each entry of a credential.
68
+
69
+ Attributes:
70
+ key: The property name of the API Key for credentials data
71
+ value: The value of the credential
72
+ """
73
+
74
+ key: str
75
+ value: str
76
+
77
+
78
+ class ToolCredential(BaseModel):
79
+ """Tool credential information.
80
+
81
+ Attributes:
82
+ id: Unique identifier for the credential
83
+ name: Name of the credential
84
+ display_identifier_name: Display name for the credential identifier
85
+ created_at: When the credential was created
86
+ project_id: ID of the project this credential belongs to
87
+ type: Type of credential
88
+ expired: Whether the credential has expired
89
+ expires_on: When the credential expires
90
+ administrative_scope: Scope of the credential (e.g., "Tenant")
91
+ user_id: ID of the user who owns the credential
92
+ credential_data: List of credential entries
93
+ custom_credentials: Custom credentials data
94
+ custom_credentials_id: ID of custom credentials
95
+ tenant_id: ID of the tenant this credential belongs to
96
+ origin: Origin of the credential (Platform or Chat)
97
+ """
98
+
99
+ id: str
100
+ name: Optional[str] = None
101
+ display_identifier_name: Optional[str] = Field(None, alias="displayIdentifierName")
102
+ created_at: Optional[datetime] = Field(None, alias="createdAt")
103
+ project_id: Optional[str] = Field(None, alias="projectId")
104
+ type: str
105
+ expired: Optional[bool] = None
106
+ expires_on: Optional[datetime] = Field(None, alias="expiresOn")
107
+ administrative_scope: str = Field(alias="administrativeScope")
108
+ user_id: Optional[str] = Field(None, alias="userId")
109
+ credential_data: List[CredentialEntry] = Field(default_factory=list, alias="credentialData")
110
+ custom_credentials: Optional[dict] = Field(None, alias="customCredentials")
111
+ custom_credentials_id: Optional[str] = Field(None, alias="customCredentialsId")
112
+ tenant_id: Optional[str] = Field(None, alias="tenantId")
113
+ origin: str
114
+
115
+
116
+ class ToolCredentials(BaseModel):
117
+ """Credentials configuration for a tool.
118
+
119
+ Attributes:
120
+ tool_credential_settings: Settings for tool credentials
121
+ tool_credentials: The actual credential object
122
+ tool_credentials_id: ID of the tool credentials
123
+ auth_required: Whether authentication is required
124
+ use_user_credentials: Whether to use user credentials
125
+ user_credential_connector_id: ID of the user credential connector
126
+ use_user_credentials_type: Type of user credentials to use
127
+ credentials_source_type: Source type of the credentials
128
+ use_airia_key_support: Whether Airia key support is enabled
129
+ """
130
+
131
+ tool_credential_settings: ToolCredentialSettings = Field(
132
+ alias="toolCredentialSettings"
133
+ )
134
+ tool_credentials: Optional[ToolCredential] = Field(None, alias="toolCredentials")
135
+ tool_credentials_id: Optional[str] = Field(None, alias="toolCredentialsId")
136
+ auth_required: bool = Field(alias="authRequired")
137
+ use_user_credentials: bool = Field(alias="useUserCredentials")
138
+ user_credential_connector_id: Optional[str] = Field(
139
+ None, alias="userCredentialConnectorId"
140
+ )
141
+ use_user_credentials_type: str = Field(alias="useUserCredentialsType")
142
+ credentials_source_type: str = Field(alias="credentialsSourceType")
143
+ use_airia_key_support: bool = Field(alias="useAiriaKeySupport")
144
+
145
+
146
+ class ProjectReference(BaseModel):
147
+ """Reference to a project.
148
+
149
+ Attributes:
150
+ id: Project ID
151
+ name: Project name
152
+ """
153
+
154
+ id: str
155
+ name: str
156
+
157
+
158
+ class ToolMetadata(BaseModel):
159
+ """Metadata key-value pair for a tool.
160
+
161
+ Attributes:
162
+ key: The metadata key
163
+ value: The metadata value
164
+ """
165
+
166
+ key: str
167
+ value: str
168
+
169
+
170
+ class CreateToolResponse(BaseModel):
171
+ """Response data for tool creation and retrieval operations.
172
+
173
+ This response contains complete information about a tool including
174
+ its configuration, credentials, parameters, and metadata.
175
+
176
+ Attributes:
177
+ id: Unique identifier for the tool
178
+ created_at: Timestamp when the tool was created
179
+ updated_at: Timestamp when the tool was last updated
180
+ tool_type: Type of the tool (e.g., "custom")
181
+ name: Name of the tool
182
+ standardized_name: Standardized version of the tool name
183
+ display_name: Display name of the tool (includes provider suffix for gateway tools)
184
+ origin: Origin of the tool
185
+ description: Brief description of what the tool does
186
+ method_type: HTTP method type (Get, Post, Put, Delete)
187
+ purpose: When and why to use this tool
188
+ api_endpoint: Web API endpoint where the tool sends requests
189
+ provider: Provider of the tool
190
+ tool_credentials: Credentials configuration for the tool
191
+ headers: Headers required when making API requests
192
+ body: Body of the request that the tool sends to the API
193
+ body_type: Type of the request body (Json, XFormUrlEncoded, None)
194
+ parameters: List of parameters the tool accepts
195
+ project_id: ID of the project this tool belongs to
196
+ project_name: Name of the project this tool belongs to
197
+ project: Project reference object
198
+ children: Child tool definitions
199
+ route_through_acc: Whether the tool should route through an ACC specific group
200
+ should_redirect: Whether the tool should redirect
201
+ acc_group: ACC specific group name
202
+ documentation: Documentation for the tool
203
+ tags: List of tags associated with the tool
204
+ tool_metadata: List of metadata key-value pairs
205
+ supports_pagination: Whether the tool supports pagination
206
+ category: Category of the tool (Action, Airia, Mcp)
207
+ request_timeout: Request timeout in seconds
208
+ """
209
+
210
+ id: str
211
+ created_at: datetime = Field(alias="createdAt")
212
+ updated_at: datetime = Field(alias="updatedAt")
213
+ tool_type: str = Field(alias="toolType")
214
+ name: str
215
+ standardized_name: str = Field(alias="standardizedName")
216
+ display_name: Optional[str] = Field(None, alias="displayName")
217
+ origin: Optional[str] = None
218
+ description: str
219
+ method_type: str = Field(alias="methodType")
220
+ purpose: str
221
+ api_endpoint: str = Field(alias="apiEndpoint")
222
+ provider: str
223
+ tool_credentials: ToolCredentials = Field(alias="toolCredentials")
224
+ headers: List[ToolHeader]
225
+ body: str
226
+ body_type: str = Field(alias="bodyType")
227
+ parameters: List[ToolParameter]
228
+ project_id: Optional[str] = Field(None, alias="projectId")
229
+ project_name: Optional[str] = Field(None, alias="projectName")
230
+ project: Optional[ProjectReference] = None
231
+ children: Optional[List["CreateToolResponse"]] = None
232
+ route_through_acc: bool = Field(alias="routeThroughACC")
233
+ should_redirect: bool = Field(alias="shouldRedirect")
234
+ acc_group: Optional[str] = Field(None, alias="accGroup")
235
+ documentation: Optional[str] = None
236
+ tags: Optional[List[str]] = None
237
+ tool_metadata: Optional[List[ToolMetadata]] = Field(None, alias="toolMetadata")
238
+ supports_pagination: Optional[bool] = Field(None, alias="supportsPagination")
239
+ category: str
240
+ request_timeout: int = Field(alias="requestTimeout")
241
+
242
+
243
+ # Update forward references
244
+ ToolParameter.model_rebuild()
245
+ CreateToolResponse.model_rebuild()
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: airia
3
- Version: 0.1.26
3
+ Version: 0.1.28
4
4
  Summary: Python SDK for Airia API
5
5
  Author-email: Airia LLC <support@airia.com>
6
6
  License: MIT