Upgrade Access Document更新时间: 2023-05-08 14:42:17

Developer Privacy Upgrade Access Document

From August 1, 2022, new apps will be accessed according to the upgraded service, and existing apps will have 30 days for rectification and transition . Developers must complete the service upgrade before the rectification and transition period ends.


Upgrade description
In response to the privacy compliance requirements outside Mainland China, for users in India, the European Economic Area + the UK, and Russia, cell phone message push services need to meet: app services need to be deployed to local server rooms; data is stored in local databases.
To this end, we have carried out the privacy upgrade to solve possible cross-server room data synchronization problems and enable data to be independent of services in each region.


Different overseas regions/server room definition

Region Scope Server room Region enumeration
Russia The Russian region Russia
India The Indian region India
European Economic Area + the UK European Economic Area countries and the UK Europe
Others Regions other than those listed above Singapore


Impact of not upgrading
1. Devices with persistent connections to Russia/Europe/India will not be able to receive messages from non-local server rooms.
2. Devices with persistent connections to Russia/Europe/India will not be able to query device-related data (referring to whether it is registered/whether it is online/statistics, etc.) from non-local server rooms.
3. The v4 interface fails to send by calling server room outside Mainland China; China's server room sends only to China


Developer access description
This privacy upgrade will have some impact on developers outside Mainland China and require them to make some adjustments accordingly, mainly involving the use of the operating platform, API access, and V4 interface adjustment.


Mi Push operating platform access TODO list
If the developer mainly pushes messages through Mi push operating platform, operators need to: Select the region - user packages by region - create push by region - view push data by region.Privacy upgrade todo list recommendations are as follows:


Single-region apps (apps distributed to only one of the four regions)

  1. Maintain the region information of the server room where the push user package is located
  2. Focus on the operating platform's region selection function, select the exact region when creating a push, and then operate
  3. V4 interface goes offline overseas, and V3 interfaces are used as an alternative

Muti-region apps (apps distributed to more than one of the four regions)

  1. Maintain the region information of the server room where the push user package is located. In particular, the user packages of different regions are maintained separately
  2. Focus on the operating platform's region selection function, and separated pushes need to be created for user packages of different regions
  3. V4 interface goes offline overseas, and V3 interfaces are used as an alternative

API access TODO list
If developers mainly use API for access, they need to specify the user's region (the four regions supported by the privacy upgrade) and deploy the service call message push API interface in the user's corresponding region so that the domain name can be accurately sent to the user's client in the corresponding region after resolution.Privacy upgrade todo list recommendations are as follows:


Single-region apps (apps distributed to only one of the four regions)

  1. Deploy the server in the server room in the user‘s region
  2. Maintain the region information of the server room where the push user package is located
  3. It is recommended to use subdomain names for message push
  4. V4 interface goes offline overseas, and V3 interfaces are used as an alternative

Muti-region apps (apps distributed to more than one of the four regions)

  1. Deploy the server in the server room in the user's region
  2. Maintain the region information of the server room where the push user package is located. In particular, the user packages of different regions are maintained separately
  3. It is recommended to use subdomain names for message push
  4. V4 interface goes offline overseas, and V3 interfaces are used as an alternative

Java SDK access TODO list
If developers mainly use SDK for access, they need to specify the user's region (the four regions supported by the privacy upgrade) and deploy the SDK in the user's corresponding region so that the domain name can be accurately sent to the user's client in the corresponding region after the resolution requested by SDK.Privacy upgrade todo list recommendations are as follows:


Single-region apps (app distributed to only one of the four regions)

  1. Deploy the server in the server room in the user‘s region
  2. Maintain the region information of the server room where the push user package is located
  3. Upgrade the SDK version to 1.0.14, and Java SDK can be downloaded at: https://admin.xmpush.xiaomi.com/en/mipush/downpage/java-http2, select Version 1.0.14 
  4. Modify the SDK part that sets the Region, and change the server rooms set to call Region.other according to the actual needs to: Europe, Russia, India, and Singapore (it is backward compatible and can continue to use other; other request is sent to the Singapore server room, and it is recommended to use Singapore uniformly)
  5. Note that if you are using the localeToRegion() method in the DevTools class to return the Region enumeration, we recommend you to call the new localeToRegionStandardization() method in this class instead (original ohter is changed to Singapore)

Muti-region apps (apps distributed to more than one of the four regions)

  1. Deploy the server in the server room in the user‘s region
  2. Maintain the region information of the server room where the push user package is located. In particular, the user packages of different regions are maintained separately
  3. Upgrade the SDK version to 1.0.14, and Java SDK can be downloaded at: https://admin.xmpush.xiaomi.com/en/mipush/downpage/java-http2, select Version 1.0.14 
  4. Modify the SDK part that sets the Region, and change the server rooms set to call Region.other according to the actual needs to: Europe, Russia, India, and Singapore (it is backward compatible and can continue to use other; other request is sent to the Singapore server room, and it is recommended to use Singapore uniformly)
  5. Note that if you are using the localeToRegion() method in the DevTools class to return the Region enumeration, we recommend you to call the new localeToRegionStandardization() method in this class instead (original other is changed to Singapore)

