Check app is paid in Apklis
Installing
- Step 1. Add the JitPack repository to your build file
allprojects { repositories { ... maven { url 'https://jitpack.io' } } }
- Step 2. Add the dependency
implementation 'com.github.cz9dev:apklispaidchequed:$VERSION'
Usage
- Check paid Kotlin
var paidCheked = PaidCheked.isPurchased(this, PACKAGE_ID) when (paidCheked){ "result00" -> Toast.makeText(this,"El movil no cuenta con la aplicacion Apklis instalada.",Toast.LENGTH_LONG).show() "result02" -> Toast.makeText(this,"No se encuentra autenticado en Apklis.",Toast.LENGTH_LONG).show() "result03" -> Toast.makeText(this,"Usted no ha comprado la aplicación en Apklis.",Toast.LENGTH_LONG).show() "result04" -> Toast.makeText(this,"Compra verificada en Apklis.",Toast.LENGTH_LONG).show() }
- Check paid Java
String paidCheked = PaidCheked.Companion.isPurchased(this, PACKAGE_ID); switch (paidCheked) { case "result00": Toast.makeText(this, "El movil no cuenta con la aplicacion Apklis instalada.", Toast.LENGTH_LONG).show(); case "result02": Toast.makeText(this, "No se encuentra autenticado en Apklis.", Toast.LENGTH_LONG).show(); case "result03": Toast.makeText(this, "Usted no ha comprado la aplicación en Apklis.", Toast.LENGTH_LONG).show(); case "result04": Toast.makeText(this, "Compra verificada en Apklis.", Toast.LENGTH_LONG).show(); default: Toast.makeText(this, "Puede continuar", Toast.LENGTH_LONG).show(); }