Skip to content

Commit

Permalink
Prepare for 2.1.6 In App consume updates + fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
davidtruong committed Jul 19, 2017
1 parent 504fd8a commit 90d4d3d
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 30 deletions.
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,15 @@ This project adheres to [Semantic Versioning](http://semver.org/).
#### Fixed
- nothing yet

## [2.1.6](https://github.com/Iterable/iterable-android-sdk/releases/tag/2.1.6)
_Released on 2017-07-19_

#### Added
- Added the in-app consume logic to automatically remove the notification from list of in-app notifications.

#### Fixed
- Fixed the payloadfor trackInAppClick to contain the userId.

## [2.1.5](https://github.com/Iterable/iterable-android-sdk/releases/tag/2.1.5)
_Released on 2017-06-09_

Expand Down
60 changes: 31 additions & 29 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,42 +1,55 @@
# Iterable Android SDK

`iterable-android-sdk` is a java implementation of an android client for Iterable, for api version 15 and higher.
The `iterable-android-sdk` is a java implementation of an android client for Iterable, supporting api versions 15 and higher.

# Setting up a push integration in Iterable
## Setting up a push integration in Iterable

Before you even start with the SDK, you will need to
Before you even start with the SDK, you will need to:

1. Set your application up to receive push notifications, and
2. Set up a push integration in Iterable. This allows Iterable to communicate on your behalf with Google's Push Notification Service.

You will also need to generate an SSL certificate and private key for use with the push service. See the links at the end of this section for more information on how to do that.
For information on setting up your Google Api Project, see

Once you have your APNS certificates set up, go to `Integrations -> Mobile Push` in Iterable. When creating an integration, you will need to pick a name and a platform. The name is entirely up to you; it will be the `applicationName` when you use `registerDeviceToken` in our SDK. The platform will be `GCM`. Add the GCM api server key.
* [Configuring Push Notifications](http://docs.aws.amazon.com/sns/latest/dg/mobile-push-gcm.html)

![Creating an integration in Iterable](https://support.iterable.com/hc/en-us/article_attachments/211841066/2016-12-08_1442.png)
To setup your push integration with Iterable in the web dashboard go to `Integrations -> Mobile Push`. When creating an integration, you will need to pick a name and a platform. The name is entirely up to you; it will be the `applicationName` when you use `registerForPush` or `registerDeviceToken` in our SDK.

For more information, see
The platform will be `GCM` (This also includes FCM since it runs off of GCM). Add the Api server key (If on FCM use the Legacy Server Key).

* [Configuring Push Notifications](http://docs.aws.amazon.com/sns/latest/dg/mobile-push-gcm.html)
![Creating an integration in Iterable](https://support.iterable.com/hc/en-us/article_attachments/211841066/2016-12-08_1442.png)

Congratulations, you've configured your mobile application to receive push notifications! Now, let's set up the Iterable SDK...

# Automatic Installation
## Automatic Installation

See BinTray for the latest version of the Iterable Android SDK on [Bintray](https://bintray.com/davidtruong/maven/Iterable-SDK)
See [Bintray](https://bintray.com/davidtruong/maven/Iterable-SDK) for the latest version of the Iterable Android SDK.

#### InApp Notifications
To display the user's InApp notifications call `spawnInAppNotification` with a defined `IterableActionHandler` callback handler. When a user clicks a button on the notification, the defined handler is called and passed the action name defined in the InApp template.

InApp opens and button clicks are automatically tracked when the notification is called via `spawnInAppNotification`.

# Additional Information
## Additional Information

See our [setup guide](http://support.iterable.com/hc/en-us/articles/204780589-Push-Notification-Setup-iOS-and-Android-) for more information.

Also see our [push notification setup FAQs](http://support.iterable.com/hc/en-us/articles/206791196-Push-Notification-Setup-FAQ-s).

# Deeplinking
##Optional Setup

### Firebase Messaging
At this time there is no requirement to upgrade to FCM since Google will continue to support current versions of GCM android.

If you want to use using Firebase Cloud Messaging (FCM) instead of Google Cloud Messaging (GCM) pass in `IterableConstants. MESSAGING_PLATFORM_FIREBASE` as the pushServicePlatform.

```java
public void registerForPush(String iterableAppId, String projectNumber, String pushServicePlatform) {
```

**Note**: If you are upgrading to FCM, do not downgrade back to GCM as this will cause devices to be registered for notifications twice and users will get duplicate notifications.

### InApp Notifications
To display the user's InApp notifications call `spawnInAppNotification` with a defined `IterableActionHandler` callback handler. When a user clicks a button on the notification, the defined handler is called and passed the action name defined in the InApp template. If no action is defined, the callback handler will not be called.
InApp opens and button clicks are automatically tracked when the notification is called via `spawnInAppNotification`. `spawnInAppNotification` automatically consumes and removes the notification from the user's list of pending notification. If you do not want to remove the notification use `getInAppMessages` & `IterableInAppManager.showNotification` instead.

### Deeplinking

See our [Deeplinking Setup Guide] (https://support.iterable.com/hc/en-us/articles/211676923)

Expand All @@ -58,18 +71,7 @@ protected void onCreate(Bundle savedInstanceState) {
}
```
# Firebase Messaging
At this time there is no requirement to upgrade to FCM since Google will continue to support current versions of GCM android.

If you want to use using Firebase Cloud Messaging (FCM) instead of Google Cloud Messaging (GCM) pass in `IterableConstants. MESSAGING_PLATFORM_FIREBASE` as the pushServicePlatform.

```java
public void registerForPush(String iterableAppId, String projectNumber, String pushServicePlatform) {
```

**Note**: If you are upgrading to FCM, do not downgrade back to GCM as this will cause devices to be registered for notifications twice and users will get duplicate notifications.

# License
## License
The MIT License
Expand Down
2 changes: 1 addition & 1 deletion iterableapi/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ ext {
siteUrl = 'https://github.com/Iterable/iterable-android-sdk'
gitUrl = 'https://github.com/Iterable/iterable-android-sdk.git'

libraryVersion = '2.1.5'
libraryVersion = '2.1.6'

developerId = 'davidtruong'
developerName = 'David Truong'
Expand Down

0 comments on commit 90d4d3d

Please sign in to comment.