检测图片是否含人脸
<pre><code class="language-text">配音-建议字数</code></pre>
<h4>接口URL</h4>
<p>> /api/v1/ai/tool/checkface</p>
<h4>请求方式</h4>
<p>> POST</p>
<h4>请求Query参数</h4>
<table>
<thead>
<tr>
<th>参数名</th>
<th>示例值</th>
<th>参数类型</th>
<th>是否必填</th>
<th>参数描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>cv</td>
<td>1.1.0</td>
<td>String</td>
<td>是</td>
<td>-</td>
</tr>
<tr>
<td>cp</td>
<td>a</td>
<td>String</td>
<td>是</td>
<td>-</td>
</tr>
<tr>
<td>ci</td>
<td>999999</td>
<td>String</td>
<td>是</td>
<td>-</td>
</tr>
</tbody>
</table>
<h4>请求Body参数</h4>
<table>
<thead>
<tr>
<th>参数名</th>
<th>示例值</th>
<th>参数类型</th>
<th>是否必填</th>
<th>参数描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>token</td>
<td>-</td>
<td>string</td>
<td>是</td>
<td>登录令牌</td>
</tr>
<tr>
<td>uid</td>
<td>-</td>
<td>string</td>
<td>是</td>
<td>用户标识</td>
</tr>
<tr>
<td>deviceId</td>
<td>-</td>
<td>string</td>
<td>是</td>
<td>-</td>
</tr>
<tr>
<td>params</td>
<td>-</td>
<td>string</td>
<td>是</td>
<td>数据集</td>
</tr>
</tbody>
</table>
<h4>params参数说明</h4>
<table>
<thead>
<tr>
<th>参数名</th>
<th>示例值</th>
<th>参数类型</th>
<th>是否必填</th>
<th>参数描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>imageUrl</td>
<td>-</td>
<td>string</td>
<td>是</td>
<td>图片链接</td>
</tr>
<tr>
<td>faceCount</td>
<td>-</td>
<td>int</td>
<td>否</td>
<td>需要检测图片中包含的人脸数量,默认为1</td>
</tr>
</tbody>
</table>
<h4>返回参数说明</h4>
<table>
<thead>
<tr>
<th>参数名</th>
<th>示例值</th>
<th>参数类型</th>
<th>是否必填</th>
<th>参数描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>checkState</td>
<td>-</td>
<td>int</td>
<td>-</td>
<td>通过状态,1通过,0未通过</td>
</tr>
<tr>
<td>faceCount</td>
<td>-</td>
<td>int</td>
<td>-</td>
<td>要求的人脸数量</td>
</tr>
<tr>
<td>faceResult</td>
<td>-</td>
<td>int</td>
<td>-</td>
<td>检测出来的人脸数量</td>
</tr>
</tbody>
</table>
<h5>返回示例</h5>
<pre><code>{
&quot;checkState&quot;: 0,
&quot;faceCount&quot;: 1,
&quot;faceResult&quot;: 0
}</code></pre>
<h5>失败返回示例</h5>
<pre><code>{
&quot;code&quot;: 1001,
&quot;reason&quot;: &quot;请求参数错误&quot;,
&quot;extInfo&quot;: null
}</code></pre>