8 Comments

  • song donghao
    Comment actions Permalink

    Our app used Token-based way to use APNs, do you support this way?

    0
  • Greg - Community Manager
    Comment actions Permalink

    Hi Song, at this time, we do not support token-based APNs. You would need to use the methods described in this article.

    Greg Katechis | Developer Support and Enablement Engineer

    0
  • Gabriel
    Comment actions Permalink

    Hi, can anybody confirm that this code is right?

    - (void)userNotificationCenter:(UNUserNotificationCenter *)center didReceiveNotificationResponse:(UNNotificationResponse *)response withCompletionHandler:(void(^)())completionHandler{
    [ZDKChat didReceiveRemoteNotification:userInfo in:application];
    completionHandler();
    }

    I'm not an iOS developer (I'm making React Native app), and XCode is saying that userInfo and application are not defined, which makes sense for me, so I'm using this code:

    - (void) application:(UIApplication*)application didReceiveRemoteNotification:(NSDictionary*)userInfo {
      [ZDKChat didReceiveRemoteNotification:userInfo in:application];
    }

    Am I right? the code still not working for me, but at least I'll be one step farther to make it work :)

    0
  • Gabriel
    Comment actions Permalink

    Ok, now I can verify that the code was wrong, the code should be this:

    - (void)userNotificationCenter:(UNUserNotificationCenter *)center

    didReceiveNotificationResponse:(UNNotificationResponse *)response

             withCompletionHandler:(void (^)(void))completionHandler

    {

      NSDictionary* userInfo = response.notification.request.content.userInfo;

      UIApplication* application = UIApplication.sharedApplication;

      [ZDKChat didReceiveRemoteNotification:userInfo in:application];

      completionHandler();

    }
    0
  • Daniel Conway
    Comment actions Permalink

    Nice work, Gabriel! This is super helpful.

    0
  • Ilya
    Comment actions Permalink

    > Hi Song, at this time, we do not support token-based APNs. You would need to use the methods described in this article.

    The deadline to upgrade to the APNs provider API has been extended to March 31, 2021. APNs will no longer support the legacy binary protocol after this date.

    So, push notifications become broken after 31 of March?

    0
  • Serban Bajdechi
    Comment actions Permalink

    I am having an issue on iOS where i get the zd.chat.end message, but i do not get the zd.chat.msg. what would be the case in this would happen? Chat logs report as dissconnected.

    0
  • Eric Nelson
    Comment actions Permalink

    Hey Serban,

    Is this issue for in-app notifications or device level push notifications?

    Have a wonderful day!

    Eric Nelson | Manager - Developer Advocacy

    0

Please sign in to leave a comment.

Powered by Zendesk