quantumapi 0.2.0b0__tar.gz → 0.20.0__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.
- {quantumapi-0.2.0b0/quantumapi.egg-info → quantumapi-0.20.0}/PKG-INFO +5 -5
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/README.md +1 -1
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/pyproject.toml +4 -4
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/client/keys.py +41 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/client/secrets.py +19 -3
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/models/__init__.py +2 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/models/applications.py +15 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/models/keys.py +33 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0/quantumapi.egg-info}/PKG-INFO +5 -5
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/LICENSE +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/__init__.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/client/__init__.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/client/applications.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/client/async_client.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/client/base.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/client/encryption.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/client/end_users.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/client/health.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/client/resource_groups.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/client/roles.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/client/sync_client.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/errors/__init__.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/errors/exceptions.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/models/encryption.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/models/end_users.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/models/health.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/models/resource_groups.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/models/roles.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/models/secrets.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi/py.typed +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi.egg-info/SOURCES.txt +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi.egg-info/dependency_links.txt +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi.egg-info/requires.txt +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/quantumapi.egg-info/top_level.txt +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/setup.cfg +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/tests/test_exceptions.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/tests/test_models.py +0 -0
- {quantumapi-0.2.0b0 → quantumapi-0.20.0}/tests/test_parity.py +0 -0
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: quantumapi
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.20.0
|
|
4
4
|
Summary: Official Python SDK for QuantumAPI - Quantum-safe encryption and identity platform
|
|
5
5
|
Author-email: QuantumAPI Team <developers@quantumapi.eu>
|
|
6
6
|
License-Expression: MIT
|
|
7
7
|
Project-URL: Homepage, https://quantumapi.eu
|
|
8
8
|
Project-URL: Documentation, https://docs.quantumapi.eu/sdk/python
|
|
9
|
-
Project-URL: Repository, https://github.com/victorZKov/
|
|
10
|
-
Project-URL: Bug Tracker, https://github.com/victorZKov/
|
|
11
|
-
Project-URL: Changelog, https://github.com/victorZKov/
|
|
9
|
+
Project-URL: Repository, https://github.com/victorZKov/quantumapi
|
|
10
|
+
Project-URL: Bug Tracker, https://github.com/victorZKov/quantumapi/issues
|
|
11
|
+
Project-URL: Changelog, https://github.com/victorZKov/quantumapi/blob/main/src/sdk/python-quantumapi/CHANGELOG.md
|
|
12
12
|
Keywords: quantum,encryption,post-quantum,cryptography,security,api,sdk,ml-kem,ml-dsa,pqc
|
|
13
13
|
Classifier: Development Status :: 4 - Beta
|
|
14
14
|
Classifier: Intended Audience :: Developers
|
|
@@ -555,7 +555,7 @@ See [CHANGELOG.md](CHANGELOG.md) for a history of changes to this SDK.
|
|
|
555
555
|
|
|
556
556
|
## Security
|
|
557
557
|
|
|
558
|
-
For security concerns, please email
|
|
558
|
+
For security concerns, please email it@kovimatic.ie. Do not create public issues for security vulnerabilities.
|
|
559
559
|
|
|
560
560
|
## Links
|
|
561
561
|
|
|
@@ -514,7 +514,7 @@ See [CHANGELOG.md](CHANGELOG.md) for a history of changes to this SDK.
|
|
|
514
514
|
|
|
515
515
|
## Security
|
|
516
516
|
|
|
517
|
-
For security concerns, please email
|
|
517
|
+
For security concerns, please email it@kovimatic.ie. Do not create public issues for security vulnerabilities.
|
|
518
518
|
|
|
519
519
|
## Links
|
|
520
520
|
|
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "quantumapi"
|
|
7
|
-
version = "0.
|
|
7
|
+
version = "0.20.0"
|
|
8
8
|
description = "Official Python SDK for QuantumAPI - Quantum-safe encryption and identity platform"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.9"
|
|
@@ -60,9 +60,9 @@ dev = [
|
|
|
60
60
|
[project.urls]
|
|
61
61
|
Homepage = "https://quantumapi.eu"
|
|
62
62
|
Documentation = "https://docs.quantumapi.eu/sdk/python"
|
|
63
|
-
Repository = "https://github.com/victorZKov/
|
|
64
|
-
"Bug Tracker" = "https://github.com/victorZKov/
|
|
65
|
-
Changelog = "https://github.com/victorZKov/
|
|
63
|
+
Repository = "https://github.com/victorZKov/quantumapi"
|
|
64
|
+
"Bug Tracker" = "https://github.com/victorZKov/quantumapi/issues"
|
|
65
|
+
Changelog = "https://github.com/victorZKov/quantumapi/blob/main/src/sdk/python-quantumapi/CHANGELOG.md"
|
|
66
66
|
|
|
67
67
|
[tool.setuptools.packages.find]
|
|
68
68
|
include = ["quantumapi*"]
|
|
@@ -12,6 +12,7 @@ from quantumapi.models.keys import (
|
|
|
12
12
|
KeyListResponse,
|
|
13
13
|
KeyResponse,
|
|
14
14
|
KeyType,
|
|
15
|
+
PublicKeyResponse,
|
|
15
16
|
RotateKeyRequest,
|
|
16
17
|
UpdateKeyRequest,
|
|
17
18
|
)
|
|
@@ -288,6 +289,46 @@ class KeysClient:
|
|
|
288
289
|
)
|
|
289
290
|
return response["publicKey"]
|
|
290
291
|
|
|
292
|
+
async def get_public_key(
|
|
293
|
+
self,
|
|
294
|
+
key_id: UUID,
|
|
295
|
+
include: Optional[List[str]] = None,
|
|
296
|
+
format: Optional[str] = None,
|
|
297
|
+
) -> PublicKeyResponse:
|
|
298
|
+
"""
|
|
299
|
+
Get the public key as a full response, optionally enriched with
|
|
300
|
+
programmable metadata fields when ``include`` is provided.
|
|
301
|
+
|
|
302
|
+
Args:
|
|
303
|
+
key_id: ID of key to export.
|
|
304
|
+
include: Optional list of metadata fields to include in the
|
|
305
|
+
response (e.g. ``["name", "labels"]``). Pass ``["all"]`` or
|
|
306
|
+
``["metadata"]`` to include every supported field. Recognized
|
|
307
|
+
tokens: ``name``, ``description``, ``keyType``, ``isPostQuantum``,
|
|
308
|
+
``isActive``, ``isDefault``, ``isFavorite``, ``createdAt``,
|
|
309
|
+
``expiresAt``, ``lastRotatedAt``, ``labels``, ``state``,
|
|
310
|
+
``scheduledDeletionDate``.
|
|
311
|
+
format: Optional export format (``raw``, ``pem``, ``der``). Not
|
|
312
|
+
applicable to JWK — use a separate JWK export endpoint for that.
|
|
313
|
+
|
|
314
|
+
Returns:
|
|
315
|
+
Full :class:`PublicKeyResponse` including any requested metadata.
|
|
316
|
+
|
|
317
|
+
Example:
|
|
318
|
+
>>> resp = await client.keys.get_public_key(key_id, include=["name", "labels"])
|
|
319
|
+
>>> print(resp.public_key, resp.name, resp.labels)
|
|
320
|
+
"""
|
|
321
|
+
params: dict[str, str] = {}
|
|
322
|
+
if format:
|
|
323
|
+
params["format"] = format
|
|
324
|
+
if include:
|
|
325
|
+
params["include"] = ",".join(include)
|
|
326
|
+
response = await self._client.get(
|
|
327
|
+
f"/api/v1/keys/{key_id}/public",
|
|
328
|
+
params=params or None,
|
|
329
|
+
)
|
|
330
|
+
return PublicKeyResponse(**response)
|
|
331
|
+
|
|
291
332
|
async def check(self, key_id: UUID) -> KeyHealthReport:
|
|
292
333
|
"""
|
|
293
334
|
Check the health of a key.
|
|
@@ -136,21 +136,37 @@ class SecretsClient:
|
|
|
136
136
|
response = await self._client.get("/api/v1/secrets", params=params)
|
|
137
137
|
return SecretListResponse(**response)
|
|
138
138
|
|
|
139
|
-
async def get(
|
|
139
|
+
async def get(
|
|
140
|
+
self,
|
|
141
|
+
secret_id: UUID,
|
|
142
|
+
include: Optional[List[str]] = None,
|
|
143
|
+
) -> SecretWithValueResponse:
|
|
140
144
|
"""
|
|
141
145
|
Get secret by ID (includes value).
|
|
142
146
|
|
|
143
147
|
Args:
|
|
144
148
|
secret_id: Secret ID
|
|
149
|
+
include: Optional list of programmable metadata fields to include
|
|
150
|
+
in the response (e.g. ``["customFields", "notes", "labels"]``).
|
|
151
|
+
Pass ``["all"]`` or ``["metadata"]`` to include every supported
|
|
152
|
+
field. Recognized tokens: ``description``, ``customFields``,
|
|
153
|
+
``notes``, ``labels``, ``expiresAt``, ``folderId``, ``isActive``,
|
|
154
|
+
``isFavorite``, ``hasTotp``, ``isTravelSafe``, ``createdAt``,
|
|
155
|
+
``updatedAt``, ``createdBy``, ``updatedBy``.
|
|
145
156
|
|
|
146
157
|
Returns:
|
|
147
|
-
Secret metadata and decrypted value
|
|
158
|
+
Secret metadata and decrypted value.
|
|
148
159
|
|
|
149
160
|
Example:
|
|
150
161
|
>>> secret = await client.secrets.get(secret_id)
|
|
151
162
|
>>> print(secret.value)
|
|
163
|
+
>>> with_meta = await client.secrets.get(secret_id, include=["customFields", "notes"])
|
|
164
|
+
>>> print(with_meta.custom_fields)
|
|
152
165
|
"""
|
|
153
|
-
|
|
166
|
+
params: Dict[str, str] = {}
|
|
167
|
+
if include:
|
|
168
|
+
params["include"] = ",".join(include)
|
|
169
|
+
response = await self._client.get(f"/api/v1/secrets/{secret_id}", params=params or None)
|
|
154
170
|
return SecretWithValueResponse(**response)
|
|
155
171
|
|
|
156
172
|
async def update(
|
|
@@ -36,6 +36,7 @@ from quantumapi.models.keys import (
|
|
|
36
36
|
KeyResponse,
|
|
37
37
|
KeyStatus,
|
|
38
38
|
KeyType,
|
|
39
|
+
PublicKeyResponse,
|
|
39
40
|
RotateKeyRequest,
|
|
40
41
|
UpdateKeyRequest,
|
|
41
42
|
)
|
|
@@ -100,6 +101,7 @@ __all__ = [
|
|
|
100
101
|
"KeyResponse",
|
|
101
102
|
"KeyListResponse",
|
|
102
103
|
"KeyHealthReport",
|
|
104
|
+
"PublicKeyResponse",
|
|
103
105
|
# Secrets
|
|
104
106
|
"CreateSecretRequest",
|
|
105
107
|
"UpdateSecretRequest",
|
|
@@ -42,6 +42,10 @@ class Application(BaseModel):
|
|
|
42
42
|
default_factory=list, alias="postLogoutRedirectUris", description="Post-logout redirect URIs"
|
|
43
43
|
)
|
|
44
44
|
allowed_scopes: List[str] = Field(default_factory=list, alias="allowedScopes", description="Allowed OAuth2 scopes")
|
|
45
|
+
resources: List[str] = Field(
|
|
46
|
+
default_factory=list,
|
|
47
|
+
description="RFC 8707 resource indicators declared on the application",
|
|
48
|
+
)
|
|
45
49
|
custom_domain: Optional[str] = Field(default=None, alias="customDomain", description="Custom domain")
|
|
46
50
|
custom_domain_verified: bool = Field(default=False, alias="customDomainVerified", description="Custom domain verified")
|
|
47
51
|
created_at: datetime = Field(..., alias="createdAt", description="Creation timestamp")
|
|
@@ -84,6 +88,10 @@ class CreateApplicationRequest(BaseModel):
|
|
|
84
88
|
allowed_scopes: Optional[List[str]] = Field(
|
|
85
89
|
default=None, alias="allowedScopes", description="Allowed OAuth2 scopes"
|
|
86
90
|
)
|
|
91
|
+
resources: Optional[List[str]] = Field(
|
|
92
|
+
default=None,
|
|
93
|
+
description="RFC 8707 resource indicators (absolute URIs) the app may request at /connect/authorize",
|
|
94
|
+
)
|
|
87
95
|
|
|
88
96
|
model_config = {"populate_by_name": True}
|
|
89
97
|
|
|
@@ -101,5 +109,12 @@ class UpdateApplicationRequest(BaseModel):
|
|
|
101
109
|
allowed_scopes: Optional[List[str]] = Field(
|
|
102
110
|
default=None, alias="allowedScopes", description="Allowed OAuth2 scopes"
|
|
103
111
|
)
|
|
112
|
+
resources: Optional[List[str]] = Field(
|
|
113
|
+
default=None,
|
|
114
|
+
description=(
|
|
115
|
+
"RFC 8707 resource indicators. None = leave the existing list intact; "
|
|
116
|
+
"[] clears all entries; a populated list replaces the current set."
|
|
117
|
+
),
|
|
118
|
+
)
|
|
104
119
|
|
|
105
120
|
model_config = {"populate_by_name": True}
|
|
@@ -111,6 +111,39 @@ class UpdateKeyRequest(BaseModel):
|
|
|
111
111
|
status: Optional[str] = Field(default=None, description="New status (active|disabled)")
|
|
112
112
|
|
|
113
113
|
|
|
114
|
+
class PublicKeyResponse(BaseModel):
|
|
115
|
+
"""Response model containing the exported public key.
|
|
116
|
+
|
|
117
|
+
Programmable metadata fields are populated only when requested via
|
|
118
|
+
``?include=`` on ``GET /api/v1/keys/{id}/public``.
|
|
119
|
+
"""
|
|
120
|
+
|
|
121
|
+
key_id: UUID = Field(..., alias="keyId", description="Key ID")
|
|
122
|
+
algorithm: str = Field(..., description="Algorithm of the key")
|
|
123
|
+
version: int = Field(..., description="Version of the key")
|
|
124
|
+
public_key: str = Field(..., alias="publicKey", description="Encoded public key")
|
|
125
|
+
format: str = Field(..., description="Format of the public key (raw, pem, der)")
|
|
126
|
+
|
|
127
|
+
# Opt-in metadata (populated when requested via ?include=)
|
|
128
|
+
name: Optional[str] = Field(default=None)
|
|
129
|
+
description: Optional[str] = Field(default=None)
|
|
130
|
+
key_type: Optional[KeyType] = Field(default=None, alias="keyType")
|
|
131
|
+
is_post_quantum: Optional[bool] = Field(default=None, alias="isPostQuantum")
|
|
132
|
+
is_active: Optional[bool] = Field(default=None, alias="isActive")
|
|
133
|
+
is_default: Optional[bool] = Field(default=None, alias="isDefault")
|
|
134
|
+
is_favorite: Optional[bool] = Field(default=None, alias="isFavorite")
|
|
135
|
+
created_at: Optional[datetime] = Field(default=None, alias="createdAt")
|
|
136
|
+
expires_at: Optional[datetime] = Field(default=None, alias="expiresAt")
|
|
137
|
+
last_rotated_at: Optional[datetime] = Field(default=None, alias="lastRotatedAt")
|
|
138
|
+
labels: Optional[List[str]] = Field(default=None)
|
|
139
|
+
state: Optional[str] = Field(default=None)
|
|
140
|
+
scheduled_deletion_date: Optional[datetime] = Field(
|
|
141
|
+
default=None, alias="scheduledDeletionDate"
|
|
142
|
+
)
|
|
143
|
+
|
|
144
|
+
model_config = {"populate_by_name": True}
|
|
145
|
+
|
|
146
|
+
|
|
114
147
|
class KeyHealthReport(BaseModel):
|
|
115
148
|
"""Result of a client-side key health check."""
|
|
116
149
|
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: quantumapi
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.20.0
|
|
4
4
|
Summary: Official Python SDK for QuantumAPI - Quantum-safe encryption and identity platform
|
|
5
5
|
Author-email: QuantumAPI Team <developers@quantumapi.eu>
|
|
6
6
|
License-Expression: MIT
|
|
7
7
|
Project-URL: Homepage, https://quantumapi.eu
|
|
8
8
|
Project-URL: Documentation, https://docs.quantumapi.eu/sdk/python
|
|
9
|
-
Project-URL: Repository, https://github.com/victorZKov/
|
|
10
|
-
Project-URL: Bug Tracker, https://github.com/victorZKov/
|
|
11
|
-
Project-URL: Changelog, https://github.com/victorZKov/
|
|
9
|
+
Project-URL: Repository, https://github.com/victorZKov/quantumapi
|
|
10
|
+
Project-URL: Bug Tracker, https://github.com/victorZKov/quantumapi/issues
|
|
11
|
+
Project-URL: Changelog, https://github.com/victorZKov/quantumapi/blob/main/src/sdk/python-quantumapi/CHANGELOG.md
|
|
12
12
|
Keywords: quantum,encryption,post-quantum,cryptography,security,api,sdk,ml-kem,ml-dsa,pqc
|
|
13
13
|
Classifier: Development Status :: 4 - Beta
|
|
14
14
|
Classifier: Intended Audience :: Developers
|
|
@@ -555,7 +555,7 @@ See [CHANGELOG.md](CHANGELOG.md) for a history of changes to this SDK.
|
|
|
555
555
|
|
|
556
556
|
## Security
|
|
557
557
|
|
|
558
|
-
For security concerns, please email
|
|
558
|
+
For security concerns, please email it@kovimatic.ie. Do not create public issues for security vulnerabilities.
|
|
559
559
|
|
|
560
560
|
## Links
|
|
561
561
|
|
|
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
|
|
File without changes
|
|
File without changes
|