药品信息同步
接口描述
可通过本接口实现实时同步药品的价格和药品的库存信息以及批号的修改
接口说明
仅可同步脉景平台中已导入或配置的合作药房药品库存信息, 如合作药房需要新增药品品种,则无法直接通过该接口进行新增药品信息的同步, 须先行在脉景平台导入或配置该新增药品品种;
接入点: his提供地址
请求方法: GET
请求参数位置: Http Headers
请求参数详情:
字段名 | 类型 | 是否必填 | 详细 |
---|---|---|---|
biz_user_id | string | 是 | 脉景PC分配给HIS用户的唯一编号 |
返回参数位置: HTTP Body
返回参数格式: JSON
返回参数详情(由HIS前置服务器API返回):
字段名 | 类型 | 何时返回 | 详细 |
---|---|---|---|
success | boolean | 总是 | 调用是否成功 |
code | number | 总是 | 返回的HTTP状态码 |
message | string | 成功或是已知的失败原因时 | 成功或失败原因的消息 |
data | array | 成功时 | 药品数据列表 |
data 中item:
字段名 | 类型 | 何时返回 | 详细 |
---|---|---|---|
name | string | 总是 | 药品名称 |
medicine_code | string | 总是 | 商家药品编码 |
specification | number | 总是 | 装量 |
retail_unit | string | 总是 | 零售单位 |
supply_price | number | 总是 | 供货价 |
floor_price | number | 总是 | 成本价 |
batch_number | string | 总是 | 药品批次 |
storage | number | 总是 | 药品库存 |
storage_code | string | 总是 | 药品库存编码 |
示例:
假设his前置服务器地址为10.10.12.13, 端口为8080
HIS用户编号: 152da0f61d4f11ea84ee00163e08eb19
Request URL: http://10.10.12.13:8080/medicine_sync/?biz_user_id=152da0f61d4f11ea84ee00163e08eb19
Request Method: GET
Content-type: application/json
Response Payload:
合作方返回示例
{
"success": true,
"code": 200,
"message": "",
"data": [
{
"name": "阿胶",
"medicine_code": "79172",
"specification": 1.0,
"retail_unit": "粒",
"supply_price": 8.33,
"floor_price": 8.33,
"batch_number": "202101190833",
"storage": 833.0,
"storage_code": "20210333-sduwsdd123424"
},
{
"name": "生白芍",
"medicine_code": "79174",
"specification": 1.0,
"retail_unit": "粒",
"supply_price": 8.33,
"floor_price": 8.33,
"batch_number": "202101190833",
"storage": 833.0,
"storage_code": "20210333-sduwsdd123424"
}
]
}