-
Notifications
You must be signed in to change notification settings - Fork 40
Description
When retrieving an instance of RequestState via the authenticate_request() method, the organization information is visible in the payload variable but the to_auth() method does not include this in the returned AuthObject instance for the v2 API (which returns a SessionAuthObjectV2 instance). The expected "o" variable or organization claim is missing, which means the active organisation cannot be determined (although it can be retrieved from the payload but via dictionary keys, which is not desirable as it places the onus on developers to maintain this as opposed to relying on the SDK's mapping). Critically, this is necessary to determine which organization is active, as whilst the SDK can query Clerk to find all organizations for a given user, this does not provide any active information.