CRUD: Chatbot Configuration — Create, Update, Delete
Property: ChurchWiseAI Category: Admin Dashboard
Tier:
starter-chat
Persona: pastor-admin
Touchpoint: /admin/[token]/chatbot-settings
Preconditions
- Pastor logged into admin dashboard
- Has access to chatbot configuration section
Steps
| # | Action | Expected Result |
|---|---|---|
| 1 | Create new chatbot instance | Form allows: chatbot name, description, initial system prompt. Saves and shows in dashboard. |
| 2 | Edit chatbot system prompt | Text editor loads. Can modify personality, tone, handling rules. Changes preview in live widget. |
| 3 | Add training documents (FAQ, handbook) | File upload accepts PDF/DOC. Documents indexed and added to knowledge base. |
| 4 | Test chatbot with new config | Live test widget shows updated behavior. Can ask questions and see responses in real-time. |
| 5 | Enable/disable specific features | Toggles for: accept visitor contacts, require email, escalation rules, etc. All save and take effect immediately. |
| 6 | Update chatbot name/description | Can change at any time. Changes reflected in dashboard and any public-facing displays. |
| 7 | Delete training document | Removes document from knowledge base. Confirmation prompt prevents accidental deletion. |
| 8 | Duplicate existing config | Can clone a chatbot config to create similar one. Faster than creating from scratch. |
| 9 | Disable chatbot | Toggle off removes chatbot from website. Visitors see 'chatbot unavailable' or fallback message. |
Known Failure Modes
- System prompt edit not saving — changes lost
- File upload fails for PDF — can't add knowledge
- Live preview not updating — admin can't see changes before going live
- Deletion doesn't confirm — accidental data loss
References
- Playwright spec:
e2e/crud-chatbot.spec.ts - Code files:
Notes
Tests full CRUD workflow for chatbot configuration. Pastor needs to create, update, test, and manage chatbot behavior. System must support file uploads (PDFs, docs), live preview, and safe deletion. Configuration changes should take effect immediately (or be scheduled).