poelis-sdk 0.1.1__py3-none-any.whl → 0.1.2__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.
Potentially problematic release.
This version of poelis-sdk might be problematic. Click here for more details.
- poelis_sdk/__init__.py +24 -3
- poelis_sdk/client.py +4 -4
- {poelis_sdk-0.1.1.dist-info → poelis_sdk-0.1.2.dist-info}/METADATA +1 -1
- {poelis_sdk-0.1.1.dist-info → poelis_sdk-0.1.2.dist-info}/RECORD +6 -6
- {poelis_sdk-0.1.1.dist-info → poelis_sdk-0.1.2.dist-info}/WHEEL +0 -0
- {poelis_sdk-0.1.1.dist-info → poelis_sdk-0.1.2.dist-info}/licenses/LICENSE +0 -0
poelis_sdk/__init__.py
CHANGED
|
@@ -1,8 +1,29 @@
|
|
|
1
|
-
"""Poelis Python SDK public exports.
|
|
1
|
+
"""Poelis Python SDK public exports.
|
|
2
|
+
|
|
3
|
+
Exposes the primary client and resolves the package version from installed
|
|
4
|
+
metadata so it stays in sync with ``pyproject.toml`` without manual edits.
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from importlib import metadata
|
|
2
8
|
|
|
3
9
|
from .client import PoelisClient
|
|
4
10
|
|
|
5
|
-
|
|
6
|
-
|
|
11
|
+
__all__ = ["PoelisClient", "__version__"]
|
|
12
|
+
|
|
13
|
+
def _resolve_version() -> str:
|
|
14
|
+
"""Return installed package version or a dev fallback.
|
|
15
|
+
|
|
16
|
+
Returns:
|
|
17
|
+
str: Version string from package metadata, or ``"0.0.0-dev"`` when
|
|
18
|
+
metadata is unavailable (e.g., editable installs without built metadata).
|
|
19
|
+
"""
|
|
20
|
+
|
|
21
|
+
try:
|
|
22
|
+
return metadata.version("poelis-sdk")
|
|
23
|
+
except metadata.PackageNotFoundError:
|
|
24
|
+
return "0.0.0-dev"
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
__version__: str = _resolve_version()
|
|
7
28
|
|
|
8
29
|
|
poelis_sdk/client.py
CHANGED
|
@@ -30,7 +30,7 @@ class ClientConfig(BaseModel):
|
|
|
30
30
|
timeout_seconds: Request timeout in seconds.
|
|
31
31
|
"""
|
|
32
32
|
|
|
33
|
-
base_url: HttpUrl = Field(default="https://
|
|
33
|
+
base_url: HttpUrl = Field(default="https://poelis-be-py-753618215333.europe-west1.run.app")
|
|
34
34
|
api_key: str = Field(min_length=1)
|
|
35
35
|
org_id: str = Field(min_length=1)
|
|
36
36
|
timeout_seconds: float = 30.0
|
|
@@ -44,7 +44,7 @@ class PoelisClient:
|
|
|
44
44
|
resource accessors to unblock incremental development.
|
|
45
45
|
"""
|
|
46
46
|
|
|
47
|
-
def __init__(self, api_key: str, org_id: str, base_url: str = "https://
|
|
47
|
+
def __init__(self, api_key: str, org_id: str, base_url: str = "https://poelis-be-py-753618215333.europe-west1.run.app", timeout_seconds: float = 30.0) -> None:
|
|
48
48
|
"""Initialize the client with API endpoint and credentials.
|
|
49
49
|
|
|
50
50
|
Args:
|
|
@@ -81,12 +81,12 @@ class PoelisClient:
|
|
|
81
81
|
"""Construct a client using environment variables.
|
|
82
82
|
|
|
83
83
|
Expected variables:
|
|
84
|
-
- POELIS_BASE_URL (optional, defaults to
|
|
84
|
+
- POELIS_BASE_URL (optional, defaults to managed GCP endpoint)
|
|
85
85
|
- POELIS_API_KEY
|
|
86
86
|
- POELIS_ORG_ID
|
|
87
87
|
"""
|
|
88
88
|
|
|
89
|
-
base_url = os.environ.get("POELIS_BASE_URL", "https://
|
|
89
|
+
base_url = os.environ.get("POELIS_BASE_URL", "https://poelis-be-py-753618215333.europe-west1.run.app")
|
|
90
90
|
api_key = os.environ.get("POELIS_API_KEY")
|
|
91
91
|
org_id = os.environ.get("POELIS_ORG_ID")
|
|
92
92
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
poelis_sdk/__init__.py,sha256=
|
|
1
|
+
poelis_sdk/__init__.py,sha256=QzPuy0lsmF0JEOrcnHDWsUfR_WCO1XpegwrYpSGyUVI,738
|
|
2
2
|
poelis_sdk/_transport.py,sha256=0yLpcMbZB7KUmBBG3epwbGi2NwOqt0dwMBYh-Y8o6Pc,5830
|
|
3
3
|
poelis_sdk/browser.py,sha256=zyMoNqFCvKZDV4ZSFVk2N1-HHiq80gzmkGN3uRo1CuM,12409
|
|
4
|
-
poelis_sdk/client.py,sha256=
|
|
4
|
+
poelis_sdk/client.py,sha256=Sr05go8eNpEXswWAhomQuSakE5Oai_kUsGDwHgPnnLY,3731
|
|
5
5
|
poelis_sdk/exceptions.py,sha256=qX5kpAr8ozJUOW-CNhmspWVIE-bvUZT_PUnimYuBxNY,1101
|
|
6
6
|
poelis_sdk/items.py,sha256=uFm-fu16QUOsVnlnEDF012zpgvySlN9N0SXMwIWXeOw,2183
|
|
7
7
|
poelis_sdk/models.py,sha256=zKbqHkK2xOdkqWUQlmu-BZ0Zyj8uC2d10PK69f3QUHo,470
|
|
@@ -11,7 +11,7 @@ poelis_sdk/workspaces.py,sha256=LNVt73nqdssNx42_YB_V5Qp35kEdFn9rNBYmEjpM7vk,1518
|
|
|
11
11
|
poelis_sdk/.github/workflows/sdk-ci.yml,sha256=hWO-igHeTAsxEJGCueteEQnAEi00GWXJJPa8DWgqhHM,750
|
|
12
12
|
poelis_sdk/.github/workflows/sdk-docs.yml,sha256=bS1uUxOKRMA6TWrmzzJHTokyP0Nt0aJwojcLAgLoEhs,1166
|
|
13
13
|
poelis_sdk/.github/workflows/sdk-publish-testpypi.yml,sha256=FBZcfDrtUijs6rcC8WeIimi9SfgoB8Xm5pTNtcztT44,776
|
|
14
|
-
poelis_sdk-0.1.
|
|
15
|
-
poelis_sdk-0.1.
|
|
16
|
-
poelis_sdk-0.1.
|
|
17
|
-
poelis_sdk-0.1.
|
|
14
|
+
poelis_sdk-0.1.2.dist-info/METADATA,sha256=jGVzZZFVynSO28j2FE02st7UekeGOZEGRxaJP08zu3U,3280
|
|
15
|
+
poelis_sdk-0.1.2.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
16
|
+
poelis_sdk-0.1.2.dist-info/licenses/LICENSE,sha256=EEmE_r8wk_pdXB8CWp1LG6sBOl7--hNSS2kV94cI6co,1075
|
|
17
|
+
poelis_sdk-0.1.2.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|