How to open developer page with all his apps on AppGallery

560 views Asked by At

we can open this page on playmarket with scheme "market://dev?id=...", but on app gallery its not working. If we try open link like https://appgallery.huawei.com/#/tab/appdetailCommon%1234%7Cautomore%7Cdoublecolumncardwithstar%1234 with startActivity(Intent(Intent.ACTION_VIEW, uri) it open browser, not app gallery.

1

There are 1 answers

5
zhangxaochen On

The following are some common redirection scenarios for your reference.


  1. Redirecting to the AppGallery Home Page

    Use the action method from Intent to implement the function.

action: com.huawei.appmarket.intent.action.MainA

Example:

public void launchAGHomePage() {
     Intent intent = new Intent("com.huawei.appmarket.intent.action.MainActivity");
     startActivity(intent);
 }
  1. Redirecting to an App's Details Page on AppGallery

    Use the action method from Intent to implement the function.

    Method 1: by app ID

action:com.huawei.appmarket.appmarket.intent.action.AppDetail. withid
setPackage("com.huawei.appmarket");
name: "appId", value: "C100170981"

Method 2: by package name

action: com.huawei.appmarket.intent.action.AppDetail
setPackage("com.huawei.appmarket");
name: "APP_PACKAGENAME", value: "com.huawei.browser"

Note: Compared with method 2, method 1 includes additional appmarket and withid parameters from the action method.

  1. Launching All App Stores Installed on a Device to Redirect Users to an App's Details Page in an App Store via MARKET

Pass the link whose scheme is market://. Android supports the standard MARKET protocol, to ensure that all app stores can be launched on Android devices. The methods are as follows:

Method 1: market://details?id=pkgName // for all stores
Method 2: appmarket://details?id=pkgName  // only for AppGallery
Method 3: market://com.huawei.appmarket.applink?appId=App ID" // only for AppGallery

Note: Method 1 is a standard method for Android devices, and is applicable to all app stores, such as Google Play and Tecent Appstore.

For more detail,pls kindly check this link.