allowly 0.3.0__tar.gz → 0.4.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.
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.4
1
+ Metadata-Version: 2.5
2
2
  Name: allowly
3
- Version: 0.3.0
3
+ Version: 0.4.0
4
4
  Summary: Python SDK for the Allowly API
5
5
  Project-URL: Repository, https://github.com/Allowly-AI/allowly-sdk-python
6
6
  License: MIT
@@ -8,7 +8,7 @@ License-File: LICENSE
8
8
  Requires-Python: >=3.10
9
9
  Requires-Dist: httpx>=0.27.0
10
10
  Provides-Extra: dev
11
- Requires-Dist: allowly-receipt-format<5.0.0,>=4.0.0; extra == 'dev'
11
+ Requires-Dist: allowly-receipt-format<5.0.0,>=4.0.1; extra == 'dev'
12
12
  Requires-Dist: cryptography>=42; extra == 'dev'
13
13
  Requires-Dist: fastmcp<3,>=2.9; extra == 'dev'
14
14
  Requires-Dist: pytest-asyncio>=0.23; extra == 'dev'
@@ -17,7 +17,7 @@ Requires-Dist: respx>=0.21; extra == 'dev'
17
17
  Provides-Extra: fastmcp
18
18
  Requires-Dist: fastmcp<3,>=2.9; extra == 'fastmcp'
19
19
  Provides-Extra: verifier
20
- Requires-Dist: allowly-receipt-format<5.0.0,>=4.0.0; extra == 'verifier'
20
+ Requires-Dist: allowly-receipt-format<5.0.0,>=4.0.1; extra == 'verifier'
21
21
  Description-Content-Type: text/markdown
22
22
 
23
23
  # Allowly Python SDK
@@ -112,7 +112,7 @@ integration examples honest and makes SDK gaps visible early.
112
112
  ## Offline receipt verification
113
113
 
114
114
  Install `allowly[verifier]` to verify signed receipts locally. The extra uses
115
- `allowly-receipt-format>=4.0.0,<5.0.0`, which verifies receipt wire format 4 (the package major equals the wire format). `alg` and
115
+ `allowly-receipt-format>=4.0.1,<5.0.0`, which verifies receipt wire format 4 (the package major equals the wire format). `alg` and
116
116
  `key_id` are signed top-level fields, and `signature` is the base64url string.
117
117
 
118
118
  Wire format 4 also supports daily `receipt.checkpoint` commitments. For an
@@ -90,7 +90,7 @@ integration examples honest and makes SDK gaps visible early.
90
90
  ## Offline receipt verification
91
91
 
92
92
  Install `allowly[verifier]` to verify signed receipts locally. The extra uses
93
- `allowly-receipt-format>=4.0.0,<5.0.0`, which verifies receipt wire format 4 (the package major equals the wire format). `alg` and
93
+ `allowly-receipt-format>=4.0.1,<5.0.0`, which verifies receipt wire format 4 (the package major equals the wire format). `alg` and
94
94
  `key_id` are signed top-level fields, and `signature` is the base64url string.
95
95
 
96
96
  Wire format 4 also supports daily `receipt.checkpoint` commitments. For an
@@ -377,15 +377,12 @@ class _AuthorizationsResource:
377
377
  authorization_id: str,
378
378
  *,
379
379
  revoked_by: str | None = None,
380
- superseded_by: str | None = None,
381
380
  notes: str | None = None,
382
381
  idempotency_key: str | None = None,
383
382
  ) -> AuthorizationRevokeResponse:
384
383
  body: dict[str, Any] = {}
385
384
  if revoked_by:
386
385
  body["revoked_by"] = revoked_by
387
- if superseded_by:
388
- body["superseded_by"] = superseded_by
389
386
  if notes:
390
387
  body["notes"] = notes
391
388
  headers = {"Idempotency-Key": idempotency_key} if idempotency_key is not None else None
@@ -35,7 +35,7 @@ def _import_verifier():
35
35
  return verify_receipt, load_keys_from_json, VerificationError, PublicKey
36
36
  except ImportError as exc:
37
37
  raise ImportError(
38
- "Receipt verification requires allowly-receipt-format>=4.0.0. "
38
+ "Receipt verification requires allowly-receipt-format>=4.0.1. "
39
39
  "Install the verifier extra: pip install 'allowly[verifier]'"
40
40
  ) from exc
41
41
 
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "allowly"
7
- version = "0.3.0"
7
+ version = "0.4.0"
8
8
  description = "Python SDK for the Allowly API"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.10"
@@ -21,10 +21,10 @@ fastmcp = [
21
21
  "fastmcp>=2.9,<3",
22
22
  ]
23
23
  verifier = [
24
- "allowly-receipt-format>=4.0.0,<5.0.0",
24
+ "allowly-receipt-format>=4.0.1,<5.0.0",
25
25
  ]
