Case Study

Enterprise AI Chatbot Management Dashboard

Admin platform for organizations deploying conversational AI systems. Real-time analytics, user management, compliance auditing.

Role

Frontend Engineer

Status

Production

Context

Internal, NDA

The Problem

  • ●Organizations needed visibility into chatbot performance — how many questions were handled, which ones failed, user engagement metrics.
  • ●Admin interface for user provisioning, role management, and bot access control with RBAC.
  • ●Compliance-focused activity log tracking every user and admin action — a requirement for organizations demonstrating control.

My Approach

Dashboard Analytics

Built KPI displays, trend line charts, distribution donut charts, and performance bars using Recharts.

  • • Time-period filtering (1-week, 1-month, 3-month views)
  • • Drill-down into most-asked and most-failed questions
  • • PDF export for direct report generation

User Management & RBAC

Admin interface for provisioning users, managing roles, and controlling bot access levels with detailed metrics.

  • • Search and filtering across user directory
  • • Per-user activity and engagement metrics
  • • Role-based access control configuration

Audit Trail

Compliance-focused activity log tracking every user and admin action, searchable and filterable.

State Management

Redux Toolkit with RTK Query for data fetching and caching across dashboard features.

  • • Redux Persist for cross-session state maintenance
  • • Normalized data caching
  • • Optimistic updates for instant feedback

Enterprise Authentication

Integrated Azure AD via MSAL with Microsoft Graph for user profiles, token caching, and refresh.

  • • Silent token refresh ahead of expiration
  • • Retry logic for 401 responses with state consistency
  • • No forced re-logins during extended sessions

Testing

Covered components with Vitest and React Testing Library for compliance-sensitive internal tooling.

The Hardest Challenge

The trickiest part was the authentication token refresh flow. Admin sessions needed to stay valid for extended periods without forcing re-logins, but tokens naturally expire.

  • →Tokens expire naturally mid-session
  • →Request goes out with expired token (401 response)
  • →Need to refresh and retry without duplicating mutations
  • →In-flight data must not be lost during token refresh

Technology Stack

Frontend

  • ·React 19
  • ·TypeScript
  • ·Vite
  • ·Tailwind CSS v4

State Management

  • ·Redux Toolkit
  • ·RTK Query
  • ·Redux Persist

Visualization

  • ·Recharts
  • ·Chart patterns

Authentication

  • ·MSAL (Azure AD)
  • ·Microsoft Graph

Testing

  • ·Vitest
  • ·React Testing Library

Features

  • ·PDF Export
  • ·Real-time sync
  • ·Audit logging

Outcome

✓Reliable admin sessions — Silent token refresh eliminated forced re-logins

✓Data consistency — Retry logic prevented duplicate mutations and data loss

✓Compliance ready — Audit trail met regulatory requirements

✓Analytics-driven decisions — Dashboard insights optimized chatbot performance

Key Learnings

Token refresh is a state machine
Treat authentication as explicit state transitions. Prevents race conditions and data inconsistency.

Optimistic updates for admins
Admin tools need instant feedback. Optimistic UI updates with rollback create responsive experiences.

Audit trails are features, not afterthoughts
Build audit logging into architecture from day one. Retrofitting is 3x harder and less reliable.

Admin dashboards need resilience
Admins rely on internal tools for critical operations. Network failures can't break workflows.

This project is confidential. Company name, internal URLs, and proprietary details have been withheld.