Handle POST requests for chat and indexing.
(self)
| 122 | self.end_headers() |
| 123 | |
| 124 | def do_POST(self): |
| 125 | """Handle POST requests for chat and indexing.""" |
| 126 | parsed_path = urlparse(self.path) |
| 127 | |
| 128 | if parsed_path.path == '/chat': |
| 129 | self.handle_chat() |
| 130 | elif parsed_path.path == '/chat/stream': |
| 131 | self.handle_chat_stream() |
| 132 | elif parsed_path.path == '/index': |
| 133 | self.handle_index() |
| 134 | else: |
| 135 | self.send_json_response({"error": "Not Found"}, status_code=404) |
| 136 | |
| 137 | def do_GET(self): |
| 138 | parsed_path = urlparse(self.path) |
nothing calls this directly
no test coverage detected