跳到主要内容
版本:202607

查询订单数量

GET 

/openapi/2026-07/orders/count

返回符合指定查询条件的订单总数。

请求

Query参数

    ids string[]

    根据订单 ID 过滤。 示例:?ids=1001&ids=1002

    status string[]

    按订单状态过滤。

    • opened: 待支付。
    • cancelled: 已取消。
    • placed: 进行中。
    • finished: 已完成。 示例:?status=opened&status=finished
    fulfillment_status string[]

    按订单物流状态过滤。

    • initialled: 初始。
    • waiting: 待发货。
    • partially_shipped: 部分发货。
    • shipped: 全部发货。
    • partially_finished: 部分收货。
    • finished: 全部收货。
    • cancelled: 已取消。
    • returning: 退货中。
    • partially_returned: 部分退货。
    • returned: 全部退货。 示例:?fulfillment_status=waiting&fulfillment_status=shipped
    financial_status string[]

    按支付状态过滤。

    • waiting: 待支付。
    • paying: 支付审核中。
    • authorized: 已授权。
    • partially_paid: 部分支付。
    • paid: 已支付。
    • cancelled: 已取消。
    • failed: 支付失败。
    • refunding: 退款中。
    • refund_failed: 退款失败。
    • refunded: 已全退。
    • partially_refunded: 部分退。 示例:?financial_status=waiting&financial_status=paid
    recovery_status string[]

    按召回状态过滤。 示例:?recovery_status=value1&recovery_status=value2

    location_id string

    按地址 ID 过滤

    keyword string

    搜索关键字

    keyword_scope_fields string[]

    搜索关键字的适用字段范围。 示例:?keyword_scope_fields=order_no&keyword_scope_fields=email

    customer_id string

    按顾客 ID 过滤

    total_min double

    订单金额最小值

    total_max double

    订单金额最大值

    created_at_min string

    创建时间起始值

    created_at_max string

    创建时间结束值

    updated_at_min string

    更新时间起始值

    updated_at_max string

    更新时间结束值

    placed_at_min string

    下单时间起始值

    placed_at_max string

    下单时间结束值

    sales_platform string[]

    按销售渠道过滤。 示例:?sales_platform=value1&sales_platform=value2

    admin_hasfilter boolean

    同 B 端未完成订单的 has_filter 过滤规则。

    • true: 应用过滤条件。
    • false: 不应用过滤条件。
    finished_at_min string

    完成时间起始值

    finished_at_max string

    完成时间结束值

    fulfilled_at_min string

    履约完成时间起始值

    fulfilled_at_max string

    履约完成时间结束值

    last_referrer_show_created_at_min string

    按最后一次互动来源时间过滤的起始值(如 2018-11-02T12:30:10Z)

    last_referrer_show_created_at_max string

    按最后一次互动来源时间过滤的结束值(如 2018-11-02T12:30:10Z)

    source_name_created_at_min string

    按首次互动来源时间过滤的起始值(如 2018-11-02T12:30:10Z)

    source_name_created_at_max string

    按首次互动来源时间过滤的结束值(如 2018-11-02T12:30:10Z)

    shipping_emails string[]

    按收货地址邮箱过滤。 示例:?shipping_emails=[email protected]&shipping_emails=[email protected]

    shipping_phones string[]

    按收货地址手机号过滤。 示例:?shipping_phones=13800000001&shipping_phones=13800000002

    browser_ips string[]

    按下单 IP 地址过滤。 示例:?browser_ips=1.2.3.4&browser_ips=5.6.7.8

    product_ids string[]

    按商品 ID 过滤。 示例:?product_ids=2001&product_ids=2002

    skus string[]

    按 SKU 过滤。 示例:?skus=SKU0001&skus=SKU0002

    spus string[]

    按 SPU 过滤。 示例:?spus=SPU0001&spus=SPU0002

    order_tags string[]

    按订单标签过滤。 示例:?order_tags=vip&order_tags=new

    customer_emails string[]

    按顾客邮箱过滤。 示例:?customer_emails=[email protected]&customer_emails=[email protected]

    fuzzy_fields string[]

    模糊匹配的字段名列表,与 fuzzy_keywords / fuzzy_relation 联合使用。 可选值:

    • name:顾客名称(非收货人名称)
    • number:订单编号
    • id:订单 ID
    • sku:商品 SKU(快照数据)。精确匹配请改用 skus
    • spu:商品 SPU(快照数据)。精确匹配请改用 spus
    • tag_list:订单标签。精确匹配请改用 order_tags
    • shipping_email:收货地址邮箱。精确匹配请改用 shipping_emails
    • shipping_phone:收货地址手机号。精确匹配请改用 shipping_phones
    • browser_ip:下单 IP。精确匹配请改用 browser_ips
    • product_tags:商品标签(快照数据)
    • product_title:商品标题(快照数据)
    • credit_card_number:支付卡号后四位
    • source:首次访问落地页
    • source_name:首次访问来源
    • tracking_number:物流单号
    • shipping_line_name:物流方案名称
    • line_item_vendor:商品供应商
    • discount_code:优惠码
    • shipping_address_extra_info:特殊物流字段信息
    • transaction_id:支付交易号
    • customer_id:顾客 ID
    • last_landing_url:最后访问落地页
    • last_referrer_show:最后访问来源
    • country:国家名称(快照数据,不支持中英文任意搜索)
    • shop_name:POS 店铺名称
    • staff_contact:POS 员工 注:当字段同时存在精确匹配数组参数(sku/spu/tag_list/shipping_email/shipping_phone/browser_ip)时, 完整值查找请走对应数组参数;fuzzy 仅用于前缀或片段搜索。 示例:?fuzzy_fields=name&fuzzy_fields=number
    fuzzy_keywords string[]

    模糊关键字列表,任一关键字在 fuzzy_fields 任一字段命中即视为匹配。 示例:?fuzzy_keywords=iphone&fuzzy_keywords=vip

    fuzzy_relation string

    fuzzy_fields 字段之间的关系:"and" 或 "or",默认 "or"

响应

OK

数据结构
    codestring

    错误码

    messagestring

    错误信息

    data object
    countint32

    符合过滤条件的订单总数