The Android SDK is available at OrcusHQ/orcuspay-android.

Requirements

  • Android Studio
  • Kotlin
  • minSdk configured by your app
  • Orcuspay access and secret keys

Install

Until the SDK is published to Maven Central or GitHub Packages, add it as a Git submodule or include the orcuspay module from the official repository.
git submodule add https://github.com/OrcusHQ/orcuspay-android.git vendor/orcuspay-android
Then include the module in settings.gradle.kts:
include(":orcuspay")
project(":orcuspay").projectDir = file("vendor/orcuspay-android/orcuspay")
Add the dependency:
dependencies {
    implementation(project(":orcuspay"))
}

Create a checkout session

import com.orcuspay.android.OrcusPayClient
import kotlinx.serialization.json.buildJsonObject
import kotlinx.serialization.json.put

val client = OrcusPayClient(
    accessKey = "ak_test_xxxxx",
    secretKey = "sk_test_xxxxx",
)

val payload = buildJsonObject {
    put("amount", 10000)
    put("currency", "BDT")
    put("success_url", "https://example.com/payment/success")
    put("cancel_url", "https://example.com/payment/cancel")
}

val session = client.createCheckoutSession(payload)

Notes

  • Do not ship production secret keys inside a public mobile app.
  • For consumer-facing apps, create sessions from your backend and send only the checkout URL/session ID to the Android app.
  • Use the Android SDK only in trusted/internal apps unless your backend is protecting secret credentials.