All Products
Search
Document Center

Message push through OPPO Push failed

Last Updated: Jul 13, 2021

In case of OPPO channel message push failure, refer to the following steps for troubleshooting:

  1. Make sure that you have successfully integrated OPPO PUSH by following the instructions in Access OPPO Push. The main steps include:

    1. Download the library of OPPO Push SDK and import it to project;
    2. Add the Push - OPPO component;
    3. Configure AndroidManifest.xml in the project;
    4. Integrate the MpaaSNcActivity class.
      Note:
  2. Check if the SDK version corresponding to OPPO PUSH mcssdk-2.xx.jar is correct.

    • For mPaaS baseline 10.1.68.29 or later versions, please use OPPO PUSH SDK V2.1.0 (mcssdk-2.1.0.jar).
    • For mPaaS baseline earlier than 10.1.68.29, please use OPPO PUSH SDK V2.0.2 (mcssdk-2.0.2.jar).
  3. Check if the service classes in AndroidManifest.xml are correctly configured. The service classes required vary with the SDK version.

    • For OPPO PUSH SDK V2.0.2 (mPaaS baseline earlier than 10.1.68.29), the corresponding service classes are com.heytap.mcssdk.PushService and com.heytap.mcssdk.AppPushService. The configuration is as follows:
           
      1. <uses-permission android:name="com.coloros.mcs.permission.RECIEVE_MCS_MESSAGE" />
      2. <uses-permission android:name="com.heytap.mcs.permission.RECIEVE_MCS_MESSAGE"/>
      3. <application>
      4. <!-- V2.0.2 Add Service START-->
      5. <service
      6. android:name="com.heytap.mcssdk.PushService"
      7. android:permission="com.coloros.mcs.permission.SEND_MCS_MESSAGE"
      8. android:process=":push">
      9. <intent-filter>
      10. <action android:name="com.coloros.mcs.action.RECEIVE_MCS_MESSAGE"/>
      11. </intent-filter>
      12. </service>
      13. <service
      14. android:name="com.heytap.mcssdk.AppPushService"
      15. android:permission="com.heytap.mcs.permission.SEND_MCS_MESSAGE"
      16. android:process=":push">
      17. <intent-filter>
      18. <action android:name="com.heytap.mcs.action.RECEIVE_MCS_MESSAGE"/>
      19. </intent-filter>
      20. </service>
      21. <!-- V2.0.2 Add Service END-->
      22. <meta-data
      23. android:name="com.oppo.push.app_key"
      24. android:value="Obtain from OPPO Developer Platform"
      25. />
      26. <meta-data
      27. android:name="com.oppo.push.app_secret"
      28. android:value="Obtain from OPPO Developer Platform"
      29. />
      30. </application>
    • For OPPO PUSH SDK V2.1.0 (mPaaS baseline is 10.1.68.29 or later version), the corresponding service classes are com.heytap.msp.push.service.CompatibleDataMessageCallbackService and com.heytap.msp.push.service.DataMessageCallbackService. The configuration is as follows:
           
      1. <uses-permission android:name="com.coloros.mcs.permission.RECIEVE_MCS_MESSAGE" />
      2. <uses-permission android:name="com.heytap.mcs.permission.RECIEVE_MCS_MESSAGE"/>
      3. <application>
      4. <!-- V2.1.0 Add Service START-->
      5. <service
      6. android:name="com.heytap.msp.push.service.CompatibleDataMessageCallbackService"
      7. android:permission="com.coloros.mcs.permission.SEND_MCS_MESSAGE"
      8. android:process=":push">
      9. <intent-filter>
      10. <action android:name="com.coloros.mcs.action.RECEIVE_MCS_MESSAGE"/>
      11. </intent-filter>
      12. </service>
      13. <service
      14. android:name="com.heytap.msp.push.service.DataMessageCallbackService"
      15. android:permission="com.heytap.mcs.permission.SEND_PUSH_MESSAGE"
      16. android:process=":push">
      17. <intent-filter>
      18. <action android:name="com.heytap.mcs.action.RECEIVE_MCS_MESSAGE"/>
      19. <action android:name="com.heytap.msp.push.RECEIVE_MCS_MESSAGE"/>
      20. </intent-filter>
      21. </service>
      22. <!-- V2.1.0 Add Service END-->
      23. <meta-data
      24. android:name="com.oppo.push.app_key"
      25. android:value=" Obtain from OPPO Developer Platform"
      26. />
      27. <meta-data
      28. android:name="com.oppo.push.app_secret"
      29. android:value=" Obtain from OPPO Developer Platform "
      30. />
      31. </application>