Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use of Firebase Messaging iOS Direct Channel API? #648

Open
AmirBen78 opened this issue Dec 22, 2020 · 1 comment
Open

Use of Firebase Messaging iOS Direct Channel API? #648

AmirBen78 opened this issue Dec 22, 2020 · 1 comment

Comments

@AmirBen78
Copy link

Firebase Messaging iOS SDK version 7.0 will be a breaking change where the SDK will no longer support iOS Direct Channel API:

Hi company

We are writing to let you know that Firebase Messaging iOS Direct Channel API support is marked for deprecation. Firebase Messaging iOS SDK version 7.0 will be a breaking change where the SDK will no longer support iOS Direct Channel API.

What do I need to know?

Firebase Messaging iOS Direct Channel has been used for sending data to apps when they are in the foreground and for upstream messages. The Firebase Messaging iOS SDK v7.0 (slated to be released in September 2020) will no longer support the iOS Direct Channel API**. Your app will break if you update to the Firebase Messaging iOS SDK v7.0 without migrating off the iOS Direct Channel API.**

We are removing this feature in favor of natively supported messaging features provided by Apple Push Notification Service.

To prevent disruptions to your users, we recommend that you discontinue use of the iOS Direct Channel API as soon as possible. Please note that for the time being, your existing users can still continue to receive messages via the iOS Direct Channel API. However, within the next year, we will follow up this announcement with plans to deprecate the backend service support which may break your app with older versions of the Messaging iOS SDK (prior to v7.0).

What do I need to do?

  • To prevent disruptions to your users, we recommend that you discontinue use of the iOS Direct Channel API and use an alternative such as FCM’s APNs interface for downstream data message delivery.

  • If you are not using FCM HTTP v1 API. FCM HTTP v1 API provides full APNs support. If you need to continue using FCM Legacy API, you can:

  • Add the content_available key to your payload if you continue to use the legacy sender API.

  • For upstream messages, make arrangements to send messages directly from your app to your servers.

  • For real time updates, you can use Cloud Firestore, or other services.

You are an owner of the following Firebase project(s) that uses Firebase Messaging iOS Direct Channel API:

  • xxxxxx

As always, if you have any questions or need any assistance, feel free to reach out to support for more assistance.

I think this plugin does not use direct channel API, I did not see the following code:

[FIRMessaging messaging].shouldEstablishDirectChannel = true;

Do you confirm that there is no impact?

@alexandrox92
Copy link

Could you pass me the code fragment that you use to obtain the token in android?

this is my index.js and i can't get the token.

var app = {
// Application Constructor
initialize: function() {
document.addEventListener('deviceready', this.onDeviceReady.bind(this), false);
},

// deviceready Event Handler
onDeviceReady: function() {
    this.receivedEvent('deviceready');
    this.pushNotification();
},

// Update DOM on a Received Event
receivedEvent: function(id) {
    var parentElement = document.getElementById(id);
    var listeningElement = parentElement.querySelector('.listening');
    var receivedElement = parentElement.querySelector('.received');
    listeningElement.setAttribute('style', 'display:none;');
    receivedElement.setAttribute('style', 'display:block;');
    console.log('Received Event: ' + id);
},
pushNotification: function(){

/***********************************************************************************************/

  FCMPluginNG.onNotification(function(data)
  {
    if(data.wasTapped){
      alert(JSON.stringify(data));
    }else{
      alert(JSON.stringify(data));
    }
  });

/***********************************************************************************************/

}

};

app.initialize();

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants