Get Regional Distribution Details

Last Updated on : 2023-07-28 06:26:47download

Get the regional distribution details of activated devices based on the time format, product, and regional type. The details of cities are not included in the country and region data.

API address

GET: /v1.1/devices/locations-active-datas

Request parameter

Parameter nameTypeINRequiredDescription
date_typeStringquerytrueThe time format. Valid values:
  • day: day
  • week: week
  • weeks: two weeks
  • month: month
product_idStringqueryfalseThe product ID. If you do not set the parameter, all your product IDs will be returned.
typeStringquerytrueThe scope of the region. Valid values:
  • country: country/region
  • province: province
  • city: city
limitIntegerquerytrueThe limit. Valid values: 0 to 100.

Return parameter

Parameter nameTypeDescription
resultJSONArrayThe returned result.

Description of result

Parameter nameTypeDescription
percentageStringThe number of regional activated devices divided by the total number of activated devices.
nameStringThe name of the region.
valueIntegerThe total number of activated devices in the region.

Request example

GET: /v1.1/devices/locations-active-datas?date_type=week&productId=123&type=province&limit=3

Return example

    "result": [
            "percentage": "25.00%",
            "name": "Hunan Province",
            "value": 2
            "percentage": "25.00%",
            "name": "Others",
            "value": 2
    "t": 1544411872724,
    "success": true

Error code

For more information, see error code.