Skip to content

需求说明

联想VMI系统负责与国内外3PL进行对接。对接过程中常有一些全量数据的接口,数据量大,在网络不好的情况下,容易丢包,因此本方案是将大批的数据分页发送且需要校验完整性。

1.1 版本记录

版本时间内容变更人
v1.02021-8-23第一版wangdong18
v1.12021-09-28补充链路,补充流程,补充key值lingcq1
V1.22021-10-191. soi_gr, loi_gr 删除asn字段,增加an, anLine字段 2. pull _info 增加字段destStorageLoclingcq1
V1.32021-11-181. pull_info, mo_pull_list 增加route字段 2. pull_info 增加groupId, totalQty字段 3. confirm pull增加destStorageLocation字段 4. 增加发货汇总,发货明细,暂存发货三个apilingcq1
v1.42021-12-091. 添加body.code 代码异常说明 2. 添加支持hgc 3.为每个接口增加source_system, target_system, system_timelingcq1
v1.42021-12-13发货明细添加四个参数送货单号,车牌号,总毛重,总件数lingcq1
v1.52021-12-17purchase_order和item_supplier_all全量逻辑修改,从全量到by工厂全量lingcq1
v1.62022-01-05方案修改lingcq1
v1.72022-01-131. 增加方案说明 2. 修改系统名为VMI/H*****/L*****E 3. confirm data 请求示例修改 4. 增加业务完整的请求示例lingcq1
v1.82022-01-171. 修改确认接口, 增加数据状态faillingcq1
v1.92022-01-21补充链接lingcq1
v1.102022-01-22补充VMI 链接, WSO2 key& tokenlingcq1
v1.112022-02-15外仓和3号GR-H**C发货汇总, 3号暂存发货汇总增加pallet信息, 新接口待开发,后续补充结构lingcq1
v1.122022-02-16外仓和3号GR-H**C发货汇总, 3号暂存发货汇总这两个接口增加逻辑(待定): 1. 一个push_id下的data中的数据只有一个拍号 2. 一个拍的数据必须放在同一个push_id的信号中,也就是一个push_id和一拍等价 3. 理论上一拍数据不会超1000条,该接口不分页。lingcq1
v1.132022-02-173号暂存改为实时接口lingcq1
v1.142022-02-213号暂存改为实时接口, 增加deliveryNo和deliveryLineNo字段lingcq1
v1.152022--02-22更新3号暂存接口url:/specialReceive/H**C/whse_tmp_trd_sum_deliverylingcq1
v1.162022--02-231. 更新确认接口: 确认请求对于fail的情况,增加failList, failReason, data(可以为整条数据,最少为promary key + shipToId),返回增加result.message; 2. balance pull增加字段destStorageLocation,且pullId的定义, H以H开头, LE 以L开头; 3. inventory snapshot, po snapshot, po 频率和时段更新; 4. 整理primary keygaomx5/lingcq1
v1.172022-02-28确认3号暂存接口为实时接口:url:/specialReceive/H**C/whse_tmp_trd_sum_delivery 以及对应的字段lingcq1
v1.182022-03-041. 3号暂存url修改, 字段修改; 2. 增加3号GR和外仓收货汇总接口; 3. 添加PDA扫描的接口 FOR HIK;4.添加WSO2示例lingcq1
v1.192022-03-08报关明细添加供应商代码, 订单号等信息lingcq1
v1.202022-03-233号暂存, 3号GR和外仓收货汇总 接口返回值调整lingcq1
v1.212022-04-07接口调整purchase_order改为purchase_ordergaomx5
v1.222022-04-13PULL_INFO增加saNumber和saLineId字段gaomx5
v0.002022-04-20PULL_MO_INFO增加indicator和remark字段gaomx5
v1.242022-04-221. PULL_MO_INFO增加changeType字段。 2. 3号暂存接口quantity修改为mo+item的总数, palletQty表示这一拍上这一个deliveryNo上的总数lingcq1
v1.252022-05-11增加WSO2 uat(pre-p)环境配置,补充token连接gaomx5
v1.262022-05-16pull_info接口 增加productionOrdId。 如果有值,认为mo bom change, 非mo bom change, 该字段为空(不传). 此外,针对mo bom chang, 在v1.24中提到的pull_mo_info中的changeType取值, 如果mo 创建了mo bom change的manual pull, 则对应的整个mo list都要重新发给3pl, 且字段取值是UPDATE, 非mo bom change取值ADD。lingcq1
v1.272022-05-16增加WSO2 prd环境配置,补充token连接lingcq1
v1.282022-06-06整理文档格式,将扫描相关接口独立到另一个文档lingcq1
v1.292022-06-301. 拓展workshopCode: 1.4节增加workshopCode的描述 ;1.8和1.9增加跟push_id平级的workshop_code; 2. 1.8节增加push_id的要求:客户端生成的全局唯一批量数据ID,LE: LE*; HC BOX: 时间戳; H*** SMT: H*****-SMT** 3. 1.10 PULL_INFO, PULL_MO_INFO增加排程和栈位号相关内容lingcq1
v1.302022-07-22支持LSSC SMT: 1.10 pull_mo_info接口增加prodDesc 和 moQty 2. 1.10 customs接口增加字段dropshipFlag,单独装车单独报关标记, 取值Y/Nlingcq1
v1.312022-07-251.9 简化responselingcq1
v1.322022-09-29pull line 接口增加runFlag:取值产品好年月日run次,9* - NDT, 如RUN1,RUN2lingcq1
v1.332023-01-04mo list接口增加runFlag:取值产品好年月日run次,9* - NDT, 如RUN1,RUN2lingcq1
v1.342023-04-11增加sh2 wso2环境lingcq1
v1.352023-06-14增加urgent pull链路, 3PL可通过此链路发起类似于manual pull的需求, LX VMI 会正常走src-900-dest的库存移动lingcq1
v1.362023-07-28修改urgent pull,改为异步确认lingcq1
v1.372023-12-13补充并修改WSO2环境及对应S4环境gaomx5

