Enterprise-grade incident management system demonstrating OpenAI ChatKit with role-based access control and identity propagation.
This prototype showcases:
- Single Shared Agent: One incident management agent serves all departments
- Identity Propagation: User roles (IT, Ops, Finance, CSM) flow through entire tool chain
- Role-Based Access Control: Tool-level permissions based on user identity
- Embedded ChatKit UI: Custom React components with ChatKit integration
- Custom ChatKit server implementation
- Identity extraction from request headers
- Role-based tool filtering
- SQLite storage for incidents and threads
| Role | Capabilities |
|---|---|
| IT Admin | View logs, restart services, run diagnostics |
| Operations Director | Set priority, allocate resources, view business impact |
| Finance Controller | View costs, approve emergency spending, view SLA penalties |
| Customer Success Manager | View affected customers, send notifications |
- Python 3.10+
- OpenAI API key
cd backend
pip install -r requirements.txt- Copy
.envand add your OpenAI API key:
OPENAI_API_KEY=your_key_herecd backend
python main.pyServer runs on http://localhost:8000
# IT Admin request
curl -X POST http://localhost:8000/api/chat \
-H "Content-Type: application/json" \
-H "X-User-Role: IT" \
-H "X-User-Id: it-admin-001" \
-d '{"message": "What technical logs are available?"}'
# Operations Director request
curl -X POST http://localhost:8000/api/chat \
-H "Content-Type: application/json" \
-H "X-User-Role: OPS" \
-H "X-User-Id: ops-director-001" \
-d '{"message": "Set incident priority to P1"}'- FastAPI backend with ChatKit server
- Identity propagation
- Role-based tools
- React dashboard with embedded ChatKit
- Visual access matrix
- Real-time incident updates across roles