文档中心 > API类目 > 阿里健康-本地医疗-通用渠道

alibaba.alihealth.medical.channel.inventory.calendar.query (日历库存查询)

日历库存查询

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
jk_item_id String 必须 1234 健康商品id
jk_store_id String 必须 2345 门店id
inventory_date_range_from String 必须 2021-12-17 起始时间,含当日
inventory_date_range_to String 必须 2021-12-27 结束时间,含当日,不大于起始时间60天
source String 必须 ITEM 请求来源

响应参数

名称 类型 示例值 描述
data InventoryCalendarVO 结果
  • └ support_time_slice_inventory
  • Boolean
  • true
  • 是否支持时间片库存
  • inventory_quantity_details
  • InventoryQuantityDetail []
  • 库存详情
  • └ inventory_date
  • String
  • 2022-01-01
  • 日期yyyy-MM-dd
  • └ total_amount
  • Number
  • 20
  • 库存总量
  • └ used_amount
  • Number
  • 12
  • 已使用量
msg_info String 请求成功 错误信息
msg_code String SUCCESS 错误码

请求示例

  • JAVA
  • .NET
  • PHP
  • CURL
  • Python
  • C/C++
  • NodeJS
TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
AlibabaAlihealthMedicalChannelInventoryCalendarQueryRequest req = new AlibabaAlihealthMedicalChannelInventoryCalendarQueryRequest();
req.setJkItemId("1234");
req.setJkStoreId("2345");
req.setInventoryDateRangeFrom("2021-12-17");
req.setInventoryDateRangeTo("2021-12-27");
req.setSource("ITEM");
AlibabaAlihealthMedicalChannelInventoryCalendarQueryResponse rsp = client.execute(req);
System.out.println(rsp.getBody());

响应示例

  • XML示例
  • JSON示例
<alibaba_alihealth_medical_channel_inventory_calendar_query_response>
    <data>
        <support_time_slice_inventory>true</support_time_slice_inventory>
        <inventory_quantity_details>
            <inventory_quantity_detail>
                <inventory_date>2022-01-01</inventory_date>
                <total_amount>20</total_amount>
                <used_amount>12</used_amount>
            </inventory_quantity_detail>
        </inventory_quantity_details>
    </data>
    <msg_info>请求成功</msg_info>
    <msg_code>SUCCESS</msg_code>
</alibaba_alihealth_medical_channel_inventory_calendar_query_response>

异常示例

  • XML示例
  • JSON示例
<error_response>
    <code>50</code>
    <msg>Remote service error</msg>
    <sub_code>isv.invalid-parameter</sub_code>
    <sub_msg>非法参数</sub_msg>
</error_response>

错误码解释

错误码 错误描述 解决方案

API工具

如何获得此API

FAQ

返回
顶部