/erp/sc/routing/data/local_inventory/createPurchasePlan{
"operation": {
"method": "POST",
"path": "/erp/sc/routing/data/local_inventory/createPurchasePlan"
},
"protocol": "HTTPS",
"host": "https://openapi.lingxing.com",
"rateLimit": {
"tokenBucketCapacity": 1,
"text": ""
},
"requestExample": {
"remark": "备注",
"custom_fields": [
{
"id": "field_001",
"val": "100",
"character": "CNY"
}
],
"data": [
{
"sid": "1",
"supplier_id": 1,
"sku": "SKU001",
"fnsku": "FNSKU001",
"wid": 1,
"purchaser_id": 1,
"expect_arrive_time": "2021-10-01",
"cg_uid": 0,
"quantity_plan": 100,
"remark": "",
"perm_uid": [
1,
10002
],
"options": {
"is_auto_fill_fnsku": 1,
"is_auto_fill_store": 1
}
}
]
},
"responseExample": {
"code": 0,
"message": "success",
"error_details": [],
"request_id": "D41373ED-AF54-CDF1-1658-B8F86286F209",
"response_time": "2021-11-12 12:37:55",
"data": {
"ppg_sn": "PPG211112001",
"plan_sn": [
"PP211112002"
]
},
"total": 0
}
}| No. | Field | Name | Type | Default | Required | Description |
|---|---|---|---|---|---|---|
| 1 | remark | 计划备注 | string | — | Optional | 计划备注 |
| 2 | custom_fields | 表头自定义字段 | array<object> | — | Optional | 表头自定义字段 |
| 2.1 | id | 自定义字段 ID | string | — | Required | 自定义字段 ID |
| 2.2 | val | 字段值 | string | — | Optional | 字段值 |
| 2.3 | character | 字段额外属性 | string | — | Optional | 字段额外属性,如单位/币种;无则传空字符串 |
| 3 | data | 产品信息 | array<object> | — | Required | 产品信息 |
| 3.1 | sid | 店铺id | string | — | Optional | 店铺id ,对应查询亚马逊店铺列表接口对应字段【sid】 |
| 3.2 | supplier_id | 供应商id | integer | — | Optional | 供应商id |
| 3.3 | sku | sku | string | — | Required | sku |
| 3.4 | fnsku | fnsku | string | — | Optional | fnsku |
| 3.5 | wid | 仓库id | integer | — | Optional | 仓库id |
| 3.6 | purchaser_id | 采购方id | integer | — | Optional | 采购方id |
| 3.7 | expect_arrive_time | 期望到货时间 | string | — | Optional | 期望到货时间,格式:Y-m-d |
| 3.8 | cg_uid | 采购员id | integer | — | Optional | 采购员id |
| 3.9 | quantity_plan | 计划采购量 | integer | — | Required | 计划采购量 |
| 3.10 | remark | 产品备注 | string | — | Optional | 产品备注 |
| 3.11 | perm_uid | 单据负责人 | array<any> | — | Optional | 单据负责人,int数组 |
| 3.12 | options | 可选参数 | object | — | Optional | 可选参数 |
| 3.12.1 | is_auto_fill_fnsku | 是否自动FNSKU | integer | — | Optional | 是否自动FNSKU:【默认0】 0 否,1 是 |
| 3.12.2 | is_auto_fill_store | 是否自动填充店铺 | integer | — | Optional | 是否自动填充店铺:【默认0】 0 否,1 是 |
| No. | Field | Name | Type | Default | Required | Description |
|---|---|---|---|---|---|---|
| 1 | code | 状态码 | integer | 0 | Required | 状态码,0 成功 |
| 2 | message | 响应消息 | string | 操作成功 | Required | 响应消息 |
| 3 | error_details | 错误信息 | array<any> | — | Required | 错误信息 |
| 4 | request_id | 请求链路id | string | 8DFEE1CA-EC9B-F401-5D41-9F95251D5D50 | Required | 请求链路id |
| 5 | response_time | 响应时间 | string | 2021-09-21 15:48:58 | Required | 响应时间 |
| 6 | data | 响应数据 | object | — | Required | 响应数据 |
| 6.1 | plan_sn | 计划编号 | array<any> | ["PP211112002"] | Required | 计划编号 |
| 6.2 | ppg_sn | 计划批次号 | string | PPG211112001 | Required | 计划批次号 |
The 创建待采购的采购计划 API (/erp/sc/routing/data/local_inventory/createPurchasePlan) of 领星ERP is curated by the API asset management module of the Qeasy Cloud data integration platform and kept in sync with 领星ERP version updates.
Qeasy ships with prebuilt adaptation for this API — contact us to start configuring data integration.