All Products
Search
Document Center

Mobile Platform as a Service:Integrate vivo Push

Last Updated:Jul 20, 2023

This guide mainly introduces the process of integrating vivo Push. The process falls into three steps:

  1. Register vivo Push

  2. Integrate vivo Push

  3. Test vivo Push

Register vivo Push

Register an account on the vivo Developers Platform and request to integrate the push service with reference to vivo Push Platform Operation Guide.

Integrate vivo Push

  1. Add Push - vivo component in the IDE plugin. The steps are roughly the same as adding MPS SDK, see Add SDK.

    The component has integrated the vivo Push SDK V2.3.4. You can upgrade the vivo Push SDK on demand. Generally, the vendor's SDK is downward compatible. If it is not compatible, you can submit a ticket about the adaption issue.

  2. Configure AndroidManifest.xml, and replace the values of com.vivo.push.api_key and com.vivo.push.app_id. If you integrate the vivo Push SDK through Portal & Bundle projects, please configure the AndroidManifest.xml in the Portal project.

     <application>
         <service
             android:name="com.vivo.push.sdk.service.CommandClientService"
             android:process=":push"
             android:exported="true" />
         <activity
             android:name="com.vivo.push.sdk.LinkProxyClientActivity"
             android:exported="false"
             android:process=":push"
             android:screenOrientation="portrait"
             android:theme="@android:style/Theme.Translucent.NoTitleBar" />
         <meta-data
             android:name="com.vivo.push.api_key"
             android:value="Provided by vivo Developers Platform" />
         <meta-data
             android:name="com.vivo.push.app_id"
             android:value="Provided by vivo Developers Platform" />
     </application>
  3. To use obfuscation, you need to add the related obfuscation configurations.

Test vivo Push

  1. After integrating vivo Push, you can start the app on your vivo phone, and the MPS SDK will automatically get the OPPO Push token and report it. Before you start the app, make sure that you have called the initialization method, see Message push initialization.

  2. Push test messages when the app process is killed:

    • If you can still receive the messages, it means that the app has successfully integrated vivo Push.

    • If you cannot receive the messages, you can follow the steps below for troubleshooting.

Troubleshooting

  1. Check if AndroidManifest.xml has related configurations added, and check if the values of com.vivo.push.api_key and com.vivo.push.app_id are the same as that on vivo Developers Platform.

  2. Check if vivo Push is enabled in the mPaaS console (see Configure vivo Push), and the relevant configurations are consistent with that on vivo Developers Platform.

  3. View the logs in Logcat to troubleshoot:

    1. Select the push process, filter mPush.PushProxyFactory, and check if the following log exists:

      D/mPush.PushProxyFactory: found proxy com.mpaas.push.external.vivo.Creator

      If not, it means that there may be a problem with the Push - vivo component. Check if the component has been correctly added.

    2. Select the push process, filter mVIVO, and check if the channel token of vivo Push has been obtained. If the following log “fail to turn on vivo push” appears:

      It means the vivo Push registration failed, see vivo Push Error Codes.

    3. Select the main process, filter report channel token, check if the channel token of vivo Push has been successfully reported. If the following log appears:

      report channel token error: xxxx

      It means the channel token reporting failed, you need to check if the base64Code in the mPaaS configuration file has a value, and check if the apk signature that you uploaded when obtaining the configuration file is consistent with the app.

  4. If the above steps do not resolve the issue, please search for the group number 31591197 with DingTalk to join DingTalk group for further communication.

FAQ

Models and OS versions supported by vivo Push

The models and earlier system versions supported by vivo Push are listed in the following table. For other questions on vivo Push, see vivo Push FAQs.

1