export const OA_BASE = 'https://oa.fysxkj.com' export const IM_HTTP = 'https://oa.fysxkj.com/im' export const IM_WS = 'wss://oa.fysxkj.com/im/websocket' export const LIVEKIT_WS = 'wss://oa.fysxkj.com/livekit' export const BRAND = '风影随行通讯' export function livekitPublicUrl(raw) { const trimmed = String(raw || '').trim().replace(/\/$/, '') if (!trimmed) return LIVEKIT_WS try { const u = new URL(trimmed) if (u.port === '7880' && (u.hostname === 'oa.fysxkj.com' || u.hostname === '47.96.23.244')) { return LIVEKIT_WS } } catch (_) {} return trimmed } export function callRoomOf(a, b) { return 'call-' + [String(a), String(b)].sort().join('-') }