Maven Central

Billy the android

Our goal is to make a modern api of BillingClient so that it is easier to use in compose world.
This library is still early beta and APIs for usages will be changes!

How to include in your project

The library is available via MavenCentral:

allprojects {
    repositories {
        // ...
Snapshots of the development version are available in Sonatype’s snapshots repository.

Sonatype Nexus (Snapshots)

allprojects {
    repositories {
        // ...
        maven {
            url ''

Add it to your module dependencies:

dependencies {

How to use

All you need to do is to call collect the state of an Sku and then call buy() when it is ready:

val earlyBirdProductStatus by Sku.Subscription("early_bird").statusFlow.collectAsState(
    initial = SkuStatus.Loading(earlyBirdProduct)

when (val earlyBirdProduct = earlyBirdProductStatus) {
    is SkuStatus.Available -> {
        Text("Available to buy!")
        Button(onClick = {
            // Launch buy flow
        }) {
            Text(text = "buy")
    is SkuStatus.Loading -> Text("Loading....")
    is SkuStatus.Unavailable -> Text("Unavailable")
    is SkuStatus.Owned -> Text("Owned")

For a full implementation
see: Full sample


There is no need to initiate the BillingClient we are doing it for you! see: BillingInitializer


View Github