Expand my Community achievements bar.

ACC - Android - Migration process to FCM HTTPv1

Avatar

Employee

6/12/24

What is the change?

  • Legacy FCM APIs will be discontinued on June 20, 2024
  • Adobe Campaign Classic v7 and Adobe Campaign v8 already support the latest APIs to send push notification messages.
  • Legacy implementations still rely on the legacy APIs. These implementations must be updated.

Legacy Implementation

The support of HTTPv1 has been added in AC7 20.3.1 release. HTTPv1 is supported by all AC8 releases.

AC7 customers using a version released before 20.3.1 will have to migrate to the latest recommended version of AC7 to be able to migrate to HTTPv1.

Pre-requisites

  • V7 Build 20.3.1 or higher.
  • All v8 builds are compatible.
  • Account JSON file.
  • Marketing instance and Message Center instance are impacted based on your use case.
  • Mid-sourcing instance is not impacted.

Adobe Campaign Side

Marketing server

Locate all Android Mobile applications on your marketing instance.

Proceed to update the API version on all Android applications.

Vipul_Raghav_1-1718237674426.png

Next you need to the Project JSON file. For more information on how to extract your JSON file, please refer to this page. We have summarized the steps below:

  • Go to Firebase Console https://console.firebase.google.com/u/0/ 
  • Open the Mobile application Project
    Vipul_Raghav_2-1718237715656.png
  • Open Project settings under Project Overview
    Vipul_Raghav_3-1718237740296.png
  • Click Generate Private Key under Service Accounts.
    Vipul_Raghav_4-1718237842410.png

     

  • Get the file using secure mechanism.
  • Verify the Project JSON file. Must have 
    • Private Key
    • Client Email
    • Project ID
      Vipul_Raghav_5-1718238582947.png

       

Migration Steps

  • Change API version on each mobile app.
  • Upload JSON to ACC Android Mobile Application
  • Upload on marketing and message center (if applicable)
  • Test Connection
    Vipul_Raghav_6-1718238661490.png

     

  • Save the mobile application

Important Points to Remember

  • Only the OOB Android template is updated by product to manage HTTP v1.
  • Custom templates created prior to 20.3 build upgrade are still non-compliant.
  • Any duplicated templates created from pre 20.3 build era will also be non-compliant.
  • New templates created using OOB Android template will automatically work.
  • Applies to those created post 20.3 build upgrade.
  • Old templates will still work after the switch as ACC fallbacks to legacy API on such templates
  • Old templates will stop working from Jun 20th 2024
  • How to know if my implementation is still using legacy API? The delivery logs will show text as Message pushed to connector.
    Vipul_Raghav_7-1718238726354.png

     

Bulk Messaging Android Templates – Manual changes

Steps outlined below are, if not applied correctly, can break the templates. Please proceed with caution and take utmost care. It will be a good idea to backup your templates by exporting them as a package

  • Check Android Routing Connector is androidPushConnectorV2.js (nms)
    • In a hybrid setup, this can be checked on the MID instance. Reach out to support if your mid-sourcing environment is hosted by Adobe.
      Vipul_Raghav_8-1718238795026.png

       

  • Open each template and then open xml source.
  • Locate this line in code inside node androidCheckParams.
    Vipul_Raghav_10-1718238875653.png
  • Replace the entire if  clause with this code.
    Vipul_Raghav_11-1718238895579.png

 

 

 

if( appSubscription.mobileApp.label!='' && appSubscription.mobileApp.img!='' && appSubscription.mobileApp.fcmProtocol!='' && 
      ( ( appSubscription.mobileApp.senderId!='' && appSubscription.mobileApp.password!='' ) || 
        ( appSubscription.mobileApp.fcmProjectId!='' && appSubscription.mobileApp.fcmPrivateKey!='' && appSubscription.mobileApp.fcmClientEmail!='' ) )  &&  
        String(message.delivery.idTracking)!='' && String(message.delivery.idMarketing)!='' ) 

 

 

 

  • Save the template and test.

     

Mid Sourcing Server

Mid-sourcing is not impacted.

Message Center Execution Instance

Adobe Campaign support needs to be contacted to have the configuration changes done.

The Firebase Admin SDK service's account JSON file needs to be added to the request. 

The same procedure as the marketing server needs to be followed on Message Center. Existing deliveries on RT instance will continue to use Legacy API. Follow the steps from next section to make them compatible with HTTPv1

Transactional Messaging Android Templates – Manual changes

Steps outlined below are, if not applied correctly, can break the templates. Please proceed with caution and take utmost care. It will be a good idea to back up your templates by exporting them as a package.

These steps have to be performed for each Android Template on the Control instance.

  • Check Android Routing Connector is androidPushConnectorV2.js (nms)
    Vipul_Raghav_0-1718239078391.png

     

    • This has to be checked on the RT instance. Reach out to support if your execution instance is hosted by Adobe.
  • Open each template on the Control instance and then open xml source.
  • Locate this line in code inside node androidCheckParams.
    Vipul_Raghav_1-1718239138858.png

     

  • Replace the entire if clause with this code.
    Vipul_Raghav_2-1718239171049.png

 

if( rtEvent.mobileApp.label!='' && rtEvent.mobileApp.img!='' && rtEvent.mobileApp.fcmProtocol!='' && 
          ( ( rtEvent.mobileApp.senderId!='' && rtEvent.mobileApp.password!='' ) || 
            ( rtEvent.mobileApp.fcmProjectId!='' && rtEvent.mobileApp.fcmPrivateKey!='' && rtEvent.mobileApp.fcmClientEmail!='' ) )  &&  
            String(message.delivery.idTracking)!='' && String(message.delivery.idMarketing)!='' )

 

  • Save the template. Publish the template from Control to execution and test.

How to confirm if Adobe Campaign Classic is using HTTPv1 to send the Android push notifications?

The Delivery Log should say it was sent using HTTP v1

Vipul_Raghav_3-1718239252229.png

 

Best Practice

Your implementation must have a lot of templates and manually updating them can take time. Given the deadline for Jun 20th, we advise 

  • To categorize those templates into priorities like Critical, Urgent, Good to Have, Not needed anymore.
  • Focus on Critical and Urgent ones to be fixed first and tested.
  • Others can be targeted post Jun 20th based on schedule and also based on the the marketing campaign schedule.