文档中心 > API类目 > 闲鱼电商SAAS

alibaba.logistics.idlefish.ship.bill.query.list (寄件账单批量查询)

按寄件单号或下单时间查询寄件账单,用于对账

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
idle_fish_ship_bill_query_request IdleFishShipBillQueryRequest 可选 寄件账单批量查询请求,寄件单号与时间范围二选一
  • └ service_type
  • Number
  • 必须
  • 1001
  • 寄件服务类型,平台颁发,本期仅 1001(闲鱼大盘申通寄件 3PL)
  • └ order_id_list
  • String []
  • 可选
  • 22648510111421501
  • 寄件单号列表,上限 20。与时间范围二选一,都传时优先本字段
  • └ create_time_start
  • String
  • 可选
  • 2026-08-01 00:00:00
  • 下单时间起,格式 yyyy-MM-dd HH:mm:ss
  • └ create_time_end
  • String
  • 可选
  • 2026-08-20 23:59:59
  • 下单时间止,格式 yyyy-MM-dd HH:mm:ss。与起始时间跨度不超过 31 天
  • └ page_no
  • Number
  • 可选
  • 1
  • 页码,从 1 起。按时间范围查询时使用
  • └ page_size
  • Number
  • 可选
  • 20
  • 每页条数。按时间范围查询时使用

响应参数

名称 类型 示例值 描述
result IdleFishShipBillQueryResult 寄件账单批量查询结果
  • └ success
  • Boolean
  • true
  • 是否成功,仅全部成功为 true
  • └ error_code
  • String
  • isv.invalid-parameter
  • 错误码,失败时返回
  • └ error_msg
  • String
  • 时间范围超过31天
  • 错误信息,请按 errorCode 判断,不要匹配文案
  • data
  • IdleFishShipBillQueryData
  • 账单业务数据
  • bill_list
  • IdleFishShipBillItem []
  • 账单列表
  • └ order_id
  • String
  • 22648510111421501
  • 寄件单号,不是运单号
  • └ create_time
  • String
  • 2026-08-20 12:00:00
  • 寄件下单时间,格式 yyyy-MM-dd HH:mm:ss
  • └ mail_no
  • String
  • 7731234567890
  • 运单号,未取号时为空
  • fee_detail
  • IdleFishShipFeeDetailDto
  • 费用明细,无费用时为空
  • └ charge_weight
  • Number
  • 1000
  • 计费重量,克
  • └ total_fee
  • Number
  • 1200
  • 应付总金额,分 = 基础运费 + 全部增值服务费,不扣优惠。以本字段为准,不要自行累加
  • └ actual_pay_fee
  • Number
  • 1000
  • 实付总金额,分 = 应付 − 抵扣。未支付时为空,表示尚未支付
  • └ first_weight
  • Number
  • 1000
  • 首重重量(报价口径),克
  • └ first_weight_unit_price
  • Number
  • 1200
  • 首重报价,分。语义:首重 first_weight 克收该金额
  • └ continue_weight_step
  • Number
  • 1000
  • 续重计价刻度,克
  • └ continue_weight_unit_price
  • Number
  • 200
  • 续重报价,分。语义:每 continue_weight_step 克加收该金额
  • └ first_weight_fee
  • Number
  • 1200
  • 首重实收金额,分
  • └ continue_weight_fee
  • Number
  • 0
  • 续重实收金额,分
  • └ discount_fee
  • Number
  • 200
  • 全部抵扣总额,分(不区分优惠券/权益)
  • └ pay_status
  • Number
  • 0
  • 支付状态,0 未支付、1 已支付、2 支付失败、3 已退款。未出账,支付状态为空
  • └ order_status
  • Number
  • 1
  • 寄件单状态,-1 已取消、1 已创建、2 已完结。已创建是聚合态,不提供轨迹
  • └ page_no
  • Number
  • 1
  • 当前页码
  • └ page_size
  • Number
  • 20
  • 每页条数
  • └ total_count
  • Number
  • 1
  • 总条数

请求示例

  • JAVA
  • .NET
  • PHP
  • CURL
  • Python
  • C/C++
  • NodeJS
TaobaoClient client = new DefaultTaobaoClient(url, appkey, secret);
AlibabaLogisticsIdlefishShipBillQueryListRequest req = new AlibabaLogisticsIdlefishShipBillQueryListRequest();
AlibabaLogisticsIdlefishShipBillQueryListRequest.IdleFishShipBillQueryRequest obj1 = new AlibabaLogisticsIdlefishShipBillQueryListRequest.IdleFishShipBillQueryRequest();
obj1.setServiceType(1001L);
obj1.setOrderIdList("22648510111421501");
obj1.setCreateTimeStart("2026-08-01 00:00:00");
obj1.setCreateTimeEnd("2026-08-20 23:59:59");
obj1.setPageNo(1L);
obj1.setPageSize(20L);
req.setIdleFishShipBillQueryRequest(obj1);
AlibabaLogisticsIdlefishShipBillQueryListResponse rsp = client.execute(req, sessionKey);
System.out.println(rsp.getBody());

响应示例

  • XML示例
  • JSON示例
<alibaba_logistics_idlefish_ship_bill_query_list_response>
    <result>
        <success>true</success>
        <error_code>isv.invalid-parameter</error_code>
        <error_msg>时间范围超过31天</error_msg>
        <data>
            <bill_list>
                <idle_fish_ship_bill_item>
                    <order_id>22648510111421501</order_id>
                    <create_time>2026-08-20 12:00:00</create_time>
                    <mail_no>7731234567890</mail_no>
                    <fee_detail>
                        <charge_weight>1000</charge_weight>
                        <total_fee>1200</total_fee>
                        <actual_pay_fee>1000</actual_pay_fee>
                        <first_weight>1000</first_weight>
                        <first_weight_unit_price>1200</first_weight_unit_price>
                        <continue_weight_step>1000</continue_weight_step>
                        <continue_weight_unit_price>200</continue_weight_unit_price>
                        <first_weight_fee>1200</first_weight_fee>
                        <continue_weight_fee>0</continue_weight_fee>
                        <discount_fee>200</discount_fee>
                    </fee_detail>
                    <pay_status>0</pay_status>
                    <order_status>1</order_status>
                </idle_fish_ship_bill_item>
            </bill_list>
            <page_no>1</page_no>
            <page_size>20</page_size>
            <total_count>1</total_count>
        </data>
    </result>
</alibaba_logistics_idlefish_ship_bill_query_list_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

返回
顶部