1. Reference
CallerAPI Documentation
  • Quickstart
  • Use cases
    • For carriers (MNOs/MVNOs)
    • CPaaS platforms
    • Cloud communications providers
    • SIP trunking providers
    • PBX/Cloud PBX
    • UCaaS vendors
  • Account
    • Balance and email
      GET
  • Spam protection
    • Daily spam reports
      • Webhook
        • Subscribe to daily reports
        • Unsubscribe from daily reports
        • List webhook subscriptions
        • Manual dispatch of reports
        • Test webhook
      • REST
        • Fetch daily spam reports
    • Spam score + HLR
      GET
    • 15 days spam CSV snapshot
      GET
  • Mobile SDK
    • Get started
    • Quickstart
      • What you get
      • Get your keys
      • Android
      • iOS
      • Flutter
      • React Native
      • Check it works
    • Call screening
      • What each platform can do
      • Android call screening
      • iOS prerequisites
      • iOS add the extension
      • iOS test on device
    • Reference
      • Methods
      • Errors
      • Limits and billing
      • Troubleshooting
  • Data partners
    • Partner tems & docs
    • Upload spam reports
      POST
    • Upload contacts
      POST
  • Fraud prevention
    • Ported date
      GET
    • Porting history
      GET
    • Online presence
      GET
    • KYC user identity
      POST
  • Schemas
    • Spam protection
      • Spam score request
      • Business info
      • Carrier info
      • Complaint (without number)
      • Daily spam reports request
      • Complaint (with phone)
  1. Reference

Errors

The one you will see first#

Code -2, authentication failed. Your credentials are missing, wrong, or presented by an app they were not issued to.
Check three things, in this order:
1.
All credentials are present. On Android, all three meta-data entries sit inside <application>. On iOS, you called configure, or both Info.plist keys are spelled correctly.
2.
Your bundle identifier or application ID matches the app in the dashboard.
3.
You copied the values with no leading or trailing spaces.

Every code#

CodeNameMeaningWhat to do
0OKSuccessNothing
-1InitThe SDK is not startedCall register or configure first
-2AuthCredentials refusedSee above
-3HTTPThe network request failedRetry. Check the device is online
-4CryptoAn encryption step failedReport it to us. This is a bug
-5ParseThe server sent something unreadableRetry. Report it if it repeats
-6IOA file or keychain read failedOn iOS, check the App Group
-7ExpiredThe session expiredThe SDK retries by itself
-8Not foundThe number is not in the dataNothing. This is normal
-9BusyAnother lookup for that number is runningTreat as unknown
-8 and -9 are not failures. Both mean "no answer for this number". Show your fallback text.

How each platform reports them#

Android#

lookupLabel returns null for both "not a business" and a failed lookup. It never throws for a lookup failure.
Use lookupLabelCode when the difference matters:
spamCheckCode returns 1 for spam, 0 for clean, and a negative code for a failure. isSpam collapses every failure to false, so it fails open.
A lookup before register throws IllegalStateException with the message CallerAPI not initialised - call register() first. That is a programming mistake, not a runtime condition, so do not catch it. Fix the startup order.
Init failures do not throw. register logs the failure and the SDK stays off. Filter Logcat for CallerAPI and look for native init failed.

iOS#

Both lookup functions throw CallerAPIError:
lookupLabel returns nil rather than throwing for code -8, so a number that is not a business is not an error.
CallerAPIError has localizedDescription, so you can log it without a switch.

Flutter#

Failures arrive as PlatformException. The numeric code is not exposed, so treat any throw as "no answer":

React Native#

The promise rejects. The numeric code is not exposed:
let name: string;
try {
  name = (await CallerAPI.lookupLabel(phone)) ?? 'Unknown';
} catch (e) {
  console.warn('CallerAPI lookup failed', e);
  name = 'Unknown';
}

Quota and rate errors#

These come from the server, not from the codes above.
ResponseMeaningWhat to do
402 with sandbox_limit_reached200 devices this month, on a sandbox appContact us to go live
402 with mau_cap_reachedYour agreed device cap is reachedContact us to raise it
429Too many requests from this deviceWait. Retry-After says how long
Devices already counted this month keep working past a cap. Only new devices are refused, so the problem shows up as new installs failing while existing users are fine.
See Limits and billing.

Always fail open#

Never block a call or hide a contact because a lookup failed. A missed spam call annoys a user. A blocked real call loses you one.
Every default in the SDK follows this rule. isSpam returns false on failure, and the Android call screening path lets an unknown number ring.
Modified at 2026-07-29 23:18:34
Previous
Methods
Next
Limits and billing
Built with