Skip to main content
The Sure mobile app is a Flutter-based application that provides on-the-go access to your financial data. Available for both iOS and Android, it connects to your Sure backend server to deliver core account management features in a native mobile experience.

Key Features

The mobile app provides essential financial management capabilities:
  • Secure Authentication - OAuth 2.0 with SSO support and two-factor authentication (MFA)
  • Account Dashboard - View all linked accounts with real-time balances
  • Transaction Management - View, create, edit, and delete transactions
  • Calendar View - Visualize transactions and events on a calendar
  • AI Chat Assistant - Get financial insights (when enabled on your account)
  • Offline Support - Queue transactions when offline and sync automatically
  • Material Design 3 - Modern UI with light/dark theme support

Platform Availability

iOS

Available for iOS 12.0 and laterDownload from TestFlight (beta) or build from source

Android

Available for Android 5.0 (API 21) and laterDownload APK from releases or build from source

System Requirements

iOS

  • iOS 12.0 or later
  • iPhone, iPad, or iPod touch
  • Internet connection for server sync

Android

  • Android 5.0 (Lollipop, API level 21) or later
  • ARMv7, ARM64, or x86 processor
  • Internet connection for server sync

Installation

iOS (TestFlight)

The iOS app is distributed via TestFlight for beta testing:
  1. Install TestFlight from the App Store
  2. Get the TestFlight invitation link from your administrator
  3. Open the link on your iOS device
  4. Tap “Accept” and install the Sure app
iOS builds are automatically uploaded to TestFlight when new versions are tagged with mobile-release-*.

Android (Direct APK)

For Android, download the APK directly:
  1. Go to the GitHub Releases page
  2. Download the latest app-release.apk
  3. Enable “Install from Unknown Sources” in your device settings
  4. Open the APK file to install

Building from Source

Developers can build the app from source. See the Setup Guide for detailed instructions.

Architecture

Technology Stack

  • Framework: Flutter 3.27.0+
  • Language: Dart 3.0+
  • State Management: Provider pattern
  • Networking: HTTP with automatic token refresh
  • Storage:
    • Flutter Secure Storage for tokens and sensitive data
    • SharedPreferences for app settings
    • SQLite (sqflite) for offline transaction queue

Project Structure

lib/
├── main.dart                      # App entry point
├── models/                        # Data models
│   ├── account.dart
│   ├── auth_tokens.dart
│   ├── user.dart
│   ├── transaction.dart
│   └── chat.dart
├── providers/                     # State management
│   ├── auth_provider.dart
│   ├── accounts_provider.dart
│   ├── transactions_provider.dart
│   └── chat_provider.dart
├── screens/                       # UI screens
│   ├── login_screen.dart
│   ├── dashboard_screen.dart
│   ├── transactions_list_screen.dart
│   ├── calendar_screen.dart
│   └── chat_conversation_screen.dart
├── services/                      # API services
│   ├── api_config.dart
│   ├── auth_service.dart
│   ├── accounts_service.dart
│   ├── transactions_service.dart
│   └── device_service.dart
└── widgets/                       # Reusable components
    └── account_card.dart

API Integration

The mobile app communicates with the Sure Rails backend via REST API:

Authentication Endpoints

  • POST /api/v1/auth/login - Email/password login
  • POST /api/v1/auth/signup - User registration
  • POST /api/v1/auth/refresh - Token refresh
  • POST /api/v1/auth/sso_exchange - Exchange SSO authorization code

Data Endpoints

  • GET /api/v1/accounts - Fetch user accounts
  • GET /api/v1/transactions - Get transactions (with optional account filter)
  • POST /api/v1/transactions - Create transaction
  • PUT /api/v1/transactions/:id - Update transaction
  • DELETE /api/v1/transactions/:id - Delete transaction

Chat Endpoints

  • GET /api/v1/chats - List chat conversations
  • POST /api/v1/chats - Create new chat
  • GET /api/v1/chats/:id/messages - Get messages
  • POST /api/v1/chats/:id/messages - Send message
All API requests include automatic token refresh and retry logic to maintain session continuity.

Security Features

Secure Token Storage

Tokens are stored using Flutter Secure Storage, which provides:
  • Encrypted storage on both iOS (Keychain) and Android (KeyStore)
  • Automatic data clearing when the app is uninstalled
  • Protection against unauthorized access

Token Management

  • Access tokens are automatically refreshed before expiration
  • Refresh tokens are used to obtain new access tokens
  • Invalid tokens trigger automatic logout and redirect to login

Device Tracking

Each login records device information:
  • Device ID (UUID)
  • Device name
  • Device type (iOS/Android)
  • OS version
  • App version
This enables backend session management and security monitoring.

Configuration

Backend Server

On first launch, the app prompts for your Sure backend server URL:
  • Local Development: http://10.0.2.2:3000 (Android) or http://localhost:3000 (iOS)
  • Production: https://your-sure-server.com
The server URL is stored locally and can be changed in Settings.

API Configuration

Configuration is managed in lib/services/api_config.dart:
class ApiConfig {
  static const String _defaultBaseUrl = 'https://demo.sure.am';
  static const Duration connectTimeout = Duration(seconds: 30);
  static const Duration receiveTimeout = Duration(seconds: 30);
}

App Version

Current version: 0.6.9 Version information is defined in pubspec.yaml:
version: 0.6.9+1
The format is major.minor.patch+buildNumber.

Future Enhancements

Planned features for upcoming releases:
  • Budget management and tracking
  • Investment portfolio tracking
  • Push notifications for transactions and alerts
  • Biometric authentication (fingerprint/Face ID)
  • Multi-language support
  • Enhanced offline capabilities
  • Financial charts and visualizations
  • Receipt photo capture and attachment

Getting Help

License

The Sure mobile app is distributed under the AGPLv3 license.

Build docs developers (and LLMs) love