GET 获取商品组合详情
GET 查询。query 参数见接口参考。
| 接口编码 | 所需范围 | 后端接口 |
|---|---|---|
production.bundle.detail | production:read | GET /v1/product-bundle/detail(comap-srm) |
请求参数(query)
| 字段 | 类型 | 必填 | 说明 |
|---|---|---|---|
id | integer(int64) | 是 | — |
「必填」仅反映接口规格声明的部分。服务内还有未体现在规格里的校验, 标「—」不等于可以不传;租户在主站配置的字段必填不约束本接口。 详见必填字段的判定与字段清单与自定义字段。
请求示例
curl -X POST https://open.risemap.cn/v1/api/invoke \
-H "Authorization: Bearer <访问令牌>" \
-H "Content-Type: application/json" \
-d '{
"apiCode": "production.bundle.detail",
"query": {
"id": "1961000000000000001"
}
}'
响应 data 字段
| 字段 | 类型 | 必填 | 说明 |
|---|---|---|---|
id | integer(int64) | — | 组合ID |
no | string | — | 组合编号 |
name | string | — | 组合名称 |
recommendAmount | number | — | 建议售价 |
description | string | — | 描述 |
enabled | integer(int32) | — | 启用状态:0禁用,1启用 |
citationNum | integer(int32) | — | 引用次数 |
costTotal | number | — | 成本合计 |
itemCount | integer(int32) | — | 明细数量 |
itemQtyTotal | number | — | 子件件数合计(各子件单套用量之和) |
creatorName | string | — | 创建人名称 |
creatorAvatar | string | — | 创建人头像 |
createTime | string | — | 创建时间 |
categoryId | integer(int64) | — | 物料分类ID |
categoryName | string | — | 物料分类名称 |
brandId | integer(int64) | — | 品牌ID |
brandName | string | — | 品牌名称 |
defaultTaxRate | integer(int32) | — | 默认税率 |
model | string | — | 型号 |
unitId | integer(int64) | — | 单位ID |
unitName | string | — | 单位名称 |
specName | string | — | 规格名称 |
taxIncluded | boolean | — | 是否含税 |
taxInclusiveCostTotal | number | — | 含税成本合计 |
taxInclusiveSaleTotal | number | — | 含税销售合计 |
saleTotal | number | — | 不含税销售合计 |
currentSets | integer(int32) | — | 当前可组套,不适用/未知时为空 |
availableSets | integer(int32) | — | 可用可组套,不适用/未知时为空 |
stockStatus | string | — | 可组套计算状态:NORMAL正常,NOT_APPLICABLE不适用,UNKNOWN未知 |
bottleneckProductId | integer(int64) | — | 瓶颈子件物料ID,无唯一瓶颈时为空 |
bottleneckProductName | string | — | 瓶颈子件名称,无唯一瓶颈时为空 |
stockCalcTime | string | — | 库存折算时刻 |
items27 | PrdGroupRecordVO[] | — | 组合明细列表 |
错误处理
响应统一信封 { code, message, data },code == 200 为成功。以下是本接口可能返回的开放平台层错误:
| 错误码 | 说明 | 可重试 |
|---|---|---|
| 92101 | 访问凭证无效 | 否 |
| 92201 | 接口未登记或已停用 | 否 |
| 92202 | 超出凭证授权范围——本接口需 production:read | 否 |
| 92204 | 绑定员工无此接口的功能权限 | 否 |
| 92203 | 上游服务调用失败 | 是 |
| 92301 | 请求过于频繁 | 是 |
除此之外,comap-srm 自身的业务校验失败会原样透传其业务码与提示
(如字段校验、状态不允许、数据不存在),这类码不在开放平台的号段内,
以响应里的 message 为准。完整的平台层错误码见错误码说明。
← 返回商品组合