Convert chatbot slash commands to agents with anonymous issue reporting
Replace chatbot slash commands (/help, /stats, etc.) with an "agents" UI pattern. Add a new Report Issue agent supporting anonymous bug submission with required screenshot capture.
Changes
UI (header.html)
- Replace gray slash command buttons with colored, icon-labeled agent buttons
- Add collapsible Report Issue form with URL input, description, anonymous checkbox, and screenshot capture
- Screenshot capture uses html2canvas with SRI integrity hash
- Two screenshot capture modes:
- Full Page - captures the entire page
- Select Area - click and drag to select a specific region (ESC to cancel)
Backend (website/api/views.py)
- New
ChatbotReportIssueViewat/api/chatbot/report-issue/ - Handles base64 screenshot upload, domain lookup, and IP tracking for anonymous submissions
- URL parsing preserves path/query/fragment correctly
- Screenshot is required for issue submission
# Anonymous reporting with required screenshot
POST /api/chatbot/report-issue/
{
"url": "example.com/page",
"description": "Bug description",
"screenshot": "data:image/png;base64,...", # required
"anonymous": true
}
Agent Types
| Agent | Color | Function |
|---|---|---|
| Help | Blue | Show available agents |
| Stats | Green | Link to platform stats |
| Bid | Purple | Bidding info |
| Bacon | Yellow | Token info |
| Report Issue | Red | Open issue form |
Legacy slash commands remain functional for backward compatibility.
- Fixes OWASP-BLT/BLT#5117
Original prompt
This section details on the original issue you should resolve
<issue_title>instead of slash commands have the chat bot have "agents" and each slash command is instead an agent - also add an agent to report issues and take a screenshot of the page its on and then add that issue to BLT - allow for anonymous issue reporting</issue_title> <issue_description>
</issue_description>
Comments on the Issue (you are @copilot in this section)
- Fixes OWASP-BLT/BLT#5117
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.