商品添加
<p>商品添加</p>
<h5>简要描述</h5>
<ul>
<li>商品维护,如商品已存在,则修改</li>
</ul>
<h5>请求URL</h5>
<ul>
<li><code>{{host}}/api/open/goods</code></li>
</ul>
<h5>请求方式</h5>
<ul>
<li>post</li>
</ul>
<h5>Header</h5>
<table>
<thead>
<tr>
<th>字段名</th>
<th>示例值</th>
<th>必选</th>
<th>类型</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>apikey</td>
<td>6519827339</td>
<td>是</td>
<td>string</td>
<td>apikey</td>
</tr>
<tr>
<td>timestamp</td>
<td>1724288542</td>
<td>是</td>
<td>string</td>
<td>时间戳</td>
</tr>
<tr>
<td>sign</td>
<td>10484c3264b08c830b8330e02f4e8826</td>
<td>是</td>
<td>string</td>
<td>签名</td>
</tr>
<tr>
<td>accept</td>
<td>application/json</td>
<td>是</td>
<td>string</td>
<td>accept</td>
</tr>
<tr>
<td>content-type</td>
<td>application/json;charset=UTF-8</td>
<td>是</td>
<td>string</td>
<td>content-type</td>
</tr>
<tr>
<td>lang</td>
<td>en-us</td>
<td>是</td>
<td>string</td>
<td>lang</td>
</tr>
</tbody>
</table>
<h5>请求参数示例</h5>
<pre><code>{
&quot;sku_code&quot;: &quot;CB98S878&quot;,
&quot;art_no&quot;: &quot;CB98&quot;,
&quot;cn_name&quot;: &quot;诊断连接线&quot;,
&quot;en_name&quot;: &quot;Diagnostic cable&quot;,
&quot;net_weight&quot;: 0.16,
&quot;cross_weight&quot;: 0.21,
&quot;unit_price&quot;: 5,
&quot;hg_currency_code&quot;: &quot;USD&quot;,
&quot;unit_price_currency_code&quot;: &quot;CNY&quot;,
&quot;material&quot;: &quot;机器&quot;,
&quot;use&quot;: &quot;医用&quot;,
&quot;brand&quot;: &quot;好利友&quot;,
&quot;length&quot;: 10.19,
&quot;width&quot;: 10.25,
&quot;height&quot;: 250.35,
&quot;unit&quot;: &quot;个&quot;,
&quot;hg_cn_name&quot;: &quot;诊断连接线&quot;,
&quot;hg_en_name&quot;: &quot;Diagnostic cable&quot;,
&quot;hg_brand&quot;: &quot;好利友&quot;,
&quot;hg_hs_code&quot;: &quot;8544421900&quot;,
&quot;hg_unit_price&quot;: 5,
&quot;hg_unit_one&quot;: &quot;个&quot;,
&quot;hg_unit_second&quot;: &quot;Kg&quot;,
&quot;hg_transaction_unit&quot;: &quot;个&quot;,
&quot;hg_source_of_goods&quot;: &quot;深圳&quot;,
&quot;hg_country_of_origin&quot;: &quot;中国&quot;,
&quot;hg_declaration_elements&quot;: &quot;诊断连接线|好利友|无品牌&quot;,
&quot;hg_exemption_method&quot;: &quot;一般征免&quot;
}</code></pre>
<h5>请求json字段说明</h5>
<table>
<thead>
<tr>
<th>字段名</th>
<th>必选</th>
<th>类型</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>sku_code</td>
<td>是</td>
<td>string</td>
<td>sku_code</td>
</tr>
<tr>
<td>art_no</td>
<td>否</td>
<td>string</td>
<td>货号</td>
</tr>
<tr>
<td>cn_name</td>
<td>是</td>
<td>string</td>
<td>中文品名</td>
</tr>
<tr>
<td>en_name</td>
<td>是</td>
<td>string</td>
<td>英文品名</td>
</tr>
<tr>
<td>net_weight</td>
<td>是</td>
<td>string</td>
<td>净重</td>
</tr>
<tr>
<td>cross_weight</td>
<td>否</td>
<td>string</td>
<td>毛重</td>
</tr>
<tr>
<td>unit_price</td>
<td>是</td>
<td>string</td>
<td>售价</td>
</tr>
<tr>
<td>unit_price_currency_code</td>
<td>是</td>
<td>string</td>
<td>售价币种</td>
</tr>
<tr>
<td>material</td>
<td>否</td>
<td>string</td>
<td>材质</td>
</tr>
<tr>
<td>use</td>
<td>否</td>
<td>string</td>
<td>用途</td>
</tr>
<tr>
<td>brand</td>
<td>否</td>
<td>string</td>
<td>品牌</td>
</tr>
<tr>
<td>length</td>
<td>否</td>
<td>string</td>
<td>长(cm)</td>
</tr>
<tr>
<td>width</td>
<td>否</td>
<td>string</td>
<td>宽(cm)</td>
</tr>
<tr>
<td>height</td>
<td>否</td>
<td>string</td>
<td>高(cm)</td>
</tr>
<tr>
<td>unit</td>
<td>是</td>
<td>string</td>
<td>单位</td>
</tr>
<tr>
<td>hg_cn_name</td>
<td>否</td>
<td>string</td>
<td>申报中文品名</td>
</tr>
<tr>
<td>hg_en_name</td>
<td>否</td>
<td>string</td>
<td>申报英文品名</td>
</tr>
<tr>
<td>hg_brand</td>
<td>否</td>
<td>string</td>
<td>申报品牌</td>
</tr>
<tr>
<td>hg_hs_code</td>
<td>否</td>
<td>string</td>
<td>申报海关编码</td>
</tr>
<tr>
<td>hg_unit_price</td>
<td>否</td>
<td>string</td>
<td>申报单价</td>
</tr>
<tr>
<td>hg_currency_code</td>
<td>否</td>
<td>string</td>
<td>申报币种</td>
</tr>
<tr>
<td>hg_unit_one</td>
<td>否</td>
<td>string</td>
<td>申报法定第一单位</td>
</tr>
<tr>
<td>hg_unit_second</td>
<td>否</td>
<td>string</td>
<td>申报法定第二单位</td>
</tr>
<tr>
<td>hg_transaction_unit</td>
<td>否</td>
<td>string</td>
<td>申报成交单位</td>
</tr>
<tr>
<td>hg_source_of_goods</td>
<td>否</td>
<td>string</td>
<td>申报货源地</td>
</tr>
<tr>
<td>hg_country_of_origin</td>
<td>否</td>
<td>string</td>
<td>申报目的国</td>
</tr>
<tr>
<td>hg_declaration_elements</td>
<td>否</td>
<td>string</td>
<td>申报要素</td>
</tr>
<tr>
<td>hg_exemption_method</td>
<td>否</td>
<td>string</td>
<td>申报征免方式</td>
</tr>
</tbody>
</table>
<h5>成功返回示例</h5>
<pre><code>{
&quot;code&quot;: 1,
&quot;msg&quot;: &quot;修改成功&quot;,
&quot;time&quot;: 1730452193,
&quot;data&quot;: {
&quot;sku_code&quot;: &quot;CB98S878&quot;
},
&quot;log_id&quot;: &quot;271d62d784b32b5ca6bc169295f1373e&quot;
}</code></pre>
<h5>成功返回示例的参数说明</h5>
<table>
<thead>
<tr>
<th>参数名</th>
<th>类型</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>code</td>
<td>string</td>
<td>1:成功 ,0: 失败</td>
</tr>
<tr>
<td>msg</td>
<td>string</td>
<td>提示信息</td>
</tr>
<tr>
<td>time</td>
<td>string</td>
<td>无</td>
</tr>
<tr>
<td>data.order_no</td>
<td>string</td>
<td>订单订单号</td>
</tr>
<tr>
<td>data.awb_no</td>
<td>string</td>
<td>转单号</td>
</tr>
<tr>
<td>data.reference_no</td>
<td>string</td>
<td>客户单号</td>
</tr>
<tr>
<td>log_id</td>
<td>string</td>
<td>日志ID</td>
</tr>
</tbody>
</table>
<h5>失败返回示例</h5>
<pre><code>{
&quot;code&quot;: 0,
&quot;msg&quot;: &quot;Signature timeout&quot;,
&quot;data&quot;: [],
&quot;track_id&quot;: &quot;2bef4a39c5de410e170db134fbc7e686&quot;
}</code></pre>
<h5>失败返回示例的参数说明</h5>
<table>
<thead>
<tr>
<th>参数名</th>
<th>类型</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td>code</td>
<td>string</td>
<td>1:成功 ,0: 失败</td>
</tr>
<tr>
<td>msg</td>
<td>string</td>
<td>提示信息</td>
</tr>
<tr>
<td>data</td>
<td>array</td>
<td>数据</td>
</tr>
<tr>
<td>track_id</td>
<td>string</td>
<td>日志ID</td>
</tr>
</tbody>
</table>