Skip to content

Commit 3d8f2d7

Browse files
authored
Updated Sample app (#671)
* Updated Sample app * CHANGELOG update
1 parent d0aaf82 commit 3d8f2d7

File tree

6 files changed

+73
-65
lines changed

6 files changed

+73
-65
lines changed

CHANGELOG.md

Lines changed: 39 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Changelog
22

33
## 18.0.0
4-
###### Release Date: TBD
4+
###### Release Date: 31-03-2026
55

66
### ⚡ Important Changes
77

@@ -930,15 +930,15 @@ Minor bug fixes
930930
### 🚀 Enhancements
931931
* We've renamed some of our API methods. The term `register` has been replaced with `login`. As part of this change, we've also added success and failure callbacks to the updated login methods.
932932

933-
This means that the following old `register` methods are now deprecated
934-
- `registerUnidentifiedUser()`
935-
- `registerIdentifiedUser(registration)`
936-
- `updateUser(userAttributes)`
933+
This means that the following old `register` methods are now deprecated
934+
- `registerUnidentifiedUser()`
935+
- `registerIdentifiedUser(registration)`
936+
- `updateUser(userAttributes)`
937937

938-
We've replaced them with
939-
- `loginUnidentifiedUser(statusCallback)`
940-
- `loginIdentifiedUser(registration, statusCallback)`
941-
- `updateUser(userAttributes, statusCallback)`
938+
We've replaced them with
939+
- `loginUnidentifiedUser(statusCallback)`
940+
- `loginIdentifiedUser(registration, statusCallback)`
941+
- `updateUser(userAttributes, statusCallback)`
942942

943943
* Added support to connect to Intercom workspaces that are hosted on servers in our Australian region
944944

@@ -1035,7 +1035,7 @@ New features in this update:
10351035
* Place the article search card at the top of the Messenger home screen to give your self-serve content more prominence.
10361036
* Uncover insights and opportunities to optimize your self-serve support by using our updated Articles reporting.
10371037
* If you’ve set a custom icon for the Intercom launcher, that icon will now be used in your app as well.
1038-
<img src="https://user-images.githubusercontent.com/5046761/134326966-f1b08bbc-da9d-46ee-b1c8-2e1afd00c836.png" width="350px"/>
1038+
<img src="https://user-images.githubusercontent.com/5046761/134326966-f1b08bbc-da9d-46ee-b1c8-2e1afd00c836.png" width="350px"/>
10391039

10401040
## Version 10.1.1
10411041
26-08-2021
@@ -1065,7 +1065,7 @@ New features in this update:
10651065
* Localization - with right to left language display
10661066
* Accessibility support: screen readers, dynamic font sizes, and keyboard navigation - to support all end users
10671067
* New Help Center Data API that enables you to build your own help center UI, enabling a much deeper and custom integration into your app.
1068-
![Help center](https://user-images.githubusercontent.com/3718984/122231184-2c707480-ceb2-11eb-8178-6d0aaab34713.gif)
1068+
![Help center](https://user-images.githubusercontent.com/3718984/122231184-2c707480-ceb2-11eb-8178-6d0aaab34713.gif)
10691069

10701070
### Improvements and bug fixes
10711071
* Fixed an issue where the special notice message would not display.
@@ -1075,7 +1075,7 @@ New features in this update:
10751075
26-05-2021
10761076
* Intercom no longer depends on Glide and now uses Coil to load images.
10771077
* Intercom no longer requires the Jcenter repository.
1078-
https://developers.intercom.com/installing-intercom/docs/android-installation#section-maven-central
1078+
https://developers.intercom.com/installing-intercom/docs/android-installation#section-maven-central
10791079
* Bug fixes and performance improvements.
10801080

10811081
## Version 9.1.2
@@ -1116,7 +1116,7 @@ https://developers.intercom.com/installing-intercom/docs/android-installation#se
11161116
10-11-2020
11171117
* New feature: You can now open an article or Mobile Carousel programmatically in your app. We have added two new methods to our API to enable this, [displayArticle](https://developers.intercom.com/installing-intercom/docs/android-configuration#section-present-an-article-programmatically) and [displayCarousel](https://developers.intercom.com/installing-intercom/docs/android-configuration#section-present-a-carousel-programmatically).
11181118
* Improvement: Added an optional special notice message, that can be displayed at the top of a conversation. This has been commonly used to set expectations during COVID, find more details [here](https://www.intercom.com/help/en/articles/3822642-tips-for-using-intercom-to-help-with-your-covid-19-response).
1119-
![Special notice message](https://user-images.githubusercontent.com/3718984/98683858-6ea26800-235d-11eb-9bb3-4dc3a89eaf6d.png)
1119+
![Special notice message](https://user-images.githubusercontent.com/3718984/98683858-6ea26800-235d-11eb-9bb3-4dc3a89eaf6d.png)
11201120

11211121
* Fixed: An issue where the links would not open inside conversations on Android 11.
11221122
* Fixed: An issue where we would display the wrong timezone in the conversation header.
@@ -1467,8 +1467,8 @@ The Business Messenger reimagined.
14671467

14681468
**Experimental API**
14691469
* Added an experimental API. To use it please import `io.intercom.android.sdk.experimental.Intercom`. The changes to the new API are:
1470-
* Replaced `Intercom.initialize(Application, String, String)` with `Intercom.boot(Application, IntercomSettings)` Unlike `initialize`, `boot` does not need to be called in a custom Application class. It also results in the creation/ logging in of a user.
1471-
* The methods `registerUnidentifiedUser()` and `registerIdentifiedUser(Registration)` are removed. Calling `boot` now registers a user. The `IntercomSettings` object has an optional email and userId. If either of those was provided an identified user is registered, otherwise an unidentified user is created.
1470+
* Replaced `Intercom.initialize(Application, String, String)` with `Intercom.boot(Application, IntercomSettings)` Unlike `initialize`, `boot` does not need to be called in a custom Application class. It also results in the creation/ logging in of a user.
1471+
* The methods `registerUnidentifiedUser()` and `registerIdentifiedUser(Registration)` are removed. Calling `boot` now registers a user. The `IntercomSettings` object has an optional email and userId. If either of those was provided an identified user is registered, otherwise an unidentified user is created.
14721472
* To migrate from an unidentified to an identified user you can simply call `updateUser(UserAttributes)` where the `UserAttributes` object contains an userId and/or email.
14731473
* The method `logout()` has been replaced with `shutdown()`.
14741474

@@ -1936,39 +1936,39 @@ Part of this involves a new Intercom Launcher that you can show in your app to l
19361936
### Dependencies
19371937

19381938
As part of the work to bring a better visual aesthetic to the Messenger we started using some new dependencies. Chief amongst these are the support libraries Google provides. This library now relies on:
1939-
* `com.android.support:appcompat-v7:23.3.0`
1940-
* `com.android.support:recyclerview-v7:23.3.0`
1941-
* `com.android.support:design:23.3.0`
1939+
* `com.android.support:appcompat-v7:23.3.0`
1940+
* `com.android.support:recyclerview-v7:23.3.0`
1941+
* `com.android.support:design:23.3.0`
19421942

19431943
If you use these libraries in your project be aware that we plan to stay up to date with releases and this will, by default, transitively force your app to use these versions too.
19441944

19451945
We also added some dependencies that we're namespacing to avoid version conflicts and other conflicts:
1946-
* `com.facebook.rebound:rebound:0.3.8` for nice spring animations
1947-
* `com.github.bumptech.glide:glide:3.7.0` for gif support
1946+
* `com.facebook.rebound:rebound:0.3.8` for nice spring animations
1947+
* `com.github.bumptech.glide:glide:3.7.0` for gif support
19481948

19491949
And on top of that we've updated OkHttp and Retrofit to the 3.x and 2.x versions. These are also namespaced so that won't confict with anything in your code.
19501950

19511951
### New methods on the public interface
19521952

1953-
* `void setLauncherVisibility(Visibility visibility)` will toggle whether the new Intercom launcher appears in your app. Valid parameters are `Intercom.Visibility.VISIBLE` and `Intercom.Visibility.GONE`. The default is `GONE`.
1954-
* `void setInAppMessageVisibility(Visibility visibility)` will toggle whether in-app messages appear in your app when sent to a user. Valid parameters are `Intercom.VISIBLE` and `Intercom.GONE`. The default is `VISIBLE`.
1955-
* `void hideMessenger()` will close the Intercom Messenger if it's onscreen. The typical use case we've seen for something like this is that an important event has happened in the background of your app (eg a user has taken 10,000 steps) and you need to display something immediately. We'd advise normally using an `Intent` to start your activity if that's possible within your app's architecture; we're accounting for the possibility that it isn't always possible with this method.
1956-
* `int getUnreadConversationCount` will return the last known number of unread conversations that a user has.
1957-
* `void addUnreadConversationCountListener(UnreadConversationCountListener listener)` lets you set a listener that will be notified every time the known conversation count for this user changes. For example, you may want to display a badge somewhere in your app that exposes to a user the number of unread conversations they have. Multiple listeners can be registered at a time. A **strong** reference is kept to each listener.
1958-
* `void removeUnreadConversationCountListener(UnreadConversationCountListener listener)` removes this listener from the list that will be notified of unread conversation count updates.
1953+
* `void setLauncherVisibility(Visibility visibility)` will toggle whether the new Intercom launcher appears in your app. Valid parameters are `Intercom.Visibility.VISIBLE` and `Intercom.Visibility.GONE`. The default is `GONE`.
1954+
* `void setInAppMessageVisibility(Visibility visibility)` will toggle whether in-app messages appear in your app when sent to a user. Valid parameters are `Intercom.VISIBLE` and `Intercom.GONE`. The default is `VISIBLE`.
1955+
* `void hideMessenger()` will close the Intercom Messenger if it's onscreen. The typical use case we've seen for something like this is that an important event has happened in the background of your app (eg a user has taken 10,000 steps) and you need to display something immediately. We'd advise normally using an `Intent` to start your activity if that's possible within your app's architecture; we're accounting for the possibility that it isn't always possible with this method.
1956+
* `int getUnreadConversationCount` will return the last known number of unread conversations that a user has.
1957+
* `void addUnreadConversationCountListener(UnreadConversationCountListener listener)` lets you set a listener that will be notified every time the known conversation count for this user changes. For example, you may want to display a badge somewhere in your app that exposes to a user the number of unread conversations they have. Multiple listeners can be registered at a time. A **strong** reference is kept to each listener.
1958+
* `void removeUnreadConversationCountListener(UnreadConversationCountListener listener)` removes this listener from the list that will be notified of unread conversation count updates.
19591959

19601960
### Removed methods from public interface
19611961

19621962
All deprecated methods have been dropped from Intercom, these include
1963-
* `setMessagesHidden(boolean visibility)` in favour of two new visibility methods explained below
1964-
* `openGCMMessage(Uri data)` in favour of `openGCMMessage(Intent intent)`
1963+
* `setMessagesHidden(boolean visibility)` in favour of two new visibility methods explained below
1964+
* `openGCMMessage(Uri data)` in favour of `openGCMMessage(Intent intent)`
19651965

19661966
In addition some other methods have been dropped:
1967-
* `setPreviewPosition` has been removed with no replacement
1968-
* `setVisibility` has been removed in favour of `setLauncherVisibility` and `setInAppMessageVisibility`
1967+
* `setPreviewPosition` has been removed with no replacement
1968+
* `setVisibility` has been removed in favour of `setLauncherVisibility` and `setInAppMessageVisibility`
19691969

19701970
### Miscellaneous
1971-
* We've hidden our resources so you won't see all our layouts, colours etc when you're trying to reference your own resources
1971+
* We've hidden our resources so you won't see all our layouts, colours etc when you're trying to reference your own resources
19721972

19731973
## Version 1.1.21
19741974

@@ -2207,14 +2207,14 @@ When updating to this version from a previous version we recommend cleaning the
22072207

22082208
04-29-2015
22092209
* Removed GCM permissions so that now developers have the option of adding them only if you *want* to register for push notifications
2210-
* &lt;!-- GCM REQUIRED PERMISSIONS --&gt;
2211-
* &lt;uses-permission android:name="android.permission.WAKE_LOCK" /&gt;
2212-
* &lt;uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" /&gt;
2213-
* &lt;uses-permission android:name="android.permission.VIBRATE"/>
2214-
*
2215-
* &lt;!-- GCM Optional PERMISSIONS --&gt;
2216-
* &lt;uses-permission android:name="android.permission.READ_PHONE_STATE"/&gt;
2217-
* &lt;uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/&gt;
2210+
* &lt;!-- GCM REQUIRED PERMISSIONS --&gt;
2211+
* &lt;uses-permission android:name="android.permission.WAKE_LOCK" /&gt;
2212+
* &lt;uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" /&gt;
2213+
* &lt;uses-permission android:name="android.permission.VIBRATE"/>
2214+
*
2215+
* &lt;!-- GCM Optional PERMISSIONS --&gt;
2216+
* &lt;uses-permission android:name="android.permission.READ_PHONE_STATE"/&gt;
2217+
* &lt;uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/&gt;
22182218
* Added audio cues to received and sent messages
22192219
* Fixed [issue#54](https://github.com/intercom/intercom-android/issues/54) Updated action bar visuals
22202220
* Fixed a bug where a conversation replied to by a user would update it's summary in the inbox but not it's position, related to [issue#58](https://github.com/intercom/intercom-android/issues/58)

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ The mobile SDK supports many different message formats, all of which can be crea
3131
We check for new messages when your app opens and whenever your customer or your app interacts with Intercom.
3232

3333
## Installation
34-
Intercom for Android supports API 21 and above.
34+
Intercom for Android supports API 23 and above.
3535

3636
There are 2 options for installing Intercom on your Android app.
3737

sample/app/build.gradle

Lines changed: 17 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,16 @@ plugins {
22
id 'com.android.application'
33
id 'org.jetbrains.kotlin.android'
44
id 'com.google.gms.google-services'
5+
id 'org.jetbrains.kotlin.plugin.compose' version '2.0.20'
56
}
67

78
android {
8-
compileSdk 35
9+
compileSdk 36
910

1011
defaultConfig {
1112
applicationId "com.intercom.sample"
12-
minSdk 21
13-
targetSdk 35
13+
minSdk 23
14+
targetSdk 36
1415
versionCode 1
1516
versionName "1.0"
1617

@@ -36,9 +37,6 @@ android {
3637
buildFeatures {
3738
compose true
3839
}
39-
composeOptions {
40-
kotlinCompilerExtensionVersion "1.4.8"
41-
}
4240
packagingOptions {
4341
resources {
4442
excludes += '/META-INF/{AL2.0,LGPL2.1}'
@@ -49,22 +47,22 @@ android {
4947

5048
dependencies {
5149
// Compose
52-
def composeBom = platform("androidx.compose:compose-bom:2025.04.00")
50+
def composeBom = platform('androidx.compose:compose-bom:2026.03.01')
5351
implementation composeBom
54-
implementation "androidx.compose.ui:ui"
55-
implementation "androidx.compose.material3:material3"
56-
implementation "androidx.compose.ui:ui-tooling-preview"
57-
debugImplementation "androidx.compose.ui:ui-tooling"
52+
implementation 'androidx.compose.ui:ui'
53+
implementation 'androidx.compose.material3:material3'
54+
implementation 'androidx.compose.ui:ui-tooling-preview'
55+
debugImplementation 'androidx.compose.ui:ui-tooling'
5856

59-
implementation 'androidx.core:core-ktx:1.15.0'
60-
implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.8.7'
61-
implementation 'androidx.activity:activity-compose:1.10.1'
62-
implementation("androidx.navigation:navigation-compose:2.8.8")
57+
implementation 'androidx.core:core-ktx:1.18.0'
58+
implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.10.0'
59+
implementation 'androidx.activity:activity-compose:1.13.0'
60+
implementation 'androidx.navigation:navigation-compose:2.9.7'
6361

64-
implementation "com.google.accompanist:accompanist-flowlayout:0.27.0"
62+
implementation 'com.google.accompanist:accompanist-flowlayout:0.36.0'
6563

66-
implementation("androidx.datastore:datastore-preferences:1.1.3")
64+
implementation 'androidx.datastore:datastore-preferences:1.2.1'
6765

68-
implementation("io.intercom.android:intercom-sdk:18.0.0")
69-
implementation("com.google.firebase:firebase-messaging:24.1.0")
66+
implementation 'io.intercom.android:intercom-sdk:18.0.0'
67+
implementation 'com.google.firebase:firebase-messaging:25.0.1'
7068
}

sample/app/src/main/java/com/intercom/sample/components/UserDetailsEditor.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,16 @@ import androidx.compose.material3.Icon
99
import androidx.compose.material3.IconButton
1010
import androidx.compose.material3.Text
1111
import androidx.compose.material3.TextField
12-
import androidx.compose.material.icons.Icons
13-
import androidx.compose.material.icons.outlined.Delete
1412
import androidx.compose.runtime.Composable
1513
import androidx.compose.runtime.MutableState
1614
import androidx.compose.runtime.mutableStateListOf
1715
import androidx.compose.runtime.mutableStateOf
1816
import androidx.compose.runtime.remember
1917
import androidx.compose.ui.Modifier
18+
import androidx.compose.ui.res.painterResource
2019
import androidx.compose.ui.tooling.preview.Preview
2120
import androidx.compose.ui.unit.dp
21+
import com.intercom.sample.R
2222
import io.intercom.android.sdk.UserAttributes
2323

2424
@Preview
@@ -48,7 +48,7 @@ fun UserDetailsEditor(onUserDetailsSaved: (UserAttributes) -> Unit = {}) {
4848
onClick = { userStates.remove(userStates[index]) },
4949
content = {
5050
Icon(
51-
imageVector = Icons.Outlined.Delete,
51+
painter = painterResource(R.drawable.intercom_ic_delete),
5252
contentDescription = "Delete row"
5353
)
5454
}
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<vector xmlns:android="http://schemas.android.com/apk/res/android"
2+
android:width="24dp"
3+
android:height="24dp"
4+
android:viewportWidth="24"
5+
android:viewportHeight="24"
6+
android:tint="?android:attr/colorControlNormal">
7+
<path
8+
android:fillColor="@android:color/white"
9+
android:pathData="M6,19c0,1.1 0.9,2 2,2h8c1.1,0 2,-0.9 2,-2V7H6v12zM19,4h-3.5l-1,-1h-5l-1,1H5v2h14V4z"/>
10+
</vector>

sample/build.gradle

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
plugins {
2-
id 'com.android.application' version '8.8.2' apply false
3-
id 'com.google.gms.google-services' version '4.4.2' apply false
4-
id 'org.jetbrains.kotlin.android' version '1.8.22' apply false
2+
id 'com.android.application' version '8.10.1' apply false
3+
id 'com.google.gms.google-services' version '4.4.4' apply false
4+
id 'org.jetbrains.kotlin.android' version '2.0.20' apply false
55
}
66

77
tasks.register('clean', Delete) {

0 commit comments

Comments
 (0)