scim2-client 0.1.9__py3-none-any.whl → 0.1.11__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.
scim2_client/client.py CHANGED
@@ -176,7 +176,10 @@ class SCIMClient:
176
176
  # https://datatracker.ietf.org/doc/html/rfc7644.html#section-8.1
177
177
 
178
178
  expected_response_content_types = ("application/scim+json", "application/json")
179
- if response.headers.get("content-type") not in expected_response_content_types:
179
+ if (
180
+ response.headers.get("content-type").split(";").pop(0)
181
+ not in expected_response_content_types
182
+ ):
180
183
  raise UnexpectedContentType(source=response)
181
184
 
182
185
  # In addition to returning an HTTP response code, implementers MUST return
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: scim2-client
3
- Version: 0.1.9
3
+ Version: 0.1.11
4
4
  Summary: Pythonically build SCIM requests and parse SCIM responses
5
5
  License: MIT
6
6
  Keywords: scim,scim2,provisioning,httpx,api
@@ -20,7 +20,7 @@ Classifier: Programming Language :: Python :: 3.11
20
20
  Classifier: Programming Language :: Python :: 3.12
21
21
  Classifier: Programming Language :: Python :: Implementation :: CPython
22
22
  Requires-Dist: httpx (>=0.24.0)
23
- Requires-Dist: scim2-models (>=0.1.9,<0.2.0)
23
+ Requires-Dist: scim2-models (>=0.2.0,<0.3.0)
24
24
  Description-Content-Type: text/markdown
25
25
 
26
26
  # scim2-client
@@ -53,14 +53,14 @@ Here is an example of usage:
53
53
  ```python
54
54
  import datetime
55
55
  from httpx import Client
56
- from scim2_models import User, EnterpriseUserUser, Group, Error
56
+ from scim2_models import User, EnterpriseUser, Group, Error
57
57
  from scim2_client import SCIMClient
58
58
 
59
59
  client = Client(base_url=f"https://auth.example/scim/v2", headers={"Authorization": "Bearer foobar"})
60
60
  scim = SCIMClient(client, resource_types=(User[EnterpriseUser], Group))
61
61
 
62
62
  # Query resources
63
- user = scim.query(User, "2819c223-7f76-453a-919d-413861904646")
63
+ user = scim.query(User[EnterpriseUser], "2819c223-7f76-453a-919d-413861904646")
64
64
  assert user.user_name == "bjensen@example.com"
65
65
  assert user.meta.last_updated == datetime.datetime(
66
66
  2024, 4, 13, 12, 0, 0, tzinfo=datetime.timezone.utc
@@ -0,0 +1,6 @@
1
+ scim2_client/__init__.py,sha256=vgrTJZIqJLZc72XCJwYKrSCGUDkMZTJjCJiZkHERZGs,780
2
+ scim2_client/client.py,sha256=Hh4Cdk1fN1ugsbpIZ4PhDgRCUaJGlaJbLFGguy8myao,27174
3
+ scim2_client/errors.py,sha256=Lu_4lPlbryqWYGLPmH2iWaVmlay8S4PrH6lUPIvcisA,4430
4
+ scim2_client-0.1.11.dist-info/METADATA,sha256=dVkQERckaYa-2NAsysoA4asPRakdfyX166k58XOrj08,3498
5
+ scim2_client-0.1.11.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
6
+ scim2_client-0.1.11.dist-info/RECORD,,
@@ -1,6 +0,0 @@
1
- scim2_client/__init__.py,sha256=vgrTJZIqJLZc72XCJwYKrSCGUDkMZTJjCJiZkHERZGs,780
2
- scim2_client/client.py,sha256=f0Hgc6ghZ84FtaAHca7T7NV3OcmlaIbZCJ9xwAMPQX4,27120
3
- scim2_client/errors.py,sha256=Lu_4lPlbryqWYGLPmH2iWaVmlay8S4PrH6lUPIvcisA,4430
4
- scim2_client-0.1.9.dist-info/METADATA,sha256=WAc8T_B9rgvEe1aHSNotBBMkQWlyAws1UWhob9Ve6kE,3485
5
- scim2_client-0.1.9.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
6
- scim2_client-0.1.9.dist-info/RECORD,,