Skip to content

MoneySwift is a fictitious Fintech company that provides an e-commerce solution. This project is a basic Android application that simulates a simple e-commerce platform. The app showcases a list of products and allows users to select items and proceed to a checkout screen where they can enter their payment information via a custom payment sheet.

Notifications You must be signed in to change notification settings

KennethMathari/MoneySwift

Repository files navigation

MoneySwift Android App

MoneySwift is a fictitious Fintech company that provides an e-commerce solution. This project is a basic Android application that simulates a simple e-commerce platform. The app showcases a list of products and allows users to select items and proceed to a checkout screen where they can enter their payment information via a custom payment sheet that supports Stripe(card payments) or any other payment platform e.g MPESA, Airtel Money, Bitcoin etc.

Setup

To set up and run this project on your local machine, follow these steps:

  1. Clone the repository:

git clone https://github.com/KennethMathari/MoneySwift

  1. Open the project in Android Studio.
  • Launch Android Studio and select Open an existing Android Studio project. Then navigate to the directory where you cloned the repository and select the project.
  1. Sync Gradle files:
  • After opening the project, Gradle will automatically start syncing. Wait for the process to finish.

Build and Run

After opening the project, build and run to install the app in the emulator or a connected device.

App Features

  1. Product Listing Page
  • Displays a list of products with their logo, name, and price.
  1. Product Info Page
  • Displays detailed information for a selected product, including logo, name, price, and description.
  • Includes "Add to Cart" and "Buy Now" buttons.
  1. Cart Functionality
  • Adds selected items to the cart and displays a badge with the item count.
  • Allows removing items from the cart.
  1. Payment Sheet
  • Collects the user's billing information e.g. Card, MPesa, Bitcoin etc
  1. Confirmation Screen
  • Displays a message to the user, notifying them whether the payment was successful or not.

API

Products API: https://my-json-server.typicode.com/carry1stdeveloper/mock-product-api/productBundles

Libraries & Plugins

  • Jetpack Compose : For building the UI in a declarative manner.
  • Koin : For dependency injection to manage dependencies efficiently.
  • Retrofit : For network operations to fetch data from the API.
  • Kotlinx Serialization : Facilitates data serialization and deserialization in a format-agnostic way.
  • Room : For local storage.
  • App Search : a high-performance on-device search solution for managing locally stored, structured data.
  • List-Detail Layout : For a dual-pane layout where one pane presents a list of items and another pane displays the details of items selected from the list.
  • Instantiator : a little Kotlin library that uses reflection to fill data class with random test data.
  • Coil : For image loading and caching.
  • KtLint: creates convenient tasks in your Gradle project that run ktlint checks or do code auto format.
  • JUnit : For unit testing.
  • MockK : For mocking dependencies in tests.
  • Turbine : Specialized library for testing kotlinx.coroutines Flow.

Other dependencies are listed in the build.gradle files.

Architecture

The project follows the MVI (Model-View-Intent) architecture and is modularized into features consisting of the Data, Domain & UI layers.

Below is an abstract diagram of the architecture

App Module

The app module serves as an entry point to the application. It depends on all, or relevant feature modules and provides root navigation. Additionally, the app module can depend directly on the core & data modules.

Feature Modules

The feature modules, represent a singular feature of the app i.e. product or cart. It allows us to decouple the features from the app itself and test these in isolation.

Domain Modules

The domain modules is usually optional but it can contain use cases, domain models & interface repositories. It is independent of frameworks and libraries specific to Android, allowing it to be reused or tested easily without the need for an Android environment.

Data Modules

The data modules contains a repository, data sources and DTO model classes.

Core Modules

Core modules, also known as common modules, contain code that other modules frequently use. They reduce redundancy and don't represent any specific layer in an app's architecture e.g Network, Database module. Features depend on core modules and core modules can depend on one another. We should be careful to not create cyclical dependencies amongst the core modules, however.

In the case of cyclical dependencies we most likely can refactor the code which is needed into a separate core module such as :core-common

App Screenshots

image

APK File

The app APK can be found from the latest successful action on the GitHub Actions tab

About

MoneySwift is a fictitious Fintech company that provides an e-commerce solution. This project is a basic Android application that simulates a simple e-commerce platform. The app showcases a list of products and allows users to select items and proceed to a checkout screen where they can enter their payment information via a custom payment sheet.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages