跳到主要内容

采购单创建

Webhookprocurements/create

采购单创建时触发。

需要 product 访问权限。最低支持版本:202007

请求头

    X-Shoplazza-Topicstring

    触发本次推送的事件,例如 orders/create

    示例: orders/create
    X-Shoplazza-Hmac-Sha256string

    请求体的 HMAC-SHA256 签名(base64 编码),使用应用的 Client Secret 生成,用于验证请求来自 Shoplazza

    X-Shoplazza-Shop-Domainstring

    产生该事件的店铺域名

    示例: example.myshoplaza.com
    X-Shoplazza-Api-Versionstring

    序列化 payload 使用的 API 版本

    示例: 2025-06
    X-Shoplazza-Deduplication-IDstring

    本次推送的去重 ID,同一事件重发时保持不变,用于幂等去重

请求体

  • procurement object
    created_atstring

    创建时间

    location_idinteger

    目标仓库 ID

    notestring

    备注

    pending_quantityinteger

    在途数

    procurement_idinteger

    采购单 ID

    procurement_items object[]

    采购单商品

  • Array [
  • expiration_datestring

    有效期

    idinteger

    商品项 ID

    lot_numberstring

    批次号

    pending_quantityinteger

    在途数

    purchase_pricestring

    采购价

    received_quantityinteger

    已收数

    rejected_quantityinteger

    拒绝数

    shipped_quantityinteger

    发货数量

    shipped_received_quantityinteger

    收货数量

    transfer_quantityinteger

    购买数 / 转运数

    variant_idstring

    小商品 UUID

    variant_skustring

    SKU

  • ]
  • procurement_nostring

    采购单编号

    received_quantityinteger

    已收数

    rejected_quantityinteger

    拒绝数

    snstring

    单号

    source_idinteger

    供应商 ID 或仓库 ID

    source_typeinteger

    来源。1 = 供应商 ID,2 = 仓库 ID

    stateinteger

    状态。1 = pending,2 = partial,3 = completed,4 = cancelled

    supplier_namestring

    供应商名称

    transfer_quantityinteger

    购买数 / 转运数

    updated_atstring

    更新时间