Skip to content

Tier1 Inventory 数据

以下接口适用于 通用数据集成

请求地址

  • API
环境URL
测试https://api-cn-t.lenovo.com/uat/v1.0/supply_chain/scc/open_platform/data/sync/t1/inventory
正式https://api-cn.lenovo.com/v1.0/supply_chain/scc/open_platform/data/sync/t1/inventory
  • FTP
环境合作伙伴 文件目录Lenovo 文件目录文件名
测试/Planning/SCC/{appName}/t1/inventory//Planning/SCC/{appName}/t1/inventory/feedback/inventory_{crud}_{yyyyMMddHHmmss}_
正式/Planning/SCC/{appName}/t1/inventory//Planning/SCC/{appName}/t1/inventory/feedback/inventory_{crud}_{yyyyMMddHHmmss}_

示例 :/Planning/SCC/LCFC/t1/inventory/inventory_update_20220928123000_001

频率时间传输方式
Daily or Real time0:00:00Daily version of data (full amount)

频率时间传输方式数据主键
Weekly Monday00:10:00API,FTP,UI(upload)bu + vendor_code + vendor_pn

请求参数

参数key类型必填长度描述示例
uidString32数据行唯一标识,存在按 uid 变更,不存在按 业务 key 变更
buYStringY50枚举值:ThinkNB,IdeaNB,ThinkOption,ThinkDT,IdeaOption,IdeaDT,WS,Smart Device,ISG,Mobile Phone,Mobile TabletThinkNB
vendor_codeYStringY30供应商编码
vendor_nameStringoption500供应商名称,根据 vendor code 联想自己 mapping
vendor_pnYStringY200供应商料号
lenovo_pnStringoption200联想料号
locationStringoption200储位库位
location_descStringoption100储位描述
vendor_qtyIntegerY10供应商库存数量ME-D Cover
vendor_hub_qtyIntegerY10供应商 hub 库存数量1
lenovo_vmi_inventoryInteger10联想vmi库存
poIntegeroption10PO
unrestricted_qtyIntegeroption10Valuated Unrestricted-Use Stock(可用库存)1
inspection_qtyIntegeroption10inspection qty 待检验库存1
block_qtyIntegeroption10锁定库存数量1
open_po_qtyIntegeroption10OPEN PO 数量1
available_to_allocateIntegeroption10可调拨库存数量1
wip_qtyIntegeroption10半成品数量40
versionYStringY8版本号,eg:2021101220211012
ownerStringoption50物料负责人

响应参数

参数类型是否必填描述
codeStringY0 成功其它失败
msgStringY响应具体信息

请求示例

json
{
  "batch_id": "100012",
  "batch_size": 1,
  "seq_id": "1",
  "seq_size": 1,
  "data": [
    {
      "version":"20230315",
      "bu": "ThinkNB",
      "vendor_code": "xxx123",
      "vendor_pn": "ln1234",
      "vendor_hub_qty": 10,
      "po": 123321
    }
  ]
}

响应示例

json
{
  "code": "0",
  "msg": "request success"
}

异常示例

json
{
    "code": "E00V00",
    "msg": "data verification failed!",
    "result": [{
        "row": {
            "bu": "xxxxxxxxxxxx",
            ...
        },
        "verify": [{
            "type": "value length exceed",
            "fields": "bu"
        }]
    }]
}

业务错误码

错误码错误描述解决方案