 try {
                // Call the join API endpoint
                const joinUrl = `/chat/join/${conversationId}`;
                console.log('Calling join API:', joinUrl);
                
                const response = await fetch(joinUrl, {
                    method: 'POST',
                    headers: {
                        'Content-Type': 'application/json',
                        'Authorization': `Bearer ${authToken}`
                    },
                    credentials: 'include'
       