Skip to Content
Docs
Get startedPartner API v4Partner API v3Android SDK
v1.0.6

Direct Calls (Mode 1 only)

v1.0.6 supports direct calls only. Use loanApplicationId as the identifier for all capture methods. No orchestrator or docked button in this version.

// Create loan case
AbleCredit.createNewLoanCase(this, payload) { result ->
    when (result) {
        is AbleCreditResult.Success -> {
            val applicationId = result.data?.data?.application?.id ?: ""
        }
        is AbleCreditResult.Failure ->
            Log.e("AbleCredit", "Error: ${result.ableCreditErrorCode} / ${result.message}")
    }
}

// Audio (with upload listener)
val audioListener = object : AbleCreditFileUploadListener {
    override fun onStatusChanged(uniqueId: String, status: AbleCreditFileStatus, message: String?) {
        Log.d("AbleCredit", "id=$uniqueId status=$status message=$message")
    }
}
AbleCredit.recordAudio(this, applicationId, audioListener)
AbleCredit.captureFamilyPhotos(this, applicationId)
AbleCredit.captureBusinessPhotos(this, applicationId)
AbleCredit.captureCollateralPhotos(this, applicationId)

// Fetch / report / clear
AbleCredit.fetchLoanDetails(this, loanReference) { result -> }
AbleCredit.requestReportGeneration(this, applicationId) { result -> }
AbleCredit.clearSdkData { result -> }