How jayashree-011/chatmate-springai-chatbot works
ChatMate is a full-stack chatbot: users compose messages in a React interface, which sends the current message and conversation history to a Spring Boot API; the API obtains a Gemini reply for display. Conversation history and sidebar actions remain in browser memory, while the backend does not store conversations. The frontend request/response path is visible in excerpts, and the README documents the API contract and Gemini integration. Backend implementation details were not sampled, so internal backend call relationships are left unasserted.
Main entry points: chatApi.ts Chat API client · ChatController.java Chat endpoint · App.tsx Conversation UI · main.tsx React bootstrap
Components 9
Chat interface
- Conversation UI
chatmate-frontend/src/App.tsx - React bootstrap
chatmate-frontend/src/main.tsx - Chat API client
chatmate-frontend/src/services/chatApi.ts - Chat contracts
chatmate-frontend/src/types.ts
Chat API
- Chat endpoint
chatmate-backend/src/main/java/com/example/chatmate/controller/ChatController.java - Chat service
chatmate-backend/src/main/java/com/example/chatmate/service/ChatService.java - API messages
chatmate-backend/src/main/java/com/example/chatmate/dto
AI provider
- Gemini 2.5 Flash
Other components
- Chat user
Connections 9
- Chat user → Conversation UI: submits messages
chatmate-frontend/src/App.tsx - React bootstrap → Conversation UI: renders
chatmate-frontend/src/main.tsx - Conversation UI → Chat API client: sends turns
chatmate-frontend/src/App.tsx - Chat API client → Chat contracts: uses types
chatmate-frontend/src/services/chatApi.ts - Chat API client → Chat endpoint: posts message
README.md - Chat endpoint → API messages: accepts and returns
- Chat endpoint → Chat service: delegates to
- Chat endpoint → Gemini 2.5 Flash: requests AI reply
README.md - Chat API client → Conversation UI: returns reply
chatmate-frontend/src/App.tsx