创建调拨单
Frequency |
---|
Real time |
请求地址
- API
请求参数
字段 | 类型 | 必填 | 长度 | 示例 | 描述 |
---|---|---|---|---|---|
source_system | String | Y | 20 | LCFC | 数据来源系统 |
transaction_id | String | Y | 64 | Inspur101_Create_Transfer_20240603001 | 幂等号,接⼝保证同⼀幂等号多次调⽤只会创建⼀次单据,并返回相同的响应值 |
source_number | String | Y | 64 | Inspur101_Move_20240603001 | 发起本次调拨的来源单据号 |
biz_scenes | String | Y | 64 | inventoryTransfer | 调拨场景,枚举值值列表为: rtReceipt (RT签收),opoTransfer (OPO调拨), inventoryTransfer (库存转移) |
transfer_type | String | Y | 64 | organization_transfer | 枚举值值列表: organization_transfer(组织调拨), sub_transfer(⼦库转移) |
creator_name | String | Y | 32 | Inspur | 创建单据的来源名称 |
expect_arrive_date | Date | Y | 2024-06-03 | 期望到货⽇期,表明预期的到货时间 | |
source_organization | String | Y | 64 | Inspur101 | 来源组织编码 |
source_sub_organization | String | Y | 64 | INSPUR_CO01 | 来源⼦组织编码 |
target_organization | String | Y | 64 | Inspur102 | ⽬的组织编码 |
target_sub_organization | String | Y | 64 | INSPUR102_CO01 | ⽬的⼦组织编码 |
auto_asn | Integer | N | 0 | 是否⾃动发货: 0⾮⾃动发货, 1⾃动发货 | |
remark | String | N | 64 | 调拨单备注 | 备注信息 |
extends_map | Map | N | 扩展信息 | ||
lines | List<TransferLineCreateDTO> | Y | 调拨⾏信息 |
TransferLineCreateDTO 结构
字段 | 类型 | 父类型 | 必填 | 长度 | 示例 | 描述 |
---|---|---|---|---|---|---|
line_no | String | TransferInventoryCreateDTO | Y | 64 | 1 | ⾏号 |
mpn | String | TransferInventoryCreateDTO | N | 128 | E5-2683V3 | MPNMPN/FixBom两个值⼆选⼀只能传递⼀个 |
fixBom | String | TransferInventoryCreateDTO | N | 128 | 7DH7002QCN-F78M2T1 | FixBomMPN/FixBom两个值⼆选⼀只能传递⼀个 |
quantity | Integer | TransferInventoryCreateDTO | Y | 20 | 调拨数量 | |
extends_map | Map | TransferInventoryCreateDTO | N | 扩展信息 | ||
ship_goods_list | List<ShipGoodsCreateDTO> | TransferInventoryCreateDTO | N | 调拨设备清单 | ||
from_warehouse_location | String | TransferLineCreateDTO | Y | 128 | original | 来源箱区枚举值: original (原箱区), mix (混箱区) |
to_warehouse_location | String | TransferLineCreateDTO | Y | 128 | original | ⽬的箱区枚举值: original (原箱区), mix (混箱区) |
ShipGoodsCreateDTO 结构
字段 | 类型 | 父类型 | 必填 | 长度 | 示例 | 描述 |
---|---|---|---|---|---|---|
sku_type | String | TransferLineCreateDTO | Y | 64 | BOX | 设备类型枚举值列表: BOX (箱包), SN (SN) |
sku_code | String | TransferLineCreateDTO | Y | 64 | CTN-91152845-000838 | 箱包的编码或SN的编码全局唯⼀ |
warehouse_location | String | TransferLineCreateDTO | Y | 128 | original | 箱区枚举值: original (原箱区), mix (混箱区) |
quantity | Integer | TransferLineCreateDTO | Y | 1 | 箱包数量或SN数量: 当SkuType为BOX时表示箱⼦的数量,箱包数量固定为1,当SkuType为SN时表示SN的数量,SN数量固定为1 | |
specification | Integer | TransferLineCreateDTO | N | 20 | 箱包的规格: 当SkuType为BOX时必填,表示⼀箱中有多少个 | |
children | ShipGoodsCreateDTO | ShipGoodsCreateDTO | N | ⼦设备信息 |
响应参数
参数 | 必填 | 类型 | 定义 | 描述 |
---|---|---|---|---|
code | Y | String | 状态码 | "0"代表成功,其他失败可参考返回码 |
msg | N | String | 提示消息 | 非"0"时,会提示错误消息 |
result | N | TransferCreateResultDTO | 数据体 |
TransferCreateResultDTO 结构
字段 | 类型 | 父类型 | 必填 | 长度 | 示例 | 描述 |
---|---|---|---|---|---|---|
transfer_number | String | TransferCreateResultDTO | Y | 128 | TR202406030001 | 调拨单号 |
plan_delivery_order | String | TransferCreateResultDTO | Y | 128 | PDO202406030001 | 计划发货单号 |
atd_number | String | TransferCreateResultDTO | N | 128 | ATD20240603001 | 实际发货单号: 当参数中auto_asn=1时,该值有返回 |
请求示例
json
{
"batch_id": "90397",
"batch_size": 1,
"seq_id": "1",
"seq_size": 1,
"data": [
{
"source_system": "LCFC",
"transaction_id": "Inspur101_Create_Transfer_20240603001",
"source_number": "Inspur101_Move_20240603001",
"biz_scenes": "inventoryTransfer",
"transfer_type": "organization_transfer",
"creator_name": "Inspur",
"expect_arrive_date": "2024-06-03",
"source_organization": "Inspur101",
"source_sub_organization": "Inspur101_CO01",
"target_organization": "Inspur102",
"target_sub_organization": "Inspur102_CO01",
"auto_asn": 1,
"remark": "调拨单备注",
"extends_map": {},
"lines": [
{
"line_no": "1",
"mpn": "8163A",
"fixBom": "7DH7002QCN-F78M2T1",
"quantity": "20",
"extends_map": {},
"from_warehouse_location": "original",
"to_warehouse_location": "original",
"ship_goods_list": [
{
"sku_type": "BOX",
"sku_code": "IMAFQ0001",
"quantity": 1,
"warehouse_location": "original",
"specification": 10
},
{
"sku_type": "BOX",
"sku_code": "IMAFQ0002",
"quantity": 1,
"warehouse_location": "original",
"specification": 10
}]
},
{
"line_no": "2",
"mpn": "8164B",
"quantity": "3",
"from_warehouse_location": "mix",
"to_warehouse_location": "mix",
"ship_goods_list": [{
"sku_type": "BOX",
"sku_code": "MIX20240810001",
"quantity": 3,
"warehouse_location": "mix",
"children": [{
"sku_type": "SN",
"sku_code": "SN001",
"warehouse_location": "mix",
"quantity": 1
}, {
"sku_type": "SN",
"sku_code": "SN002",
"warehouse_location": "mix",
"quantity": 1
}, {
"sku_type": "SN",
"sku_code": "SN003",
"warehouse_location": "mix",
"quantity": 1
}]
}]
},
{
"line_no": "3",
"mpn": "8164B",
"quantity": "2",
"from_warehouse_location": "original",
"to_warehouse_location": "mix",
"ship_goods_list": [{
"sku_type": "BOX",
"sku_code": "IMAFQ0003",
"quantity": 2,
"warehouse_location": "original",
"children": [{
"sku_type": "SN",
"sku_code": "SN004",
"warehouse_location": "mix",
"quantity": 1
}, {
"sku_type": "SN",
"sku_code": "SN005",
"warehouse_location": "mix",
"quantity": 1
}]
}]
},
{
"line_no": "4",
"mpn": "8164B",
"quantity": "2",
"from_warehouse_location": "mix",
"to_warehouse_location": "original",
"ship_goods_list": [{
"sku_type": "BOX",
"sku_code": "IMAFQ0004",
"quantity": 2,
"warehouse_location": "original",
"children": [{
"sku_type": "SN",
"sku_code": "SN006",
"warehouse_location": "mix",
"quantity": 1
}, {
"sku_type": "SN",
"sku_code": "SN007",
"warehouse_location": "mix",
"quantity": 1
}]
}]
}
]
}
]
}
成功响应示例
json
{
"code":"0",
"msg":"request success",
"result": {
"transfer_number": "TR202406030001",
"plan_delivery_order": "PDO202406030001",
"atd_number": "ATD20240603001"
}
}
异常响应示例
json
{
"code": "-1",
"msg": "system error!"
}