Skip to content

Instantly share code, notes, and snippets.

@jialechan
Last active December 13, 2016 06:06
Show Gist options
  • Save jialechan/2787d1d60be98e258198c80d4c02793e to your computer and use it in GitHub Desktop.
Save jialechan/2787d1d60be98e258198c80d4c02793e to your computer and use it in GitHub Desktop.

查找用户

接口说明

根据用户国家,年纪,身高,是否结婚等条件过滤查找用户

定义

curl 'http://localhost:49494/admin/ad/create' -H 'Content-Type:application/json' -X POST -d \
'{
    "promotionType": "APP_POP_ADS",
    "addTime": 1481513178676,
    "promotionEnd": 1481772378676,
    "promotionInterval": 10,
    "channel": "INNER",
    "start": true,
    "adUrl": "http://www.baidu.com",
    "pause": false,
    "promotionTimePeriodList": [
        1,
        2
    ],
    "imgUrl": "http://52.76.173.126/images/push-sdk/AppPopAds/800_800.jpg",
    "promotionBegin": 1481685978676,
    "modifyTime": 1481513178676,
    "targetAppList": [
        "com.facebook",
        "com.twitter"
    ],
    "allCountry": true,
    "name": "应用内插屏广告1",
    "promotionUpperLimit": 100,
    "allOperators": true
}'

请求参数说明

参数名 必要参数 限制 说明
country 必须 长度边界[1 : 20] 用户所在国家
age 必须 必须大于或等于0
必须小于或等于120
必须为一个整型数字
年龄

正确返回

{
	"code":"code",
	"pages":{
		"totalPage":0,
		"version":"version"
	},
	"tels":["string"],
	"urls":[
		"string"
	],
	"users":[
		{
			"age":0,
			"country":"country",
			"height":0,
			"isMarried":false,
			"name":"name"
		}
	]
}

正确返回参数说明

参数名 必要参数 说明
code 必须 状态码, 0:完成
pages 可选 结果的分页信息
    totalPage 可选 结果共有都少页
    version 可选 结果集的版本号
tels 可选 电话字符串列表
urls 可选 url的字符串列表
users 可选 查找返回的用户列表
    age 必须 年龄
    country 必须 用户所在国家
    height 必须 身高
    isMarried 可选 是否已婚
    name 必须 用户名称
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment