Injecting authenticated user attributes into Genesys Web Messaging widget via SDK

Can anyone clarify the correct sequence for injecting custom guest attributes when deploying the @genesys/web-messaging-widget SDK? I am building a custom analytics dashboard that requires correlating widget sessions with internal CRM user IDs.

I am attempting to set the userId and custom crmContext fields before the widget initializes to ensure they are attached to the underlying conversation. However, when I query the interactions/summary/query endpoint later, the custom attributes are missing from the personDetails object.

Here is the initialization payload I am constructing:

{
 "widgetId": "my-widget-id",
 "settings": {
 "customAttributes": {
 "userId": "usr_89234",
 "crmContext": "premium_segment"
 },
 "guest": {
 "name": "John Doe",
 "email": "[email protected]"
 }
 }
}

I am calling GenesysWebMessaging.init(config) with this object. The widget renders correctly, but the backend API does not persist these attributes. Is there a specific setCustomAttribute method I need to call post-initialization, or should I be using the POST /api/v2/conversations/messaging/{conversationId} endpoint to patch these details immediately after session creation? The docs are vague on the timing of attribute injection relative to the WebSocket handshake.