3. 餐饮产品规格详情
<h3>获取产品规格详情</h3>
<p>> 请求URL</p>
<p><strong>[post]</strong> <code>{{base_url}}/api/open_service/v1/catering_product/specifications</code></p>
<p>> 接口描述</p>
<p><code>获取产品规格详情接口</code></p>
<p>> 请求参数 header参数</p>
<p><code>请求头参数, 详见请求约定中的鉴权说明.</code></p>
<p>> 请求参数 body参数</p>
<p><code>注意, 此请求参数为json格式. 放置在post请求体中, 以raw格式数据请求</code></p>
<table>
<thead>
<tr>
<th style="text-align: left;">参数名</th>
<th style="text-align: left;">必选</th>
<th style="text-align: left;">类型</th>
<th style="text-align: left;">说明</th>
</tr>
</thead>
<tbody>
<tr>
<td style="text-align: left;">product_type</td>
<td style="text-align: left;">是</td>
<td style="text-align: left;">int</td>
<td style="text-align: left;">固定参数:2</td>
</tr>
<tr>
<td style="text-align: left;">id</td>
<td style="text-align: left;">是</td>
<td style="text-align: left;">int</td>
<td style="text-align: left;">产品id</td>
</tr>
</tbody>
</table>
<p>> 请求示例</p>
<pre><code class="language-json">{&quot;product_type&quot;:2,&quot;id&quot;:525}</code></pre>
<p>> 返回示例</p>
<pre><code class="language-json">{
&quot;code&quot;: 0,
&quot;message&quot;: &quot;成功&quot;,
&quot;data&quot;: {
&quot;id&quot;: 525, // 产品id
&quot;product_type&quot;: 2, // 产品类型 固定值 2:餐饮
&quot;min_buy_num&quot;: 1, // 起订数量
&quot;inventories&quot;: [ // 规格数据
{
&quot;id&quot;: 280, // 规格id
&quot;title&quot;: &quot;111&quot;, // 规格名称
&quot;pictures&quot;: &quot;http://dongli-oss.malldongli.com/upload/default/20230714100528/d08a005e1167926cf8dce9166e359043.jpg?imageMogr2/format/jpg&quot;, // 规格图片
&quot;original_price&quot;: 1.02, // 原价 (单位元)
&quot;current_price&quot;: 1.01, // 现价 (单位元)
&quot;sold_surplus&quot;: 294, // 库存数量
&quot;get_week&quot;: [ // 适用星期 0:周日 1:周一 以此类推
&quot;0&quot;,
&quot;1&quot;,
&quot;2&quot;,
&quot;3&quot;,
&quot;4&quot;,
&quot;5&quot;,
&quot;6&quot;
],
&quot;status&quot;: 0, // 0:下架 1:上架
&quot;validity_argument&quot;: [ // 有效期范围 第一个为开始时间 第二个为截至时间
&quot;2023-07-14 00:00:00&quot;,
&quot;2023-12-31 23:59:59&quot;
]
},
{
&quot;id&quot;: 281,
&quot;title&quot;: &quot;2222&quot;,
&quot;pictures&quot;: &quot;http://dongli-oss.malldongli.com/upload/default/20230714100528/d08a005e1167926cf8dce9166e359043.jpg?imageMogr2/format/jpg&quot;,
&quot;original_price&quot;: 2.22,
&quot;current_price&quot;: 1,
&quot;sold_surplus&quot;: 7,
&quot;get_week&quot;: [
&quot;0&quot;,
&quot;1&quot;,
&quot;2&quot;,
&quot;3&quot;,
&quot;4&quot;,
&quot;5&quot;,
&quot;6&quot;
],
&quot;status&quot;: 0, // 0:下架 1:上架
&quot;validity_argument&quot;: [
&quot;2023-07-14 00:00:00&quot;,
&quot;2023-12-29 23:59:59&quot;
]
}
],
&quot;sale_status&quot;: 0 // 销售状态:0-可销售;1-未开售;2-已下架;3-无库存;
}
}</code></pre>
<p>> 返回参数说明</p>
<table>
<thead>
<tr>
<th style="text-align: left;">参数名</th>
<th style="text-align: left;">类型</th>
<th style="text-align: left;">说明</th>
</tr>
</thead>
<tbody>
<tr>
<td style="text-align: left;">code</td>
<td style="text-align: left;">int</td>
<td style="text-align: left;">0:成功 1:失败 其他:详见约定说明</td>
</tr>
<tr>
<td style="text-align: left;">message</td>
<td style="text-align: left;">string</td>
<td style="text-align: left;">消息内容, 成功/错误提示</td>
</tr>
<tr>
<td style="text-align: left;">data</td>
<td style="text-align: left;">array</td>
<td style="text-align: left;">返回值</td>
</tr>
</tbody>
</table>
<p>> 备注</p>
<p><code>备注</code></p>