diff --git a/tests/test_sso.py b/tests/test_sso.py index 94ad6590..6bee38a1 100644 --- a/tests/test_sso.py +++ b/tests/test_sso.py @@ -28,6 +28,11 @@ def mock_profile(self): "last_name": "Demo", "connection_type": "OktaSAML", "idp_id": "00u1klkowm8EGah2H357", + "raw_attributes": { + "email": "demo@workos-okta.com", + "first_name": "WorkOS", + "last_name": "Demo", + }, } @pytest.fixture @@ -133,6 +138,11 @@ def test_get_profile_returns_expected_workosprofile_object( "connection_type": mock_profile["connection_type"], "last_name": mock_profile["last_name"], "idp_id": mock_profile["idp_id"], + "raw_attributes": { + "email": mock_profile["raw_attributes"]["email"], + "first_name": mock_profile["raw_attributes"]["first_name"], + "last_name": mock_profile["raw_attributes"]["last_name"], + }, }, "access_token": "01DY34ACQTM3B1CSX1YSZ8Z00D", } diff --git a/workos/__about__.py b/workos/__about__.py index 5b31cbfc..c28932c8 100644 --- a/workos/__about__.py +++ b/workos/__about__.py @@ -12,7 +12,7 @@ __package_url__ = "https://github.com/workos-inc/workos-python" -__version__ = "0.4.2" +__version__ = "0.5.0" __author__ = "WorkOS" diff --git a/workos/resources/sso.py b/workos/resources/sso.py index 86fc3002..a8e82129 100644 --- a/workos/resources/sso.py +++ b/workos/resources/sso.py @@ -3,7 +3,7 @@ class WorkOSProfile(WorkOSBaseResource): """Representation of a User Profile as returned by WorkOS through the SSO feature. - + Attributes: OBJECT_FIELDS (list): List of fields a WorkOSProfile is comprised of. """ @@ -15,4 +15,5 @@ class WorkOSProfile(WorkOSBaseResource): "last_name", "connection_type", "idp_id", + "raw_attributes", ]