import os document.getElementById('avgResponseTime').textContent = data.avg_request_time_ms.toFixed(0) + 'ms'; document.getElementById('concurrentRequests').textContent = data.concurrent_requests; document.getElementById('requestsPerMinute').textContent = data.requests_per_minute; document.getElementById('todayRequests').textContent = data.today_requests; } } catch (error) { console.error('Error updating metrics:', error); } } function showLoading(show) { if (show) { loadingModal.classList.remove('hidden'); } else { loadingModal.classList.add('hidden'); } } function showNotification(message, type = 'info') { const notification = document.createElement('div'); notification.className = `fixed top-4 right-4 p-4 rounded-lg shadow-lg z-50 ${ type === 'error' ? 'bg-red-500' : 'bg-indigo-500' } text-white`; notification.innerHTML = `