版本:202506
创建采购单
POST/openapi/2025-06/procurements
使用提供的详情创建新采购单。
请求
- application/json
- 请求体
- 示例
请求体必填
procurement object必填
采购单
supplier_idstring必填
本次采购的供应商 ID
notestring
关于采购的可选备注或说明
{
"procurement": {
"supplier_id": "string",
"note": "string"
}
}
响应
- 200
OK
- application/json
- 数据结构
- 示例
数据结构
codestring
错误码
messagestring
错误信息
data object
Procurement object
采购单
idstring
采购 ID
procurement_snstring
采购单编号
supplier_idstring
供应商 ID
location_idstring
位置 ID
notestring
备注
stateint32
采购单状态
pending_quantityint32
待处理数量
received_quantityint32
已收货数量
rejected_quantityint32
被拒绝数量
transfer_quantityint32
调拨数量
created_bystring
创建人
created_atstring
创建时间,ISO-8601 格式
updated_atstring
最后更新时间,ISO-8601 格式
{
"code": "string",
"message": "string",
"data": {
"Procurement": {
"id": "string",
"procurement_sn": "string",
"supplier_id": "string",
"location_id": "string",
"note": "string",
"state": 0,
"pending_quantity": 0,
"received_quantity": 0,
"rejected_quantity": 0,
"transfer_quantity": 0,
"created_by": "string",
"created_at": "string",
"updated_at": "string"
}
}
}