26
26
  dev = [
27
- "allowly-receipt-format>=4.0.0,<5.0.0",
27
+ "allowly-receipt-format>=4.0.1,<5.0.0",
28
28
  "cryptography>=42",
29
29
  "fastmcp>=2.9,<3",
30
30
  "pytest>=8.0",
@@ -1295,18 +1295,9 @@ async def test_authorizations_revoke_requires_revoked_confirmations(client):
1295
1295
  await client.authorizations.revoke("auth_123")
1296
1296
 
1297
1297
 
1298
- @respx.mock
1299
- @pytest.mark.asyncio
1300
- async def test_authorizations_revoke_with_superseded_by(client):
1301
- route = respx.delete(f"{BASE}/v1/authorizations/auth_123").mock(return_value=httpx.Response(200, json={
1302
- "authorization_id": "auth_123",
1303
- "revoked_at": "2026-05-01T09:00:00Z",
1304
- "receipt": PENDING_RECEIPT,
1305
- "revoked_confirmations": [],
1306
- }))
1307
- await client.authorizations.revoke("auth_123", superseded_by="auth_456")
1308
- body = json.loads(route.calls[0].request.content)
1309
- assert body["superseded_by"] == "auth_456"
1298
+ def test_authorizations_revoke_rejects_superseded_by(client):
1299
+ with pytest.raises(TypeError, match="unexpected keyword argument 'superseded_by'"):
1300
+ client.authorizations.revoke("auth_123", superseded_by="auth_456")
1310
1301
 
1311
1302
 
1312
1303
  @respx.mock
@@ -4,7 +4,7 @@ requires-python = ">=3.10"
4
4
 
5
5
  [[package]]
6
6
  name = "allowly"
7
- version = "0.3.0"
7
+ version = "0.4.0"
8
8
  source = { editable = "." }
9
9
  dependencies = [
10
10
  { name = "httpx" },
@@ -28,8 +28,8 @@ verifier = [
28
28
 
29
29
  [package.metadata]
30
30
  requires-dist = [
31
- { name = "allowly-receipt-format", marker = "extra == 'dev'", specifier = ">=4.0.0,<5.0.0" },
32
- { name = "allowly-receipt-format", marker = "extra == 'verifier'", specifier = ">=4.0.0,<5.0.0" },
31
+ { name = "allowly-receipt-format", marker = "extra == 'dev'", specifier = ">=4.0.1,<5.0.0" },
32
+ { name = "allowly-receipt-format", marker = "extra == 'verifier'", specifier = ">=4.0.1,<5.0.0" },
33
33
  { name = "cryptography", marker = "extra == 'dev'", specifier = ">=42" },
34
34
  { name = "fastmcp", marker = "extra == 'dev'", specifier = ">=2.9,<3" },
35
35
  { name = "fastmcp", marker = "extra == 'fastmcp'", specifier = ">=2.9,<3" },
@@ -42,14 +42,14 @@ provides-extras = ["fastmcp", "verifier", "dev"]
42
42
 
43
43
  [[package]]
44
44
  name = "allowly-receipt-format"
45
- version = "4.0.0"
45
+ version = "4.0.1"
46
46
  source = { registry = "https://pypi.org/simple" }
47
47
  dependencies = [
48
48
  { name = "cryptography" },
49
49
  ]
50
- sdist = { url = "https://files.pythonhosted.org/packages/86/4d/cd30ade1b597ee0ee1bdbfea33fd6f77c294999f4cc42504152690df13e2/allowly_receipt_format-4.0.0.tar.gz", hash = "sha256:27cd96a06edea1a23c340d9015ef1c0434b6dc1d4b2d7b56653d18b3991d6eec", size = 18059, upload-time = "2026-08-02T07:14:52.971Z" }
50
+ sdist = { url = "https://files.pythonhosted.org/packages/fc/f8/e3e98e0aeaa288b730047219ec3a92b60b725e1972ecdfe0ed7eac216d1f/allowly_receipt_format-4.0.1.tar.gz", hash = "sha256:952d6570bfc4b9d367157f72db4653add3284930a76fac322c0adbac46dc46ff", size = 18063, upload-time = "2026-08-04T21:55:08.179Z" }
51
51
  wheels = [
52
- { url = "https://files.pythonhosted.org/packages/60/d9/45545ccdda5810e31d907bb5d26d5c4953864425a79b94708b61fccd23fe/allowly_receipt_format-4.0.0-py3-none-any.whl", hash = "sha256:18a038b9ffe9be25c63bd2f39b1f26fffbebb89e43622de9d2b479b06ea14b93", size = 16630, upload-time = "2026-08-02T07:14:51.615Z" },
52
+ { url = "https://files.pythonhosted.org/packages/6c/41/fc6bcf26f3735dc1e985abed0ffdf42d5a8bd7cec87565c026ac03364d38/allowly_receipt_format-4.0.1-py3-none-any.whl", hash = "sha256:557cb4c9e2ceffb705626815716227fa66cc792aa33b9a289c4e9a73e53469c5", size = 16633, upload-time = "2026-08-04T21:55:07.146Z" },
53
53
  ]
54
54
 
55
55
  [[package]]
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