You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

73 lines
1.6 KiB

meta {
name: 导入公海池
type: http
seq: 6
tags: [
generated
]
}
post {
url: {{baseUrl}}/api/rule/pool/import
body: multipartForm
auth: inherit
}
body:multipart-form {
file: @本地文件
}
docs {
# 导入公海池
`POST /api/rule/pool/import`
导入公海池(Excel 模板批量,逐行独立事务、部分成功;文件级守门失败 64035)。
## 请求参数
| 参数 | 类型 | 必填 | 默认 | 说明 |
| --- | --- | --- | --- | --- |
| file | file | 是 | - | Excel 模板文件(列集与导出闭环) |
## 请求示例
请求头:Authorization: Bearer {{token}}
Content-Type: multipart/form-data
POST /api/rule/pool/import
file=@本地文件
## 响应 data 结构
| 字段 | 类型 | 说明 |
| --- | --- | --- |
| total | int | 处理总数(successCount + failCount) |
| successCount | int | 成功条数 |
| failCount | int | 失败条数 |
| failures | array<object> | 失败明细列表 |
| failures[].rowNo | int | Excel 数据行号(表头为第 1 行,数据从 2 起) |
| failures[].poolName | string | 该行池名称(原样回显,便于定位) |
| failures[].message | string | 失败文案 |
## 响应示例
// 示例数据,字段结构以上表为准,非真实返回
```json
{
"code": 0,
"success": true,
"message": "success",
"data": {
"total": 3,
"successCount": 2,
"failCount": 1,
"failures": [
{
"rowNo": 4,
"poolName": "华东区公海",
"message": "领取规则值非法"
}
]
}
}
```
}