1.2 接入流程

WSO2接入的示例,联系VMI IT进行咨询。

mermaid
sequenceDiagram
Partner->>WSO2: 获取Token
WSO2-->>Partner: 返回Token
Partner->>WSO2: 请求API
WSO2->>VMI: 请求API
VMI-->>WSO2:返回结果
WSO2-->>Partner:返回结果

1.3 方案说明

方案一:【推荐方案】 按批分页发送 , 只要保证每页正常发送,无需异步确认。

方案二: 按批分页发送 + 异步确认

根据上述得方案,三方(Lenovo VMI, 海晨,联晟) 都需要提供一个发送数据的接口和一个确认数据的接口。发送数据接口用于接收对方发送过来的数据。确认数据的接口是对方对已发送数据的确认。确认成功后方可进行后续处理。Lenovo vmi重发数据,会启用一个新的push_id推送数据。同时也要求海晨和联晟,重发数据,必须使用一个新的唯一的push_id.该方案不包含3号暂存发货, 3号GR收货,外仓收货接口, pda扫描接口。3号暂存发货, 3号GR收货,外仓收货接口, pda扫描接口接口等多要求实时性,做成实时接口,放在另外的文档。

1.4 公共参数说明

参数位置参数名称描述示例
pathbiz_key下发给客户端的biz_key如: item_supplier_all
headersign通过下发给用户的secret_key,对body进行签名的结果详见签名文档,使用WSO2,暂时不启用
bodysource_systemYstring
bodytarget_systemYstring
bodysystem_timeYstring,请求的当前时间, 如2021-12-09 11:00:00
bodyworkshop_code业务标识, 南方厂BOX: LSSC; 南方厂SMT: LSSC-SMT, 不填则默认为LSSCLSSC-SMT

1.5 请求限制

  • RequestBody的JSON内容的总条数不得超过1000条,即单页中的数据量不大于1000条。1000条非固定,上线前可根据压测进行调整。 如果一个push_id的总条数大于1000条,则需要分页推送。

1.6 公共返回说明

参数位置参数名称是否必填/不为空参数类型参数格式描述示例
responsecodeYstring---状态码"0"代表接口是成功还是失败,不起业务判断作用
responsemsgNstring---提示消息提示信息

1.7 返回码说明(更多code见具体接口)

参数位置Value描述
httpcode200正常返回结果
httpcode401Token错误/签名错误
body.code"0"成功
body.code"-1"系统异常

1.8 发送数据接口Push data

Description: 对于同一时间,并发量较大的数据,需要压缩为同一个push_id进行发送,否则会影响后续的工作流程. Sender如果发完一个push_id数据,则可以等待Receiver来confirm。

Method:POST

ContentType: application/json

请求说明

参数位置参数名称是否必填/不为空参数类型参数格式描述示例
bodypush_idYstring---客户端生成的全局唯一批量数据ID,LE: LE*; HC BOX: 时间戳; HC SMT: H**C-SMT*---
bodyworkshop_codeNstring业务标识, 南方厂BOX: LSSC; 南方厂SMT: LSSC-SMT, 不填则默认为LSSC
bodytotal_sizeYnumber---push_id要发送的总数据量,如果分页,这个total_size 要保证在不同页都一样,Sender要保证---
bodycurrent_pageYnumber当前页
bodycurrent_page_sizeYnumber当前页的page size, 理论上应该是保证数据大小与data size一致, Sender要保证
bodydataYarray---要push到Receiver的数据---
接口请求示例
json
第一次push data, total_size是2, 当前第一页,当前页1条数据
{
  "push_id": "11111",
  "workshop_code":"workshop code",
  "source_system": "VMI",
  "target_system": "source system", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "data": [
    {
      "pull1": "ABCD001"
    }
  ]
}

第二次push data, total_size是2, 当前第二页,当前页1条数据
{
  "push_id": "11111",
  "workshop_code":"workshop code",
  "source_system": "VMI",
  "target_system": "source system", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 2,
  "current_page_size": 1,
  "data": [
    {
      "pull2": "ABCD001"
    }
  ]
}
接口返回示例
json
正常返回code=0才能认为这一页是成功发到Receiver
{
    "code":"0",
    "msg":"success"
}

{
    "code":"-1",
    "msg":"exception for what"
}

1.9 确认数据接口Confirm data - 异步确认(方案二才需要看)

Description: 当对于一个push_id, Receiver收集到了达到总数的数据后,需要给Sender一个confirm的信号。只有confirm这个信号本身达到双方系统,才认为这个push结束。

