EN - How to find the Channel ID using the Channel Capture Tool

Overview

Airship uses unique Channel IDs to identify specific devices for your app.  The Channel ID is often the most important piece of information that you will need to track push delivery to a specific device.

To help find your Channel ID, our SDK contains a built-in tool for retrieving your Channel ID called the Channel Capture Tool.  

This document will walk you through the following:

  • Obtaining your app's Channel Capture Token through the Airship Support Team
  • Preparing Your Device
  • Using the Channel Capture Token to reveal your device's Channel ID

We recommend sending a test message to your app on a test device (or group of test devices) prior to sending to your desired audience to ensure the message functions and displays as expected.

 

 

Requirements 

  • SDK version 6.1+ on iOS or Android
  • The Channel Capture Tool needs to be enabled at both the application level and the individual device level in order to return a device's Channel ID.
    • By default, the Channel Capture tool is enabled at the application level. If you're having trouble using the tool, please check that it hasn't been disabled at the application level. (iOS | Android)
    • By default, the Channel Capture tool is disabled at the individual device level. The rest of the article will walk you through enabling it at the device level so you can see your device's Channel ID.

 

Instructions

  • Reach out to the Airship Support Team with the app key of the application you would like a Channel Capture Token for.

 

Each Airship project has its own Channel Capture Token. This token can be used to get the Channel ID for any Android or iOS device that has the corresponding application installed.

If you have production and development versions of the app, each will have its own app key and token. You can include multiple applications in one email.

 

  • Once we receive the email we will respond with the Channel Capture token for your app. This will be a long string of letters and numbers, similar to the below example:

 

MTcxMTBlM2UwZTI0MzMyOTA3NmMyNjEzMzB4TDA4MzQxBDYyNjE2MzJmMTA

 

  • Send the Channel Capture Token to your device (for example, by email or SMS). 

  • Open the message on your device and long press on the token to copy it to your device's clipboard. Be sure to copy the full token and nothing else such as punctuation or white space.

    copy_token.jpg


  • Open your application on your device.

  • A pop-up should appear on your screen which shows your Channel ID with options to copy or share.

    channel_showing.jpg

Depending on the version of the Airship SDK which is integrated into your application, there may be a few extra steps necessary for the Channel Capture Tool to work.

 

Click one of the below links to jump directly to instructions for the relevant SDK version:


iOS SDK Version 8.5.0 +

Channel Capture Tool's capabilities are disabled by default on the individual device. It can be enabled on the device by doing the following (This is in addition to and will not override the application level flag mentioned in requirements):

  1. Open the Settings menu on the Device.
  2. Scroll down until you find your application listed and tap on it to select

    Screen_Shot_2018-07-06_at_3.37.21_PM.png

  3. Turn Off Background App Refresh

    backgroundrefreshoff.png
  4. Follow the above instructions to copy the Channel Capture Token into the device clipboard and open the app to reveal the Channel ID
  5. Remember to Turn Background App Refresh back on

Android SDK Version 8.4 + 

Channel Capture Tool's capabilities are disabled by default on the individual device. It can be enabled on the device by doing the following (This is in addition to and will not override the application level flag mentioned in requirements):

  1. Open the Settings menu on the Device.
  2. Go to Apps and Notifications (May be called Applications or Notifications depending on the Android Version and Manufacturer)

    Screen_Shot_2018-07-07_at_11.02.02_AM.png

  3. Find and select your application

    select_app.png

  4. Block/Turn off Push Notifications for the application

    notifications_off.png

  5. Follow the above instructions to copy the Channel Capture Token into the device clipboard and open the app to reveal the Channel ID

    Screen_Shot_2018-07-07_at_11.08.09_AM.png

  6. Remember to unblock notifications once you retrieve your Channel ID

Android SDK Versions 8.3-8.3.2

The Channel Capture Tool is disabled by default on the individual device. Channel capture can only be enabled by sending a specific silent push (This is in addition to and will not override the application level flag mentioned in requirements).

Sending a silent push is usually transparent to your end users, however some applications may implement code which is triggered when a push is received. Consult with your development team if you have a concern prior to sending a push. If you do not regularly target your entire audience for a push notification, you may see an increase in uninstalled devices. Consult our guide on Detecting Uninstalled Devices for an explanation of why this would be expected.
  1. Retrieve your app key and master secret which will be needed to send a notification (Keep this secure)
  2. Copy the following cURL request, which will send a silent push to your audience and enable the Channel Capture Tool for the number of seconds specified in the channel_capture_action.
    You will replace the text in the '-u' line with your actual app key and master secret
    curl -X POST \
    https://go.urbanairship.com/api/push \
    -H 'accept: application/vnd.urbanairship+json; version=3;' \
    -u 'REPLACE-WITH-APP-KEY:REPLACE-WITH-MASTER-SECRET' \
    -H 'cache-control: no-cache' \
    -H 'content-type: application/json' \
    -d '{
             "audience": "all",
             "notification": {
                 "ios": {
                     "content_available": 1
                 },
                 "android": {
    
                 },
                 "actions": {
                     "app_defined": {
                         "channel_capture_action": 180
                     }
                 }
             },
             "device_types": ["ios","android"]
         }'


  3. Follow the above instructions to copy the Channel Capture Token into the device clipboard and open the app to reveal the Channel ID

If you are setting up your device for testing purposes you may now add this Channel ID to a Test Group on the application, or you can create a .CSV list of many test devices and upload this list following our Upload List Tutorial.

The Test Group or the Uploaded List can then be targeted as an audience for a push notification for testing.


Related Content 
 

Was this article helpful?
0 out of 0 found this helpful
Submit a request