Introduction of Mi Push operating platform's region selection function
The operating platform has added the region selection, selecting services of different regions' operating platforms. It currently supports the following regions.
Note: If developers provide services to users across regions, e.g. for both Mainland China and Russia users, they need to select Mainland China/Russia separately to use the operating platform

RegionScopeServer room Region enumerationServer room locationSDK document
RussiaThe Russian regionRussiaMoscowRussia
IndiaThe Indian regionIndiaMumbaiIndia
Mainland ChinaMainland ChinaChinaBeijingChina
European Economic Area + the UKEuropean Economic Area and the UKEuropeFrankfurtEurope
OthersRegions other than those listed aboveSingaporeSingaporeSingapore

1. The default region
When the developer enters the operating platform for the first time, the default region is Mainland China when entering from China and others when entering from places outside Mainland China.
2. After the developer selects the region
All subsequent operations on the operating platform are only saved on the server or database in the corresponding region, and services such as push tools and app management are only supported in the selected region.At the same time, the relevant push statistics include only the data statistics of the corresponding region and do not support aggregating data of different regions. If necessary, developers can gather the data themselves.



Language selection description: The operating platform supports both Chinese and English preference options. Before the privacy upgrade, the China's operating platform only supports Chinese and the global operating platform only supports English. After the privacy upgrade, the language only affects the display of the page elements and is irrelevant to the region selected, so it does not affect the specific service logic.
During the rectification period, developers outside Mainland China please select the region: others, which has the forwarding function and will forward messages from other regions to the server room in the corresponding region.
After the upgrade,others will no longer have the forwarding function and the correct region needs to be selected for message push.


Introduction to the maintenance of the server room location information of push's user package
Due to the privacy upgrade, the server room data is isolated and the push user packages need to be categorized by region to create the push.
During the rectification period, we provide developers with interfaces for batch query, and by querying regid's registration area, you can categorize user packages by region. You can refer to
Guide for developers to query the device region
for interface use.(Note: This interface can only obtain the existing users' region information)
After the upgrade, the interface for batch query regid registration region will be offline.
Therefore, to guarantee the effective device and delivery of the push users, we suggest developers save and maintain user packages of different regions for message push by region after finishing the privacy upgrade.
Reminder: If developers push messages to users outside the corresponding region, users will not receive the pushed message.It will not affect the actual delivery number but may affect the delivery rate
We provide the ability to integrate pusher packages and regions by upgrading the Push SDK to the latest version, which is also applicable to Android and IOS. (Note: Users who can obtain regional information after upgrading the SDK are only new users)
Android Reference Documentation:https://dev.mi.com/console/doc/detail?pId=2626
IOS Reference Documentation:https://dev.mi.com/console/doc/detail?pId=98
Push SDK Upgrade Tips:
Initialize the Mi Push service by calling MiPushClient.registerPush. After successful registration, you can receive the registration result in the custom onCommandResult and onReceiveRegisterResult, where the regId is the unique identifier of the current app on the current device. You can upload the regId to your own server to facilitate sending messages to it.
When you get the regId, please use the MiPushClient.getAppRegion(Context context) interface to get the service room location that the current device is connected to. When you send push messages to the device, you need to use the service room location;
(Note that on MIUI devices, the location of service room connected to the device obtained through the getAppRegion interface of MiPushClient may be different from the one you set through the setRegion interface. In this case, be sure to use the service room location obtained through the getAppRegion interface to send push messages. Otherwise the message cannot be delivered)
Introduction to domain name resolution support adjustment
After the upgrade, we will disable the main domain's api.xmpush.global.xiaomi.com request support and provide subdomain name support.Using a subdomain means that developers know users in which region they want to push the message to, and then the message is pushed directly to the user's server room.The specific domain name information is shown in the table below and is used in the same way as api.xmpush.global.xiaomi.com.


Subdomain name information

Region Subdomain name
Russia ru-api.xmpush.global.xiaomi.com
India idmb-api.xmpush.global.xiaomi.com
European Economic Area + the UK fr-api.xmpush.global.xiaomi.com
Others sgp-api.xmpush.global.xiaomi.com

Introduction of push message v4 interface going offline
The v4 interface supports sending messages to China and regions outside Mainland China and does not meet the privacy compliance requirements
This update will take this interface offline, and the message sending interface in the sdk no longer supports cross-server room sending.
Developers can use V3 interfaces as an alternative.
For API requests from China, please use the api.xmpush.xiaomi.com domain name to send messages.
For API requests from outside China, you need to use the subdomain of the corresponding region to send messages in the user's region.
Planned timeframe
1. V4 interface termination time: August 31, 2022
2. Rectification and transition period for developers: August 1, 2022 to August 31, 2022
3. Domain name support adjustment becomes effective: September 1, 2022
4. Cross-server room service is disabled and privacy upgrade is completed: September 7, 2022

文档内容是否有帮助?
有帮助有帮助
无帮助无帮助