qanswer_sdk 3.1209.0__py3-none-any.whl → 3.1210.0__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.
- qanswer_sdk/__init__.py +1 -1
- qanswer_sdk/api_client.py +1 -1
- qanswer_sdk/configuration.py +1 -1
- qanswer_sdk/models/page_organization.py +6 -6
- qanswer_sdk/models/page_team_with_count.py +6 -6
- qanswer_sdk/models/pageable_object.py +8 -8
- qanswer_sdk/models/sort_object.py +4 -4
- qanswer_sdk-3.1210.0.dist-info/METADATA +266 -0
- {qanswer_sdk-3.1209.0.dist-info → qanswer_sdk-3.1210.0.dist-info}/RECORD +10 -10
- qanswer_sdk-3.1209.0.dist-info/METADATA +0 -125
- {qanswer_sdk-3.1209.0.dist-info → qanswer_sdk-3.1210.0.dist-info}/WHEEL +0 -0
qanswer_sdk/__init__.py
CHANGED
qanswer_sdk/api_client.py
CHANGED
@@ -90,7 +90,7 @@ class ApiClient:
|
|
90
90
|
self.default_headers[header_name] = header_value
|
91
91
|
self.cookie = cookie
|
92
92
|
# Set default User-Agent.
|
93
|
-
self.user_agent = 'OpenAPI-Generator/3.
|
93
|
+
self.user_agent = 'OpenAPI-Generator/3.1210.0/python'
|
94
94
|
self.client_side_validation = configuration.client_side_validation
|
95
95
|
|
96
96
|
def __enter__(self):
|
qanswer_sdk/configuration.py
CHANGED
@@ -421,7 +421,7 @@ conf = qanswer_sdk.Configuration(
|
|
421
421
|
"OS: {env}\n"\
|
422
422
|
"Python Version: {pyversion}\n"\
|
423
423
|
"Version of the API: 1.0\n"\
|
424
|
-
"SDK Package Version: 3.
|
424
|
+
"SDK Package Version: 3.1210.0".\
|
425
425
|
format(env=sys.platform, pyversion=sys.version)
|
426
426
|
|
427
427
|
def get_host_settings(self):
|
@@ -31,8 +31,8 @@ class PageOrganization(BaseModel):
|
|
31
31
|
""" # noqa: E501
|
32
32
|
total_pages: Optional[StrictInt] = Field(default=None, alias="totalPages")
|
33
33
|
total_elements: Optional[StrictInt] = Field(default=None, alias="totalElements")
|
34
|
-
pageable: Optional[PageableObject] = None
|
35
34
|
sort: Optional[SortObject] = None
|
35
|
+
pageable: Optional[PageableObject] = None
|
36
36
|
number_of_elements: Optional[StrictInt] = Field(default=None, alias="numberOfElements")
|
37
37
|
first: Optional[StrictBool] = None
|
38
38
|
last: Optional[StrictBool] = None
|
@@ -40,7 +40,7 @@ class PageOrganization(BaseModel):
|
|
40
40
|
content: Optional[List[Organization]] = None
|
41
41
|
number: Optional[StrictInt] = None
|
42
42
|
empty: Optional[StrictBool] = None
|
43
|
-
__properties: ClassVar[List[str]] = ["totalPages", "totalElements", "
|
43
|
+
__properties: ClassVar[List[str]] = ["totalPages", "totalElements", "sort", "pageable", "numberOfElements", "first", "last", "size", "content", "number", "empty"]
|
44
44
|
|
45
45
|
model_config = ConfigDict(
|
46
46
|
populate_by_name=True,
|
@@ -81,12 +81,12 @@ class PageOrganization(BaseModel):
|
|
81
81
|
exclude=excluded_fields,
|
82
82
|
exclude_none=True,
|
83
83
|
)
|
84
|
-
# override the default output from pydantic by calling `to_dict()` of pageable
|
85
|
-
if self.pageable:
|
86
|
-
_dict['pageable'] = self.pageable.to_dict()
|
87
84
|
# override the default output from pydantic by calling `to_dict()` of sort
|
88
85
|
if self.sort:
|
89
86
|
_dict['sort'] = self.sort.to_dict()
|
87
|
+
# override the default output from pydantic by calling `to_dict()` of pageable
|
88
|
+
if self.pageable:
|
89
|
+
_dict['pageable'] = self.pageable.to_dict()
|
90
90
|
# override the default output from pydantic by calling `to_dict()` of each item in content (list)
|
91
91
|
_items = []
|
92
92
|
if self.content:
|
@@ -108,8 +108,8 @@ class PageOrganization(BaseModel):
|
|
108
108
|
_obj = cls.model_validate({
|
109
109
|
"totalPages": obj.get("totalPages"),
|
110
110
|
"totalElements": obj.get("totalElements"),
|
111
|
-
"pageable": PageableObject.from_dict(obj["pageable"]) if obj.get("pageable") is not None else None,
|
112
111
|
"sort": SortObject.from_dict(obj["sort"]) if obj.get("sort") is not None else None,
|
112
|
+
"pageable": PageableObject.from_dict(obj["pageable"]) if obj.get("pageable") is not None else None,
|
113
113
|
"numberOfElements": obj.get("numberOfElements"),
|
114
114
|
"first": obj.get("first"),
|
115
115
|
"last": obj.get("last"),
|
@@ -31,8 +31,8 @@ class PageTeamWithCount(BaseModel):
|
|
31
31
|
""" # noqa: E501
|
32
32
|
total_pages: Optional[StrictInt] = Field(default=None, alias="totalPages")
|
33
33
|
total_elements: Optional[StrictInt] = Field(default=None, alias="totalElements")
|
34
|
-
pageable: Optional[PageableObject] = None
|
35
34
|
sort: Optional[SortObject] = None
|
35
|
+
pageable: Optional[PageableObject] = None
|
36
36
|
number_of_elements: Optional[StrictInt] = Field(default=None, alias="numberOfElements")
|
37
37
|
first: Optional[StrictBool] = None
|
38
38
|
last: Optional[StrictBool] = None
|
@@ -40,7 +40,7 @@ class PageTeamWithCount(BaseModel):
|
|
40
40
|
content: Optional[List[TeamWithCount]] = None
|
41
41
|
number: Optional[StrictInt] = None
|
42
42
|
empty: Optional[StrictBool] = None
|
43
|
-
__properties: ClassVar[List[str]] = ["totalPages", "totalElements", "
|
43
|
+
__properties: ClassVar[List[str]] = ["totalPages", "totalElements", "sort", "pageable", "numberOfElements", "first", "last", "size", "content", "number", "empty"]
|
44
44
|
|
45
45
|
model_config = ConfigDict(
|
46
46
|
populate_by_name=True,
|
@@ -81,12 +81,12 @@ class PageTeamWithCount(BaseModel):
|
|
81
81
|
exclude=excluded_fields,
|
82
82
|
exclude_none=True,
|
83
83
|
)
|
84
|
-
# override the default output from pydantic by calling `to_dict()` of pageable
|
85
|
-
if self.pageable:
|
86
|
-
_dict['pageable'] = self.pageable.to_dict()
|
87
84
|
# override the default output from pydantic by calling `to_dict()` of sort
|
88
85
|
if self.sort:
|
89
86
|
_dict['sort'] = self.sort.to_dict()
|
87
|
+
# override the default output from pydantic by calling `to_dict()` of pageable
|
88
|
+
if self.pageable:
|
89
|
+
_dict['pageable'] = self.pageable.to_dict()
|
90
90
|
# override the default output from pydantic by calling `to_dict()` of each item in content (list)
|
91
91
|
_items = []
|
92
92
|
if self.content:
|
@@ -108,8 +108,8 @@ class PageTeamWithCount(BaseModel):
|
|
108
108
|
_obj = cls.model_validate({
|
109
109
|
"totalPages": obj.get("totalPages"),
|
110
110
|
"totalElements": obj.get("totalElements"),
|
111
|
-
"pageable": PageableObject.from_dict(obj["pageable"]) if obj.get("pageable") is not None else None,
|
112
111
|
"sort": SortObject.from_dict(obj["sort"]) if obj.get("sort") is not None else None,
|
112
|
+
"pageable": PageableObject.from_dict(obj["pageable"]) if obj.get("pageable") is not None else None,
|
113
113
|
"numberOfElements": obj.get("numberOfElements"),
|
114
114
|
"first": obj.get("first"),
|
115
115
|
"last": obj.get("last"),
|
@@ -27,13 +27,13 @@ class PageableObject(BaseModel):
|
|
27
27
|
"""
|
28
28
|
PageableObject
|
29
29
|
""" # noqa: E501
|
30
|
-
paged: Optional[StrictBool] = None
|
31
|
-
page_number: Optional[StrictInt] = Field(default=None, alias="pageNumber")
|
32
30
|
page_size: Optional[StrictInt] = Field(default=None, alias="pageSize")
|
33
|
-
sort: Optional[SortObject] = None
|
34
31
|
unpaged: Optional[StrictBool] = None
|
32
|
+
sort: Optional[SortObject] = None
|
35
33
|
offset: Optional[StrictInt] = None
|
36
|
-
|
34
|
+
paged: Optional[StrictBool] = None
|
35
|
+
page_number: Optional[StrictInt] = Field(default=None, alias="pageNumber")
|
36
|
+
__properties: ClassVar[List[str]] = ["pageSize", "unpaged", "sort", "offset", "paged", "pageNumber"]
|
37
37
|
|
38
38
|
model_config = ConfigDict(
|
39
39
|
populate_by_name=True,
|
@@ -89,12 +89,12 @@ class PageableObject(BaseModel):
|
|
89
89
|
return cls.model_validate(obj)
|
90
90
|
|
91
91
|
_obj = cls.model_validate({
|
92
|
-
"paged": obj.get("paged"),
|
93
|
-
"pageNumber": obj.get("pageNumber"),
|
94
92
|
"pageSize": obj.get("pageSize"),
|
95
|
-
"sort": SortObject.from_dict(obj["sort"]) if obj.get("sort") is not None else None,
|
96
93
|
"unpaged": obj.get("unpaged"),
|
97
|
-
"
|
94
|
+
"sort": SortObject.from_dict(obj["sort"]) if obj.get("sort") is not None else None,
|
95
|
+
"offset": obj.get("offset"),
|
96
|
+
"paged": obj.get("paged"),
|
97
|
+
"pageNumber": obj.get("pageNumber")
|
98
98
|
})
|
99
99
|
return _obj
|
100
100
|
|
@@ -26,10 +26,10 @@ class SortObject(BaseModel):
|
|
26
26
|
"""
|
27
27
|
SortObject
|
28
28
|
""" # noqa: E501
|
29
|
-
sorted: Optional[StrictBool] = None
|
30
29
|
unsorted: Optional[StrictBool] = None
|
31
30
|
empty: Optional[StrictBool] = None
|
32
|
-
|
31
|
+
sorted: Optional[StrictBool] = None
|
32
|
+
__properties: ClassVar[List[str]] = ["unsorted", "empty", "sorted"]
|
33
33
|
|
34
34
|
model_config = ConfigDict(
|
35
35
|
populate_by_name=True,
|
@@ -82,9 +82,9 @@ class SortObject(BaseModel):
|
|
82
82
|
return cls.model_validate(obj)
|
83
83
|
|
84
84
|
_obj = cls.model_validate({
|
85
|
-
"sorted": obj.get("sorted"),
|
86
85
|
"unsorted": obj.get("unsorted"),
|
87
|
-
"empty": obj.get("empty")
|
86
|
+
"empty": obj.get("empty"),
|
87
|
+
"sorted": obj.get("sorted")
|
88
88
|
})
|
89
89
|
return _obj
|
90
90
|
|
@@ -0,0 +1,266 @@
|
|
1
|
+
Metadata-Version: 2.1
|
2
|
+
Name: qanswer_sdk
|
3
|
+
Version: 3.1210.0
|
4
|
+
Summary: QAnswer: Api Documentation
|
5
|
+
Home-page: https://github.com/GIT_USER_ID/GIT_REPO_ID
|
6
|
+
License: NoLicense
|
7
|
+
Keywords: OpenAPI,OpenAPI-Generator,QAnswer: Api Documentation
|
8
|
+
Author: OpenAPI Generator Community
|
9
|
+
Author-email: team@openapitools.org
|
10
|
+
Requires-Python: >=3.8,<4.0
|
11
|
+
Classifier: License :: Other/Proprietary License
|
12
|
+
Classifier: Programming Language :: Python :: 3
|
13
|
+
Classifier: Programming Language :: Python :: 3.8
|
14
|
+
Classifier: Programming Language :: Python :: 3.9
|
15
|
+
Classifier: Programming Language :: Python :: 3.10
|
16
|
+
Classifier: Programming Language :: Python :: 3.11
|
17
|
+
Classifier: Programming Language :: Python :: 3.12
|
18
|
+
Requires-Dist: pydantic (>=2)
|
19
|
+
Requires-Dist: python-dateutil (>=2.8.2)
|
20
|
+
Requires-Dist: typing-extensions (>=4.7.1)
|
21
|
+
Requires-Dist: urllib3 (>=1.25.3,<3.0.0)
|
22
|
+
Project-URL: Repository, https://github.com/GIT_USER_ID/GIT_REPO_ID
|
23
|
+
Description-Content-Type: text/markdown
|
24
|
+
|
25
|
+
# QAnswer Python SDK
|
26
|
+
|
27
|
+
[](https://pypi.org/project/qanswer-sdk/)
|
28
|
+
[](https://pypi.org/project/qanswer-sdk/)
|
29
|
+
[](LICENSE)
|
30
|
+
|
31
|
+
Official **Python SDK** for the [QAnswer API](https://qanswer.eu), automatically generated from the OpenAPI specification.
|
32
|
+
|
33
|
+
This SDK allows Python applications to interact with QAnswer's services programmatically without needing to craft raw HTTP requests.
|
34
|
+
|
35
|
+
---
|
36
|
+
|
37
|
+
## 🚀 Features
|
38
|
+
|
39
|
+
- Full coverage of QAnswer API endpoints
|
40
|
+
- Type-safe models via [Pydantic](https://docs.pydantic.dev)
|
41
|
+
- Easy configuration of authentication and base URL
|
42
|
+
- Auto-generated and versioned with each API release
|
43
|
+
|
44
|
+
---
|
45
|
+
|
46
|
+
## 📦 Installation
|
47
|
+
|
48
|
+
You can install from [PyPI](https://pypi.org/project/qanswer-sdk/):
|
49
|
+
|
50
|
+
```bash
|
51
|
+
pip install qanswer-sdk
|
52
|
+
```
|
53
|
+
|
54
|
+
|
55
|
+
Or add it to your `requirements.txt`
|
56
|
+
|
57
|
+
```txt
|
58
|
+
qanswer-sdk==3.1184.0
|
59
|
+
```
|
60
|
+
|
61
|
+
---
|
62
|
+
|
63
|
+
## 🔑 Authentication
|
64
|
+
|
65
|
+
Most endpoints require authentication. You can configure authentication in several ways:
|
66
|
+
|
67
|
+
### API Key Authentication
|
68
|
+
|
69
|
+
```python
|
70
|
+
from qanswer_sdk import Configuration, ApiClient
|
71
|
+
from qanswer_sdk.api.chatbot_api import ChatbotApi
|
72
|
+
|
73
|
+
# Configure API key authorization
|
74
|
+
config = Configuration(
|
75
|
+
host="https://api.qanswer.eu",
|
76
|
+
api_key={"QAnswer-Api-Key": "your-api-key-here"}
|
77
|
+
)
|
78
|
+
|
79
|
+
# Initialize client
|
80
|
+
with ApiClient(config) as client:
|
81
|
+
api = ChatbotApi(client)
|
82
|
+
# Use the API...
|
83
|
+
```
|
84
|
+
|
85
|
+
### Bearer Token Authentication
|
86
|
+
|
87
|
+
```python
|
88
|
+
from qanswer_sdk import Configuration, ApiClient
|
89
|
+
from qanswer_sdk.api.chatbot_api import ChatbotApi
|
90
|
+
|
91
|
+
# Configure Bearer token authorization
|
92
|
+
config = Configuration(
|
93
|
+
host="https://api.qanswer.eu",
|
94
|
+
access_token="your-jwt-token-here"
|
95
|
+
)
|
96
|
+
|
97
|
+
# Initialize client
|
98
|
+
with ApiClient(config) as client:
|
99
|
+
api = ChatbotApi(client)
|
100
|
+
# Use the API...
|
101
|
+
```
|
102
|
+
|
103
|
+
### Basic Authentication
|
104
|
+
|
105
|
+
```python
|
106
|
+
from qanswer_sdk import Configuration, ApiClient
|
107
|
+
from qanswer_sdk.api.chatbot_api import ChatbotApi
|
108
|
+
|
109
|
+
# Configure Basic authorization
|
110
|
+
config = Configuration(
|
111
|
+
host="https://api.qanswer.eu",
|
112
|
+
username="your-username",
|
113
|
+
password="your-password"
|
114
|
+
)
|
115
|
+
|
116
|
+
# Initialize client
|
117
|
+
with ApiClient(config) as client:
|
118
|
+
api = ChatbotApi(client)
|
119
|
+
# Use the API...
|
120
|
+
```
|
121
|
+
|
122
|
+
---
|
123
|
+
|
124
|
+
## 📖 Usage Examples
|
125
|
+
|
126
|
+
### Chatbot API
|
127
|
+
|
128
|
+
```python
|
129
|
+
from qanswer_sdk import Configuration, ApiClient
|
130
|
+
from qanswer_sdk.api.chatbot_api import ChatbotApi
|
131
|
+
from qanswer_sdk.models.chatbot_chat_payload import ChatbotChatPayload
|
132
|
+
|
133
|
+
config = Configuration(
|
134
|
+
host="https://api.qanswer.eu",
|
135
|
+
api_key={"QAnswer-Api-Key": "your-api-key"}
|
136
|
+
)
|
137
|
+
|
138
|
+
with ApiClient(config) as client:
|
139
|
+
api = ChatbotApi(client)
|
140
|
+
|
141
|
+
# Create chat payload
|
142
|
+
payload = ChatbotChatPayload(
|
143
|
+
message="What is artificial intelligence?",
|
144
|
+
# Add other required fields based on your model
|
145
|
+
)
|
146
|
+
|
147
|
+
# Send chat message
|
148
|
+
response = api.free_text_chatbot_chat(payload)
|
149
|
+
print(response.answer) # Access response data
|
150
|
+
```
|
151
|
+
### Chat Completion API
|
152
|
+
|
153
|
+
```python
|
154
|
+
from qanswer_sdk.api.chat_completion_api import ChatCompletionApi
|
155
|
+
|
156
|
+
with ApiClient(config) as client:
|
157
|
+
api = ChatCompletionApi(client)
|
158
|
+
# Use chat completion endpoints...
|
159
|
+
```
|
160
|
+
|
161
|
+
### Handle Different Response Types
|
162
|
+
|
163
|
+
```python
|
164
|
+
# Get just the data
|
165
|
+
response_data = api.free_text_chatbot_chat(payload)
|
166
|
+
|
167
|
+
# Get full HTTP response info
|
168
|
+
full_response = api.free_text_chatbot_chat_with_http_info(payload)
|
169
|
+
print(full_response.status_code)
|
170
|
+
print(full_response.headers)
|
171
|
+
print(full_response.data)
|
172
|
+
|
173
|
+
# Get raw HTTP response for streaming
|
174
|
+
raw_response = api.free_text_chatbot_chat_without_preload_content(payload)
|
175
|
+
```
|
176
|
+
|
177
|
+
---
|
178
|
+
|
179
|
+
## ⚙️ Configuration Options
|
180
|
+
|
181
|
+
```python
|
182
|
+
from qanswer_sdk import Configuration
|
183
|
+
|
184
|
+
config = Configuration(
|
185
|
+
host="https://api.qanswer.eu", # API base URL
|
186
|
+
api_key={"QAnswer-Api-Key": "your-key"}, # API key auth
|
187
|
+
access_token="jwt-token", # Bearer token auth
|
188
|
+
username="user", # Basic auth username
|
189
|
+
password="pass", # Basic auth password
|
190
|
+
verify_ssl=True, # SSL verification
|
191
|
+
ssl_ca_cert="/path/to/ca.pem", # Custom CA certificate
|
192
|
+
connection_pool_maxsize=10, # Connection pool size
|
193
|
+
retries=3, # Number of retries
|
194
|
+
debug=False, # Enable debug logging
|
195
|
+
proxy="http://proxy:8080" # Proxy URL
|
196
|
+
)
|
197
|
+
```
|
198
|
+
---
|
199
|
+
|
200
|
+
## 🛠 Error Handling
|
201
|
+
|
202
|
+
```python
|
203
|
+
from qanswer_sdk.exceptions import (
|
204
|
+
ApiException,
|
205
|
+
BadRequestException,
|
206
|
+
UnauthorizedException,
|
207
|
+
NotFoundException
|
208
|
+
)
|
209
|
+
|
210
|
+
try:
|
211
|
+
response = api.free_text_chatbot_chat(payload)
|
212
|
+
except UnauthorizedException:
|
213
|
+
print("Invalid authentication credentials")
|
214
|
+
except BadRequestException as e:
|
215
|
+
print(f"Bad request: {e}")
|
216
|
+
except ApiException as e:
|
217
|
+
print(f"API error: {e.status} - {e.reason}")
|
218
|
+
```
|
219
|
+
---
|
220
|
+
|
221
|
+
## 📝 Models and Type Safety
|
222
|
+
|
223
|
+
All request and response objects are Pydantic models with full type safety:
|
224
|
+
|
225
|
+
```python
|
226
|
+
from qanswer_sdk.models.chatbot_chat_payload import ChatbotChatPayload
|
227
|
+
from qanswer_sdk.models.chatbot_response import ChatbotResponse
|
228
|
+
|
229
|
+
# Create typed request payload
|
230
|
+
payload = ChatbotChatPayload(
|
231
|
+
message="Hello",
|
232
|
+
# IDE will provide autocomplete for available fields
|
233
|
+
)
|
234
|
+
|
235
|
+
# Response is fully typed
|
236
|
+
response: ChatbotResponse = api.free_text_chatbot_chat(payload)
|
237
|
+
# Access typed response fields with autocomplete
|
238
|
+
print(response.answer)
|
239
|
+
```
|
240
|
+
|
241
|
+
---
|
242
|
+
|
243
|
+
## 📌 Versioning
|
244
|
+
|
245
|
+
This SDK follows the version of the QAnswer API.
|
246
|
+
The current version is: `3.1210.0 (branch: main)`
|
247
|
+
|
248
|
+
---
|
249
|
+
|
250
|
+
## 🤝 Support
|
251
|
+
|
252
|
+
For issues related to:
|
253
|
+
|
254
|
+
- **SDK usage:** Open an issue in this repository
|
255
|
+
- **API functionality:** Contact QAnswer support
|
256
|
+
- **Authentication:** Check your API key and permissions
|
257
|
+
|
258
|
+
---
|
259
|
+
|
260
|
+
## 📄 License
|
261
|
+
|
262
|
+
This project is licensed under the MIT License - see the LICENSE file for details.
|
263
|
+
|
264
|
+
---
|
265
|
+
|
266
|
+
## Made with ❤️ by The QA Company
|
@@ -1,4 +1,4 @@
|
|
1
|
-
qanswer_sdk/__init__.py,sha256=
|
1
|
+
qanswer_sdk/__init__.py,sha256=vlrj9r0Bbo6iK8h7AgKGnXg5aHs8fA71Rgkl9iG9FDo,25115
|
2
2
|
qanswer_sdk/api/__init__.py,sha256=Kast1nz7b747MDqgVYhf8NEOlV8lL6IeUm_fNw_JckA,2974
|
3
3
|
qanswer_sdk/api/admin_api.py,sha256=_K-7kMYZ2YCpU-GNMlUWsDFkTgDTYqEEMYXdfP5YaF8,423068
|
4
4
|
qanswer_sdk/api/ai_assistant_access_rights_api.py,sha256=_6YQ_WQdEsXKzGM2NoPrAjZs4EJWTm-jhEM6phPzUJQ,198227
|
@@ -43,9 +43,9 @@ qanswer_sdk/api/task_sparql2text_api.py,sha256=ZTmFwWNxTGi0Useie4zvZkKfYWhLci6mV
|
|
43
43
|
qanswer_sdk/api/task_text2sparql_api.py,sha256=gBK7VGdZz6MM8TRLz0wF0wrMYgJrtBvAAAtJ8uFJBCU,35540
|
44
44
|
qanswer_sdk/api/task_text_classification_api.py,sha256=oqI4-s1pN4_m5oqAlLr92i5I6ycLhkEZg454D2X7XE4,36358
|
45
45
|
qanswer_sdk/api/user_api.py,sha256=JA2j_eX9nDuRA0BnsLyXivJA8ORK5nhjxGUD8OnwG0s,269575
|
46
|
-
qanswer_sdk/api_client.py,sha256=
|
46
|
+
qanswer_sdk/api_client.py,sha256=Glwh35KmA61OquCCQEjEiVKi9DxqfrcB3ozL0VdjqGQ,27387
|
47
47
|
qanswer_sdk/api_response.py,sha256=eMxw1mpmJcoGZ3gs9z6jM4oYoZ10Gjk333s9sKxGv7s,652
|
48
|
-
qanswer_sdk/configuration.py,sha256=
|
48
|
+
qanswer_sdk/configuration.py,sha256=TN7ZTEskTyoC2NLj_VtRB10xf66dWjU1Ay1DIu7b30I,16184
|
49
49
|
qanswer_sdk/exceptions.py,sha256=BCaz7REoUyrBq8zuVBNTmEHGvJfM1YyLSyOnkB1XQLU,5907
|
50
50
|
qanswer_sdk/models/__init__.py,sha256=Eca-t0Jcyn-mZCDtG-rl3kxQmQ9ir5zPtC_HaFKOLq8,21669
|
51
51
|
qanswer_sdk/models/access_pdf_payload_model.py,sha256=0oamrJeAIZdpjmcWby_PFmz-GrXD0ObDU3ecRpf7nRI,3626
|
@@ -201,10 +201,10 @@ qanswer_sdk/models/organization.py,sha256=TFiNrBOqP2L79PCOQgufKwytMUfHChZa18fbUs
|
|
201
201
|
qanswer_sdk/models/organization_creation.py,sha256=0eXaalMljpyHSprSvPMAuBPSmHQygc8pOecybvMKXI0,2897
|
202
202
|
qanswer_sdk/models/organization_filter.py,sha256=9TD4e-Vpw0w7tISOg7BEHpkRH8wmgrvkHus78vYmsLA,2458
|
203
203
|
qanswer_sdk/models/organization_shared.py,sha256=lpWhLRUS8qK5fmrd-_jmDnvYL5SY6NNmhxJmfsMav8M,3610
|
204
|
-
qanswer_sdk/models/page_organization.py,sha256=
|
205
|
-
qanswer_sdk/models/page_team_with_count.py,sha256=
|
204
|
+
qanswer_sdk/models/page_organization.py,sha256=gwlbqqSWImcFhHerCJCajESgO6jlmBcY9jAbuXJk-9A,4604
|
205
|
+
qanswer_sdk/models/page_team_with_count.py,sha256=mRs9I81s68PatbqdJBMosaZZGrfDbsp3K1BnzzazP0U,4614
|
206
206
|
qanswer_sdk/models/pageable.py,sha256=GxN48ebyEVbgQPGrqoT0KBiKfyRymlKsCMrrf2kWRR8,2689
|
207
|
-
qanswer_sdk/models/pageable_object.py,sha256=
|
207
|
+
qanswer_sdk/models/pageable_object.py,sha256=0HjF7xonfrLWNQEAOVJ2ZdcBrbPqzZApKaRA2gsvXXo,3266
|
208
208
|
qanswer_sdk/models/password.py,sha256=PrJ3DpYh6bdLzT1lhfsmuEKr0PPkZqsU-YOr8Os4Cyk,2711
|
209
209
|
qanswer_sdk/models/pinecone_index_model.py,sha256=MKSy39jXeCTre-jDjCBthF60pHsvTBzOHmFjBCHNa6o,2592
|
210
210
|
qanswer_sdk/models/plan.py,sha256=l1To0jD1NJ6-KR0LKWVvOR9eYvYPHLFTn9K__zt6lGI,4508
|
@@ -289,7 +289,7 @@ qanswer_sdk/models/socket_report_copilot_generation_from_slots_response.py,sha25
|
|
289
289
|
qanswer_sdk/models/socket_report_copilot_refinement_response.py,sha256=0s529QVuPUYOcRuKCidkdCK9ReTz5c16VoBr_LVVEm4,3820
|
290
290
|
qanswer_sdk/models/socket_speech2_text_response.py,sha256=EYYFqcHVMkyn51FmAEiklh8miFZuK1luxyVvAO-lvP0,3377
|
291
291
|
qanswer_sdk/models/socket_stop_conversation.py,sha256=6BSqMK5hNbf56TGFUH-fwCW8B4XGM_u4ySVadcf-J4E,3264
|
292
|
-
qanswer_sdk/models/sort_object.py,sha256=
|
292
|
+
qanswer_sdk/models/sort_object.py,sha256=pTvuXE2ECPnGX-fuJRviefYi7HH4Vg_IjOkSkgEUqm4,2614
|
293
293
|
qanswer_sdk/models/source.py,sha256=Q2T38fiVcb2fv0rRZfqUa1jHcXugSbanxPSHS871gZM,6163
|
294
294
|
qanswer_sdk/models/sparql2_text_payload.py,sha256=5twWJV1efp8N22tR0Zb3Woj9csugXO2G0zNIS9NFTKU,2940
|
295
295
|
qanswer_sdk/models/speech2_text_response.py,sha256=h6BhgXOQpYYGrRh5jBtlbB1icuKrSuY4fIrl6qKwNPk,2463
|
@@ -341,6 +341,6 @@ qanswer_sdk/models/website_connector_settings.py,sha256=mlKuTG7Nsmv4XyEDUpVlg8ZO
|
|
341
341
|
qanswer_sdk/models/widget_configs.py,sha256=IpPx-mqAZzoKp18x0KAb5Qo6fLTyHYzVkc4jAcMvFUs,3540
|
342
342
|
qanswer_sdk/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
343
343
|
qanswer_sdk/rest.py,sha256=9cpA9eEQsfuHcThVnF2c7CEK0HCJYGyGZnWqmfkQpT8,9344
|
344
|
-
qanswer_sdk-3.
|
345
|
-
qanswer_sdk-3.
|
346
|
-
qanswer_sdk-3.
|
344
|
+
qanswer_sdk-3.1210.0.dist-info/METADATA,sha256=w6beTw16NstZxFchR7EnRc4xAk5XI-DCKN2AARQmE_8,6768
|
345
|
+
qanswer_sdk-3.1210.0.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
346
|
+
qanswer_sdk-3.1210.0.dist-info/RECORD,,
|
@@ -1,125 +0,0 @@
|
|
1
|
-
Metadata-Version: 2.1
|
2
|
-
Name: qanswer_sdk
|
3
|
-
Version: 3.1209.0
|
4
|
-
Summary: QAnswer: Api Documentation
|
5
|
-
Home-page: https://github.com/GIT_USER_ID/GIT_REPO_ID
|
6
|
-
License: NoLicense
|
7
|
-
Keywords: OpenAPI,OpenAPI-Generator,QAnswer: Api Documentation
|
8
|
-
Author: OpenAPI Generator Community
|
9
|
-
Author-email: team@openapitools.org
|
10
|
-
Requires-Python: >=3.8,<4.0
|
11
|
-
Classifier: License :: Other/Proprietary License
|
12
|
-
Classifier: Programming Language :: Python :: 3
|
13
|
-
Classifier: Programming Language :: Python :: 3.8
|
14
|
-
Classifier: Programming Language :: Python :: 3.9
|
15
|
-
Classifier: Programming Language :: Python :: 3.10
|
16
|
-
Classifier: Programming Language :: Python :: 3.11
|
17
|
-
Classifier: Programming Language :: Python :: 3.12
|
18
|
-
Requires-Dist: pydantic (>=2)
|
19
|
-
Requires-Dist: python-dateutil (>=2.8.2)
|
20
|
-
Requires-Dist: typing-extensions (>=4.7.1)
|
21
|
-
Requires-Dist: urllib3 (>=1.25.3,<3.0.0)
|
22
|
-
Project-URL: Repository, https://github.com/GIT_USER_ID/GIT_REPO_ID
|
23
|
-
Description-Content-Type: text/markdown
|
24
|
-
|
25
|
-
# QAnswer Python SDK
|
26
|
-
|
27
|
-
[](https://pypi.org/project/qanswer-sdk/)
|
28
|
-
[](https://pypi.org/project/qanswer-sdk/)
|
29
|
-
[](LICENSE)
|
30
|
-
|
31
|
-
Official **Python SDK** for the [QAnswer API](https://qanswer.eu), automatically generated from the OpenAPI specification.
|
32
|
-
|
33
|
-
This SDK allows Python applications to interact with QAnswer's services programmatically without needing to craft raw HTTP requests.
|
34
|
-
|
35
|
-
---
|
36
|
-
|
37
|
-
## 🚀 Features
|
38
|
-
|
39
|
-
- Full coverage of QAnswer API endpoints
|
40
|
-
- Type-safe models via [Pydantic](https://docs.pydantic.dev)
|
41
|
-
- Easy configuration of authentication and base URL
|
42
|
-
- Auto-generated and versioned with each API release
|
43
|
-
|
44
|
-
---
|
45
|
-
|
46
|
-
## 📦 Installation
|
47
|
-
|
48
|
-
You can install from [PyPI](https://pypi.org/project/qanswer-sdk/):
|
49
|
-
|
50
|
-
```bash
|
51
|
-
pip install qanswer-sdk
|
52
|
-
```
|
53
|
-
|
54
|
-
|
55
|
-
Or add it to your `requirements.txt`
|
56
|
-
|
57
|
-
```txt
|
58
|
-
qanswer-sdk==3.1184.0
|
59
|
-
```
|
60
|
-
|
61
|
-
---
|
62
|
-
|
63
|
-
## 🔑 Authentication
|
64
|
-
|
65
|
-
Most endpoints require authentication. You can set your API key like this:
|
66
|
-
```python
|
67
|
-
from qanswer_sdk import Configuration, ApiClient
|
68
|
-
from qanswer_sdk.apis import DefaultApi
|
69
|
-
|
70
|
-
# Configure API key authorization
|
71
|
-
config = Configuration(
|
72
|
-
host="https://api.qanswer.eu",
|
73
|
-
api_key={"Authorization": "Bearer <YOUR_TOKEN>"}
|
74
|
-
)
|
75
|
-
|
76
|
-
# Initialize client
|
77
|
-
with ApiClient(config) as client:
|
78
|
-
api = DefaultApi(client)
|
79
|
-
response = api.health_check()
|
80
|
-
print(response)
|
81
|
-
```
|
82
|
-
|
83
|
-
---
|
84
|
-
|
85
|
-
## 📖 Usage Examples
|
86
|
-
|
87
|
-
#### Call an endpoint
|
88
|
-
|
89
|
-
```python
|
90
|
-
from qanswer_sdk import Configuration, ApiClient
|
91
|
-
from qanswer_sdk.apis import DefaultApi
|
92
|
-
|
93
|
-
config = Configuration(host="https://api.qanswer.eu")
|
94
|
-
|
95
|
-
with ApiClient(config) as client:
|
96
|
-
api = DefaultApi(client)
|
97
|
-
result = api.ask_question(question="What is ISO 27001?")
|
98
|
-
print(result)
|
99
|
-
```
|
100
|
-
|
101
|
-
#### Handle responses
|
102
|
-
|
103
|
-
```python
|
104
|
-
print(result.answer) # direct answer
|
105
|
-
print(result.confidence) # model confidence
|
106
|
-
```
|
107
|
-
|
108
|
-
---
|
109
|
-
|
110
|
-
## ⚙️ Configuration
|
111
|
-
|
112
|
-
```python
|
113
|
-
config = Configuration(
|
114
|
-
host="https://api.qanswer.eu",
|
115
|
-
api_key={"Authorization": "Bearer <YOUR_TOKEN>"},
|
116
|
-
timeout=30
|
117
|
-
)
|
118
|
-
```
|
119
|
-
|
120
|
-
---
|
121
|
-
|
122
|
-
📌 Versioning
|
123
|
-
|
124
|
-
This SDK follows the version of the QAnswer API.
|
125
|
-
The current version is: `3.1209.0 (branch: main)`
|
File without changes
|