聚美智数


车辆限行查询

<h2>概述</h2> <p>车辆限行查询接口,包括以下API: <a href="#city">1.获取城市</a> <a href="#get">2. 查询限行</a></p> <h2>Api接入说明</h2> <h3>公用参数</h3> <p>车辆限行查询所有API都需要以下公用参数</p> <table> <thead> <tr> <th>名称</th> <th>类型</th> <th>说明</th> </tr> </thead> <tbody> <tr> <td>appId</td> <td>String</td> <td>服务商分配的唯一标识</td> </tr> <tr> <td>timestamp</td> <td>Long</td> <td>当前时间的毫秒数</td> </tr> <tr> <td>sign</td> <td>String</td> <td>签名,详见签名算法说明</td> </tr> </tbody> </table> <p><a name="sign"></a></p> <h3>签名算法</h3> <pre><code>sign = sha256(appId + appSecret + timestamp)</code></pre> <p>用服务商分配的 <strong>appId</strong>、服务商分配的 <strong>appSecret</strong>,当前时间毫秒数 <strong>timestamp</strong>,按上述顺序拼接成字符串,再进行 <strong>sha256</strong> 哈希得到。如下:</p> <pre><code class="language-java">String appId = "xyzxy2121zxyz"; String timestamp = "1555378976238"; String appSecret = "efcefcef1121cefcefc1212121"; String str = appId + appSecret + timestamp; String sign = sha256(str);</code></pre> <h3>公共code返回码说明</h3> <table> <thead> <tr> <th>code</th> <th>说明</th> </tr> </thead> <tbody> <tr> <td>200</td> <td>成功(计费)</td> </tr> <tr> <td>400</td> <td>参数错误</td> </tr> <tr> <td>404</td> <td>请求地址不正确</td> </tr> <tr> <td>500</td> <td>系统维护,请稍候再试</td> </tr> <tr> <td>601</td> <td>接口未开通</td> </tr> <tr> <td>602</td> <td>账号停用</td> </tr> <tr> <td>603</td> <td>余额不足请充值</td> </tr> <tr> <td>604</td> <td>接口停用</td> </tr> <tr> <td>999</td> <td>其他,以实际返回为准</td> </tr> </tbody> </table> <blockquote> <p>具体API返回码,请见以下具体API说明</p> </blockquote> <p><a name="city"></a></p> <h2>城市</h2> <h3>请求地址</h3> <p><code>https://api.jumdata.com/vehicle/limit/city</code></p> <h3>请求方式</h3> <ul> <li>GET/POST</li> </ul> <h3>参数</h3> <ul> <li>无 <blockquote> <p>注:公共参数必须,详见公共参数说明</p> </blockquote></li> </ul> <h3>正确返回</h3> <pre><code class="language-json">{ "msg": "成功", "code": 200, "taskNo": "09522434433117405247", // 本次请求号 "data": [ { "city": "beijing",//城市代号 "cityname": "北京"//城市名称 }, ... ] }</code></pre> <h3>失败返回</h3> <pre><code class="language-json">{ "msg": "接口地址不正确", "code": 404 }</code></pre> <p><a name="get"></a></p> <h2>限行查询</h2> <h3>请求地址</h3> <p><code>https://api.jumdata.com/vehicle/limit/query</code></p> <h3>请求方式</h3> <ul> <li>GET/POST</li> </ul> <h3>参数</h3> <table> <thead> <tr> <th>名称</th> <th>必须</th> <th>说明</th> </tr> </thead> <tbody> <tr> <td>city</td> <td>是</td> <td>城市代号</td> </tr> <tr> <td>date</td> <td>否</td> <td>默认今天 例如:2022-03-09</td> </tr> </tbody> </table> <blockquote> <p>注:公共参数必须,详见公共参数说明</p> </blockquote> <h3>正确返回</h3> <pre><code class="language-json">{ "msg": "成功", "code": 200, "taskNo": "09522434433117405247", // 本次请求号 "data": { "city": "hangzhou",//城市代号 "cityname": "杭州",//城市名称 "date": "2015-12-03",//日期 "week": "",//星期 "time": [//限行时间 "07:00-09:00", "16:30-18:30" ], "area": "",//限行区域 "summary": "",//限行摘要 "numberrule": "",//尾号规则 "number": ""//限行尾号 } } }</code></pre> <h3>失败返回</h3> <pre><code class="language-json">{ "msg": "参数错误", "code": 400 }</code></pre>

页面列表

ITEM_HTML