概述
根据提供的区域id、开始时间、结束时间和时间粒度查询当前时间段内的年龄、性别、来源地等画像数据。
请求URL和参数
该请求为POST请求
bigdata/realtime/v1.1/userprofileinterval
该请求参数为json格式
{"id":"8","begin":1494043200,"end":1494129600,"type":"1,2,3","key":"xxx"}
请求参数字段说明
| 名称 | 描述 | 类型 | 备注 |
|---|---|---|---|
| id | 区域id | string | 无 |
| begin | 查询开始时间 | integer | 精确到秒的整型,从整点开始到整点结束,时间跨度不超过两天 |
| end | 查询结束时间 | integer | 精确到秒的整型,从整点开始到整点结束,时间跨度不超过两天 |
| type | 区域画像类别,可组合 | string | 1:年龄 2:性别 3:来源地(全国精确到市) 4:来源地(本市的县城) 5:消费能力 6:学历 7:有车用户 8:健身用户 9:理财类用户 10:手机类型 组合以逗号分隔 1,2:年龄+性别。当时间段内人数<100时,画像接口不输出 |
| key | 开发密钥 | string | 待分配 |
响应字段说明
| 名称 | 描述 | 类型 | 备注 |
|---|---|---|---|
| status | 处理状态码 | integer | 0:正常非0:异常 |
| message | 错误信息 | string | status != 0的时候返回,说明错误信息 |
| data | 人口画像结果。内容构成:{
age:年龄比例(array),gender:性别比例(array),origin:全国市级别来源地比例(array),distict:本市县级别来源地比例(array),consumpting_ability:消费能力(array),
education:学历(array),car:是否有车(array),fitness:是否健身(array),finance:是否理财(array),mobile_phone:手机类型(array)}。 各数组具体构成: 年龄:{property:年龄区间(string),percent:比例(double)} 性别:{property:男/女(string),percent:比例(double)} 来源地:{property:来源地adcode(string),省份province(string),城市city(string),区县district(string),percent:比例(double) 消费能力:{property:消费能力指数 (string),percent:比例(double)} 学历:{property:学历(string),percent:比例(double)} 是否有车:{property:有车/无车(string),percent:比例(double)} 是否健身:{property:健身/非健身(string),percent:比例(double)} 是否理财:{property:理财/不理财(string),percent:比例(double)} 手机类型:{property:Android/iOS(string),percent:比例(double)} |
array | 暂无 |
返回结果示例
{
"status":0,
"data":{
"age":[{
"property":"other",
"percent":0.03341,
},{
"property":"20-29",
"percent":0.376,
}...]
"gender":[{
"property":"female",
"percnet":0.46,
},{
"property":"male",
"percent":0.54
}],
"origin":[{
"property":"110000",
"province":"北京市",
"city":"北京市",
"percnet":0.032
}...]
},"distinct":[{
"property":"110000",
"province":"北京市",
"city":"北京市",
"district":"海淀区",
"percent":0.032
}...]
}
}