舆情监测
<p>[TOC]</p>
<h3>接口调用说明</h3>
<ul>
<li>通过企业名称查询企业新闻舆情。</li>
</ul>
<h4>请求方式</h4>
<p>如接口没有单独说明,所有接口均为:<strong>POST</strong></p>
<h4>请求格式</h4>
<p>如接口没有单独说明,所有接口均为:<strong>application/x-www-form-urlencoded</strong></p>
<h4>请求参数</h4>
<p>请求参数包括公共参数和业务参数(业务参数见具体接口说明)
调用接口时,需要把<strong>公共参数</strong>和<strong>业务参数</strong>一并放在<strong>请求参数</strong>中提交</p>
<h5>公共请求参数</h5>
<table>
<thead>
<tr>
<th>名称</th>
<th>类型</th>
<th>必须</th>
<th><div style="width:420px;">说明</div></th>
</tr>
</thead>
<tbody>
<tr>
<td>appId</td>
<td>String</td>
<td>是</td>
<td>服务商分配的唯一标识</td>
</tr>
<tr>
<td>timestamp</td>
<td>Long</td>
<td>是</td>
<td>当前时间戳(毫秒)</td>
</tr>
<tr>
<td>sign</td>
<td>String</td>
<td>是</td>
<td>签名,详见<a href="#签名算法">签名算法说明</a></td>
</tr>
</tbody>
</table>
<p><a name="签名算法"></a></p>
<h5>签名算法说明</h5>
<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 = &quot;xyzxy2121zxyz&quot;;
String timestamp = &quot;1555378976238&quot;;
String appSecret = &quot;efcefcef1121cefcefc1212121&quot;;
String str = appId + appSecret + timestamp;
String sign = sha256(str);</code></pre>
<h4>返回说明</h4>
<h5>公共返回字段说明</h5>
<p>所有接口均返回以下公共字段:</p>
<table>
<thead>
<tr>
<th>字段名</th>
<th><div style="width:420px">说明</div></th>
</tr>
</thead>
<tbody>
<tr>
<td>code</td>
<td>返回码,详见:code返回码说明</td>
</tr>
<tr>
<td>msg</td>
<td>code对应的描述</td>
</tr>
<tr>
<td>charge</td>
<td>计费标志 true为计费,false为不计费</td>
</tr>
<tr>
<td>taskNo</td>
<td>本次请求号</td>
</tr>
<tr>
<td>data</td>
<td>返回具体结果,object类型,详见data返回字段描述</td>
</tr>
</tbody>
</table>
<p><a name="公共code返回码说明"></a></p>
<h5>公共code返回码说明</h5>
<p>所有接口公共返回码如下:</p>
<table>
<thead>
<tr>
<th>code</th>
<th><div style="width:420px;">说明</div></th>
</tr>
</thead>
<tbody>
<tr>
<td>200</td>
<td>成功</td>
</tr>
<tr>
<td>201</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>604</td>
<td>接口停用</td>
</tr>
<tr>
<td>606</td>
<td>调用超限,请稍候再试</td>
</tr>
<tr>
<td>607</td>
<td>ip不在白名单</td>
</tr>
<tr>
<td>609</td>
<td>请求过于频繁,请稍候再试</td>
</tr>
<tr>
<td>610</td>
<td>请求超时</td>
</tr>
<tr>
<td>999</td>
<td>其他,以实际返回为准</td>
</tr>
</tbody>
</table>
<h3>舆情列表</h3>
<h4>接口描述</h4>
<ul>
<li>通过企业名称查询企业新闻舆情。</li>
</ul>
<h4>请求地址</h4>
<p><code>https://api.jumdata.com/public-sentiment/news-list</code></p>
<h4>业务参数</h4>
<table>
<thead>
<tr>
<th>名称</th>
<th>类型</th>
<th>必须</th>
<th><div style="width:400px">说明</div></th>
</tr>
</thead>
<tbody>
<tr>
<td>entName</td>
<td>String</td>
<td>是</td>
<td>企业名称/统一社会信用代码</td>
</tr>
<tr>
<td>pageNo</td>
<td>String</td>
<td>否</td>
<td>分页,默认为1</td>
</tr>
<tr>
<td>pageSize</td>
<td>String</td>
<td>否</td>
<td>每页数量, 最大 100,默认为10</td>
</tr>
<tr>
<td>type</td>
<td>String</td>
<td>否</td>
<td>分类:1001经营状态,1002 业绩向好,1003=业绩风险,1004 破产清算,1005 公示公告,1006 招标投标,1007 考察访问,1008 签约合作,1009 业务落地,1010 投资融资,1011 抵押质押,1012 担保行为,1013 信用事件,1014 荣誉资质,1015 知识产权,1016 高管动态,1017 员工动态,1018 产品服务,1019 产品风险,1020 违法违规,1021 法律纠纷,1022 会议论坛;输入多个分类时用半角分隔符,如:1001; 1002</td>
</tr>
<tr>
<td>queryWord</td>
<td>String</td>
<td>否</td>
<td>查询词,输入queryWord后,企业名称无效</td>
</tr>
<tr>
<td>startTime</td>
<td>String</td>
<td>是</td>
<td>开始时间</td>
</tr>
<tr>
<td>endTime</td>
<td>String</td>
<td>是</td>
<td>结束时间</td>
</tr>
</tbody>
</table>
<h4>成功返回样例</h4>
<pre><code class="language-json">{
&quot;msg&quot;: &quot;成功&quot;,//code对应的描述
&quot;code&quot;: 200,//返回码,详见code返回码说明
&quot;taskNo&quot;: &quot;687882815162227863699691&quot;,//本次唯一请求号
&quot;charge&quot;: true, //计费标志
&quot;data&quot;: {
&quot;page&quot;: {
&quot;pageCount&quot;: 1,//页数
&quot;pageNo&quot;: 1,//当前页号
&quot;pageSize&quot;: 10,//每页记录数
&quot;recordCount&quot;: 9 //记录数
},
&quot;KEYWORD&quot;: [//查询关键词
[
&quot;深圳市华为技术有限公司&quot;
],
[
&quot;华为技术有限公司&quot;
],
[
&quot;Tech Support&quot;,
&quot;华为技术&quot;
]
],
&quot;EVENT&quot;: [//舆情数据集
{
&quot;PUBLISHTIME&quot;: &quot;2023-10-11 19:01:44&quot;,//发布时间
&quot;SOURCE&quot;: &quot;周文凯&quot;,//新闻来源
&quot;ROWKEY&quot;: &quot;2672836025536612670999647&quot;,//关联舆情详情主键
&quot;TITLE&quot;: &quot;乐凯新材:在汽车内外饰领域,公司全资子公司xxxxx&quot;,//新闻标题
&quot;SENTENCE&quot;: &quot;智能座舱部件、发动机轻量化部件和相关模具的研发与制造的高新技术企业,xxxxxxx&quot;,//关键词语句
&quot;TYPE&quot;: [//新闻分类
&quot;1001&quot;
],
&quot;URL&quot;: &quot;http://xxxxx.com/2023-10-11/210531040.html&quot; //新闻网址
}
]
}
}</code></pre>
<h4>失败返回样例</h4>
<pre><code class="language-json">{
&quot;msg&quot;: &quot;结束时间不能为空!&quot;,
&quot;code&quot;: 400,
&quot;charge&quot;: false
}</code></pre>
<h3>查询舆情详情</h3>
<h4>接口描述</h4>
<ul>
<li>通过新闻舆情唯一主键查询企业新闻舆情详情信息。</li>
</ul>
<h4>请求地址</h4>
<p><code>https://api.jumdata.com/public-sentiment/news-detail</code></p>
<h4>业务参数</h4>
<table>
<thead>
<tr>
<th>名称</th>
<th>类型</th>
<th>必须</th>
<th><div style="width:400px">说明</div></th>
</tr>
</thead>
<tbody>
<tr>
<td>rowKey</td>
<td>String</td>
<td>是</td>
<td>企业舆情列表接口返回的rowKey</td>
</tr>
</tbody>
</table>
<h4>成功返回样例</h4>
<pre><code class="language-json">{
&quot;msg&quot;: &quot;成功&quot;,//code对应的描述
&quot;code&quot;: 200,//返回码,详见code返回码说明
&quot;taskNo&quot;: &quot;687882815162227863699691&quot;,//本次唯一请求号
&quot;charge&quot;: true, //计费标志
&quot;data&quot;: {
&quot;PUBLISHTIME&quot;: &quot;2023-10-29 19:44:00&quot;,//发布时间
&quot;SOURCE&quot;: &quot;&quot;,//新闻来源
&quot;TITLE&quot;: &quot;不造车但有大动作!华为受让AITO商标&quot;,//新闻标题
&quot;CONTENT&quot;: &quot;html页面内容&quot;,//新闻内容
&quot;TYPE&quot;: [//新闻分类
&quot;1015&quot;
],
&quot;URL&quot;: &quot;https://xxxx.com/news/126/a1246442.html&quot; //新闻网址
}
}</code></pre>
<h4>失败返回样例</h4>
<pre><code class="language-json">{
&quot;msg&quot;: &quot;查无记录&quot;,
&quot;code&quot;: 201,
&quot;charge&quot;: false
}</code></pre>