Skip to content

A self-hosted UPI & COD payment gateway with zero per-transaction platform fees, universal JavaScript checkout integration, dynamic QR payments, WhatsApp OTP authentication, and automated payment verification.

JavaScript

ci(android): add automated Android APK compilation and artifact upload workflow

ArunGupta15264f3be8b61c34
diff --git a/.github/workflows/android-build.yml b/.github/workflows/android-build.yml
new file mode 100644
index 0000000..ae6fdbb
--- /dev/null
+++ b/.github/workflows/android-build.yml
@@ -0,0 +1,63 @@
+name: Build Android APK
+
+on:
+ push:
+ branches:
+ - main
+ paths:
+ - 'apps/android-observer-app/**'
+ - 'scripts/build-android-apk.js'
+ - 'scripts/sync-android-allowlist.js'
+ - '.github/workflows/android-build.yml'
+ pull_request:
+ branches:
+ - main
+ paths:
+ - 'apps/android-observer-app/**'
+ - 'scripts/build-android-apk.js'
+ - 'scripts/sync-android-allowlist.js'
+ - '.github/workflows/android-build.yml'
+ workflow_dispatch:
+
+permissions:
+ contents: read
+
+jobs:
+ build-apk:
+ name: Compile & Verify Android APK
+ runs-on: ubuntu-latest
+ timeout-minutes: 15
+
+ steps:
+ - name: Checkout Repository
+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
+
+ - name: Set up Java 17
+ uses: actions/setup-java@b843ebf9b913146b38da2eaa7aeddf76074ae1ad # v6.1.0
+ with:
+ distribution: 'temurin'
+ java-version: '17'
+
+ - name: Set up Node.js 22
+ uses: actions/setup-node@949feb2413d6458794dcd2491c4babbbce0c15c1 # v7
+ with:
+ node-version: '22'
+ cache: 'npm'
+
+ - name: Install Dependencies
+ run: npm ci
+
+ - name: Compile Certified Android APK
+ run: npm run build:android
+
+ - name: Verify Android Observer Tests
+ run: node --test apps/android-observer-app/__tests__/android-observer.test.js
+
+ - name: Upload Android APK & Checksum Artifacts
+ uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
+ with:
+ name: youpi-sms-gateway-apk
+ path: |
+ apps/android-observer-app/youpi-sms-gateway.apk
+ apps/android-observer-app/youpi-sms-gateway.apk.sha256
+ if-no-files-found: error