上传尾程派送单号与面单

此接口用于让客户上传自行获取到的尾程派送单号与面单,以便我司在将货物交到尾程派送仓库前,进行换单操作。

为了保证打印质量,请保证

注意:尾程派送面单中不要包含配货单

请求规格说明

请求方式

PUT api/parcels/{processCode}/last-mile

processCode 为我司处理号,请求 url 中不需要花括号({})

请求数据格式

名称 类型 是否必须 描述 示例值
TrackingNumber string 必须 尾程派送单号 92001901755477000000000012
Label Label 必须 尾程派送面单

Label

名称 类型 是否必须 描述 示例值
LabelBase64 string Base64文件 Base64文件与面单URL二者必填一项
LabelUrl string 面单URL 必须为可访问的 HTTP/HTTPS 链接,且需要保证在包裹履约期间均可访问。(如保持3个月有效期)
Base64文件与面单URL二者必填一项
LabelType string 视情况而定 面单类型
目前支持 PDF, PNG, JPG
当传递 LabelBase64 时,此项必填
当传递 LabelUrl 时,系统会根据链接响应请求头中的 Content-Type 判断面单类型。请保证您的面单服务器返回的 Content-Typeapplication/pdf, image/pngimage/jpeg

示例请求

Base64 面单

{
  "TrackingNumber": "92001901755477000000000012",
  "Label": {
    "LabelBase64": "JVBERi0xLjUKJe...",
    "LabelUrl": null,
    "LabelType": "PDF"
  }
}

面单链接

{
  "TrackingNumber": "92001901755477000000000012",
  "Label": {
    "LabelBase64": null,
    "LabelUrl": "https://public-accessible-server.com/92001901755477000000000012",
    "LabelType": null
  }
}

返回数据格式说明

返回数据格式

接口返回的 Data 字段为字符串

返回数据示例

{
  "Data": "Applied",
  "Succeeded": true,
  "Error": null
}