请求说明
参数位置参数名称是否必填/不为空参数类型参数格式描述示例
bodypush_idYstring---客户端生成的全局唯一批量数据ID---
bodyworkshop_codeNstring业务标识, 南方厂BOX: LSSC; 南方厂SMT: LSSC-SMT, 不填则默认为LSSC
bodyresult.statusYstring取值只能是success/fail
bodyresult.messageNstring用于返回失败的原因描述,是一个总的失败原因
bodyresult.failListNarray用于返回失败的行对象及错误信息
bodyresult.failList.failReasonNstring用于返回失败行的错误信息
bodyresult.failList.dataNobject用于返回失败行的对象, 对应的不同的api, 是不同的对象。
json
确认成功示例
{
"push_id": "11111",
"workshop_code":"workshop code",
"source_system": "VMI",
"target_system": "source system", 
"system_time":"2020-11-20 14:00:00",
"result":{
   "status": "success",
   "message":"success" 
	}
}

确认失败示例
{
"push_id": "wwww",
"workshop_code":"workshop code",
"source_system": "VMI",
"target_system": "source system", 
"system_time":"2020-11-20 14:00:00",
"result":{
   "status": "fail",
   "message":"fail reason",
   "failList":[{"failReason":"fail reason", "data":{//可以整条数据返回,也可以只返回primary key + 工厂 }}]
	}
}
接口返回参数
参数位置参数名称是否必填/不为空参数类型参数格式描述示例
bodyresult.statusYstring确认之后数据的最终状态。接收方带着确认信息(成功或者失败)过来。发送方自身也可能维护着超时和失败的状态,此时这个返回值应该是发送方根据接收方的信息和自身维护的信息,综合给出这条数据最终的状态。 如果发送方自身维护的状态是超时和失败,则忽略接收方发过来的信息,返回该条数据的最终状态为超时或者失败。如果发送自身没有维护信息,则以接收方发过来的信息为准,给出最终状态为接收方确认的状态。 取值只能是success/timeout/in_process/fail
bodyresult.messageNstring用于返回失败的原因描述
接口返回示例
json
成功确认且数据状态是成功 code = 0 && result.status = 'success', 双方认为数据有效
{
    "code":0,
    "msg": "success",
    "result":{
        "status":"success",
        "message":"ok"
    }
}
    
失败确认1, code != "0",系统异常,需要继续confirm, 建议定时重复确认(每分钟重复确认,超过20分钟的,可以不用确认了)
{
    "code":-1,
    "msg": "exception/in_process"
}

失败确认2 code = '0' && status = 'fail',这种情况数据作废,不需要继续confirm了, status= fail的原因, 可能是对方确认的fail, 也可能是超时
{
    "code":0,
    "msg": "success"
    "result":{
        "status":"fail",
    	"message":"fail/timeout"
    }
}
数据防重复操作机制和频率
数据操作机制频率
SOI_GR增量,多个相同Primary Key数据视为重复,只取一条
LOI_GR增量,多个相同Primary Key数据视为重复,只取一条
MO_PREKITTING_FINISH增量,多个相同Primary Key数据视为重复,只取一条
CONFIRM_PULL增量,多个相同Primary Key数据视为重复,只取一条
DISPATCH_PULL增量,多个相同Primary Key数据视为重复,只取一条
BALANCE_PULL增量,多个相同Primary Key数据视为重复,只取一条
INVENTORY_SNAPSHOT增量,多个相同Primary Key数据视为重复,只取一条H*****/ L*****E:一天一次, 凌晨2点做快照, by工厂发
PO_SNAPSHOT增量,多个相同Primary Key数据视为重复,只取一条H*****/L*****E: 一天一次, 凌晨2点做快照,全量发
CUSTOMS_DELIVERY_DETAIL增量,多个相同Primary Key数据视为重复,只取一条
PURCHASE_ORDER全量,取完一批数据后,区别出工厂后删除表内对应工厂数据再插入2小时一次
ITEM_SUPPLIER_ALL全量,取完一批数据后,区别出工厂后删除表内对应工厂数据再插入
ITEM_SUPPLIER增量,根据PrimaryKey进行update or insert
PULL_INFO增量,多个相同Primary Key数据视为重复,只取一条
PULL_MO_LIST增量,多个相同Primary Key数据视为重复,只取一条

1.10 业务数据 data 部分说明

SOI_GR data部分说明
参数名称参数类型数据库type描述Primary key是否必填/不为空
tplReceiptIdstringVARCHAR2(20)3PL receipt id,Y
supplierIdstringVARCHAR2(10)Supplier id
shipToIdstringVARCHAR2(4)Logical plant
receiptDatestringDateReceipt date, yyyy-MM-dd HH:mm:ss
tplReceiptLineIdstringVARCHAR2(20)3PL receipt line idY
itemIdstringVARCHAR2(18)Item id
destBinstringVARCHAR2(40)Destination bin
destTypestringVARCHAR2(40)Destination type
destStorageLocationstringVARCHAR2(40)Destination storage location
quantitynumberNUMBER(13,3)Quantity
holdTypestringCHAR(1)Q或者S , 如果为空字符串,表示没有hold
holdQuantitynumberNUMBER(13,3)Hold quantity
houseAirWayBillstringVARCHAR2(32)House Airway Bill
purchaseOrderIdstringVARCHAR2(10)Empty for now
purchaseOrderLineIdstringVARCHAR2(10)Empty for now
dnNumberstringVARCHAR2(26)Delivery Notes on Packing info
anstringVARCHAR2(10)arrival notice
anLinestringVARCHAR2(5)arrival notice line
dataTypestringVARCHAR2(20)dt1
json
{
  "push_id": "11111",
  "source_system": "source system",
  "target_system": "VMI", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "workshop_code": "workshop code",
   "data": [
    {
      "tplReceiptId": "receipt1",
      "supplierId": "supplier1",
      "shipToId": "111",
      "receiptDate": "2020-11-20 14:00:00",
      "tplReceiptLineId": "line1",
      "itemId": "item1",
      "destBin": "VENDOR",
      "destType": "222",
      "destStorageLocation": "CCCDDD",
      "quantity": 111,
      "holdType": "Q",
	 "holdQuantity":0,
	 "houseAirWaybill":"123456789",
	 "purchaseOrderId": "",
	 "purchaseOrderLineId":"",
	  "dnNumber":"dn1",
      "an": "1234567896",
      "anLine": "1234567896",
      "dataType": "dt1"
    }
  ]
}
LOI_GR data部分说明
参数名称参数类型数据库type描述Primary Key是否必填/不为空
tplReceiptIdstringVARCHAR2(20)3PL receipt idY
supplierIdstringVARCHAR2(10)Supplier id
shipToIdstringVARCHAR2(4)Logical plant
receiptDatestringDATEReceipt date,yyyy-MM-dd HH:mm:ss
invoiceNumberstringVARCHAR2(16)Invoice number
tplReceiptLineIdstringVARCHAR2(20)3PL receipt line idY
itemIdstringVARCHAR2(18)Item id
destBinstringVARCHAR2(40)Destination bin
destTypestringVARCHAR2(40)Destination type
destStorageLocationstringVARCHAR2(40)Destination storage location
quantitynumberNUMBER(13,3)Quantity
holdTypestringCHAR(1)Q或者S , 如果为空字符串,表示没有hold
holdQuantitynumberNUMBER(13,3)Hold quantity
houseAirWayBillstringVARCHAR2(32)House Airway Bill
purchaseOrderIdstringVARCHAR2(10)Purchase Order (or Sales Agreement) Number
purchaseOrderLineIdstringVARCHAR2(5)Purchase Order Line (or Sales Agreement Line) Number
dnNumberstringVARCHAR2(26)Delivery Notes on Packing info.
anstringVARCHAR2(10)arrival notice
anLinestringVARCHAR2(5)arrival notice line
dataTypestringVARCHAR2(20)LOIGR
json
{
  "push_id": "11111",
   "workshop_code": "workshop code",
  "source_system": "source system",
  "target_system": "VMI", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "data": [
    {
      "tplReceiptId": "receipt1",
      "supplierId": "supplier1",
      "shipToId": "A**",
      "receiptDate": "2020-11-20 14:00:00",
	  "invoiceNumber": "9953090187",
      "tplReceiptLineId": "line1",
      "itemId": "item1",
      "destBin": "VENDOR",
      "destType": "222",
      "destStorageLocation": "CCCDDD",
      "quantity": 1440,
      "holdType": "Q",
	 "holdQuantity":0,
	 "houseAirWaybill":"123456789",
	 "purchaseOrderId": "",
	 "purchaseOrderLineId":"",
	  "dnNumber":"dn1",
      "an": "1234567896",
      "anLine": "1234567896",
      "dataType": "LOIGR"
    }
  ]
}
MO_PREKITTING_FINISH data部分说明
参数名称参数类型数据库type描述Primary Key是否必填/不为空
productionOrdIdstringVARCHAR2(80)mo idY
shipToIdstringVARCHAR2(4)plant
sourceTypestringVARCHAR2(40)pre source type
sourceStorageLocationstringVARCHAR2(40)pre source sloc
sourceBinstringVARCHAR2(40)pre source bin
destTypestringVARCHAR2(20)dest type
destStorageLocationstringVARCHAR2(40)dest location
destBinstringVARCHAR2(40)dest bin
pullQuantitynumberNUMBERpull qty
itemIdstringVARCHAR2(18)material nameY
json
{
  "push_id": "11111",
   "workshop_code": "workshop code",
  "source_system": "source system",
  "target_system": "VMI", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "data": [
    {
      "productionOrdId": "ABCD001",
      "shipToId": "AAA",
      "sourceType": "L21",
      "sourceStorageLocation": "CCCDDD",
	  "sourceBin": "FIS",
      "destType": "W02",
      "destStorageLocation": "MW02",
      "destBin": "KIT",
      "pullQuantity": 2,
      "itemId": "SP10R39102"
    }
  ]
}
CONFIRM_PULL data部分说明
参数名称参数类型数据库type描述Primary Key是否必填/不为空
pullIdStringVARCHAR2(40)Pull header idY
shipToIdStringVARCHAR2(40)Logic plant
destStorageLocationStringVARCHAR2(40)destStorageLocation
destBinStringVARCHAR2(40)Destination bin
destTypeStringVARCHAR2(40)Destination type
pullTypeStringVARCHAR2(40)Pull type
pullLineIdStringVARCHAR2(40)Pull line idY
itemIdStringVARCHAR2(18)Item id
supplierIdStringVARCHAR2(40)Supplier id
sourceStorageLocationStringVARCHAR2(40)Source storage location
sourceBinStringVARCHAR2(40)Source bin
sourceTypeStringVARCHAR2(40)Source type
quantitynumberNUMBERConfirm quantity
dataTypeStringVARCHAR2(40)PullConfirm
json
{
  "push_id": "11111",
   "workshop_code": "workshop code",
  "source_system": "source system",
  "target_system": "VMI", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "workshopCode": "workshop code",
  "data": [
      {
		"pullId": "1489865",
		"shipToId": "AAA",
        "destStorageLocation": "MMMN",
		"destBin": "W09",
		"destType": "W06",
		"pullType": "NORMAL",
		"pullLineId": "line1",
		"itemId": "item1",
		"supplierId": "supplier1",
		"sourceStorageLocation": "CCCDDD",
		"sourceBin": "VENDOR",
		"sourceType": "C51",
		"quantity": 21,
		"dataType": "PullConfirm"
	}
  ]
}
DISPATCH_PULL data部分说明
参数名称参数类型数据库type描述Primary Key是否必填/不为空
pullIdStringVARCHAR2(10)Pull header idY
shipToIdStringVARCHAR2(4)Logic plant
shippedDateStringDATEShipped date
pullLineIdStringVARCHAR2(10)Pull line idY
itemIdStringVARCHAR2(18)Item id
supplierIdStringVARCHAR2(40)Supplier id
sourceStorageLocationStringVARCHAR2(40)Source storage location
sourceBinStringVARCHAR2(40)Source bin
sourceTypeStringVARCHAR2(40)Source type
quantitynumberNUMBERDispatch quantity
dataTypeStringVARCHAR2(40)Dispatch
json
{
  "push_id": "11111",
   "workshop_code": "workshop code",
  "source_system": "source system",
  "target_system": "VMI", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "data": [
      {
		"pullId": "pull1",
		"shipToId": "AAA",
		"shippedDate": "2021-09-11 11:11:11",
		"pullLineId": "line1",
		"itemId": "item1",
		"supplierId": "supplier1",
		"sourceStorageLocation": "CCCDDD",
		"sourceBin": "VENDOR",
		"sourceType": "C51",
		"quantity": 21,
		"dataType": "Dispatch"
	}
  ]
}
BALANCE_PULL data 部分说明
参数名称参数类型数据库type描述Primary Key是否必填/不为空
pullIdStringVARCHAR2(10)Pull header idY
shipToIdStringVARCHAR2(4)Logic plant
shippedDateDATEDATEShip date
destTypeStringVARCHAR2(40)Destination type
destBinStringVARCHAR2(40)Destination bin
pullLineIdStringVARCHAR2(40)Pull line idY
itemIdStringVARCHAR2(40)Item id
supplierIdStringVARCHAR2(40)Supplier id
destStorageLocationStringVARCHAR2(40)用于集货仓IM移动
sourceStorageLocationStringVARCHAR2(40)Source storage loc
sourceBinStringVARCHAR2(40)Source bin
sourceTypeStringVARCHAR2(40)Source type
quantitynumberNUMBERquantity
dataTypeStringVARCHAR2(40)Balance
json
{
  "push_id": "11111",
   "workshop_code": "workshop code",
  "source_system": "source system",
  "target_system": "VMI", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "data": [
      {
		"pullId": "pull1",
		"shipToId": "shopto",
		"shippedDate": "2021-09-11 11:11:11",
		"destType": "A**A",
		"destBin": "FIS",
		"pullLineId": "line1",
		"itemId": "item1",
		"supplierId": "supplier1",
        "destStorageLocation":"sss",
		"sourceStorageLocation": "CCCDDD",
		"sourceBin": "VENDOR",
		"sourceType": "222",
		"quantity": 21,
		"dataType": "Balance"
	}
  ]
}
INVENTORY_SNAPSHOT data 部分说明
参数名称参数类型数据库type描述Primary Key是否必填/不为空
supplierIdStringVARCHAR2(40)Supplier idY
shipToIdStringVARCHAR2(4)Logic plantY
itemIdStringVARCHAR2(18)Item idY
statusStringVARCHAR2(10)StatusY
storageLocationStringVARCHAR2(40)Storage locationY
storageBinStringVARCHAR2(40)Storage binY
storageTypeStringVARCHAR2(40)Storage typeY
quantitynumberNUMBERquantity
dataTypeStringVARCHAR2(40)Inventory
json
{
  "push_id": "11111",
  "workshop_code": "workshop code",
  "source_system": "source system",
  "target_system": "VMI", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "data": [
      {
		"supplierId": "supplier1",
		"shipToId": "shopto",
		"itemId": "item1",
		"status": "A",
		"storageLocation": "CCCDDD",
		"storageBin": "VENDOR",
		"storageType": "A**",
		"quantity": 1,
		"dataType": "Inventory"
	}
  ]
}
PO_SNAPSHOT data部分说明
参数名称参数类型数据库type描述Primary Key是否必填/不为空
purchaseOrderIdStringVARCHAR2(10)Po idY
supplierIdStringVARCHAR2(40)Supplier id
shipToIdStringVARCHAR2(4)Logic plant
createDateDateDATECreate date
startDateDateDATEStart date
endDateDateDATEEnd date
purchaseOrderLineIdStringVARCHAR2(5)Po line idY
itemIdStringVARCHAR2(18)Item id
quantitynumberNUMBERquantity
openQuantitynumberNUMBEROpen quantity
dataTypeStringVARCHAR2(40)POK
json
{
  "push_id": "11111",
   "workshop_code": "workshop code",
  "source_system": "source system",
  "target_system": "VMI", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "data": [
      {
		"purchaseOrderId": "A**A",
		"supplierId": "supplier1",
		"shipToId": "AAA",
        "createDate":"2021-09-01 11:11:11",
        "startDate":"2021-09-01 11:11:11",
        "endDate":"2021-09-01 11:11:11",
		"purchaseOrderLineId": "L10",
		"itemId": "item1",
		"quantity": 1,
		"openQuantity": 1,
		"dataType": "POK"
	}
  ]
}
CUSTOMS_DELIVERY_DETAIL 发货明细 data部分说明
参数名称参数类型数据库type描述Primary Key是否必填/不为空
deliveryNoteNoStringVARCHAR2(18)送货单号Y
deliveryLineNoString
deliveryPlateNumbernumberVARCHAR2(10)车牌号
totalGrossWeightStringNUMBER(18,3)总毛重
totalBoxNumbernumberNUMBER(18,3)总件数
itemIdStringVARCHAR2(18)物料号
quantitynumbernumber数量
pullIdStringVARCHAR2(10)pullheaderidY
pullLineIdStringVARCHAR2(10)pulllineidY
inventoryTypeStringVARCHAR2(10)inventory type SOI或者LOI
sourcePlantStringVARCHAR2(4)起始工厂
sourceLocationStringVARCHAR2(4)起始库存地
destPlantStringVARCHAR2(4)目的工厂
destLocationStringVARCHAR2(4)目的库存地
cooStringVARCHAR2(20)原产地
brandStringVARCHAR2(20)品牌
typeStringVARCHAR2(20)包装种类
dataTypeStringVARCHAR2(40)
supplierCodeStringVARCHAR2(40)供应商代码
orderNoStringVARCHAR2(12)订单编号
orderItemStringVARCHAR2(32)订单行号
fullBoxIndicatorStringVARCHAR2(32)整箱标识,取值是Y或者N
pricenumberNUMBER(18,5)单价
currStringVARCHAR2(10)币制
dropshipFlagstringVARCHAR2(2)单独装车单独报关标记,取值Y/N
json
{
  "push_id": "11111",
  "workshop_code": "workshop code",
  "source_system": "source system",
  "target_system": "VMI", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "data": [
      {
		"deliveryNoteNo":"A**A",
        "deliveryPlateNumber":"A**A",
        "totalGrossWeight":110.00,
        "totalBoxNumber":666,
        "itemId": "A**A",
        "quantity": 1,
		"pullId": "A**A",
		"pullLineId": "A**A",
        "inventoryType":"SOI",
        "sourcePlant": "A**",
		"sourceLocation": "CCCDDD",
        "destPlant": "A**",
		"destLocation": "CCCDDD",
        "coo": "xx",
		"brand": "xx",        
        "type":"candyman",
		"dataType": "CUSTOMS_DELIVERY",
        "route":"CCCDDD_FFFF",
        "supplierCode":"A**",
        "orderNo":"moId",
        "orderItem":"molineid",
        "fullBoxIndicator":"Y",
        "price": 0,
        "curr":"502",
        "dropshipFlag":"Y"
	}
  ]
}
PURCHASE_ORDER data部分说明
参数名称参数类型数据库type描述Primary Key是否必填/不为空
purchaseOrderIdstringVARCHAR2(10)PO IdY
supplierIdstringVARCHAR2(10)Supplier Id
shipToIdstringVARCHAR2(4)Logical plant
purchaseOrderLineIdstringVARCHAR2(5)PO line idY
poTypestringVARCHAR2(40)PO类型
itemIdstringVARCHAR2(18)Material Id
quantitynumberNUMBER(13,3)Quantity
openQuantitynumberNUMBER(13,3)Open quantity
storageLocationstringVARCHAR2(40)Storage location,S4 如果为空,接口可能为空
returnItemstringVARCHAR2(40)Remark return PO
dataTypestringVARCHAR2(20)PO
createDatestringDATECreateDate
startDatestringDATEStartDate
endDatestringDATEEndDate
json
{
  "push_id": "11111",
   "workshop_code": "workshop code",
  "source_system": "VMI",
  "target_system": "source system", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "data": [
      {
      "purchaseOrderId": "A**",
      "supplierId": "A**",
      "shipToId": "A**",
      "purchaseOrderLineId": "A**",
      "poType": "MB",
      "itemId": "A**A",
      "quantity": 111,
      "openQuantity": 22,
      "storageLocation": "MRMN",
      "returnItem": "eeeeeee",
      "dataType": "PO",
      "createDate": "2021-01-01 11:11:11",
      "startDate": "2021-01-01 11:11:11",
      "endDate": "2021-01-01 11:11:11"
	}
  ]
}
ITEM_SUPPLIER_ALL/ITEM_SUPPLIER data部分说明
参数名称参数类型数据库type描述Primary Key是否必填/不为空
supplierIdstringVARCHAR2(40)Supplier IdY
supplierDescstringVARCHAR2(200)Supplier Description
itemIdstringVARCHAR2(18)Material IdY
itemDescstringVARCHAR2(200)Material Description
shipToIdstringVARCHAR2(4)Logical plantY
itemTypestringVARCHAR2(40)Material type, defined by ECC sscode
statusstringVARCHAR2(40)Operation type *
inspectionTypestringVARCHAR2(40)Whether the item needs inspection, IQC检测flag
dataTypestringVARCHAR2(20)ItemSupplier
json
{
  "push_id": "11111",
  "workshop_code": "workshop code",
  "source_system": "VMI",
  "target_system": "source system", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "data": [
      {
		"supplierId": "A**",
		"supplierDesc": "desc",
		"itemId": "A**A",
		"itemDesc": "desc ",
		"shipToId": "A**",
		"itemType": "PU",
		"status": "UPDATE",
		"inspectionType": "Y",
		"dataType": "ItemSupplier"
	}
  ]
}
PULL_INFO data部分说明
参数名称参数类型数据库type描述Primary Key是否必填/不为空
shipToIdStringVARCHAR2(4)Logic plant
productionLineStringVARCHAR2(40)Production line
deliveryDateStringDATEDelivery date (DS upload) XXX
destStorageLocStringVARCHAR2(40)Destination storage location
destTypeStringVARCHAR2(40)Destination type
destBinStringVARCHAR2(40)Destination bin
pullTypeStringVARCHAR2(40)Pull type *
moTypeStringVARCHAR2(40)Demand type *
isSOIStringVARCHAR2(10)CASE WHEN INVENTORY_TYPE='SOI' THEN 'Y' ELSE 'N' END
creationDateStringDATECreation date
pullIdStringVARCHAR2(10)Pull header IDY
pullLineIdStringVARCHAR2(10)Pull line IDY
tplReceiptIdStringVARCHAR2(10)3PL receipt ID
tplReceiptLineIdStringVARCHAR2(10)3PL receipt line ID
sourceTypeStringVARCHAR2(40)Source type
sourceStorageLocationStringVARCHAR2(40)Source storage location
sourceBinStringVARCHAR2(40)Source bin
specialRemarkStringVARCHAR2(40)Nullable
supplierIdStringVARCHAR2(40)Supplier ID
supplierDescStringVARCHAR2(40)Nullable in case of LOI
quantitynumberNUMBERRequest quantity
fullBoxQuantitynumberNUMBERFull box quantity
itemIdStringVARCHAR2(18)Material ID
itemDescStringVARCHAR2(200)Material description
lotNumberStringNUMBER收货批次 有值或空,only for manual
boxIdStringVARCHAR2(40)箱号 有值或空,only for manual
brandStringVARCHAR2(40)品牌 有值或空,only for manual
cooStringVARCHAR2(18)COO 有值或空,only for manual
dateCodeStringVARCHAR2(40)datecode 有值或空,only for manual
urgentStringVARCHAR2(40)加急 有值或空,only for manual
dataTypeStringVARCHAR2(40)Pull
routeStringVARCHAR2(400)字符串,路径
groupIdStringVARCHAR2(20)
totalQtynumbernumber
saNumberStringVARCHAR2(64)
saLineIdStringVARCHAR2(5)
productionOrdIdStringVARCHAR2(20)For BOX, 是MO; for SMT, 是排程号
stackLocationBarCodestringVARCHAR2(20)栈号, SMT 特有, BOX不传这个字段
runFlagstringVARCHAR2(100)forbox,取值举例RUN1,RUN2
json
{
  "push_id": "11111",
  "workshop_code": "workshop code",
  "source_system": "VMI",
  "target_system": "source system", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "workshop_code":"workshop code",
  "data": [
      {
		"shipToId": "111",
		"productionLine": "**",
		"deliveryDate": "2021-01-01 11:11:11",
        "destStorageLoc": "CCCDDD",
		"destType": "W02",
		"destBin": "A**",
		"pullType": "MANUAL",
		"moType": "SO",
		"isSOI": "Y",
		"creationDate": "2021-01-01 11:11:11",
		"pullId": "A**A",
		"pullLineId": "A**A",
		"tplReceiptId ": "111",
		"tplReceiptLineId ": "1",
		"sourceType": "A**",
		"sourceStorageLocation": "CCCDDD",
		"sourceBin": "VENDOR",
		"specialRemark": "1494233 L-121",
		"supplierId": "A**",
		"supplierDesc": "desc",
		"quantity": 1,
		"fullBoxQuantity": 6,
		"itemId": "A**A",
		"itemDesc": "item desc",
		"lotNumber": "xx",
		"boxId": "xx",
		"brand": "xx",
		"coo": "xx",
		"dateCode": "xx",
		"urgent": "xx",
		"dataType": "Pull",
        "route":"CCCDDD_FFFF",
        "groupId":"GROUP1",
        "totalQty":1009,
        "saNumber":"00000000",
        "saLineId":"00010",
        "productionOrdId": "SSSSSSS", -- For BOX, 是MO; for SMT, 是排程号
        "stackLocationBarCode":"0000",  -- 栈号, SMT 特有, BOX不传这个字段
        "runFlag":"RUN1,RUN2",  -- 
	}
  ]
}
PULL_MO_INFO data部分说明
参数名称参数类型数据库type描述Primary Key是否必填/不为空
productionOrdIdStringVARCHAR2(12)For BOX, 是MO; for SMT, 是排程号Y
stackLocationBarCodestringVARCHAR2(20)栈号, SMT 特有, BOX不传这个字段Y- Only for smt
shipToIdStringVARCHAR2(4)plant
bomNameStringVARCHAR2(18)finish goods name
pullIdStringVARCHAR2(10)pull header idY
pullLineIdStringVARCHAR2(10)pull line idY
sourceTypeStringVARCHAR2(40)source type
sourceStorageLocationStringVARCHAR2(40)source sloc
sourceBinStringVARCHAR2(40)source bin
destTypeStringVARCHAR2(40)dest type
destStorageLocationStringVARCHAR2(40)dest sloc
destBinStringVARCHAR2(40)dest bin
pullTypeStringVARCHAR2(40)
inventoryTypeStringVARCHAR2(40)inventory type LOI/SOI
supplierIdStringVARCHAR2(40)soi是vendor号, loi 默认写3PL
headerSupplierIdStringVARCHAR2(40)3pl
pullQuantitynumberNUMBERpull qty
productionLineStringVARCHAR2(40)production line
deliveryDateStringDATEdelivery date by APS
itemIdStringVARCHAR2(18)material name
posnrStringVARCHAR2(4)reservation no in MO bom
routeStringVARCHAR2(400)字符串,路径
indicatorStringVARCHAR2(10)CSC原包装发货,取值是CSC, 其他取值为空(不传该字段)
remarkStringVARCHAR2(250)
changeTypeStringVARCHAR2(10)ADD/UPDATE新增或者更新. 如果发生了mo bom change, 则整个mo list重新发送,取值UPDATE, 否则为ADD
prodDescstringVARCHAR2(120)成品料号描述
moQtynumberNUMBER(11,0)mo qty, 成品数量
runFlagstringVARCHAR2(100)forbox,取值举例RUN1,RUN2
json
{
  "push_id": "11111",
  "workshop_code": "workshop code",
  "source_system": "VMI",
  "target_system": "source system", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "data": [
      {
		"productionOrdId": "ABCD001",
        "stackLocationBarCode":"0001"  -- 栈号, SMT 特有, BOX不传这个字段
		"shipToId": "shopto",
		"bomName": "****",
		"pullId": "****",
		"pullLineId": "****",
		"sourceType": "A**",
		"sourceStorageLocation": "CCCDDD",
		"sourceBin": "VENDOR",
		"destType": "A**",
		"destStorageLocation": "CCCDDD",
		"destBin": "VENDOR",
		"pullType": "NORMAL",
		"inventoryType": "SOI",
		"supplierId": "****",
		"headerSupplierId": "flex",
		"pullQuantity": 2,
		"productionLine": "**",
		"deliveryDate": "2021-01-01 11:11:11",
		"itemId": "A**A",
		"posnr": "1",
        "route":"CCCDDD_FFFF",
        "indicator": "",
        "remark":"",
        "changeType":"ADD"
        "prodDesc":"成品",
         "moQty":10
         "runFlag":"RUN1,RUN2",  -- 
	}
  ]
}
URGENT_PULL data 部分说明
参数名称参数类型数据库type描述Primary Key是否必填/不为空
pullIdStringVARCHAR2(10)Pull header id,必须与H开头,不能与balance pull重复Y
shipToIdStringVARCHAR2(4)
shippedDateDATEDATEShip date
destTypeStringVARCHAR2(40)Destination type
destBinStringVARCHAR2(40)Destination bin
pullLineIdStringVARCHAR2(40)Pull line idY
itemIdStringVARCHAR2(40)Item id
supplierIdStringVARCHAR2(40)Supplier id, 如果是LOI, 请填写3PL, 如果是SOI,请填写供应商id
destStorageLocationStringVARCHAR2(40)用于集货仓IM移动
sourceStorageLocationStringVARCHAR2(40)Source storage loc
sourceBinStringVARCHAR2(40)Source bin
sourceTypeStringVARCHAR2(40)Source type
remarkStringVARCHAR2(4000)数据库限制,不要太长,最长4000
quantitynumberNUMBERquantity
dataTypeStringVARCHAR2(40)Balance
json
{
  "push_id": "11111",
   "workshop_code": "code**",
  "source_system": "source system",
  "target_system": "VMI", 
  "system_time":"2020-11-20 14:00:00",
  "total_size": 2,
  "current_page": 1,
  "current_page_size": 1,
  "mode":"sync", //该接口会由工作流进行异步确认,所以加上这个参数
  "data": [
      {
		"pullId": "pull1",//H开头,且不能与balance pull重复
        "pullLineId": "line1",
		"shipToId": "shopto",
		"shippedDate": "2021-09-11 11:11:11",
        "destStorageLocation":"sss",
		"destType": "A**A",
		"destBin": "FIS",
		"itemId": "item1",
		"supplierId": "3PL",//Supplier id, 如果是LOI, 请填写3PL, 如果是SOI,请填写供应商id
		"sourceStorageLocation": "CCCDDD",
		"sourceBin": "VENDOR",
		"sourceType": "222",
		"quantity": 21,
        "remark":"for what DN",
		"dataType": "URGENT"
	}
  ]
}