qimen.taobao.life.fulfillment.create (本地生活-到店-履约创单)

本地生活-到店-履约创单

公共参数

请求参数

名称 类型 是否必须 示例值 更多限制 描述
trade_info TradeInfo 必须 交易数据,例如订单号、金额、份数等
  • └ quantity
  • Number
  • 必须
  • 2
  • 购买商品份数
  • └ real_amount
  • Number
  • 必须
  • 100
  • 商户实收金额,单位:分。例如值:100,代表1元
  • └ total_amount
  • Number
  • 必须
  • 100
  • 订单原始金额,单位:分。如果1:1,即整个订单的金额;如果多个子单,仅子单的订单总金额
  • └ tp_sub_order_no
  • String
  • 必须
  • 1234567891234567890
  • 订单子单号,订单主子1:1时,主子订单号相同。当前长度19位,建议25位(预留6位)
  • └ tp_order_no
  • String
  • 必须
  • 1234567891234567890
  • 订单主单号。当前长度19位,建议25位(预留6位)
item_info ItemInfo 必须 商品数据,例如商品名、类目等
  • └ service_mode
  • String
  • 必须
  • TO_SHOP
  • 服务方式。TO_SHOP:到店;TO_HOME:上门
  • └ item_name
  • String
  • 必须
  • 任意洗3件
  • 商品名称
  • └ category_name
  • String
  • 必须
  • 洗衣
  • 类目名称,类目值咨询对接人
  • └ partner_item_id
  • String
  • 可选
  • 12415
  • 外部商品ID,接入场景咨询对接人
  • └ item_id
  • String
  • 必须
  • 123456789012
  • 商品ID,当前长度12位,建议16位(预留4位)
shop_info ShopInfo 必须 门店信息,例如门店id
  • └ shop_id
  • String
  • 可选
  • 12345678901234567890123456789012
  • 口碑shopId。个别场景接入,如果store_id不适配,再使用这个字段。建议32位
  • └ store_id
  • String
  • 必须
  • 123456789
  • 淘侧店铺id。长度不固定,建议16位
user_info UserInfo [] 必须
  • 最大列表长度:999
  • 预约人信息,列表
    • └ ext_info
    • String
    • 可选
    • {"key":"value"}
    • 用户扩展信息,json结构,内容见具体业务场景的对接文档
    • credentials
    • Credentials
    • 可选
    • 身份证件
    • └ credential_no
    • String
    • 可选
    • 410881xxxxxxxxxxxxxx
    • 证件号
    • └ credential_type
    • String
    • 可选
    • idCard
    • 证件类型。idCard:身份证
    • └ mobile
    • String
    • 必须
    • 123456678901
    • 联系电话
    • └ name
    • String
    • 必须
    • 张先生
    • 用户姓名/昵称
    fulfillment_info FulfillmentInfo 必须 履约信息,例如履约时间、地点等
    • address_info
    • AddressInfo []
    • 可选
    • 地址信息
    • └ address_detail
    • String
    • 可选
    • xxxx街道xxx小区xx栋
    • 详细地址(用户填写),可能不会具体到门牌号,依赖用户填写
    • district_list
    • DistrictInfo []
    • 可选
    • 区域id列表,顺序:省、市、区;个别地方第三级为街道
    • └ district_name
    • String
    • 可选
    • 杭州市
    • 区域名称
    • └ district_id
    • String
    • 可选
    • 330100
    • 区域id;菜鸟地址库id
    • └ contact_phone
    • String
    • 可选
    • 13911112222
    • 联系电话
    • └ contact_name
    • String
    • 可选
    • 李先生
    • 联系人名称
    • └ type
    • String
    • 可选
    • DEFAULT
    • 地址类型。DEFAULT:默认类型;OBTAIN:取件地址;GIVE_BACK:送件地址
    • time_option
    • TimeOption
    • 必须
    • 时间信息
    • └ end
    • String
    • 可选
    • 2022-07-10 13:00
    • 结束时间
    • └ start
    • String
    • 必须
    • 2022-07-10 12:00
    • 开始时间
    • └ type
    • String
    • 必须
    • DAY_TIME
    • 时间类型。DAY:yyyy-MM-dd;DAY_TIME:yyyy-MM-dd HH:mm;
    • └ memo
    • String
    • 可选
    • test
    • 用户填写的备注
    • └ quantity
    • Number
    • 可选
    • 1
    • 默认值:1
    • 预约份数
    • └ fulfillment_order_no
    • String
    • 必须
    • 1234567890123456789
    • 履约单号,后续履约驱动识别的唯一标识,对接方需要存储。长度19位

    响应参数

    名称 类型 示例值 描述
    success Boolean true 合作方是否收到请求,true表示收到
    biz_result String fail 业务执行结果,success表示成功,fail表示失败
    biz_error_code String NO_INVENTORY 业务错误码,见对接文档异常码
    biz_error_msg String 商品库存不足,请看看其他商品 业务错误信息
    partner_order_id String 1232480 外部履约单号

    请求示例

    {"item_info":{"category_name":"洗衣","item_id":"123456789012","partner_item_id":"12415","item_name":"任意洗3件","service_mode":"TO_SHOP"},"shop_info":{"store_id":"123456789","shop_id":"12345678901234567890123456789012"},"user_info":[{"credentials":{"credential_type":"idCard","credential_no":"410881xxxxxxxxxxxxxx"},"mobile":"123456678901","name":"张先生","ext_info":"{\"key\":\"value\"}"}],"fulfillment_info":{"address_info":[{"address_detail":"xxxx街道xxx小区xx栋","contact_name":"李先生","district_list":[{"district_name":"杭州市","district_id":"330100"}],"contact_phone":"13911112222","type":"DEFAULT"}],"time_option":{"start":"2022-07-10 12:00","end":"2022-07-10 13:00","type":"DAY_TIME"},"quantity":1,"memo":"test","fulfillment_order_no":"1234567890123456789"},"trade_info":{"real_amount":100,"quantity":2,"total_amount":100,"tp_order_no":"1234567891234567890","tp_sub_order_no":"1234567891234567890"}}

    响应示例

    {
        "success":true,
        "biz_result":"fail",
        "biz_error_code":"NO_INVENTORY",
        "biz_error_msg":"商品库存不足,请看看其他商品",
        "partner_order_id":"1232480"
    }

    验签示例

    {"biz_error_msg":"Illegal request","success":"false","biz_error_code":"sign-check-failure"}

    错误码解释

    错误码 错误描述 解决方案
    response-body-parse-error
    isp.http-read-timeout

    API工具

    FAQ

    返回
    顶部