Add chat to an Android app

The Ada Android SDK consists of a framework that you can use to embed Ada in your Android app, along with settings and actions that can help you customize the behavior of your bot. You can do things like:

  • Programatically set the bot language
  • Specify an initial greeting
  • Use metaFields to pass stored information from your backend systems into Ada


The Android SDK reference covers all of the settings and actions available to developers of Android apps.

Third-party cookies

The Android SDK supports third-party cookies. Note that apps targeting Build.VERSION_CODES.KITKAT and lower already allow third-party cookies by default.

app:ada_accept_third_party_cookies = "true"

Send files

When using Ada Glass (for Zendesk live agent support), users sometimes need to upload files. AdaEmbedActivity and AdaEmbedDialog already have this functionality, but if you work directly with AdaEmbedView you must handle uploads as described below.

  1. Set up a callback to AdaEmbedView. This callback will be fired when a user makes a request to attach a file.
  2. Once you get the URI, invoke filePickerCallback.onFileTaken(someUri). This will signal to AdaEmbedView that the file is ready to attach. It's also possible to pass null, which will cancel the request.
adaView.filePickerCallback = { filePickerCallback ->

This operation doesn't require you to pass the file URI to callback immediately. You can save filePickerCallback and invoke the callback later (for example, taking the URI via file picker).

To notify AdaEmbedView that you are going to handle file attachments, you should return true.