@15311494814
2017-12-18T07:10:01.000000Z
字数 4502
阅读 497
亲健康追加接口
[get] rest/hBloodpressureController/countmonth/{userid}/{field}/{year}
//{用户id,字段:(),年份(2017...)
field:{bp_sys|bp_dia|bp_pulse}
{
"result": [
{
"month": 10,
"field": "bp_sys",
"max": "5",
"min": "1",
"avg": "1.67"
},
{
"month": 11,
"field": "bp_sys",
"max": "1",
"min": "1",
"avg": "1.00"
}
],
"statusCode": "000000",
"error": ""
}
[get] rest/hBloodoxygenController/countmonth/{userid}/{field}/{year}
//{用户id,字段:(),年份(2017...)
field:{bo_xy , bo_mb}
{
"result": [
{
"month": 11,
"field": "bo_xy",
"max": "98",
"min": "96",
"avg": "96.46"
}
],
"error": "",
"statusCode": "000000"
}
[get] rest/hEartemperatureController/countmonth/{userid}/{year}
//{用户id,字段:(),年份(2017...)
{
"result": [
{
"month": 10,
"field": "eartemp_temp",
"max": "3",
"min": "3",
"avg": "3.00"
},
{
"month": 11,
"field": "eartemp_temp",
"max": "1",
"min": "1",
"avg": "1.00"
}
],
"error": "",
"statusCode": "000000"
}
[get] rest/hWeightBodyfatController/countmonth/{userid}/{field}/{year}
//{用户id,字段:(),年份(2017...)
*field:{"body_weight|body_fat_ratio|body_muscle_mass|body_moisture|body_bmi|
body_bmr|body_bone_mass|body_visceral_fat"};
{
"result": [
{
"month": 11,
"field": "body_weight",
"max": "79.6",
"min": "44.1",
"avg": "67.89"
}
],
"error": "",
"statusCode": "000000"
}
[get] rest/hUrineTestController/countmonth/{userid}/{field}/{year}
//{用户id,字段:(),年份(yyyy)
field:{leu|nit|ubg|pro|ph|bld|sg|ket|bil|glu|vc}
{
"result": [
{
"month": 11,
"field": "leu",
"max": "2",
"min": "2",
"avg": "2.00"
}
],
"error": "",
"statusCode": "000000"
}
[get] rest/hElectrocardingraphyController/countmonth/{userid}/{year}
//{用户id,字段:(),年份(yyyy)
{"result":[{"month":11,"field":"hr","max":"88","min":"3","avg":"64.12"}],"error":"","statusCode":"000000"}
[get] rest/hBloodSugarController/countmonth/{userid}/{foodstatus}/{year}
//{用户id,字段:(),年份(yyyy)
{"result":[{"month":10,"field":"foodstatus","max":"7","min":"5.29","avg":"6.81"}],"error":"","statusCode":"000000"}
[get] rest/hBloodSugarController/count/{userid}/{year}
//{用户id,字段:(),年份(yyyy)
{
"result": [
{
"date": "2017-10-23",
"field": "foodstatus",
"max": "5.29",
"min": "5.29",
"avg": "5.29"
}
],
"error": "",
"statusCode": "000000"
}
[post] rest/hBloodSugarController/get
body:{
"userid":"" ,
"startindex":"10",
"pagesize":"3",
"begincreatetime":"2016-12-12 00:00:00",
"endcreatetime":"2018-12-13 00:00:00"
}
result:
{
"result": [
{
"id": "402881475f47fe24015f47fed75a0000",
"result": "7",
"createName": null,
"createBy": null,
"status": "100",
"devicesn": "2AH4MHR0886",
"createdateBegin": null,
"createdateEnd": null,
"foodstatus": "8",
"sysOrgCode": null,
"sysCompanyCode": null,
"updateName": null,
"updateBy": null,
"page": 1,
"updateDate": null,
"rows": 10,
"realname": null,
"code": "31215087291631",
"userId": "402881035ebd51e0015ebd5353590001",
"unit": "0",
"aimstatus": "5",
"openid": "",
"testtime": "2017-10-25 11:25:25",
"usercode": "100114",
"createtime": "2017-10-25 11:26:03",
"time": null,
"token": null
}
],
"error": "",
"statusCode": "000000"
}
[post] rest/hBloodFatController
body:{
"userid":"",//用户id
"token":"",
"chol":"",//胆固醇
"trig":"",//甘油三脂
"hdl_chol":"",//高密度蛋白质
"calc_ldl":"",//低密度蛋白质
"tc_hdl":"",//
"source":"",//数据来源(ios,android,wx)
"boundtype":"",//绑定类型,暂时只有bluetooth
"name":"",//设备名称
}
result:{
"result": {
"name": "apple watch 38mm",
"id": "ff8080816063cfce016063d2a2130000",
"chol": "10",
"trig": "2",
"hdlChol": "3",
"calcLdl": "2",
"tcHdl": "1",
"source": "ios",
"userid": "8af4dd1c5f46eeb3015f471d693c0024",
"createDate": 1513503236619,
"boundtype": "bluetooth"
},
"error": "",
"statusCode": "000000"
}
error:{"result":"","error":"result丢失","statusCode":"666666"}
[get] rest/hBloodFatController/{id}
result:{"result":{},"error":"","statusCode":"000000"}
[post] rest/hBloodFatController/get
body:{
"userid":"",//用户id
"startindex":"",//起始下标,分页用
"pagesize":"",//每页条数
"begincreatetime":"2017-01-01 12:01:21" ,
"endcreatetime":"2017-01-01 12:01:21"
}
result:{"result":[{}],"statusCode":"000000","error":""}
delete] rest/hBloodFatController/{id}
result:{"result":"ok","error":"","statusCode":"000000"}
[get] rest/hBloodFatController/count/{userid}/{field}/{starttime}/{endtime}
//{用户id,字段:(),开始时间(yyyy-MM-dd) 结束时间(yyyy-MM-dd)}
field:{chol | trig | hdl_chol| calc_ldl | tc_hdl}
result:{
"result": [
{
"date": "2017-10-20",
"field": "chol",
"max": "5",
"min": "1",
"avg": 3
},
{
"date": "2017-10-31",
"field": "chol",
"max": "1",
"min": "1",
"avg": 1
}
],
"error": "",
"statusCode": "000000"
}
[get] rest/hBloodFatController/countmonth/{userid}/{field}/{starttime}/{endtime}
//{用户id,字段:(),开始时间(yyyy-MM-dd) 结束时间(yyyy-MM-dd)}
field:{chol | trig | hdl_chol| calc_ldl | tc_hdl}
result:{
"result": [
{
"month": "12",
"field": "chol",
"max": "5",
"min": "1",
"avg": 3
}
],
"error": "",
"statusCode": "000000"
}