docges-api-py 0.1.8__tar.gz → 0.1.9__tar.gz
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.
- {docges_api_py-0.1.8/src/docges_api_py.egg-info → docges_api_py-0.1.9}/PKG-INFO +1 -1
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/pyproject.toml +1 -1
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/src/docges_api_py/client.py +12 -11
- {docges_api_py-0.1.8 → docges_api_py-0.1.9/src/docges_api_py.egg-info}/PKG-INFO +1 -1
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/LICENSE +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/README.md +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/setup.cfg +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/src/docges_api_py/__init__.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/src/docges_api_py/models/__init__.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/src/docges_api_py/models/auth.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/src/docges_api_py/models/document.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/src/docges_api_py/models/requests.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/src/docges_api_py/models/responses.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/src/docges_api_py.egg-info/SOURCES.txt +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/src/docges_api_py.egg-info/dependency_links.txt +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/src/docges_api_py.egg-info/requires.txt +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/src/docges_api_py.egg-info/top_level.txt +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/tests/test_check_dir_struct.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/tests/test_client_auth.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/tests/test_content_methods.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/tests/test_endpoints.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/tests/test_examples.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/tests/test_get_document.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/tests/test_initial_cats.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/tests/test_models_auth.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/tests/test_models_init.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/tests/test_models_requests.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/tests/test_models_responses.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/tests/test_remaining_methods.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/tests/test_retry.py +0 -0
- {docges_api_py-0.1.8 → docges_api_py-0.1.9}/tests/test_token_refresh.py +0 -0
|
@@ -81,10 +81,10 @@ class AsyncDocGes:
|
|
|
81
81
|
# token_ttl kept for backward-compat signature but unused (session-based now)
|
|
82
82
|
token_ttl: int = 3600,
|
|
83
83
|
) -> None:
|
|
84
|
-
self.
|
|
85
|
-
self.
|
|
86
|
-
self.
|
|
87
|
-
self.
|
|
84
|
+
self._base_url = base_url.rstrip("/")
|
|
85
|
+
self._user = user
|
|
86
|
+
self._pwd = pwd
|
|
87
|
+
self._appid = appid
|
|
88
88
|
|
|
89
89
|
self.timeout = timeout
|
|
90
90
|
self.intents = intents
|
|
@@ -100,7 +100,7 @@ class AsyncDocGes:
|
|
|
100
100
|
async def _get_client(self) -> httpx.AsyncClient:
|
|
101
101
|
if self._client is None:
|
|
102
102
|
self._client = httpx.AsyncClient(
|
|
103
|
-
base_url=self.
|
|
103
|
+
base_url=self._base_url,
|
|
104
104
|
timeout=self.timeout,
|
|
105
105
|
headers={"Content-Type": "application/json"},
|
|
106
106
|
)
|
|
@@ -125,9 +125,9 @@ class AsyncDocGes:
|
|
|
125
125
|
async def auth(self) -> AuthResponse:
|
|
126
126
|
"""Authenticate against /Auth/Login and store the session loginResponse dict."""
|
|
127
127
|
payload = AuthRequest(
|
|
128
|
-
username=self.
|
|
129
|
-
password=self.
|
|
130
|
-
appID=self.
|
|
128
|
+
username=self._user,
|
|
129
|
+
password=self._pwd,
|
|
130
|
+
appID=self._appid,
|
|
131
131
|
)
|
|
132
132
|
|
|
133
133
|
try:
|
|
@@ -200,10 +200,11 @@ class AsyncDocGes:
|
|
|
200
200
|
# Include original login request data (loginDocGesData) so bridge can reconstruct
|
|
201
201
|
# the DocGesLoginModel (some bridges expect this field).
|
|
202
202
|
request_model["loginDocGesData"] = {
|
|
203
|
-
"username": self.
|
|
204
|
-
"password": self.
|
|
205
|
-
"appID": self.
|
|
203
|
+
"username": self._user,
|
|
204
|
+
"password": self._pwd,
|
|
205
|
+
"appID": self._appid,
|
|
206
206
|
}
|
|
207
|
+
|
|
207
208
|
if self._login_response is not None:
|
|
208
209
|
request_model["loginResponse"] = self._login_response
|
|
209
210
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|