Skip to content

Frak ships native SDKs for Android and iOS, so the referral loop that works on your website also works inside your app: a customer shares, a friend installs or buys, and the reward is paid on a confirmed order.

CapabilityAndroidiOS
Share sheet with a personal referral linkYesYes
Reward amounts to display in your UIYesYes
Interaction and purchase trackingYesYes
Referral deep links into your appYesYes
Handoff to install the Frak walletYesYes

Both SDKs split into two pieces: a core with no user interface (nothing pulls in a web view) and an optional UI piece that adds the ready-made sharing sheet.

  1. Register your merchant account. Sign in to the business dashboard and note your merchant ID. Your mobile app passes it explicitly at startup. See Register your site.

  2. Add the SDK to your app. Initialize it once, show a share button, and track your orders. The full walkthrough is in the developer guides below.

  3. Confirm orders from your backend. Same as on the web: a signed webhook from your server is what actually releases the reward. See Validate purchases from your backend.

Requires Android 7.0 (API 24) and Java 17. Add the artifacts:

app/build.gradle.kts
dependencies {
implementation("id.frak.sdk:core:1.0.0-beta.1")
// Only if you show the sharing sheet
implementation("id.frak.sdk:ui:1.0.0-beta.1")
}

Initialize once, in Application.onCreate or your launcher Activity:

Frak.initialize(
context = applicationContext,
config = FrakConfig(merchantId = "your-merchant-id") {
metadata = FrakMetadata {
name = "Your Store"
currency = FrakCurrency.EUR
homepageLink = "https://your-store.com"
}
},
)

Show the sharing sheet:

val sharing = FrakSharing.Builder(::onShareResult).build(this)
sharing.present(SharingRequest { targetInteraction = "purchase" })

And track a confirmed order:

Frak.client.tracking.purchase(
customerId = "cust_123",
orderId = "order_456",
token = "a-unique-order-token",
)

Everything is callable from Java too: every suspending call has a CompletableFuture twin.

A referral link opens in a browser unless your app claims it. Set up App Links on Android (with a published assetlinks.json) and Universal Links or a custom URL scheme on iOS, so a referred friend lands in your app with the referral intact. Both developer guides show the exact manifest and Info.plist entries.

Tracking a purchase from the app tells Frak an order might be coming. The reward is paid once your backend confirms the order with a signed webhook, exactly like the web integration. The order token you send from the app must match the one your server signs.