Mobile apps

CartUser ships with 3 native Flutter mobile apps: User (customer shopping), Seller (vendor management), and Delivery Boy (order delivery). Source code included. All apps share the same backend API.

The 3 apps

App Purpose Users
User App Customer shopping experience End shoppers
Seller App Manage products, orders, earnings Marketplace vendors
Delivery Boy App Pick up orders, deliver, mark complete Delivery personnel

User App features

Seller App features

Delivery Boy App features

Apps + backend

All 3 apps connect to your CartUser backend via REST API. Same URL, different login type.

API base URL

Apps need to know your backend URL. Set in app's core/strings/endpoints.dart

baseUrl=https://yourdomain.com/api

Required backend setup

  1. Backend installed + accessible via HTTPS (apps require SSL)
  2. Admin โ†’ Settings โ†’ AI Configuration โ†’ not required for apps
  3. Admin โ†’ Settings โ†’ SMS Gateway โ†’ optional, needed for OTP login
  4. Admin โ†’ Settings โ†’ Push Notification โ†’ set Firebase server key for FCM
  5. Admin โ†’ Settings โ†’ App Settings โ†’ upload onboarding screens (intro slides)

Firebase push notifications

  1. Create Firebase project at console.firebase.google.com.
  2. Add Android + iOS app to your Firebase project.
  3. Download google-services.json (Android) and GoogleService-Info.plist (iOS).
  4. Replace files in app source: android/app/ and ios/Runner/.
  5. Get Firebase Server Key from Firebase Console โ†’ Project Settings โ†’ Cloud Messaging.
  6. Paste into CartUser admin โ†’ Settings โ†’ Push Notification โ†’ FCM Server Key.
  7. Test notification: Send test notification from Firebase console to the app.

Building APK / IPA

Requirements

Quick build commands

# Android APK
cd cartuser-user-app
flutter clean && flutter pub get
flutter build apk --release

# Android App Bundle (for Play Store)
flutter build appbundle --release

# iOS (Mac only)
flutter build ios --release
cd ios && pod install && xcodebuild -workspace Runner.xcworkspace -scheme Runner archive

Output locations

Branding / customisation

App name + logo

  1. From the project directory run the following command: rename setAppName -t android -v "YOUR_APP_NAME" โ†’
  2. iOS: From the project directory run the following command: rename setAppName -t ios -v "YOUR_APP_NAME" โ†’
  3. Replace launcher icons:
    • Use flutter_launcher_icons package
    • Navigate to assets/icons
    • Replace assets/icon/app_logo.png with your 512ร—512 logo
    • IMPORTANT : Do not change the name of the files.
    • Run flutter pub run flutter_launcher_icons
  4. Replace splash screen: android/app/src/main/res/drawable/ and ios/Runner/Assets.xcassets/LaunchImage.imageset/

Colors + theme

Edit lib/themes/color_scheme.dart in app source โ€” change primary, accent, background colors. App auto-rebuilds.

Onboarding screens

Set from CartUser admin (not in code). Admin โ†’ Settings โ†’ App Settings โ†’ add 3-5 onboarding pages with heading, description, image. App fetches these via /api/config.

App Signing

Follow the official Flutter documentation: Create an upload keystore and reference it in your app

NOTE: In the key.properties file, change the value of storeFile to the path of your keystore file. To make it easier, you can put the upload-keystore.jks file in android/app/. Then change the value of storeFile to app/upload-keystore.jks.

Publishing to stores

Google Play Store

  1. Create developer account ($25 one-time)
  2. Create new app listing
  3. Upload app-release.aab
  4. Fill required metadata: screenshots, description, privacy policy URL
  5. Submit for review (1-7 days)

Apple App Store

  1. Apple Developer Program ($99/year)
  2. Create app in App Store Connect
  3. Upload IPA via Xcode โ†’ Archive โ†’ Distribute
  4. Fill metadata: screenshots, description, privacy nutrition labels
  5. Submit for review (1-7 days)

Source code structure

cartuser-user-app/
โ”œโ”€โ”€ lib/
โ”‚   โ”œโ”€โ”€ main.dart              # Entry point
โ”‚   โ”œโ”€โ”€ core/strings/endpoints.dart      # API client + endpoints
โ”‚   โ”œโ”€โ”€ models/                # Data models
โ”‚   โ”œโ”€โ”€ features/               # All UI screens
โ”‚   โ”œโ”€โ”€ _widgets/               # Reusable widgets
โ”‚   โ”œโ”€โ”€ themes/                 #Colors + typography
โ”‚   โ”œโ”€โ”€ route/                 # All Route
โ”‚   โ””โ”€โ”€ utils/                 # Helpers
โ”œโ”€โ”€ assets/                    # Images, fonts
โ”œโ”€โ”€ android/                   # Android-specific config
โ”œโ”€โ”€ ios/                       # iOS-specific config
โ””โ”€โ”€ pubspec.yaml               # Dependencies

Troubleshooting

App can't connect to backend

OTP login not working

Push notifications not arriving