A feature-rich Android client for Goose AI Agent, built with Jetpack Compose.
- Local Database Persistence - Messages and sessions now persist locally with Room
- Offline Support - Queue messages when offline and retry automatically
- Message Actions - Copy, bookmark, delete messages with context menus
- Advanced Settings - Theme selection, text size, security options
- Pull-to-Refresh - Refresh conversations by pulling down
- Search - Search through sessions and messages
- Session Management - Pin, archive, rename, delete sessions
- Biometric Security - Optional fingerprint/face unlock
- Certificate Pinning - Enhanced security for API connections
- Export Data - Export chat history to JSON
- Chat Interface: Send messages and receive streaming responses from the Goose API
- Session Management: View, create, resume, pin, archive, rename chat sessions
- Settings: Configure server URL, secret key, appearance, and security
- Trial Mode: Connect to the demo server by default
- Themes: System, Light, and Dark modes
- Text Sizes: Small, Normal, Large, Extra Large
- Message Status: See pending, sending, sent, failed states
- Database Persistence: Local storage with Room for offline access
- Full-Text Search: Search through all messages
The app follows clean architecture principles:
- UI Layer: Jetpack Compose with Material 3
- ViewModel: MVVM with StateFlow for reactive state
- Data Layer: Repository pattern with Room + Retrofit/OkHttp
- Dependency Injection: Hilt for DI
- Background Work: WorkManager for offline message sync
- Security: Encrypted SharedPreferences for credentials
app/src/main/java/com/block/goose/ ├── GooseApplication.kt # Application with Hilt ├── MainActivity.kt # Navigation setup ├── di/ │ └── DatabaseModule.kt # Hilt module for Room ├── data/ │ ├── db/ │ │ ├── AppDatabase.kt # Room database │ │ ├── dao/ # Data Access Objects │ │ │ ├── SessionDao.kt │ │ │ ├── MessageDao.kt │ │ │ ├── PendingMessageDao.kt │ │ │ └── BookmarkDao.kt │ │ ├── entity/ # Room entities │ │ │ ├── SessionEntity.kt │ │ │ ├── MessageEntity.kt │ │ │ ├── PendingMessageEntity.kt │ │ │ └── BookmarkEntity.kt │ │ └── SearchFtsEntity.kt # FTS for search │ ├── api/ │ │ ├── GooseApiService.kt # API client with SSE │ │ ├── SettingsRepository.kt # DataStore preferences │ │ ├── UserSettings.kt # App settings │ │ └── ApiResult.kt │ ├── model/ │ │ ├── Message.kt # Message models │ │ ├── ChatSession.kt # Session models │ │ ├── SSEEvent.kt # SSE event types │ │ └── ToolCall.kt │ ├── repository/ │ │ ├── SessionRepository.kt │ │ ├── MessageRepository.kt │ │ ├── PendingMessageRepository.kt │ │ ├── BookmarkRepository.kt │ │ └── UserSettingsRepository.kt │ └── security/ │ └── SecurePreferences.kt # Encrypted storage ├── worker/ │ └── PendingMessageWorker.kt # Background sync ├── ui/ │ ├── theme/ │ │ ├── Theme.kt # Material 3 theme │ │ ├── Type.kt │ │ └── Color.kt │ ├── components/ │ │ ├── ChatInputView.kt │ │ ├── MessageBubble.kt # With context menu │ │ ├── WelcomeCard.kt │ │ ├── ShimmerLoading.kt │ │ └── SearchBar.kt │ └── screens/ │ ├── HomeScreen.kt # With search │ ├── ChatScreen.kt # With pull-to-refresh │ ├── SettingsScreen.kt # Enhanced settings │ ├── HomeViewModel.kt │ ├── ChatViewModel.kt │ └── SettingsViewModel.kt └── util/ └── Utils.kt # Clipboard, Time, Retry - Android Studio Arctic Fox (or newer)
- JDK 17+
- Android SDK 26+
- Clone the repository:
git clone https://github.com/yourusername/goose-android.git cd goose-android- Open in Android Studio
- Build the project:
./gradlew assembleDebugBy default, the app connects to https://demo-goosed.fly.dev (Trial Mode).
To use your own Goose server:
- Go to Settings
- Enter your server URL
- Enter your secret key
- Tap "Test" to verify
- Save
- Certificate Pinning: Enable for production security
- Biometric Authentication: Require fingerprint/face unlock
- sessions: Chat sessions with metadata
- messages: All messages with status tracking
- pending_messages: Queue for offline messages
- messages_fts: Full-text search index
- bookmarks: User bookmarked messages
When offline:
- Messages are queued locally
- WorkManager periodically retries
- Exponential backoff handling
- Messages sync on reconnection
- Added Room database for local persistence
- Added offline message support
- Added message status tracking
- Added context menus
- Added theme/text size selection
- Added session management
- Added search
- Added encrypted storage
- Added certificate pinning
- Added biometric auth
- Added data export
- Basic chat functionality
- Session management
- Settings
- Trial mode